How to view shader source code in vtk.js

You can print out the final shader source before it gets compiled by doing a console.log at the bottom of the buildShaders call.

As far as replacing parts of the shader, take a look at the testAddShaderReplacements for an example.

1 Like