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

VRTheWorld terrain provider broken #7697

Closed
lilleyse opened this issue Apr 1, 2019 · 2 comments · Fixed by #7699
Closed

VRTheWorld terrain provider broken #7697

lilleyse opened this issue Apr 1, 2019 · 2 comments · Fixed by #7699

Comments

@lilleyse
Copy link
Contributor

lilleyse commented Apr 1, 2019

VRTheWorld terrain provider is broken in master but not in 1.55. Git bisect points to b772d52. It probably has something to do with flipY getting set incorrectly for heightmap terrain.

@OmarShehata could you check this out?

vr-the-world

@OmarShehata
Copy link
Contributor

Can confirm it's the image bitmap. If you add:

Cesium.Resource.supportsImageBitmapOptions = function(){
    return Cesium.when.resolve(false);
};

To the beginning of the terrain Sandcastle it works fine. Looking into a fix now.

@OmarShehata
Copy link
Contributor

Ok, I got it. It was peculiar because, what you see there isn't imagery flipped. It's the wrong terrain geometry.

Now why would an upside down image cause it to load the wrong terrain tiles? It's because VRTheWorldTerrainProvider constructs geometry from a heightmap by reading the pixels! The fix is just to make sure flipY: false in the requestTileGeometry function. Opening a PR now.

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

Successfully merging a pull request may close this issue.

2 participants