How do I use bokehPass for post-processing? #512
SarahVanDenBerghe
started this conversation in
General
Replies: 1 comment 3 replies
-
you can use effect composer plainly, you dont have to make it declarative. also bokeh, you use it in the same way as in plain three. https://codesandbox.io/s/r3f-instanced-colors-w3lwy the args werent correct though. it takes scene, camera and then params: https://github.com/mrdoob/three.js/blob/dev/examples/jsm/postprocessing/BokehPass.js#L18 |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm trying to add an effect
bokehPass
in order to create a simple depth-of-field as I saw on the Three.js example. But I am failing to implement it properly.I forked an r3f tutorial that is using
effectComposer
with different effects, on line 33 I added thebokehPass
, but it seems to create a weird effect. Link to Code Sandbox here.Now it's all set to 0, but even when changing the numbers it doesn't do much, am I missing something?
<bokehPass attachArray="passes" args={[aspect, 0, 0, 0]} />
Thank you in advance! 😊
Beta Was this translation helpful? Give feedback.
All reactions