OgreNewt tutorial- stuck

yuriythebest

25-08-2008 01:25:03

right I'm at this point here:

Now there's one more thing we want to add to the Application class while we're here: a frame listener. in most demos, they have you create a FrameListener class inherited from ExampleFrameListener. We'll do the same in this demo, but also add a special FrameListener just for updating and debugging the Newton world. First, setup the standard ExampleFrameListener class, in your createFrameListener() function like so:

OgreNewtApplication.cpp

void OgreNewtApplication::createFrameListener()
{
mFrameListener = new ExampleFrameListener( mWindow, mCamera );
mRoot->addFrameListener( mFrameListener );
}




however I keep getting the error

'mFrameListener' : undeclared identifier


and I have no idea how to declare it :oops:

sensius

25-08-2008 03:27:37

mFrameListener is declared in ExampleApplication.h
You might forget to include this file.

yuriythebest

25-08-2008 03:49:50

mFrameListener is declared in ExampleApplication.h
You might forget to include this file.


that's just it- I did include ExampleApplication.h in all my header files and also in the actual cpp files at the top but it didn't help

yuriythebest

25-08-2008 16:00:18

never mind figured it out - my problem was that I had to change

class ogreNewttest2App : public BaseApplication


to

class ogreNewttest2App : public ExampleApplication

for it to work :