Page MenuHome

Mirroed Collection Intances have flipped normals/face orientation.
Closed, ResolvedPublic


System Information
Operating system: Windows-10-10.0.17763 64 Bits
Graphics card: GeForce GTX 1060 6GB/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 430.39

Blender Version
Broken: version: 2.80 (sub 60), branch: blender2.7, commit date: 2019-05-07 19:17, hash: 3dc9da3a74ee
Worked: version: 2.80 (sub 60), branch: blender2.7, commit date: 2019-05-03 21:09, hash: ee0d8426ab6d

Short description of error
Mirroed collections instances have flipped normals in 3D viewport.
Screenshot of viewport with face orientation turned on.
Blue cube is the original mesh in a collection. Red cube is the collection instance mirroed in the X axis.

Exact steps for others to reproduce the error

  1. Create collection with any mesh.
  2. Add a Collection Instance of that collection
  3. Use mirror operator with any axis.

Event Timeline

Jeroen Bakker (jbakker) claimed this task.EditedMay 9 2019, 3:26 PM

According to @Clément Foucault (fclem) correct fix is to use apply the flag OB_NEG_SCALE on dupli if the parent has the flag. and remove it if both are true would be nice to have that done in the depsgraph tho

@Sebastian Parborg (zeddb) yes, I also want a good opinion about it. currently OB_NEG_SCALE (and its draw manager counterpart DRW_CALL_NEGSCALE) only influences the BACK face checking, what is too limmitted. I can see @Clément Foucault (fclem) analysis to be correct. But before we put any change in depsgraph I want to have some guidance on where and how.

My guess would be deg_objects_dupli_iterator_next

We noticed that normals are off due to recent changes. Here I will elaborate what my findings are. More issues I have seen might be related to this.

Scene I used for testing

4 days ago rB21f8e75ddb6b: fix image_changed() doing unneccessary texture updates when texture wasnt using… everything seems correct

Current master rB6b082278d195: UI: expose tool settings in the 3D view side-bar shows normals inverted and mirrored

Somewhere in between I see flipped normals (but not mirrored)

The inverted normals are introduced by rBddb71e8c20c2: DRW: Remove is_negative_m4 per draw call
The mirrored normals are introduced by rB733811330c9b: Workbench: Use common_view_lib and remove NormalMatrix usage

It might be that the mirrored normals was a fix so we need to check this against EEVEE normals in this case.

Broken eevee normals are introduced by rBf2f62b184c67: DRW: Remove WorldNormalMatrix