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

Frustum experiment #8150

Open
loshjawrence opened this issue Sep 11, 2019 · 2 comments
Open

Frustum experiment #8150

loshjawrence opened this issue Sep 11, 2019 · 2 comments

Comments

@loshjawrence
Copy link
Contributor

loshjawrence commented Sep 11, 2019

For the log depth / multi frustum stuff, here's another idea for frustum/projection. But I guess there are too many things like putting 3dtiles on top of terrain that make this more complicated that what I wrote...

  • Use a projection that maps near far to 1-0 so that all the precision is in the back of the frustum.
  • Do a z-prepass and find min max of the depth buffer to use for a tight near far. See section 4 of http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.360.3911&rep=rep1&type=pdf
  • post process the depth buffer to remap the gl_FragDepth values assuming the tight near far (may have to use a polygon offset in one of the writes to be on the safe side, i.e. push them back a little assuming the next step...)
  • Proceed as normal using the depth buffer to get some early z since its a decent/conservative approx of depth (still write actual depth values).
@OmarShehata
Copy link
Contributor

@loshjawrence if I understand the context here, these are some of your suggestions for fixing a particular bug. If so, can you put these notes in the relevant issue and close this? Otherwise this is just going to get lost.

@loshjawrence
Copy link
Contributor Author

I don't think this should be considered among fixes for the code sprint since it could end up being a considerable amount of work and end up not fixing anything, just something to experiment with in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants