hi,
I recieve segfault while using cs heightmaps:
here are my heightmap parameters in my xml:
<addon plugin="crystalspace.terraformer.simple.loader">
<name>simple</name>
<heightmap>heightmap_1024x1024.png</heightmap>
<scale x="1024" y="1" z="1024" />
</addon>
<meshfact name="TerrainFactx0y0">
<plugin>terrainFact</plugin>
<params>
<plugin>crystalspace.mesh.object.terrain.bruteblock</plugin>
<terraformer>simple</terraformer>
<sampleregion>
<min x="-512" y="-512" />
<max x="512" y="512" />
</sampleregion>
</params>
</meshfact>
...
<sector name="x0y0">
<meshobj name="Terrainx0y0">
<plugin>terrain</plugin>
<params>
<factory>TerrainFactx0y0</factory>
<material>Base</material>
<materialpalette>
<material>Grass</material>
<material>Marble</material>
<material>Stone</material>
</materialpalette>
<lodvalue name="splatting distance">200</lodvalue>
<lodvalue name="block resolution">16</lodvalue>
<lodvalue name="block split distance">8</lodvalue>
<lodvalue name="minimum block size">32</lodvalue>
<lodvalue name="cd resolution">256</lodvalue>
<materialalphamap image="alpha_marble.png" />
<materialalphamap image="alpha_stone.png" />
<staticlighting>yes</staticlighting>
<castshadows>yes</castshadows>
</params>
<move>
<v x="512.000000" y="0" z="1025.000000" />
</move>
</meshobj>
...
the is problem with '<move>' parameter: when I set the parameter
x or z higher than heightmap size then the app segfaults;
the callstack looks like that:
ntdll.dll!7c91b686()
> tto.exe!csHash<unsigned long,char const *>::Get(const char * const &
> key=0x0012e170, const unsigned long & fallback=2316092547) Line 469 + 0xd C++
kernel32.dll!7c8024b7()
glshader_fixed.dll!csArray<csHash<unsigned long,char const
*>::Element,csArrayElementHandler<csHash<unsigned long,char const
*>::Element>,csArrayMemoryAllocator<csHash<unsigned long,char const
*>::Element> >::Length() Line 476 C++
msvcr71d.dll!_heap_alloc_dbg(unsigned int nSize=4096, int nBlockUse=1,
const char * szFileName=0x00000000, int nLine=0) Line 359 + 0x1e C
msvcr71d.dll!_nh_malloc_dbg(unsigned int nSize=4096, int nhFlag=0, int
nBlockUse=1, const char * szFileName=0x00000000, int nLine=0) Line 260 + 0x15
C
msvcr71d.dll!malloc(unsigned int nSize=4096) Line 139 + 0x15 C
glshader_fixed.dll!operator new(unsigned int size=4096) Line 12 + 0x9
C++
glshader_fixed.dll!operator new[](unsigned int count=4096) Line 7 +
0x9 C++
glshader_fixed.dll!csMemoryPool::Alloc(unsigned int n=12) Line 35 +
0xc C++
glshader_fixed.dll!csMemoryPool::Store(const void * m=0x0012e414,
unsigned int n=12) Line 55 + 0xc C++
glshader_fixed.dll!csMemoryPool::Store(const char * s=0x0012e414) Line
63 + 0x40 C++
glshader_fixed.dll!csStringHash::Register(const char * s=0x0012e414,
unsigned long id=0) Line 48 + 0xf C++
glshader_fixed.dll!csShaderProgram::InitCommonTokens(csStringHash &
t={...}) Line 2 C++
glshader_fixed.dll!csShaderProgram::csShaderProgram(iObjectRegistry *
objectReg=0x00bb8c38) Line 40 + 0xc C++
glshader_fixed.dll!csGLShaderFFP::csGLShaderFFP(csGLShader_FIXED *
shaderPlug=0x08fc2f20) Line 47 + 0x64 C++
glshader_fixed.dll!csGLShader_FIXED::CreateProgram(const char *
type=0x08444aef) Line 85 + 0x2e C++
xmlshader.dll!csXMLShaderTech::LoadProgram(iShaderDestinationResolver *
resolve=0x00000000, iDocumentNode * node=0x0844af70,
csXMLShaderTech::shaderPass * __formal=0x09032094) Line 521 + 0x26 C++
xmlshader.dll!csXMLShaderTech::LoadPass(iDocumentNode *
node=0x08449ae8, csXMLShaderTech::shaderPass * pass=0x09032094) Line 104 +
0x1e C++
xmlshader.dll!csXMLShaderTech::Load(iDocumentNode * node=0x08448768,
iDocumentNode * parentSV=0x084468f0) Line 634 + 0x2d C++
xmlshader.dll!csXMLShader::GetTicket(const csRenderMeshModes &
modes={...}, const csArray<csShaderVariable
*,csArrayElementHandler<csShaderVariable
*>,csArrayMemoryAllocator<csShaderVariable *> > & stacks={...}) Line 1539 +
0x1d C++
rendstep_std.dll!ShaderTicketHelper::GetTicket(iMaterial *
material=0x08faa198, iShader * shader=0x09071c18, iShaderVariableContext *
meshContext=0x08fc3340, csRenderMesh * mesh=0x093f8a00) Line 374 + 0x15 C++
rendstep_std.dll!csGenericRenderStep::Perform(iRenderView *
rview=0x0012ef24, iSector * sector=0x084444b0, iLight * light=0x00000000,
csArray<csShaderVariable *,csArrayElementHandler<csShaderVariable
*>,csArrayMemoryAllocator<csShaderVariable *> > & stacks={...}) Line 573 +
0x4a C++
rendstep_std.dll!csGenericRenderStep::Perform(iRenderView *
rview=0x0012ef24, iSector * sector=0x084444b0, csArray<csShaderVariable
*,csArrayElementHandler<csShaderVariable
*>,csArrayMemoryAllocator<csShaderVariable *> > & stacks={...}) Line 296 C++
engine.dll!csRenderLoop::Draw(iRenderView * rview=0x0012ef24, iSector *
s=0x084444b0) Line 76 C++
engine.dll!csEngine::Draw(iCamera * c=0x08ef1798, iClipper2D *
view=0x00c4b708) Line 1723 C++
tto.exe!csView::Draw() Line 161 C++
tto.exe!CelTest::ProcessFrame() Line 134 + 0x24 C++
tto.exe!csBaseEventHandler::OnBroadcast(iEvent & event={...}) Line 111
C++
tto.exe!csBaseEventHandler::HandleEvent(iEvent & event={...}) Line 81
C++
tto.exe!csEventQueue::Notify(unsigned int pseudo_event=9) Line 220
C++
tto.exe!csEventQueue::Process() Line 236 C++
tto.exe!csDefaultRunLoop(iObjectRegistry * r=0x00bb8c38) Line 83
C++
tto.exe!csApplicationFramework::Run() Line 322 + 0xb C++
tto.exe!CelTest::Application() Line 552 C++
tto.exe!csApplicationFramework::Start() Line 72 C++
tto.exe!csApplicationFramework::Main(int argc=3, char * *
argv=0x00b85a90) Line 124 + 0x7 C++
tto.exe!main(int argc=3, char * * argv=0x00b85a90) Line 41 + 0x10
C++
tto.exe!mainCRTStartup() Line 398 + 0xe C
kernel32.dll!7c816d4f()
ntdll.dll!7c915b4f()
kernel32.dll!7c8399f3()
since it points me to shaders not to terrain I'm totaly
confused...
--
greetings,
Piotr Obrzut mailto:[EMAIL PROTECTED]
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
_______________________________________________
Crystal-main mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/crystal-main
Unsubscribe: mailto:[EMAIL PROTECTED]