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

GroundPolylinePrimitive Not Always Culled (renders through globe) #7618

Closed
timoto opened this issue Mar 3, 2019 · 6 comments
Closed

GroundPolylinePrimitive Not Always Culled (renders through globe) #7618

timoto opened this issue Mar 3, 2019 · 6 comments

Comments

@timoto
Copy link

timoto commented Mar 3, 2019

Using Cesium 1.51

GroundPolylinePrimitive is not always culled as expected and renders through globe.

This example has a single GroundPolylinePrimitive that is clamped to terrain elevation tiles and wraps around the globe: https://dev.globaltimoto.com/

path-not-culled

@hpinkos
Copy link
Contributor

hpinkos commented Mar 4, 2019

Thanks for opening this bug report @timoto! Could you put together a small Sandcastle Code Example to reproduce the error? That would be helpful for us.

This might be related to #4746

@timoto
Copy link
Author

timoto commented Mar 8, 2019

Hello @hpinkos

Here is a sandcastle.

@hpinkos
Copy link
Contributor

hpinkos commented Mar 11, 2019

Thanks @timoto! I'm not sure how soon we'll be able to look into this, but we'll give you an update when we have one. Or if you have time to look into a fix, we're more than happy to review a pull request =)

@timoto
Copy link
Author

timoto commented Mar 12, 2019

@hpinkos Thank you for giving this your attention.

I’m sorry but I don’t have the resources to develop a fix myself.

@likangning93
Copy link
Contributor

Line segments on terrain work by drawing a volume into an onscreen polygon, then computing positions on terrain within that onscreen polygon and checking them against a set of 3 planes that slice through the terrain, one for the line width and one for each of the ends. Maybe this culling problem is happening because we aren't bounding the top/bottom of this check, so in some cases the planes slice all the way from one side of the planet to the other.

We could confirm by poking around in PolylineShadowVolumeFS.glsl.

Maybe we can fix this by checking if the position-on-terrain is very far away from one of the volume's positions.

@hpinkos
Copy link
Contributor

hpinkos commented Sep 19, 2019

I'm no longer able to reproduce this. @timoto if you still see this problem please feel free to re-open this issue. Thanks!

@hpinkos hpinkos closed this as completed Sep 19, 2019
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

3 participants