CEGUI 0.8.x changes break compiling

CEGUI 0.8.x changes break compiling

Postby wirser » 07 Jun 2016, 17:47

When I started attempting to compile Tnl aside from changing a few "#include" statements for CEGUI all went well (as far as CEGUI went)

However I upgraded from ubuntu 14.04 which used CEGUI version 0.7.6 to ubuntu 16.04 which uses CEGUI version 0.8.4
many changes were made to CEGUI which break the Tnl code depending on CEGUI see
http://cegui.org.uk/wiki/Porting_tips_and_changes_from_0.7.X_to_0.8.X
for details.
It seems ther are going to be more changes when version 1.0 is released per google search of "porting CEGUI"

How to proceed here is not up to me, I'm just reporting what I ran into
I tried to solve the issues but only had limited success as I do not yet have the knowledge of the code needed to rewrite the affected codes
wirser
 
Posts: 15
Joined: 25 Feb 2016, 18:21

Re: CEGUI 0.8.x changes break compiling

Postby wirser » 07 Jun 2016, 20:32

After running make -k I got the following CEGUI errors

    In file included from MainGUI.cc:7:0:
    SettingsDlg.h:67:16: error: ‘Checkbox’ in namespace ‘CEGUI’ does not name a type
    CEGUI::Checkbox *joystick_enabled_checkbox;
    ^
    SettingsDlg.h:72:16: error: ‘Checkbox’ in namespace ‘CEGUI’ does not name a type
    CEGUI::Checkbox *shaders_enabled_checkbox;
    ^
    SettingsDlg.h:87:16: error: ‘Checkbox’ in namespace ‘CEGUI’ does not name a type
    CEGUI::Checkbox *joystick_axis_inverted_checkbox;
    ^
    MainGUI.cc: In member function ‘void UI::MainGUI::switchToState(UI::MainGUI::UIState, Ptr<UI::Dialog>)’:
    MainGUI.cc:55:9: error: ‘getSingleton’ is not a member of ‘CEGUI::MouseCursor’
    CEGUI::MouseCursor::getSingleton().setVisible(ui_state != OFF);
    ^
    make[4]: *** [MainGUI.o] Error 1
    MainMenu.cc: In member function ‘virtual void UI::MainMenu::enable(UI::MainGUI&)’:
    MainMenu.cc:9:70: error: ‘class CEGUI::WindowManager’ has no member named ‘loadWindowLayout’
    CEGUI::Window *window = CEGUI::WindowManager::getSingleton().loadWindowLayout(
    ^
    MainMenu.cc:11:39: error: ‘class CEGUI::System’ has no member named ‘setGUISheet’
    CEGUI::System::getSingleton().setGUISheet(window);
    ^
    MainMenu.cc: In member function ‘virtual void UI::MainMenu::disable(UI::MainGUI&)’:
    MainMenu.cc:42:63: error: ‘class CEGUI::System’ has no member named ‘getGUISheet’
    CEGUI::Window *window = CEGUI::System::getSingleton().getGUISheet();
    ^
    make[4]: *** [MainMenu.o] Error 1
    MissionSelector.cc: In member function ‘virtual void UI::MissionSelector::enable(UI::MainGUI&)’:
    MissionSelector.cc:23:70: error: ‘class CEGUI::WindowManager’ has no member named ‘loadWindowLayout’
    CEGUI::Window *window = CEGUI::WindowManager::getSingleton().loadWindowLayout(
    ^
    MissionSelector.cc:25:39: error: ‘class CEGUI::System’ has no member named ‘setGUISheet’
    CEGUI::System::getSingleton().setGUISheet(window);
    ^
    MissionSelector.cc: In member function ‘virtual void UI::MissionSelector::disable(UI::MainGUI&)’:
    MissionSelector.cc:81:63: error: ‘class CEGUI::System’ has no member named ‘getGUISheet’
    CEGUI::Window *window = CEGUI::System::getSingleton().getGUISheet();
    ^
    make[4]: *** [MissionSelector.o] Error 1
    In file included from SettingsDlg.cc:15:0:
    SettingsDlg.h:67:16: error: ‘Checkbox’ in namespace ‘CEGUI’ does not name a type
    CEGUI::Checkbox *joystick_enabled_checkbox;
    ^
    SettingsDlg.h:72:16: error: ‘Checkbox’ in namespace ‘CEGUI’ does not name a type
    CEGUI::Checkbox *shaders_enabled_checkbox;
    ^
    SettingsDlg.h:87:16: error: ‘Checkbox’ in namespace ‘CEGUI’ does not name a type
    CEGUI::Checkbox *joystick_axis_inverted_checkbox;
    ^
    SettingsDlg.cc: In member function ‘virtual void UI::SettingsDlg::enable(UI::MainGUI&)’:
    SettingsDlg.cc:134:53: error: ‘class CEGUI::WindowManager’ has no member named ‘loadWindowLayout’
    root = CEGUI::WindowManager::getSingleton().loadWindowLayout(
    ^
    SettingsDlg.cc:138:9: error: ‘joystick_enabled_checkbox’ was not declared in this scope
    joystick_enabled_checkbox = (CEGUI::Checkbox*)
    ^
    SettingsDlg.cc:138:38: error: ‘Checkbox’ is not a member of ‘CEGUI’
    joystick_enabled_checkbox = (CEGUI::Checkbox*)
    ^
    SettingsDlg.cc:138:54: error: expected primary-expression before ‘)’ token
    joystick_enabled_checkbox = (CEGUI::Checkbox*)
    ^
    SettingsDlg.cc:149:9: error: ‘shaders_enabled_checkbox’ was not declared in this scope
    shaders_enabled_checkbox = (CEGUI::Checkbox*)
    ^
    SettingsDlg.cc:149:37: error: ‘Checkbox’ is not a member of ‘CEGUI’
    shaders_enabled_checkbox = (CEGUI::Checkbox*)
    ^
    SettingsDlg.cc:149:53: error: expected primary-expression before ‘)’ token
    shaders_enabled_checkbox = (CEGUI::Checkbox*)
    ^
    SettingsDlg.cc:262:9: error: ‘joystick_axis_inverted_checkbox’ was not declared in this scope
    joystick_axis_inverted_checkbox = (CEGUI::Checkbox *)
    ^
    SettingsDlg.cc:262:44: error: ‘Checkbox’ is not a member of ‘CEGUI’
    joystick_axis_inverted_checkbox = (CEGUI::Checkbox *)
    ^
    SettingsDlg.cc:262:61: error: expected primary-expression before ‘)’ token
    joystick_axis_inverted_checkbox = (CEGUI::Checkbox *)
    ^
    SettingsDlg.cc:279:20: error: ‘CEGUI::Checkbox’ has not been declared
    CEGUI::Checkbox::EventCheckStateChanged,
    ^
    SettingsDlg.cc:297:39: error: ‘class CEGUI::System’ has no member named ‘setGUISheet’
    CEGUI::System::getSingleton().setGUISheet(root);
    ^
    SettingsDlg.cc: In member function ‘bool UI::SettingsDlg::toggleInvertAxis(const CEGUI::EventArgs&)’:
    SettingsDlg.cc:511:13: error: ‘joystick_axis_inverted_checkbox’ was not declared in this scope
    if (joystick_axis_inverted_checkbox->isSelected()) {
    ^
    SettingsDlg.cc: In member function ‘void UI::SettingsDlg::loadFromConfig()’:
    SettingsDlg.cc:550:9: error: ‘joystick_enabled_checkbox’ was not declared in this scope
    joystick_enabled_checkbox->setSelected(
    ^
    SettingsDlg.cc:574:9: error: ‘shaders_enabled_checkbox’ was not declared in this scope
    shaders_enabled_checkbox->setSelected(
    ^
    SettingsDlg.cc: In member function ‘void UI::SettingsDlg::saveToConfig()’:
    SettingsDlg.cc:580:13: error: ‘joystick_enabled_checkbox’ was not declared in this scope
    joystick_enabled_checkbox->isSelected()?"true":"false");
    ^
    SettingsDlg.cc:601:13: error: ‘shaders_enabled_checkbox’ was not declared in this scope
    shaders_enabled_checkbox->isSelected()?"true":"false");
    ^
    SettingsDlg.cc: In member function ‘void UI::SettingsDlg::loadEvents()’:
    SettingsDlg.cc:625:82: error: no matching function for call to ‘CEGUI::ListboxTextItem::setSelectionBrushImage(const char [12], const char [24])’
    item->setSelectionBrushImage("TaharezLook", "MultiListSelectionBrush");
    ^
    In file included from /usr/include/cegui-0.8.4/CEGUI/widgets/All.h:44:0,
    from /usr/include/cegui-0.8.4/CEGUI/CEGUI.h:132,
    from SettingsDlg.cc:12:
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:354:13: note: candidate: void CEGUI::ListboxItem::setSelectionBrushImage(const CEGUI::Image*)
    void setSelectionBrushImage(const Image* image) {d_selectBrush = image;}
    ^
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:354:13: note: candidate expects 1 argument, 2 provided
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:367:13: note: candidate: void CEGUI::ListboxItem::setSelectionBrushImage(const CEGUI::String&)
    void setSelectionBrushImage(const String& name);
    ^
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:367:13: note: candidate expects 1 argument, 2 provided
    SettingsDlg.cc:629:82: error: no matching function for call to ‘CEGUI::ListboxTextItem::setSelectionBrushImage(const char [12], const char [24])’
    item->setSelectionBrushImage("TaharezLook", "MultiListSelectionBrush");
    ^
    In file included from /usr/include/cegui-0.8.4/CEGUI/widgets/All.h:44:0,
    from /usr/include/cegui-0.8.4/CEGUI/CEGUI.h:132,
    from SettingsDlg.cc:12:
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:354:13: note: candidate: void CEGUI::ListboxItem::setSelectionBrushImage(const CEGUI::Image*)
    void setSelectionBrushImage(const Image* image) {d_selectBrush = image;}
    ^
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:354:13: note: candidate expects 1 argument, 2 provided
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:367:13: note: candidate: void CEGUI::ListboxItem::setSelectionBrushImage(const CEGUI::String&)
    void setSelectionBrushImage(const String& name);
    ^
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:367:13: note: candidate expects 1 argument, 2 provided
    SettingsDlg.cc: In member function ‘void UI::SettingsDlg::loadAxes()’:
    SettingsDlg.cc:697:82: error: no matching function for call to ‘CEGUI::ListboxTextItem::setSelectionBrushImage(const char [12], const char [24])’
    item->setSelectionBrushImage("TaharezLook", "MultiListSelectionBrush");
    ^
    In file included from /usr/include/cegui-0.8.4/CEGUI/widgets/All.h:44:0,
    from /usr/include/cegui-0.8.4/CEGUI/CEGUI.h:132,
    from SettingsDlg.cc:12:
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:354:13: note: candidate: void CEGUI::ListboxItem::setSelectionBrushImage(const CEGUI::Image*)
    void setSelectionBrushImage(const Image* image) {d_selectBrush = image;}
    ^
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:354:13: note: candidate expects 1 argument, 2 provided
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:367:13: note: candidate: void CEGUI::ListboxItem::setSelectionBrushImage(const CEGUI::String&)
    void setSelectionBrushImage(const String& name);
    ^
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:367:13: note: candidate expects 1 argument, 2 provided
    SettingsDlg.cc:701:82: error: no matching function for call to ‘CEGUI::ListboxTextItem::setSelectionBrushImage(const char [12], const char [24])’
    item->setSelectionBrushImage("TaharezLook", "MultiListSelectionBrush");
    ^
    In file included from /usr/include/cegui-0.8.4/CEGUI/widgets/All.h:44:0,
    from /usr/include/cegui-0.8.4/CEGUI/CEGUI.h:132,
    from SettingsDlg.cc:12:
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:354:13: note: candidate: void CEGUI::ListboxItem::setSelectionBrushImage(const CEGUI::Image*)
    void setSelectionBrushImage(const Image* image) {d_selectBrush = image;}
    ^
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:354:13: note: candidate expects 1 argument, 2 provided
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:367:13: note: candidate: void CEGUI::ListboxItem::setSelectionBrushImage(const CEGUI::String&)
    void setSelectionBrushImage(const String& name);
    ^
    /usr/include/cegui-0.8.4/CEGUI/widgets/./ListboxItem.h:367:13: note: candidate expects 1 argument, 2 provided
    SettingsDlg.cc: In member function ‘void UI::SettingsDlg::loadJoystickAxis()’:
    SettingsDlg.cc:713:9: error: ‘joystick_axis_inverted_checkbox’ was not declared in this scope
    joystick_axis_inverted_checkbox->setEnabled(false);
    ^
    make[4]: *** [SettingsDlg.o] Error 1
    make[4]: Target 'all' not remade because of errors.
    make[3]: *** [all-recursive] Error 1
    make[3]: Target 'all' not remade because of errors.
    In file included from /usr/include/cegui-0.8.4/CEGUI/Base.h:36:0,
    from /usr/include/cegui-0.8.4/CEGUI/String.h:32,
    from /usr/include/cegui-0.8.4/CEGUI/Affector.h:32,
    from /usr/include/cegui-0.8.4/CEGUI/CEGUI.h:33,
    from game.cc:8:
    /usr/include/cegui-0.8.4/CEGUI/Config.h:40:18: error: expected unqualified-id before numeric constant
    # define DEBUG 1
    ^
    ./TargetInfo.h:33:33: note: in expansion of macro ‘DEBUG’
    DEBUG,
    ^
    game.cc: In member function ‘void Game::startupSystem(Status&)’:
    game.cc:308:9: error: ‘Imageset’ has not been declared
    Imageset::setDefaultResourceGroup("imagesets");
    ^
    game.cc:319:9: error: ‘OpenGLRenderer’ is not a member of ‘CEGUI’
    CEGUI::OpenGLRenderer & opengl_renderer = CEGUI::OpenGLRenderer::create();
    ^
    game.cc:319:33: error: ‘opengl_renderer’ was not declared in this scope
    CEGUI::OpenGLRenderer & opengl_renderer = CEGUI::OpenGLRenderer::create();
    ^
    game.cc:319:58: error: ‘CEGUI::OpenGLRenderer’ has not been declared
    CEGUI::OpenGLRenderer & opengl_renderer = CEGUI::OpenGLRenderer::create();
    ^
    game.cc:324:46: error: ‘class CEGUI::SchemeManager’ has no member named ‘create’
    CEGUI::SchemeManager::getSingleton().create("TaharezLook.scheme");
    ^
    game.cc:327:44: error: ‘class CEGUI::FontManager’ has no member named ‘create’
    CEGUI::FontManager::getSingleton().create("Commonwealth-10.font");
    ^
    game.cc:328:44: error: ‘class CEGUI::FontManager’ has no member named ‘create’
    CEGUI::FontManager::getSingleton().create("Commonwealth-12.font");
    ^
    game.cc:329:44: error: ‘class CEGUI::FontManager’ has no member named ‘create’
    CEGUI::FontManager::getSingleton().create("Commonwealth-14.font");
    ^
    game.cc:330:44: error: ‘class CEGUI::FontManager’ has no member named ‘create’
    CEGUI::FontManager::getSingleton().create("Commonwealth-16.font");
    ^
    game.cc:331:44: error: ‘class CEGUI::FontManager’ has no member named ‘create’
    CEGUI::FontManager::getSingleton().create("Commonwealth-18.font");
    ^
    game.cc:333:39: error: ‘class CEGUI::System’ has no member named ‘setDefaultMouseCursor’
    CEGUI::System::getSingleton().setDefaultMouseCursor("TaharezLook", "MouseArrow");
    ^
    game.cc: In member function ‘void Game::doFrame()’:
    game.cc:891:35: error: ‘class CEGUI::System’ has no member named ‘renderGUI’
    CEGUI::System::getSingleton().renderGUI();
    ^
    make[3]: *** [game.o] Error 1
    CEGUIEventFilter.cc: In member function ‘virtual bool CEGUIEventFilter::feedEvent(SDL_Event&)’:
    CEGUIEventFilter.cc:147:24: error: ‘class CEGUI::System’ has no member named ‘injectMousePosition’
    consumed = gui.injectMousePosition(ev.motion.x, ev.motion.y);
    ^
    CEGUIEventFilter.cc:152:28: error: ‘class CEGUI::System’ has no member named ‘injectMouseWheelChange’
    consumed = gui.injectMouseWheelChange(1);
    ^
    CEGUIEventFilter.cc:155:28: error: ‘class CEGUI::System’ has no member named ‘injectMouseWheelChange’
    consumed = gui.injectMouseWheelChange(-1);
    ^
    CEGUIEventFilter.cc:158:28: error: ‘class CEGUI::System’ has no member named ‘injectMouseButtonDown’
    consumed = gui.injectMouseButtonDown(LeftButton);
    ^
    CEGUIEventFilter.cc:161:28: error: ‘class CEGUI::System’ has no member named ‘injectMouseButtonDown’
    consumed = gui.injectMouseButtonDown(MiddleButton);
    ^
    CEGUIEventFilter.cc:164:28: error: ‘class CEGUI::System’ has no member named ‘injectMouseButtonDown’
    consumed = gui.injectMouseButtonDown(RightButton);
    ^
    CEGUIEventFilter.cc:174:28: error: ‘class CEGUI::System’ has no member named ‘injectMouseButtonUp’
    consumed = gui.injectMouseButtonUp(LeftButton);
    ^
    CEGUIEventFilter.cc:177:28: error: ‘class CEGUI::System’ has no member named ‘injectMouseButtonUp’
    consumed = gui.injectMouseButtonUp(MiddleButton);
    ^
    CEGUIEventFilter.cc:180:28: error: ‘class CEGUI::System’ has no member named ‘injectMouseButtonUp’
    consumed = gui.injectMouseButtonUp(RightButton);
    ^
    CEGUIEventFilter.cc:185:25: error: ‘class CEGUI::System’ has no member named ‘injectChar’
    consumed = gui.injectChar(ev.key.keysym.unicode);
    ^
    CEGUIEventFilter.cc:186:25: error: ‘class CEGUI::System’ has no member named ‘injectKeyDown’
    consumed |= gui.injectKeyDown(SDLKeyToCEGUIKey(ev.key.keysym.sym));
    ^
    CEGUIEventFilter.cc:189:24: error: ‘class CEGUI::System’ has no member named ‘injectKeyUp’
    consumed = gui.injectKeyUp(SDLKeyToCEGUIKey(ev.key.keysym.sym));
wirser
 
Posts: 15
Joined: 25 Feb 2016, 18:21

Re: CEGUI 0.8.x changes break compiling

Postby toothbrush » 06 Jul 2016, 15:26

it doesn't look good when you see so many "Error" word ... anyway we can try it.
toothbrush
 
Posts: 39
Joined: 10 Jun 2016, 17:16

Re: CEGUI 0.8.x changes break compiling

Postby wirser » 14 Jul 2016, 18:35

I've been looking into this

CEGUI has a "porting guide" from 0.7.x to 0.8.x which has been some help

But my c++ rpograming skill up to this point were just past " hello world", forcing me to learn more advanced c++ concepts. And lets just say what I previously knew about CEGUI was even less. finally even under the best conditions, troubleshooting someone else's code (on a large project) is difficult.

I am trying :twisted:

however until I get past the compiling errors I don't know if any of my attempts will work :p

I am to the point of clearing most of the new errors (I think)
but this error and like ones is currently stumping me
{l Code}: {l Select All Code}
SettingsDlg.cc: In member function ‘void UI::SettingsDlg::loadEvents()’:
SettingsDlg.cc:625:82: error: no matching function for call to ‘CEGUI::ListboxTextItem::setSelectionBrushImage(const char [12], const char [24])’
item->setSelectionBrushImage("TaharezLook", "MultiListSelectionBrush");



I think it has something not properly initialized but have not solved it yet. I am still studying CEGUI tutorials trying to learn

That's all I can report so far
wirser
 
Posts: 15
Joined: 25 Feb 2016, 18:21

Who is online

Users browsing this forum: No registered users and 1 guest