index.js - nodebox - CodeSandbox
I have a transparent cylinder in my original scene, and it’s rendered into a WebGLRenderTarget, I finally sample it, and the atransparency I get is always 1.0, why? How can I get the right a-transparency?
index.js - nodebox - CodeSandbox
With it too not red. Maybe absend call for rendering this.renderPlaneScene
:
if(c.a<1.0){
c = vec4(1.0,0.0,0.0,1.0);
}else{
c = vec4(1.0,0.0,0.0,1.0);
}
this.webGLRenderer = new THREE.WebGLRenderer({ canvas: this.canvas });
to
this.webGLRenderer = new THREE.WebGLRenderer({ canvas: this.canvas,alpha:true });
Thanks, I tried it before, alpha:true, I set the background of the scene to black in my local code, so it has been getting incorrect, now it is okay to remove the background