I’ve been trying to learn all the basics before starting into a major project with jme.
I’ve gotten pretty far and my current goal is to be able to make a level of detail for my terrain. I came across this.
“GeoMipMapping: a method of changing the level of detail (LOD) of geometry tiles based on how far away they are from the camera. Between the edges of two tiles, it will seam those edges together so you don’t get gaps or holes.”
I have a simple .j3o scene created in the terrain editor.
How would I apply this “GeoMipMap” to that terrain, and then make it affect my camera.
@Sploreg Yes! Exactly you got it! I have the actual terrain made in the terrain editor!
I want to apply the lod to this! THANK YOU for understanding!
I want to make it so all of my terrain isn’t constantly visible, I want it to be a bit foggy around the camera. This is a screenshot of what it looks like currently in the game.
Tough question. If you look at FPS games with terrain, it is not that detailed. They use rock models and other props for detail.
You can test a large terrain and see what performance you get, but add in a bunch of test models too. And it’s fine to start with a 512 terrain and then scale it x2. A 1024 terrain scales x2 will be quite large and pretty detailed.
@Sploreg said:
This thread talks about how to find the terrain and attach the lod control to it. It needs to do this so the camera can be attached.
http://hub.jmonkeyengine.org/forum/topic/terrain-editor-loading-from-scene-lod-control/
That was what the other thread in the end recommended yet I am unable to do this. My spatial scene does not have getChild method and even when I look into the JME doc I can’t find it. It is probably something silly I have forgot to do but I can’t figure it out.
But your code should print “LOD NULL” then… If the model isn’t actually loaded though the spatial would be null you’d get a NPE before, as you try to call getChild() on null.