GroundMesh view distance

Hi, I’m having a lot of difficulties extending the viewing distance of a ground mesh which I generated from a heightmap. It’s showing the mesh in a box shape of approximate length 100 around the camera and culling everything beyond that. It seems like it should be a simple solution but nothing I’m trying is working here. Adding a LOD, or changing LOD strategy doesn’t seem to work but perhaps I’m doing it wrong. I’ve had a look at camera settings, with no success. Going to keep investigating, and I guess it might be a basic setting, but if someone knows how to do this, it might save me a lot of time in trying to get it working … thanks in advance.

Did you try to change the maxZ value of the camera ?

Hi @Cedric , thanks for responding. Yes I did, and I also changed the setting ignoreMaxZ on the mesh. I should also add I’m using the library react-babylonjs. I’m still not sure what’s causing this issue. And currently referencing this playground: … which works perfectly, to determine the point of failure in my application. Could be a small error on my part, or a problem with the react-babylonjs library. I don’t know, but will post anything I find out here. Cheers.

Check camera.maxZ in the Inspector or scene.activeCamera.maxZ in console.
Maybe there is some error with assigning its desired value.
By default it is 10000.
You may try to scale down your mesh and see if it will help to see it better.

Do you mean culling or clipping? Culling will result in the mesh disappearing completely. Is that what you are seeing? Can you send a screenshot?

thanks for the response @labris … this was not the issue here because changing it didn’t affect anything. In any case, I wasn’t able to find out what was causing the issue exactly. And I didn’t kill myself trying once I found a workaround which was to completely take react-babylonjs out the equation and work with just babylonjs in a react application.


my apologies, I mean clipping. In any case, I’ve moved forward without react-babylonjs, and everything is now working perfectly. Thanks for the response.