Main Menu
Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - tmm

#1
Help requests / Re: Renderwindow Exceptions
14 March 2014, 15:11:38
Will sent u a private message to my GDrive ;)
#2
Help requests / Re: Renderwindow Exceptions
14 March 2014, 14:54:00
Yes I checked, everything again.

Debug: tgui-d.lib; sfml-audio-d.lib;sfml-graphics-d.lib;sfml-window-d.lib;sfml-system-d.lib;sfml-network-d.lib;....
Release: tgui.lib;sfml-audio.lib;sfml-graphics.lib;sfml-window.lib;sfml-system.lib;sfml-network.lib;....

I replaced all dlls and lib with the ones from the download.

Downloaded zip says TGUI-0.6.1 C++11 (2012)

So I guess everything correct.


Edit: If i comment window.clear() and window.display() out, it works untill i close the window...
#3
Help requests / Renderwindow Exceptions
14 March 2014, 14:15:26
Hi,

first of all thank you for providing TGUI. It looks awesome ;)

Now to my problem. I just made a little game with sfml and Visual Studio 2012.
I just downloaded your precompiled libs.
And got it working fine, untill I close the RenderWindow.
Something like Heap damaged.

So I just started to play around with shared_ptr and and and.. nothing worked..

Then I got other errors from just calling the window.clear() or draw some other stuff.
And I made a new Project to just test TGUI.

But now I can't even get the tutorial programm running :( It seems like some window methods do cause exceptions. Please help me:

int main()
{
    // Create the window
    sf::RenderWindow window(sf::VideoMode(800, 600), "Window");
    tgui::Gui gui(window);

   /*
if (gui.setGlobalFont("arial.ttf")  == false){
      std::cout << "Main(): Can't find font!\n";
      throw new std::exception("Client_Root: Can't find font!");
   }
   */
    while (window.isOpen())
    {
        sf::Event event;
        while (window.pollEvent(event))
        {
            if (event.type == sf::Event::Closed)
                window.close();

            // Pass the event to all the widgets (if there would be widgets)
            gui.handleEvent(event);
        }

       window.clear();

        // Draw all created widgets
        gui.draw();

        window.display();
      
    }

    return EXIT_SUCCESS;
}

throwing exceptions on:

window.clear()
window.close()
window.display()


Hope it's not a very embarrasing mistake of mine  :P :-[