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

Author Topic: Possible bug in sf::sound  (Read 2926 times)

0 Members and 1 Guest are viewing this topic.

Tytan

  • Newbie
  • *
  • Posts: 12
    • View Profile
Possible bug in sf::sound
« on: December 02, 2016, 09:17:47 am »
So, I have a average game, with networking audio, and graphics, I start the game for another round of debugging, and see this in the console window:
AL lib: (EE) MMDevApiOpenPlayback: Device init failed: 0x80004005
Failed to open the audio device
An internal OpenAL call failed in SoundBuffer.cpp(46).
Expression:
   alGenBuffers(1, &m_buffer)
Error description:
   AL_INVALID_OPERATION
   The specified operation is not allowed in the current state.

An internal OpenAL call failed in SoundBuffer.cpp(265).
Expression:
   alBufferData(m_buffer, format, &m_samples[0], size, sampleRate)
Error description:
   AL_INVALID_OPERATION
   The specified operation is not allowed in the current state.

An internal OpenAL call failed in SoundSource.cpp(37).
Expression:
   alGenSources(1, &m_source)
Error description:
   AL_INVALID_OPERATION
   The specified operation is not allowed in the current state.

An internal OpenAL call failed in SoundSource.cpp(38).
Expression:
   alSourcei(m_source, AL_BUFFER, 0)
Error description:
   AL_INVALID_OPERATION
   The specified operation is not allowed in the current state.

An internal OpenAL call failed in Sound.cpp(104).
Expression:
   alSourcei(m_source, AL_BUFFER, m_buffer->m_buffer)
Error description:
   AL_INVALID_OPERATION
   The specified operation is not allowed in the current state.

 

Not quite sure if you need the source code for my game, or what this means, is it a bug I have to deal with? xD
« Last Edit: December 02, 2016, 09:24:49 am by Tytan »

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11030
    • View Profile
    • development blog
    • Email
Re: Possible bug in sf::sound
« Reply #1 on: December 02, 2016, 09:39:03 am »
It means that OpenAL can't open the audio device. This can have multiple reasons, quite common is that they driver is not installed or is buggy. Or that some application has take exclusive access to the audio device.

Try to play back some sound through another application. Check your running applications and if you can't find anything, try rebooting your system to reload all drivers.
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

Tytan

  • Newbie
  • *
  • Posts: 12
    • View Profile
Re: Possible bug in sf::sound
« Reply #2 on: December 02, 2016, 09:51:32 am »
Thank god! Though it was something to do with my code xD

Thanks :)

 

anything