I have this code here...
The lines that have Here comments are the ones of internest. I am using Ogre Rendering Engine for my 3d graphics. I also got a new better compiler than dev-c++.Code:class MyFrameListener : public Ogre::FrameListener { public: InputReader* mInputReader = PlatformManager::getSingleton().createInputReader(); //Here mInputReader->initialise(mWindow,true,true); //And Here virtual bool frameStarted(const FrameEvent& evt) { if (mInputReader.isKeyDown(Ogre::KC_ESCAPE)) { return false; } return true; } virtual bool frameEnded(const FrameEvent& evt) { return true; } MyFrameListener(); }; Ogre::FrameListener* listener = new MyFrameListener; mRoot->addFrameListener(listener); mRoot->startRendering();
But anyways, I need away to put those function either in the class, or out side the class. But if they are in I get an error saying I can't do that, if they are out, the class does not recognize the functions.
Otherwise without those 2 lines of code marked Here, and with the rest of the code, it compiles fine.



LinkBack URL
About LinkBacks



