I'm trying to put the ogre view in my own view tree. But i've a problem.
To avoid ogre of creating a new uiwindow, i pass the current uiwindow when creating the render window:
Code: Select all
Ogre::String windowHandle = Ogre::StringConverter::toString((size_t)(currentWindow));
Ogre::NameValuePairList viewConfig;
viewConfig["externalWindowHandle"] = windowHandle;
m_pOgreRenderWnd = m_pOgreRoot->createRenderWindow("OgreiOSRenderWindow", windowWidth, windowHeight, false, &viewConfig);
Code: Select all
m_pOgreSystemViewController = [(UIViewController*)m_pOgreSystem->getOgreViewController() retain];
[m_pOgreSystemViewController.view removeFromSuperview]; //ogre auto attach the view in the provided window, detach from it
Any idea?
Thanks in advance!
PD: Using iOS 4.3 SDK, XCode 3.2.6, Ogre trunk 1.8 (last checkout around 5 days ago), OpenGLES 2.0