Hallo
I am seeking help to write a shader to be used in the GPU particles library.
The shader will take a texture as input and do a lookup for each pixel of the texture.
The data evaluated for each pixel will be:
-
x coordinates pixel wise
-
y coordinates pixel wise
-
value of the pixel’ s color
The shader will output a texture to be applied to the ConstantGPUtransform shader found in the GPU particles library
The construct of the output texture will follow this order:
https://vvvv.org/sites/default/files/imagecache/large/images/Capture_6.PNG
The logic of the shader will be:
-
input texture pixel amount == particles count
-
x coordinates pixel wise → x coordinates of particle >
> scaling may apply -
y coordinates pixel wise → y coordinates of particle >
-
value of the pixel’ s color → z coordinates of particle > scaling may apply
-
if value of the pixel’ s color == 0 then particle’ s size == 0 > threshold may apply (or alpha == 0 or anything that will make the particle invisible)
tx
Simone
EDIT: patch attached
TextureTo3D.zip (21.6 kB)