When i try to make install CEGUI, i get this error:
CEGuiOgreBaseApplication.cpp:218: error: ‘class OIS::InputManager’ has no member named ‘numKeyBoards’
CEGuiOgreBaseApplication.cpp:225: error: ‘class OIS::InputManager’ has no member named ‘numMice’
I noticed, that someone else had the same problem:
viewtopic.php?p=13287&highlight=
(look at the 4th post)
The suggested solution for this is:
The fix for it is already in the source file. If you go to the location of the errors you should find a commented line for each error instance - if you comment the error line and uncomment the other line, you should find it compiles successfully.
I looked in CEGuiOgreBaseApplication.cpp, and there is no commented code whatsoever in that file, not around the lines that cause the errors, nor anywhere else.
Am i missing something? Could perhaps someone post the two correct lines of code?
Here is the function where the error occurs copied and pasted here:
Code: Select all
CEGuiDemoFrameListener::CEGuiDemoFrameListener(CEGuiBaseApplication* baseApp, Ogre::RenderWindow* window, Ogre::Camera* camera, bool useBufferedInputKeys, bool useBufferedInputMouse)
{
// OIS setup
OIS::ParamList paramList;
size_t windowHnd = 0;
std::ostringstream windowHndStr;
// get window handle
window->getCustomAttribute("WINDOW", &windowHnd);
// fill param list
windowHndStr << (unsigned int)windowHnd;
paramList.insert(std::make_pair(std::string("WINDOW"), windowHndStr.str()));
// create input system
d_inputManager = OIS::InputManager::createInputSystem(paramList);
// create buffered keyboard
if (d_inputManager->numKeyBoards() > 0)
{
d_keyboard = static_cast<OIS::Keyboard*>(d_inputManager->createInputObject(OIS::OISKeyboard, true));
d_keyboard->setEventCallback(this);
}
// create buffered mouse
if (d_inputManager->numMice() > 0)
{
d_mouse = static_cast<OIS::Mouse*>(d_inputManager->createInputObject(OIS::OISMouse, true));
d_mouse->setEventCallback(this);
unsigned int width, height, depth;
int left, top;
window->getMetrics(width, height, depth, left, top);
const OIS::MouseState& mouseState = d_mouse->getMouseState();
mouseState.width = width;
mouseState.height = height;
}
// store inputs we want to make use of
d_camera = camera;
d_window = window;
// we've not quit yet.
d_quit = false;
// setup base app ptr
d_baseApp = baseApp;
}