I’m trying to combine multiple composers, and haven’t been successful.
In particular, I’m trying to create two separate composers with their own shaders, and to create another composer which combines the results of those shaders.
The user’s webcam is the only object in the scene.
For a dummy example, I’ve created a ‘greenComposer’ and ‘blueComposer’, each of which creates a ShaderPass with the ColorifyShader, colorifying the canvas green or blue - these two composers are initialized with WebGLRenderTargets as target parameters.
The final composer is a blend composer, whose uniform diffuse arrays are set as the textures of the targets sent to the other composers.
Have you tried passing the readbuffer of the composers you want to combine to the textures of the blendShader?
That what worked for me (Although I haven’t used the BlendShader, but a custom one).
It’s part of a bigger engine, but you can see how I do for Polygonjs here:
They should be the same thing, but I had different results when I was passing it. It could be because you may have more controls on how you set it up that way.
Could you make a jsfiddle? It would be easier to try things.