0

I have a model of the brain that is using the "Outline Only" shader from the UnityWiki. I love the look aside from the opaque patches where the separate shapes overlap. Shown in link below.

Example of what it looks like

enter image description here

I have been looking into occlusion culling to fix this but I am not sure if there is a better method as it doesn't seem to be working for this? Maybe there is a way to manipulate the shader to account for it?

Any tips in the right direction would be awesome! Best, Jen

Fattie
  • 27,874
  • 70
  • 431
  • 719
Sockness_Rogers
  • 1,693
  • 3
  • 12
  • 23
  • What is it you're trying to fix? Looking at the image, do you mean the: **fifteen or so "lighter" areas**? – Fattie Jul 22 '16 at 14:59
  • Yes I am looking at getting rid of the lighter areas and if possible, the larger grey areas too! The ideal look would only consist of the thin outline lines on the outside and front view. I thought culling might be an option to only render whatever side is viewed at that angle but I am not sure how to go about it. – Sockness_Rogers Jul 22 '16 at 15:02
  • I'm not totally sure I understand what you're up to, but, culling is not really relevant here. (Culling is only for performance issues, things like "no need to draw the dinosaurs which are behind a hill" - you know?) So that's half your answer. The other half is, you'd pretty much need someone familiar with that shader to tweak it so it does what you want :/ – Fattie Jul 22 '16 at 15:10
  • Ah that's fair. Thanks for the tip! I just found documentation on Unity about ShaderLab culling and depth testing- I might be able to find something in there! – Sockness_Rogers Jul 22 '16 at 15:16

1 Answers1

0

*Update.

I was able to solve this problem of overlapping shapes by adjusting the culling on the shader. I changed the "Back" pass to Cull Front. Here is the effect.
outline shader effect

Sockness_Rogers
  • 1,693
  • 3
  • 12
  • 23