Hello everyone,
I have a simple script (simpleShader.js) that loads vertex and fragment shader from external assets. It works perfectly and the shader is applied correctly
However, as soon as I try to move the exact same shader code into a single script (inlining both the vertex and fragment shader strings inside my .js
file), it stops working. Instead of the expected effect, the model becomes either black, uniformly colored, or simply doesn’t show the intended animation/pattern.
It is not really a problem that I need to use external fragment and vertex shader but I am just trying to figure out what am i doing wrong ?
here is the exemple i use if you wanna check :