eth-igl / gp2024-Assignments

0 stars 0 forks source link

Inverted normals from marching cubes #12

Closed lorissikora closed 6 months ago

lorissikora commented 6 months ago

Hi!

I implemented everything up to Task 2.3 (non-axis-aligned grid) and everything seemed to work quite good. Once I implemented the new grid, suddenly the marching_cubes function started returning faces which all look towards the inside of the mesh. I haven't changed anything in the if (key == '4') block and when comparing before and after changes of the evaluated grid, they look very similar (apart from the orientation ofc). This happens for all models and independent of if the reconstructions has holes or not. Flipping the normals using the dialog box, gives me a similar result to what it looked like before.

If you have any idea what this could be, I would love some assistance!

Best, Loris :)

segaviv commented 6 months ago

Hey,

I believe it could be due to the orientation of the basis you use to construct the non-axis-aligned grid. Try to make sure that the orientation of the new basis is the same as that of the standard basis.

Aviv

lorissikora commented 6 months ago

Aaah yes, thank you! That was it.