I try to use dof effectPass but I find that sometimes there are some black stripes exist in the scene, if I remove this post processing then the stripe will go, and there is no light can cast shadow. why these black stripes appear and what should I do to remove them?
#How to remove these black stripe when using depth-of-field effectComposer?
8 messages · Page 1 of 1 (latest)
what does the effectcoposer code look like ?
try adding "frameBufferType":THREE.HalfFloatType into the composer constructor
this looks like NaN propagation - a given pixel is rendered out as a nan and then this value spreads due to blur. Are you using any custom post processing effects?
no other processing effect,I just add a button on the page to determine whether to use it and not all models have this issue, I tried other stage model and looks fine. The confusing part is sometimes those black patches will twinkle even if I didn't control my camera or other thiings in the scene
const bokehParams = {
focus: 1.0,
aperture: 0.00005,
maxblur: 0.01
}
const bokehPass = new BokehPass(scene, camera, bokehParams);
from
https://threejs.org/examples/#webgl_postprocessing_dof
didnt find the type in constructor
Oh you are using the three js composer i thought you were using pmndrs/post-processing when you said effectpass .. Ignore that statement then
Yea that definitelys eems like NaNs... idk too much about the dof field pass to know what would cause it
if possible try pmndrs/postprocessing
use code from here as reference https://github.com/pmndrs/postprocessing/tree/main/manual/assets/js/src/demos