[Solved]Error during creating World

Kwazar

03-11-2007 11:49:53

Hi!

My soft:
-Microsoft Visual C++ EE 2005
-Ogre 1.4.5
-PhysX 2.7.2
-NxOgre 0.9-38

I have initialized successfully Ogre and OIS. When I was debugging this simple code.

//this code is placed before rendering.
App::Params.logtype = PhysXDriverParams::LT_HTML;
App::Params.useFrameListener = true;

mWorld = new NxOgre::World( Params );


Debugger is pointing on this piece of code in file NxOgrePhysXDriver.cpp:

if (params.useFrameListener)
_createFrameListener(); // <-- there


I don't know what I'm doing wrong.
Can samebody give me the simpliest, working code using Ogre and NxOgre, or explain what I'm doing wrong ?

betajaen

03-11-2007 12:08:04

It's failing to create an ogre framelistener. Which is either down to the Ogre Singleton being 0 (doubtful since you have OIS working), or something has messed up.

Double check all the libraries are the correct versions and so forth. Then check if you can get the Ogre Root Singleton (std::cout << Ogre::Root::getSingletonPtr() << std::endl;)

Kwazar

03-11-2007 14:08:15

I checked Ogre Root Singleton, it looks ok:


But when I debugged it I can see:



Ogre Root Singleton has got NULL adress :?

betajaen: can you write me simpliest working code? If it works on my computer i will know that i have got bugs in my code.

Sorry for my english it isn't my national language :) .

betajaen

03-11-2007 18:18:21

Your NxOgre code is the most simplest as it can get, and how NxOgre gets the Ogre Singleton is the same as yours.

It must be your application. I use NxOgre all the time, and so do many others, and I've seen none that has errors like that*

* Almost. Some people forget or don't know to setup Ogre root before hand. Causing the same error.

Kwazar

03-11-2007 18:49:49

Oh no, I make so stupid mistake :shock:
2nd day I'm trying to run your soft using dll. compiled in release mode O_o and compiling my App in debug mode in VC...

Thanks a lot for help!!