As you can see, it works good. The opaque objects use the opaque version and the blue energy balls use the transparent version of the shader.
But those blue energy balls should be soft additive particles, and my shader doesn’t produce an additive effect.
I tried to look in the builtin particles shaders but they use SetTexture[_MainTex] to handle the alpha blending and I don’t know how to use that in my shader.
How can I modify the transparent version to have soft additive blending?
I think I’ve successfully converted the Particles/Additive (Soft) shader to its Horizon Bended variant.
I also deleted the fog and the soft particles support (I don’t need it).
thanks buddy !
helped me very much. and served my purpose well.
Much appreciated.
Do you have a Curved Shader on which I can apply color instead of texture ???
Hi, Glad to hear that!
If you want to use a color multiplier you have to add a color property (i.e. _Color) and then multiply each pixel by that color in the fragment shader procedure:
thanks allot !
it really helped me. Last thing if you have a minute.
Objects with alpha blended shader appear above than others. Is there a way I can fix it ?
Thanks allot for your help though. Again
actually yes the issue in the transparent version was that I wanted to bend both axis so it’s more like a sphere but the Additive shader script is bit different and I am not getting how I edit it
Like previously it was ! for only one axis bend
vv = float4(0.0f, (vv.z * vv.z) * -_Curvature, 0.0f, 0.0f);
I changed it to
vv = float4( 0.0f, ((vv.z * vv.z) + (vv.x * vv.x)) * - _Curvature, 0.0f, 0.0f );
but the Additive shader is differently written. I am so sorry if I am disturbing you. Actually I am totally new to shader scripting.
It’s differently written 'cause I’m referring to the last version of the shader, not the first in this thread. It uses a better algorithm to compute the bending.
Actually, I made this shader some months ago and I need some time to make it sphere-bending. Stay tuned, I’ll reply if I’ll succed!
Are you asking how the camera follows the bent path?
If so, I can say the camera doesn’t follow a curved path at all, it always goes straight, like the ball and the other moving objects in the scene. It’s just an effect that renders far surfaces in a different position.