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

Author Topic: procedure entry point error when trying to create sound buffer  (Read 4268 times)

0 Members and 1 Guest are viewing this topic.

bimth

  • Newbie
  • *
  • Posts: 4
    • View Profile
    • Email
I'm learning SFML and up until trying to get the audio module working things had been going fine. I haven't been able to find this particular error so I thought it was worth coming here.

All I'm trying to do is play a simple .wav file on the click of the mouse.

I stripped down all my code to the relevant audio code. There was a main game loop and events and such but its not important to the issue:
#include <SFML/Audio.hpp>

int main()
{
        sf::SoundBuffer buffer;
        buffer.loadFromFile("Ring01.wav");

        sf::Sound sound;
        sound.setBuffer(buffer);

        sound.play();
       
        return 0;
}
 

Error: "Entry Point Not Found: The procedure entry point at alcCaptureSamples could not be located in the dynamic link library C\:[rest of path]\sfml-audio-2.dll"

In Linker -> Input -> Additional Dependencies I have added:
openal32.lib;  <- Added this because I saw a suggestion somewhere online for a similar issue. Didn't help.
sfml-audio-d.lib;
sfml-graphics-d.lib;
sfml-window-d.lib;
sfml-system-d.lib;

I only installed SFML a couple days ago and followed the guide for Visual Studio. (I didn't do the SFML_STATIC method where you have to include all the -s .lib files). To be honest I'm not great at this type of stuff. (linking, additional dependencies, .dll, .libs). So any suggestions would be appreciated. Diagnosing this will probably be a valuable experience in learning how this kind of stuff works.

If more information is needed, just let me know.

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11027
    • View Profile
    • development blog
    • Email
Re: procedure entry point error when trying to create sound buffer
« Reply #1 on: July 11, 2018, 08:29:06 am »
Do you have the openal32.dll next to your executable?
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

bimth

  • Newbie
  • *
  • Posts: 4
    • View Profile
    • Email
Re: procedure entry point error when trying to create sound buffer
« Reply #2 on: July 11, 2018, 03:52:08 pm »
I am 99% sure I do. I put all the .dlls next to my executables when I set up the project. I will confirm when I get home this evening.

bimth

  • Newbie
  • *
  • Posts: 4
    • View Profile
    • Email
Re: procedure entry point error when trying to create sound buffer
« Reply #3 on: July 11, 2018, 10:53:24 pm »
Do you have the openal32.dll next to your executable?

Yes, openal32.dll is located with my main.cpp, along with the rest of the .dll files I've been successfully using to do Window and Graphics module tasks previously. Audio is the only thing that's given me trouble.

Edit: Sorry, yes that was the issue. I misunderstood the location where the .dlls had to be placed. For some reason the graphics and window modules worked with the .dlls placed where I had them previously, but the audio module needed them with the .exe. Told you I was bad at this stuff...
« Last Edit: July 13, 2018, 02:01:48 am by bimth »

bimth

  • Newbie
  • *
  • Posts: 4
    • View Profile
    • Email
Re: procedure entry point error when trying to create sound buffer
« Reply #4 on: July 12, 2018, 05:25:57 pm »
Saw another post regarding a similar error where a user questioned where the poster got his openal32.dll. The poster said he got it from a random website and his problem was resolved when he used the openal32.dll that came with the SFML download.

I am already using the .dll that came with the SFML download; therefore, I do not believe that is my issue.