I'm getting a compile error: THREE.WebGLShader: Shader couldn't compile.
I tried to insert some shaders grabbed from shaderfrog.com but they don't seem to compile.
I've used an example file and added my new vertex shader and fragment shader in to the dom.
<script id="vertexShader_new" type="x-shader/x-vertex">
. . .
</script>
material = new THREE.ShaderMaterial({
uniforms: uniforms,
vertexShader: document.getElementById('vertexShader_new').textContent,
fragmentShader: document.getElementById('fragmentShader_new').textContent
});
I've changed the id's back to vertexShader and fragmentShader in the demo to show that the rest of the code is working with a simpler shader.
What's wrong with the shader? Link with the shader: Molten Noise shader