openframeworks / openframeworks/openFrameworks
ofBox 3dPrimitive winding order inconsistent
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 10.4k
- Forks
- 2.6k
- Avg merge
- 1d 21h
- Merged PRs (30d)
- 9
Description
All primitives but ofBoxPrimitive appear to be in CW winding order, resulting in front faces to be culled instead of backfaces, when glCullFace is enabled.
test case:
https://gist.github.com/tgfrerer/7417271
test case render

related issues
We have dealt with winding isssues in the past, with #2263 being the most recent.
There is a vintage open issue addressing this: #745
thoughts
I could fix/unify this, but i think it's worth discussing which winding order we adopt as standard. I'd personally be for going with the OpenGL standard of CCW for front-facing triangles, which would mean to bring everyting in line with ofBoxPrimitive. my main reason being that these kind of special cases could make oF a bit more difficult to learn / and code harder to port.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the linked gist and compare the winding order of ofBoxPrimitive with the other 3D primitives while glCullFace is enabled. Inspect the primitive implementations and related issue #2263; done requires an agreed standard and consistent front-face culling across the primitives.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- computer-graphics
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100