[SOLVED] Weird exception with binary PLSM

Dids

23-02-2006 20:38:55

Hi all, once again I've run into trouble.

Before I used cvs head of ogre & plsm. At the moment I'm using the sourcecode available at Tuan's site along with the latest sourcecode for ogre (from the ogre site, not from the cvs). I tried using my old config files to PLSM, but it seems I get an exception error window that simply says the following:

Exception: MaxHeight > (Real)0.0


So as you can see, I'm pretty confused with this, and would be grateful for any kind of solution/help. Just in case, here's my config for the heightmap/texturemap. Oh and one more question, what formats/bits does the non-cvs-head version of PLSM support, since that might be it too?

GroupName=PLSM2
LandScapeFileName=rvmapdata
LandScapeExtension=png
Width=8
Height=8
PageSize=513
TileSize=65
Data2DFormat=HeightField
MaxValue=5000
MinValue=0
BigImage=no

# Scale values
# Beware that scaling is pagesize and heightmap definition range indepedant.
ScaleX=25000
ScaleY=5000
ScaleZ=25000

Deformable=yes
VertexCompression=yes
VertexProgramMorph=no
LODMorphStart=1.0f
MaxPixelError=1
VertexNormals=no
TextureExtension=png
TextureFormat=Image
TextureStretchFactor=1
ImageFilename=rvtexturedata
VertexColors=no
CoverageVertexColor=no
BaseVertexColor=no
BaseVertexShadow=no
BaseVertexInstantColor=no
BaseMap=no
#MaterialHeight1=20
#MaterialHeight2=40
#SplatFilename0=splatting_grass.jpg
#SplatFilename1=splatting_sand.jpg
#SplatFilename2=splatting_rock.jpg
#SplatFilename3=splatting_snow.jpg
VisibleRenderables=30
DistanceLOD=5
MaxRenderLevel=5
NumRenderablesLoading=50
MaxAdjacentPages=3
MaxPreloadedPages=4
ChangeFactor=1.5
CameraThreshold=500
MaxNumRenderables=2000
IncrementRenderables=400
MaxNumTiles=2000
IncrementTiles=400
HorizonVisibilityComputing=yes
HeightMapBlurFactor=1.0f


- Dids

tuan kuranes

24-02-2006 11:43:34

but it seems I get an exception error window that simply says the following: Exception: MaxHeight > (Real)0.0
I need more info (line, call stack, etc...)

what formats/bits does the non-cvs-head version of PLSM support
All possible from 8 to 32 bits. 16 bits being the best suited.

Dids

24-02-2006 14:05:58

Call stack is (I think this is the right one):

> msvcr80d.dll!_wassert(const wchar_t * expr=0x030cb4f0, const wchar_t * filename=0x030cb4a8, unsigned int lineno=137) Line 384 C

That undoubtedly causes the problem, although the actual error window tells me this:

Assertion failed!
Program: MyDir\MyExe.exe
File: ..\src\OgrePaginglandScapeTile.cpp
Line: 137

Expression: MaxHeight > (Real)0.0


So yeah, there's not much to "give" about the error more than that.

tuan kuranes

24-02-2006 14:29:33

Are you sure data is loaded ?
Are data accessible from resources.cfg ?
Any error in Ogre.log ?

it's maybe a bug as assert code should be assert (MaxHeight >= (Real)0.0f);

But that would mean that one page or all page are empty. all height == 0 ?
can you hit continue or it's not possible ?

Dids

01-03-2006 18:55:28

Fixed. Although, it seems that the non-cvs version of PLSM doesn't allow any "black tiles", although, those seemed to work in the cvs-head. Black tiles meaning "lowest height" for the heightmap.