FeatureNodes flickering because of depthOffsetOptions

classic Classic list List threaded Threaded
3 messages Options
krzysief krzysief
Reply | Threaded
Open this post in threaded view
|

FeatureNodes flickering because of depthOffsetOptions

Hello,

some of my FeatureNodes where collapsing under the surface of the map. For example when there was a line drawn near 0, 0 WGS coordinates only it's beginning and end was visible, so i applied DepthOffsetOptions for it to render properly:

DepthOffsetOptions depth_offset_options;
        depth_offset_options.enabled()      = true;
        depth_offset_options.automatic()    = true;
        depth_offset_options.minBias()      = 10.6f;
        depth_offset_options.maxBias()      = 150.0f;

        render_symbol->depthOffset()        = depth_offset_options;

unfortunately when i zoom close to my FeatureNodes some parts of them disappear, but when i zoom closer they are back, any tips to fix it?

Using osgEarth 2.9 Ubuntu 18.04

Cheers, Kris

gwaldron gwaldron
Reply | Threaded
Open this post in threaded view
|

Re: FeatureNodes flickering because of depthOffsetOptions

Kris,
Depth offsetting can only do so much and will typically only work over a very small area. You also will need to tessellate your geometry. Try using the LineSymbol::tessellationSize property to limit the length of any individual line segment.
Glenn Waldron / Pelican Mapping
krzysief krzysief
Reply | Threaded
Open this post in threaded view
|

Re: FeatureNodes flickering because of depthOffsetOptions

I'll try it, Thank you Glenn