The last comment about the unsigned int looping back to its max when you decrement it below zero is correct. Try it, I did, & it went to:
4294967295
which is exactly what the max of an unsigned 32 bit variable is:
( 2 ^ 32 ) - 1
A Problem with OpenAL and Ogg Vorbis
The version of openAL that supports Ogg Vorbis is still a BETA version from what I''ve heard/read. You might give those guys some feedback about whats going on, maybe its related to Ogg Vorbis. Have you tried it with WAV files or some other format that is supported in a non-beta version of openAL???
Whatsoever you do, do it heartily as to the Lord, and not unto men.
I used the code from that site and my app can play OGG files perfectly.
I had to do some changes but now it''s ok on different computers.
(if you use the exact code that tutorial gives you the sound has an odd error after about one second - anyway it works)
I don''t think the problem is about the directX version or the sound card (even if it could be).
About unsigned ints:
he doesn''t use an unsigned value, so what''s wrog with that?
Anyway if you had to put the >0 it means it''s a negative value (not 0). Maybe (i''m just guessing), that the alGetAourcei() gives "processed" the value of -1 when something goes wrong (I know of other funcions doing that).
This would mean the error is somewhere else in your code.
Try compiling the code exactly as the tutorial gives it to you.
If it works (as I think) it means you''ve done something wrong sowhere else.
Let us know...
I had to do some changes but now it''s ok on different computers.
(if you use the exact code that tutorial gives you the sound has an odd error after about one second - anyway it works)
I don''t think the problem is about the directX version or the sound card (even if it could be).
About unsigned ints:
he doesn''t use an unsigned value, so what''s wrog with that?
Anyway if you had to put the >0 it means it''s a negative value (not 0). Maybe (i''m just guessing), that the alGetAourcei() gives "processed" the value of -1 when something goes wrong (I know of other funcions doing that).
This would mean the error is somewhere else in your code.
Try compiling the code exactly as the tutorial gives it to you.
If it works (as I think) it means you''ve done something wrong sowhere else.
Let us know...
January 16, 2004 03:32 PM
I only said it would be an infinite "if he did use one" because it was suggested. Also, Lazork, did you do the same buffer_queued & buffer_processed queries? Those worked too? Or did you just load an ogg file & play it?
Just trying to examine all posibilities & then narrow things down. I will attempt some OGG crap tonight, hopefully.
Just trying to examine all posibilities & then narrow things down. I will attempt some OGG crap tonight, hopefully.
no the main code still doesn''t work on the old crap sound card, and I think that the queues thing isn''t serious, perhaps it''s because I''m using winAPI instead of consoles so the thing may be called at the start of the program where it''s not supposed to be or something. It doesn''t seem serious though - can''t detect any memory leaks or slowness of the program. I just hate it when the demo''s music won''t run on more than half of all computers!
The Love Of Trees
Here''s a question for you:
do you create a context and set up a device?
In this case (if you''re using winapi) you should do that on WM_INITDIALOG.
About that old card:
Recentlt I tried my program (wich works perfectly on most computers) on an old notebook; well, my program couldn''t even initialize OpenAL and I had to reboot the pc. It seemed like the pc had run into an endless loop...
There''s a thing I''ve not understood yet:
does your code work on any of the computers you''ve tried? I mean, can you hear the sound correctly?
do you create a context and set up a device?
In this case (if you''re using winapi) you should do that on WM_INITDIALOG.
About that old card:
Recentlt I tried my program (wich works perfectly on most computers) on an old notebook; well, my program couldn''t even initialize OpenAL and I had to reboot the pc. It seemed like the pc had run into an endless loop...
There''s a thing I''ve not understood yet:
does your code work on any of the computers you''ve tried? I mean, can you hear the sound correctly?
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement