[SOLVED] Terrain scale

Demon Lord

13-06-2008 00:13:57

Hi!

I'm trying to figure out the exact meaning of the Scale options and how to set it up to fit the world unit.

I have a 1709x1467 16-bit png heightmap, representing an area of 1709x1467 meters with a vertical scale of 515 meters. A meter is equivalent to one Ogre unit.

This png is split up through MapSplitter with the following settings (among probably irrelevant others):
PageSize=513
TileSize=65
ScaleX=1709.09f
ScaleY=515.35f
ScaleZ=1467.88f

They are loaded in the game with the following settings:
Width=3
Height=2
PageSize=513
TileSize=65
ScaleX=1709.09f
ScaleY=515.35f
ScaleZ=1467.88f

I thought these settings would be fine, but the resulting terrain is way bigger (as in >10 times?) than what I expected.

Help?

Maxi

13-06-2008 00:26:00

If I remember correctly the scale factor is the size of one page in ogre units. In your case this would mean:

ScaleX=513
ScaleY=515
ScaleZ=513

Please give me a reply if this is correct, because I'm far off from being sure. :)

Demon Lord

13-06-2008 14:47:38

Using ScaleX and ScaleZ as the size of a page work as expected, thanks!