Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update triangulation algorithm #157

Merged
merged 2 commits into from
Oct 16, 2018
Merged

Update triangulation algorithm #157

merged 2 commits into from
Oct 16, 2018

Conversation

lilleyse
Copy link
Contributor

Fixes #147 by updating to the latest triangulation code used in Cesium. This fixes a model that wasn't triangulating correctly in master. This fix required updating Cesium so I updated other dependencies with it.

csxirc5h.i2b.obj

Before and after:
triangulated-incorrect
triangulated-correct

There are still some back facing polygons but I confirmed they are present in the original model too. We don't yet do that sort of correction.

(Backfacing polygons on the steps)
steps

I checked that the new method still triangulates these models correctly:

#33
#50
#79

One thing I'm not completely sure about is whether PolygonPipeline.computeWindingOrder2D is enough to check the winding order. Would it need to use the normal like the 3-sided case?

@lilleyse
Copy link
Contributor Author

@hpinkos
Copy link
Contributor

hpinkos commented Oct 15, 2018

I don't have write access to this repo so I can't merge it, but this looks good to me @lilleyse

@lilleyse
Copy link
Contributor Author

Thanks @hpinkos. I'm going to go ahead and merge.

@lilleyse lilleyse merged commit b781459 into master Oct 16, 2018
@lilleyse lilleyse deleted the fix-triangulation branch October 16, 2018 14:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update projectTo2D function in loadObj
2 participants