Expose variable from CustomProceduralTexture & console error

Hello guys,

I’m tring to create a simple mix texture that would allow me to animate the opacity with Babylon animation system.

I have created a CustomProceduralTexture but I have no idea how to expose the opacity value or how to setup a watcher with a non object element.

https://www.babylonjs-playground.com/#1XPCZC#18

In bonus I don’t provide a config.json file with the shader as I’m using a ShadersStore and it gives a console error.
Maybe that would be the way to expose some variable from the pixelShader.
I’m using es6 to load everything so I don’t know yet how I can manager to still have the shaders somewhere outside of my packaged files.

Any help appriceated :slight_smile:

Something like that?
https://www.babylonjs-playground.com/#1XPCZC#19

2 Likes

God damn it !

Thank you :slight_smile:

1 Like