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

Author Topic: SFML2.0 app won't start if any sound classes are used  (Read 5708 times)

0 Members and 1 Guest are viewing this topic.

asphyxiac

  • Newbie
  • *
  • Posts: 5
    • View Profile
SFML2.0 app won't start if any sound classes are used
« on: November 14, 2009, 11:05:46 am »
Hi, I've been working with SFML2.0 branch, but I can't get the sound to work.

Everything works fine until I decide to use any sound class, as soon as I add sf::sound etc, my app won't launch. "Run with Debugging" in VS starts the app, I can see all the dlls loading up in the output window but it never hits the first line of main(). It doesn't crash, it just doesn't do anything either.

I suspect it's something to do with loading the dlls, but I'm not sure how all this works.

It works fine on 1.5, and the sample app 'sound' has exactly the same behaviour - it won't start.

Any ideas?

Cheers.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
SFML2.0 app won't start if any sound classes are used
« Reply #1 on: November 14, 2009, 12:44:48 pm »
Have you tried to use the static SFML libraries?
Laurent Gomila - SFML developer

asphyxiac

  • Newbie
  • *
  • Posts: 5
    • View Profile
SFML2.0 app won't start if any sound classes are used
« Reply #2 on: November 17, 2009, 03:39:36 am »
Yes, static libs work. But I'd much rather use the dlls...

asphyxiac

  • Newbie
  • *
  • Posts: 5
    • View Profile
SFML2.0 app won't start if any sound classes are used
« Reply #3 on: November 17, 2009, 04:47:24 am »
Static libs work for "sound" sample project, but not mine. But if I add "/NODEFAULTLIB:LIBCMT" to linker command line then my project will compile against static libs, but still not the dynamic ones.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
SFML2.0 app won't start if any sound classes are used
« Reply #4 on: November 17, 2009, 07:42:16 am »
Ok, I see what the problem is. Actually, almost all the audio issues have the same source :)
Laurent Gomila - SFML developer

panithadrum

  • Sr. Member
  • ****
  • Posts: 304
    • View Profile
    • Skyrpex@Github
    • Email
SFML2.0 app won't start if any sound classes are used
« Reply #5 on: November 17, 2009, 09:59:24 am »
Dynamic libs for SFML2 doesn't work?

And... my compiler tells me to put "/NODEFAULTLIB:LIBCMT" too.
What happen if I write that? I don't see anything at all.

asphyxiac

  • Newbie
  • *
  • Posts: 5
    • View Profile
SFML2.0 app won't start if any sound classes are used
« Reply #6 on: November 18, 2009, 01:23:34 am »
Laurent, Is there a workaround I can use until it gets fixed?
Cheers!

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
SFML2.0 app won't start if any sound classes are used
« Reply #7 on: November 18, 2009, 08:05:30 am »
I think that using static libs should work.
Laurent Gomila - SFML developer

 

anything