ogre exception when running demo project in Hydrax-v0.5.1

greennymph

27-02-2010 16:59:18

Hi, I am trying to run the demo project included in the Hydrax-v0.5.1 I downloaded .
But I met the following error. It was reported in Ogre.log:

...
17:07:30: [Hydrax] RTT manager initialized.
17:07:30: [Hydrax] Registring device restored listener...
17:07:30: [Hydrax] Device restored listener registred.
17:07:30: [Hydrax] Creating materials...
17:08:07: [Hydrax] Creating water material...
OGRE EXCEPTION(2:InvalidParametersException): Named constants have not been initialised, perhaps a compile error. in GpuProgramParameters::_findNamedConstantDefinition at ..\src\OgreGpuProgram.cpp (line 1087)


It occured in MarerialManager.cpp after the following code was called:
if (_isComponent(Components, HYDRAX_COMPONENT_UNDERWATER))
{
HydraxLOG("Creating underwater material...");
if(!_createUnderwaterMaterial(Components, Options))
{
return false;
}
if(!_createUnderwaterCompositor(Components, Options))
{
return false;
}
if(!_createSimpleColorMaterial(Ogre::ColourValue::Red, MAT_SIMPLE_RED, _def_Simple_Red_Material_Name, false))
{
return false;
}
HydraxLOG("Underwater material created.");
}


Does anyone know what the problem is? Thanks a lot!

Xavyiy

27-02-2010 19:52:42

Does your graphic card support SM 2.0?

This kind of errors in general are due to Ogre is not able to compile fragment/vertex shaders for your gpu

greennymph

01-03-2010 18:31:24

Hi Xavyiy,
Thanks a lot for your reply!
The graphics card on my laptop is ATI mobility radeon x700..
Does it support the shader model?

greennymph

01-03-2010 23:22:30

Hi Xavyiy,
I previously disabled DirectX because I haven't installed directx sdk yet. After I installed directx and use it instead of OpenGL to render it works..
Thanks for giving me the clue!