Author Topic: [Solved] Terminator Shading Fix causing shading issues  (Read 3744 times)

2021-02-25, 13:23:36

alexyork

  • Active Users
  • **
  • Posts: 699
  • Partner at Recent Spaces
    • View Profile
    • RECENT SPACES
Hey devs,

We have discovered that the default 0.0 value of the Terminator Shading Fix is actually causing some shading issues to appear on dodgy geometry. Of course the underlying issue is the dodgy geometry, but interestingly setting the TSF to 1.0 (disabling it) removes all these shading artefacts. We are working with some insanely detailed geometry provided to us by clients that we cannot hope to clean up fully, so this "fix" reversal works really well. But of course it means that we then start to get the terminator bug elsewhere in scenes (typically strong sun hitting cushions etc.).

Uploading a max file to show this now using the private uploader - Geometry.max. To test it just stick the value up at 1.0.

Cheers,
« Last Edit: 2023-02-17, 14:48:21 by Aram Avetisyan »
Alex York
Partner
RECENT SPACES
recentspaces.com

2021-02-25, 19:25:32
Reply #1

pokoy

  • Active Users
  • **
  • Posts: 1850
    • View Profile
If the data comes from a CAD app then the mesh has explicit normals, the terminator fix doesn't work well in that situation.

2021-02-25, 19:40:41
Reply #2

romullus

  • Global Moderator
  • Active Users
  • ****
  • Posts: 8779
  • Let's move this topic, shall we?
    • View Profile
    • My Models
Maybe a checkbox "ignore on geometry with explicit normals" somwhere in dev/experimental rollout?
I'm not Corona Team member. Everything i say, is my personal opinion only.
My Models | My Videos | My Pictures

2021-02-26, 15:11:59
Reply #3

alexyork

  • Active Users
  • **
  • Posts: 699
  • Partner at Recent Spaces
    • View Profile
    • RECENT SPACES
Or ideally if Corona worked a bit more intelligently and could apply the fix on objects without explicit normals only?
Alex York
Partner
RECENT SPACES
recentspaces.com

2021-02-26, 15:18:50
Reply #4

pokoy

  • Active Users
  • **
  • Posts: 1850
    • View Profile
Or ideally if Corona worked a bit more intelligently and could apply the fix on objects without explicit normals only?

I asked about this when I first encountered this but the answer was it's either all or nothing, unfortunately.

2021-04-05, 06:55:20
Reply #5

Aram Avetisyan

  • Corona Team
  • Active Users
  • ****
  • Posts: 543
    • View Profile
Hi Alex,

I took a look at the file and here are my investigations. Maybe you will find them helpful. Of course, some of the points mentioned below may had been already tried by you.

• Anything >0.5 for the terminator shadow shift seemed to fix shading artifacts on the model.
• I noticed that the XForm for the model was 1000%. Resetting it and welding vertecies with 0.05mm threshold did fix the problem. Rendered as expected with 0.0 shadow shift.
• There has to be something with the way it was imported/generated/converted in 3ds max, as dashed (hidden) edges are visible in Editable Poly, and for basic shapes, dashed line appear only when retriangulating/turning the edges and then they disappear. For the model you provided, they seemed to not go away/turn invisible in any case (even when converting to Editable Mesh, making some of them visible and some of them not and then converting to Editable poly) and it would be interesting to know how that happened.
• An interesting solution/workaround I found, was turning on NURMS subdivision (just checking it in in Editable Poly) for the model. It does show up bad in the viewport but renders completely fine. Shadow shift is 0.0 in this case as well. If there is a quick/one click solution (like terminator shadow shifting) you are looking for, maybe this can be one.
Aram Avetisyan | chaos-corona.com
Chaos Corona Support Representative | contact us

2021-04-06, 10:12:17
Reply #6

alexyork

  • Active Users
  • **
  • Posts: 699
  • Partner at Recent Spaces
    • View Profile
    • RECENT SPACES
Hi Alex,

I took a look at the file and here are my investigations. Maybe you will find them helpful. Of course, some of the points mentioned below may had been already tried by you.

• Anything >0.5 for the terminator shadow shift seemed to fix shading artifacts on the model.
• I noticed that the XForm for the model was 1000%. Resetting it and welding vertecies with 0.05mm threshold did fix the problem. Rendered as expected with 0.0 shadow shift.
• There has to be something with the way it was imported/generated/converted in 3ds max, as dashed (hidden) edges are visible in Editable Poly, and for basic shapes, dashed line appear only when retriangulating/turning the edges and then they disappear. For the model you provided, they seemed to not go away/turn invisible in any case (even when converting to Editable Mesh, making some of them visible and some of them not and then converting to Editable poly) and it would be interesting to know how that happened.
• An interesting solution/workaround I found, was turning on NURMS subdivision (just checking it in in Editable Poly) for the model. It does show up bad in the viewport but renders completely fine. Shadow shift is 0.0 in this case as well. If there is a quick/one click solution (like terminator shadow shifting) you are looking for, maybe this can be one.

Hey Aram,

This is all super interesting, thank you! I'll pass it on to my team and will let you know our findings too.

Cheers,
Alex York
Partner
RECENT SPACES
recentspaces.com