Page 1 of 1

Terrain 1.9 LOD Issue

Posted: Sat Sep 05, 2015 4:21 am
by lipwiq
Hello! I'm having a bit of a problem with the terrain for v1.9 rev7866: The LOD is almost always at a lower setting even for nearby meshes. Sometimes it changes drastically as the camera moves. Here's a video of this:

[youtube]https://www.youtube.com/watch?v=3HxHs-d4Mqw[/youtube]

Has anyone encountered this problem? It wasn't like this for v1.8. I'd greatly appreciate any help or pointers on how to fix this - been stuck with this for a month not knowing even where/how to begin!

Re: Terrain 1.9 LOD Issue

Posted: Sun Sep 13, 2015 7:01 am
by Crystal Hammer
Wireframe would've been nice to see too.
And probably without code nobody can guess what's wrong.

What values do you have in terrain setup code here:

Code: Select all

	//Ogre::TerrainGlobalOptions* mTerrainGlobals;  // in class
	//Ogre::TerrainGroup* mTerrainGroup;

	mTerrainGlobals->setMaxPixelError(3.f);  // 1.7 - 20
	Terrain::ImportData& di = mTerrainGroup->getDefaultImportSettings();
	di.terrainSize = 1025;
	di.worldSize = 1024.f;
	di.minBatchSize = 65;  // 17 33 65 129
	di.maxBatchSize = Terrain::TERRAIN_MAX_BATCH_SIZE;  // 129, verts
I've put mine, which work well. You can read the comments in declarations of those parameters to get more info on what they do.
You can change setMaxPixelError value to 1.f (or even 0), this way it will be on highest and this shouldn't happen at all, then tweak it to higher value.