Cannot get SSAO with R3F to work


I am attempting to get SSAO working with latest R3F. I’ve tried a couple of publically available examples, amongst others, this one: react-three-fiber by example | A collection of examples of using react-three-fiber

I get a lot of Typescript errors about missing properties (21 or so) but they all seem to be non-required, so not really sure what’s going on. I’ve made sure the imports are from the correct libraries, etc.

In other words, I can’t even get the code to compile.

Thankful for any help

Example I’ve tried:

    blendFunction={BlendFunction.MULTIPLY} // Use NORMAL to see the effect

I don’t know TS, React or Fiber have nothing to do otherwise with AO, this is just Threejs and the effect composer. But SSAO is very old and uses an outdated algorithm. prefer N8AO if you can, it is much faster and better looking.

you find the full docs for this effect here GitHub - N8python/n8ao: An efficient and visually pleasing implementation of SSAO with an emphasis on temporal stability and artist control.

Thanks @drcmda, works great!