Pass Variables to Shader

I’m trying to learn shaders. However, I found a problem which I couldn’t find a solution to - passing on variables to the shader.

I’m trying to do this - but I highly doubt this is how it works (in fact it doesn’t :stuck_out_tongue: ):


COLOR : Color

INT : size


And from the main program:

[java]mat.setInt(“size”, 1);[/java]

please read this docs

1 Like

Thanks nehon, I was only looking in the shaders’ page. Got it to work.

Could try this as well…video tutorials just posted today :slight_smile: