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

back-to-front sort should use occlusion ordering #1

Open
prideout opened this issue Jul 10, 2019 · 1 comment
Open

back-to-front sort should use occlusion ordering #1

prideout opened this issue Jul 10, 2019 · 1 comment

Comments

@prideout
Copy link
Owner

The current "sort by centroids" strategy is not robust, instead we should use a BSP as described in RTR 3rd ed section 14.1. This is what the old-school games like Doom did instead of z-buffering.

See this screenshot for an example of an issue that this will fix (gltf branch).

Screen Shot 2019-07-09 at 8 29 26 PM

@prideout
Copy link
Owner Author

prideout commented Jul 12, 2019

The main problem with a BSP approach is that splitting is inevitable for scenes like this. Splitting might be acceptable for fill-only styles, but we'd like to allow clients to use stroke.

Instead of a BSP, it would be great to use a non-splitting visibility sorting algorithm, such as the one described in Visibility Sorting and Compositing for Image-Based Rendering by Snyder and Lengyel (attached).

VisibilitySorting.pdf
NoSplitting.pdf

@prideout prideout changed the title back-to-front sort should use polygon-aligned BSP back-to-front sort should use occlusion ordering Jul 13, 2019
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

No branches or pull requests

1 participant