Author Topic: Line Renderer Support?  (Read 150 times)

Trey Hayden

  • Guest
Line Renderer Support?
« on: February 23, 2021, 01:51:06 PM »
Hey there!  The new SSRR library seems to have a strange time handling Line Renderers (see below). 



The reflected angle seems to be off and doesn't display properly.  Would like to leave a nice review on the Asset Store, hopeful that this is a quick solution.

Thanks!
-Trey

Kronnect

  • Administrator
  • Hero Member
  • *****
  • Posts: 6869
    • View Profile
Re: Line Renderer Support?
« Reply #1 on: February 24, 2021, 11:51:56 AM »
Hi Trey,

This is a limitation of all SSRR with transparent materials. The workaround is to make the effect render before transparent objects.
Go to Global Settings and change this option:


Screen Space Raytraced Reflection performs a depth-buffer raytracing. Since transparent objects do not write to this buffer, the reflection you see on the floor is actually the line render color on the wall reflected on the ground.

Regards
« Last Edit: February 24, 2021, 12:36:02 PM by Kronnect »

Kronnect

  • Administrator
  • Hero Member
  • *****
  • Posts: 6869
    • View Profile
Re: Line Renderer Support?
« Reply #2 on: February 24, 2021, 01:17:15 PM »
Using a tweaked transparent shader that also renders to depth can also work. Try the attached material/shader.
Note that this is a "trick" and could not be perfect but it could be a workaround for this case.

TreyH

  • Newbie
  • *
  • Posts: 1
    • View Profile
Re: Line Renderer Support?
« Reply #3 on: February 25, 2021, 02:41:15 PM »
Oh I had no idea, reading around and that does seem to be a known limitation.

Thanks for the info and help with workarounds!

Kronnect

  • Administrator
  • Hero Member
  • *****
  • Posts: 6869
    • View Profile
Re: Line Renderer Support?
« Reply #4 on: February 25, 2021, 02:52:59 PM »
Yes, by design, as with any post effect that relies on depth buffer: fog, etc. Anything like that requires special treatment. Usually it's not a big issue or a workaround can be implemented.
We're experimenting with reusing the last frame as an option so anything in the scene could be reflected.

Kronnect

  • Administrator
  • Hero Member
  • *****
  • Posts: 6869
    • View Profile
Re: Line Renderer Support?
« Reply #5 on: February 25, 2021, 03:15:11 PM »