Black model when inverting axis
#2
Multiplying x by -1 inverts the orientation of the triangles. 

This would require to invert the orientation of triangles - this could be done by swapping two triangle indices, for example if TriangleIndices are: 0 1 2 2 3 4 (two triangles with positions: first: 0 1 2, second: 2 3 4); to invert triangle orientation just swap two inices: 1 0 2 3 2 4 (first triangle 1 0 2; second: 3 2 4).

An easier option is to assign your material to BackMaterial instead of Material - BackMaterial is used to render back-facing triangles (a standard way to "debug" meshes is to set Material to green DiffuseMaterial and BackMaterial to red DiffuseMaterial - this shows which triangles need to be inverted).
Andrej Benedik
  


Messages In This Thread
Black model when inverting axis - by MSMess - 09-01-2021, 02:22 PM
RE: Black model when inverting axis - by abenedik - 09-01-2021, 04:31 PM
RE: Black model when inverting axis - by MSMess - 09-02-2021, 07:53 AM
RE: Black model when inverting axis - by abenedik - 09-03-2021, 12:07 PM

Forum Jump:


Users browsing this thread:
1 Guest(s)