Water animation Depth fight?

I rendered the terrain (elevation and Bathymetry) at some exaggeration scale and then I turned of the terrain by turning the scale to 0. I Enabled the water mask and its doing depth fight with terrain of the ocean now.

Take a look guys.

Hi there,

I would turn off the terrain by setting the globe’s terrainProvider to the ellipsoid itself, rather than setting scale to 0 since the ezaggeration may cause unexpected consequences.

viewer.scene.globe.terrainProvider = new Cesium.EllipsoidTerrainProvider();

``

Additionally, we would like to make improvement towards further support of bathymetry (see #5665). If you have any additional related requests or suggestions, please add them in that discussion or here.

Thanks!

Gabby

Thanks Gabby for the suggestion. I have done some work on bathymetry exaggeration and rendering. Exaggeration has some issues like it increases the size of globe. I have controlled that problem here tho. PFA the attached image.

var hasVertexNormals = false;
var hasWaterMask = false;
var littleEndianExtensionSize = true;
var isHeightmap = false;
if (data.format === 'heightmap-1.0') {
    isHeightmap = true;
    var a;
    if(that._scale == 0) a=-.001;//so there is no depth fight with the bathymetry of globe
    else a=1;
    if (!defined(that._heightmapStructure)) {
        that._heightmapStructure = {
            heightScale : that._scale,
            heightOffset : -5000.0*that._scale - 31000.0*that._scale + 1000000*a ,
            elementsPerHeight : 1,
            stride : 1,
            elementMultiplier : 256.0,
            isBigEndian : false,
            lowestEncodedHeight : 0,
            highestEncodedHeight : 256 * 256 - 1
        };
    }
    hasWaterMask = true;

Thanks and Regards

Paras

Also subsurface entities dont render please allow them

Thanks for pointing the globe size issue out! That’s definitely something to consider.

We have some way to view subsurface entities. One is that you can hide the surface of terrain using Terrain Clipping Planes. Another is that we have a PR open for underwater rendering.