strange problem running demos in ogre 1.0

Problems building or running the engine, queries about how to use features etc.
Post Reply
TorqueMaster
Gnoblar
Posts: 7
Joined: Thu Dec 16, 2004 3:14 pm
Location: Mumbai

strange problem running demos in ogre 1.0

Post by TorqueMaster »

Hi,

I have configured Ogre 1.0 and having a strange problems. Whereas I can run the demo exe directly from the common/bin/debug folder, I get an error when i build the demo (smoke for eg.) and run it. I have deleted the old exe too... a new exe is formed and i am able to run it directly by clicking on it but when run from VC7 it gives an unhandled exception. The call stcak is as follows.

Please help me out.

Code: Select all

 	kernel32.dll!7c81eb33() 	
 	kernel32.dll!7c81eb33() 	
 	msvcr71d.dll!_CxxThrowException(void * pExceptionObject=0x0012d14c, const _s__ThrowInfo * pThrowInfo=0x107162a8)  + 0x39	C++
>	OgreMain_d.dll!Ogre::ResourceGroupManager::openResource(const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & resourceName={...}, const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & groupName={...})  Line 497	C++
 	OgreMain_d.dll!Ogre::Image::load(const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & strFileName={...}, const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & group={...})  Line 345 + 0x18	C++
 	RenderSystem_Direct3D9.dll!Ogre::D3D9Texture::_loadNormTex()  Line 359 + 0x1c	C++
 	RenderSystem_Direct3D9.dll!Ogre::D3D9Texture::loadImpl()  Line 180	C++
 	OgreMain_d.dll!Ogre::Resource::load()  Line 70 + 0xd	C++
 	OgreMain_d.dll!Ogre::TextureManager::load(const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & name={...}, const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & group={...}, Ogre::TextureType texType=TEX_TYPE_2D, int numMipmaps=-1, float gamma=1.0000000)  Line 68 + 0x21	C++
 	OgreMain_d.dll!Ogre::TextureUnitState::_load()  Line 711 + 0x6c	C++
 	OgreMain_d.dll!Ogre::Pass::_load()  Line 613	C++
 	OgreMain_d.dll!Ogre::Technique::_load()  Line 254	C++
 	OgreMain_d.dll!Ogre::Material::loadImpl()  Line 123	C++
 	OgreMain_d.dll!Ogre::Resource::load()  Line 70 + 0xd	C++
 	OgreMain_d.dll!Ogre::OverlayElement::setMaterialName(const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & matName={...})  Line 317 + 0x24	C++
 	OgreMain_d.dll!Ogre::PanelOverlayElement::setMaterialName(const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & matName={...})  Line 154	C++
 	OgreMain_d.dll!Ogre::OverlayElementCommands::CmdMaterial::doSet(void * target=0x0f4da0a0, const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & val={...})  Line 84 + 0x11	C++
 	OgreMain_d.dll!Ogre::StringInterface::setParameter(const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & name={...}, const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & value={...})  Line 56 + 0x15	C++
 	OgreMain_d.dll!Ogre::OverlayManager::parseElementAttrib(const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & line={...}, Ogre::Overlay * pOverlay=0x0f4d7300, Ogre::OverlayElement * pElement=0x0f4da0a0)  Line 442 + 0x23	C++
 	OgreMain_d.dll!Ogre::OverlayManager::parseNewElement(Ogre::SharedPtr<Ogre::DataStream> & stream={...}, std::basic_string<char,std::char_traits<char>,std::allocator<char> > & elemType={...}, std::basic_string<char,std::char_traits<char>,std::allocator<char> > & elemName={...}, bool isContainer=true, Ogre::Overlay * pOverlay=0x0f4d7300, bool isTemplate=false, std::basic_string<char,std::char_traits<char>,std::allocator<char> > templateName={...}, Ogre::OverlayContainer * container=0x00000000)  Line 340	C++
 	OgreMain_d.dll!Ogre::OverlayManager::parseChildren(Ogre::SharedPtr<Ogre::DataStream> & stream={...}, const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & line={...}, Ogre::Overlay * pOverlay=0x0f4d7300, bool isTemplate=false, Ogre::OverlayContainer * parent=0x00000000)  Line 406	C++
 	OgreMain_d.dll!Ogre::OverlayManager::parseScript(Ogre::SharedPtr<Ogre::DataStream> & stream={...}, const std::basic_string<char,std::char_traits<char>,std::allocator<char> > & groupName={...})  Line 226 + 0x1f	C++
 	OgreMain_d.dll!Ogre::ResourceGroupManager::parseResourceGroupScripts(Ogre::ResourceGroupManager::ResourceGroup * grp=0x00b93410)  Line 663 + 0x23	C++
 	OgreMain_d.dll!Ogre::ResourceGroupManager::initialiseAllResourceGroups()  Line 131	C++
 	Demo_Smoke.exe!ExampleApplication::loadResources()  Line 196 + 0x19	C++
 	Demo_Smoke.exe!ExampleApplication::setup()  Line 91 + 0xd	C++
 	Demo_Smoke.exe!ExampleApplication::go()  Line 54 + 0xd	C++
 	Demo_Smoke.exe!WinMain(HINSTANCE__ * hInst=0x00400000, HINSTANCE__ * __formal=0x00000000, char * strCmdLine=0x00141f23, HINSTANCE__ * __formal=0x00000000)  Line 43 + 0x8	C++
 	Demo_Smoke.exe!WinMainCRTStartup()  Line 390 + 0x39	C
 	kernel32.dll!7c816d4f() 	
 	ntdll.dll!7c915b4f() 	
 	kernel32.dll!7c8399f3() 	
User avatar
walaber
OGRE Expert User
OGRE Expert User
Posts: 829
Joined: Sat Oct 02, 2004 2:20 pm
Location: California, USA
Contact:

Post by walaber »

this is a problem I had too. it's because you haven't set the "working directory" for your project.

if you're using MSVC++, in the project settings under "debug" there is a spot where you can set the working directory. set this to the same directory as your exe.
Go Go Gadget OGRE!!
Image
TorqueMaster
Gnoblar
Posts: 7
Joined: Thu Dec 16, 2004 3:14 pm
Location: Mumbai

Post by TorqueMaster »

no i dont think this is the problem as i have set the working directory and plus the exe gets created.
User avatar
sinbad
OGRE Retired Team Member
OGRE Retired Team Member
Posts: 19269
Joined: Sun Oct 06, 2002 11:19 pm
Location: Guernsey, Channel Islands
x 67
Contact:

Post by sinbad »

Looks like it's not finding a resource. If you let the exception get thrown instead of trapping it in the debugger you'd be able to see the message (it will be displayed in a message box).
Post Reply