Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: SFML 1.6 Runtime errors  (Read 2830 times)

0 Members and 1 Guest are viewing this topic.

inlinevoid

  • Newbie
  • *
  • Posts: 49
    • MSN Messenger - inlinevoidmain@gmail.com
    • AOL Instant Messenger - inlinevoid
    • View Profile
    • Email
SFML 1.6 Runtime errors
« on: April 17, 2010, 05:35:19 am »
Alright so I just upgraded to 1.6 and I can't get even a simple program running correctly.  Maybe I'm getting a little rusty seeing as how I wrote an SFML engine for all of my games and never actually had to write any SFML code in the past month.  

Let me list how I have everything set up and tell me if I'm missing something.

Preprocessor
    SFML_DYNAMIC


Linker dependencies
    sfml-graphics-d.lib
    sfml-system-d.lib
    sfml-audio-d.lib
    sfml-window-d.lib


Source

Code: [Select]

#include <SFML/Graphics.hpp>
int main()
{
    sf::RenderWindow App(sf::VideoMode(800, 600, 32), "SFML Graphics");
sf::Event Event;
    while (App.IsOpened())
    {
App.GetEvent(Event);
if(Event.Type == sf::Event::Closed)App.Close();
        App.Clear();
        App.Display();
    }

    return EXIT_SUCCESS;
}


All of the headers, libs, DLL's are in the right place and I'm using MSVC08.  Not sure what the problem is here but I'm getting a runtime error at App.Clear();

I've tried creating a couple different projects to see if I'm messing anything up by accident but they all have the same results.

Ashenwraith

  • Sr. Member
  • ****
  • Posts: 270
    • View Profile
SFML 1.6 Runtime errors
« Reply #1 on: April 17, 2010, 07:24:09 am »
Are you sure you set them properly and the folders are correct?

You could try setting your link order to

sfml-audio.dll
sfml-graphics.dll
sfml-window.dll
sfml-system.dll

inlinevoid

  • Newbie
  • *
  • Posts: 49
    • MSN Messenger - inlinevoidmain@gmail.com
    • AOL Instant Messenger - inlinevoid
    • View Profile
    • Email
SFML 1.6 Runtime errors
« Reply #2 on: April 17, 2010, 08:56:23 pm »
Quote from: "Ashenwraith"
Are you sure you set them properly and the folders are correct?

You could try setting your link order to

sfml-audio.dll
sfml-graphics.dll
sfml-window.dll
sfml-system.dll


Nope, doesn't work.  I'm positive I have everything in the right folders, too.

Qolz

  • Newbie
  • *
  • Posts: 2
    • View Profile
SFML 1.6 Runtime errors
« Reply #3 on: April 25, 2010, 01:59:19 pm »
Hey I got exactly the same problem as you. I'm geting runtime error at App.Clear(); aswell.

Im running windows vista ultimate 64 bit.

I have downloaded a fresh copy of SFML 1.6 and linked it in vs2008 but the problem is still there.

So if anyone have any ideas please tell  :wink:

Thanks
Qolz

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
SFML 1.6 Runtime errors
« Reply #4 on: April 25, 2010, 04:15:20 pm »
What if you recompile everything for 64 bits architecture? The SFML binaries are compiled for 32 bits.
Laurent Gomila - SFML developer

Qolz

  • Newbie
  • *
  • Posts: 2
    • View Profile
SFML 1.6 Runtime errors
« Reply #5 on: April 26, 2010, 04:24:17 pm »
Thx for posting Laurent ( no it didn't work  ... read below :) )

I found out what the problem was... it was pretty silly.

I used to have version 1.5 of sfml. Then when i upgraded to 1.6 i forgot one thing. The dlls! I used the version 1.5 dlls with version 1.6. :roll:  :oops:

Well anyways it's fixed now, so now i can start learning  :wink:

 

anything