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

Pass:polygon #769

Open
bjornbytes opened this issue May 8, 2024 · 0 comments
Open

Pass:polygon #769

bjornbytes opened this issue May 8, 2024 · 0 comments
Labels

Comments

@bjornbytes
Copy link
Owner

Should we have Pass:polygon? It's a more convenient way to draw triangles, non-plane quadrilaterals, or maybe the faces of the new convex hull physics shape.

The input points would be directly rendered as a triangle fan, and so the points need to be coplanar and the resulting polygon would need to be simple (i.e. not self-intersecting) and convex. LÖVR could try to do validation or just render it anyway (I lean towards no validation).

The normal vector of the polygon could be computed as the cross product of the 2 direction vectors formed by the first 3 points. I don't think we can compute UVs.

@bjornbytes bjornbytes added the feature yay label May 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant