NewChromantics / PopMovieTexture_Release

http://popmovie.xyz watermarked releases of PopMovieTexture Unity plugin. Repository itself contains ONLY demo projects, download the .unitypackage from the releases page. Purchase from the asset store https://www.assetstore.unity3d.com/#!/content/59097
https://github.com/NewChromantics/PopMovieTexture_Release/releases/download/v0.1.9.a7c15b5/PopMovieTexture.unitypackage
29 stars 8 forks source link

Finish shader code injection #60

Open SoylentGraham opened 8 years ago

SoylentGraham commented 8 years ago

From some requests, this has been implemented, but needs exposing to c# & more testing.

Allows user to modify decoded RGBA value with glsl/hlsl code before it's written to output texture. (for custom HSL modification, flips, warping etc)

No planned support for variables but maybe allow more robust runtime-modification of the shader code being injected. (Although maybe superfluous as compile time cannot be guaranteed and need to start handling syntax errors)

nickludlam commented 8 years ago

+1 on this. Our project which would make use of this is starting up again, so if there's any beta-testing I can help with then I'm up for it.

SoylentGraham commented 8 years ago

Let me know how you'd want to literally use it. Like for changing gamma/brightness/etc, would you need to change it dynamically with a variable/uniform (eg. if you need to key it to match something else). Or would static code (which you could change once pre-run) be okay? (adding a variable adds a bit of complexity, doable, but then needs a nice reflection interface to change it, and possibly synchronising variables for explicit frames...)

I envisioned using it just as another variable on the inspector which is just a multiline string with a stub function float4 ModifyRgba(float4 rgba,float2 uv) { return rgba; } which people could just change (I have basic HLSL/GLSL/Metal shader conversion built in)