这是我的代码:
renderTargetParametersRGBA = {
minFilter: THREE.LinearFilter, magFilter: THREE.LinearFilter,
format: THREE.RGBAFormat,stencilBuffer: true
};
colorTarget = new THREE.WebGLRenderTarget(
SCALE * SCREEN_WIDTH, SCALE * SCREEN_HEIGHT, renderTargetParametersRGBA
);
composer = new THREE.EffectComposer(
renderer,colorTarget
);
var renderScene = new THREE.RenderPass(scene,camera);
var effect2 = new THREE.ShaderPass(THREE.ShaderExtras[ "shader1" ]);
composer.addPass(renderScene);
composer.addPass(effect2);
在 renderScene 中,我将场景的 alpha 通道设置为某个值,但在我的 shader1 中,我没有找到 alpha 通道的相同值,似乎 alpha 通道被破坏了。怎么了?
谢谢