I have a gradient in font shader. And i need to change it in runtime.
Can i change uniforms for shader that i use in text node?
I have a gradient in font shader. And i need to change it in runtime.
Can i change uniforms for shader that i use in text node?
Yes, you add material properties, and add uniforms to your shader.
Then you use
go.set("#sprite", "tint", vmath.vector4(0.1,0.5, 1, 1))
it is gui instance. I can’t use go.set=)
Ok, well, there it makes less sense too, since it’s the same material+shaders for the gui scene, and all objects in it.
However, for generic things like this, I totally agree that it should be possible.
Every font have it own material. I can use different fonts with differents material in one scene.