Closed 696GrocuttT closed 4 years ago
I've been doing a bit more digging and found something (possibly) interesting. The point at which the line disappears in just above the horizon for v2.6.1 and later. However if I step back to v2.6.0 the point at which it disappears is slightly below the horizon. Not sure if this helps narrow it down, but thought I'd mention it.
Tom
Can you make a video of that?
You can download the video here: https://www.icloud.com/photos/#0WeudgBtncCTe6rG5-6GV1T0Q
Looks like z buffer weirdness. Try setting the kMaplyZBufferRead to false for the addShapes call.
Just tried that, but unfortunately it doesn't fix the problem.
Disabling the Z buffer reads did change the rendering slightly, as the yellow line in now being rendered on top of the red ball (when its below the horizon).
But its still clipping the line when above the horizon.
I've also tried playing around with the drawing priority, but that didn't fix it either.
Are you drawing anything in the background?
So this is probably the shader. By default the globe will use a shader that fixes backface problems on the globe with lines and other random stuff.
You probably want a shader that doesn't do that. If you put kMaplyShader: kMaplyNoBackfaceLineShader in the description dictionary. That might do it.
Adding kMaplyNoBackfaceLineShader fixed it :-)
Thanks for your help!!
I've got an issue with MaplyShapeLinear not displaying properly when its above the horizon. However other shapes behave correctly. EG the code below should display a red ball at the end of a vertical line:
If the view is tilted so everything is below the horizon, everything is displayed correctly and we get the screen shot below:
However if I change the tilt/zoom the top part of the MaplyShapeLinear disappears, as show below: As I change the tilt / zoom / pan the point at which the line disappears stays just above the horizon.
This is a really cool framework, but my app will displays the flight paths of skydivers, so the line disappearing is a bit of a show stopper for me. Any idea what could be causing this?
Thanks
Tom