Using OpenAL?

Everything else that doesn't fall into one of the other PB categories.
Dreglor
Enthusiast
Enthusiast
Posts: 759
Joined: Sat Aug 02, 2003 11:22 pm
Location: OR, USA

Using OpenAL?

Post by Dreglor »

I'm trying to get OpenAL to Work.

My frist attempt really didn't go anywere,
since you have to use the dll I had to convert the function exports from the header which wasn't the easiest thing to do.
The types are whats getting me.

I wrote a program to go though the header (I manually do each one) and pull the functions definitions out.

Problems is that I think the types are screwy, parameters like buffer is defined with alvoid :\
Which is defined as void when they should be longs.
So im not sure what to do really.

I got it to compile atleast but when I did a example from a tutorial and the ALUT which doesn't seam to have functions in the dll I wrote the functions by hand they seam to be Cdecl so I used callcfunction insted of callfunction

What I get is a invaild memory access.

Can you guy help me out here?
here is the source ive been working with:
OpenALForPB.zip
Image
~Dreglor
jack
Addict
Addict
Posts: 1336
Joined: Fri Apr 25, 2003 11:10 pm

Post by jack »

i will look into this, but for starters the DLL don't seem to have any functions starting with "alu", at least that's what this little prog reported.

Code: Select all

If OpenLibrary(0,"OpenAL32.dll")
  If ExamineLibraryFunctions(0) 
    While NextLibraryFunction() 
      Debug LibraryFunctionName() 
    Wend 
  EndIf 
  CloseLibrary(0) 
EndIf 
right now it's time for me to go to work.
DarkDragon
Addict
Addict
Posts: 2228
Joined: Mon Jun 02, 2003 9:16 am
Location: Germany
Contact:

Post by DarkDragon »

I made a wrapper, I'll finish it and upload it, ok? Some values are unsigned, I'll just implement something that fixes that.
bye,
Daniel
DarkDragon
Addict
Addict
Posts: 2228
Joined: Mon Jun 02, 2003 9:16 am
Location: Germany
Contact:

Post by DarkDragon »

http://www.bradan.net/downloads/OpenAL.zip OpenAL wrapper with working Example.
bye,
Daniel
Dreglor
Enthusiast
Enthusiast
Posts: 759
Joined: Sat Aug 02, 2003 11:22 pm
Location: OR, USA

Post by Dreglor »

heh, you guys just make my work so easy :lol:
~Dreglor
rory-games
User
User
Posts: 31
Joined: Sun Feb 02, 2020 9:14 am
Contact:

Re: Using OpenAL?

Post by rory-games »

is this rapper still available, I really need it for my audio games.
I can't be bothered making a 3d sound positiong formula, that'd take an extremely long time.
And pure basic sound3d is not apt for true 3d sound, since it sounds the same in front and behind.
Thanks in advance!
Post Reply