Postby enkd » Fri Jul 07, 2006 00:05
Make sure that you built CEGUI against the same version of STL or STLport that your application uses. I had the same problem, access violation calling subscribeEvent.
My problem was that I built CEGUI against STL, and my application used STLport. As such, any CEGUI class which used standard library data members would be corrupted upon returing from CEGUI calls. For example, all was fine inside WindowManager::createWindow, but back in MY code, the Window was corrupted. This caused an invalid __vfptr (virtual function table pointer) and an access violation on the subscribeEvent call.
An easy check for this is to evaluate sizeof(CEGUI::EventSet) in the debugger, both when inside a CEGUI call and in your own code. The numbers shoud match. If not:
check your includes and rebuild CEGUI with STLport (if you use it)
also, be sure to include the preprocessor directive _STLP_DEBUG if you are using a debug build.