See outline effect through transparent objects
Description of the bug
Hello @vanruesc ! Thanks again for this awesome library.
I´m trying to create a set of transparent panels in a row, where each one of them has an outline glow effect.
I want to see the outline glow of the back panels through the front panels and control their glow, as they were independent/different layers. I´m only able to see the front panel glow or the sum of both as shown of the SSs below.
To Reproduce
https://codesandbox.io/s/youthful-lichterman-uzwk3?file=/src/App.js
Expected behavior
Would that be possible to achieve with this library or should i go with other approach? Thank you.
Screenshots
Library versions used
- Three: 0.124.0
- Post Processing: 6.21.5
Desktop
- OS: MacOS
- Browser Chrome v94
- Graphics hardware: Radeon Pro 555X 4 GB
Hi,
Would that be possible to achieve with this library
no, the OutlineEffect doesn't currently support this use case. Outlines are detected based on depth, so when an object covers another object, the depth of the occluded object will be overwritten.
The planned changes for v7 will allow us to render an object ID buffer that maps objects to unique colors. This information could then be used to support separate outlines for individual objects.
Let's keep this issue open as a feature request.