0
0

hello, everyone, and thanks for this wonderul API…
I have been working on a sound system for my game for some time, under Linux, and it works great, when switching to Windows, and using FSOUND_OUTPUT_WINMM everything works fine, just like Linux, but when I switch to FSOUND_OUTPUT_DSOUND, FSOUND_SAMPLE returned by FSOUND_Sample_Load isn’t always valid, so I get an error when trying to use it later, I searched the forums, and found something about using FSOUND_FREE, made sure that my program actually use it, but still I have the same error, so my question is, what else (besides FSOUND_FREE), should I do to make FSOUND_OUTPUT_DSOUND work.
Note: Examples work fine.
Thanks in advance.

  • You must to post comments
0
0

Perhaps you’re trying to 3d position stereo sounds and using FSOUND_HW3D.

  • You must to post comments
0
0

>what flags are you passing to FSOUND_Sample_Load? And what format is the sample you are trying to load?

for 2D sounds:
FSOUND_LOADMEMORY | FSOUND_2D | FSOUND_LOOP_NORMAL

for 3D sounds:
FSOUND_LOADMEMORY | FSOUND_HW3D | FSOUND_LOOP_NORMAL

File format is wav (small files)

>Perhaps you’re trying to 3d position stereo sounds and using FSOUND_HW3D.

I set 3D positions with:
FSOUND_3D_SetAttributes
and
FSOUND_3D_Listener_SetAttributes
Anything wrong here?

PS: I would have posted to code, sound classes are in one file, but it’s huge, and filled with game-related stuff…

Thanks for you efforts :)

  • You must to post comments
0
0

This reminds me of a bug in fmod 3.6x (I don’t know if it is 3.7x): FSOUND_FORCEMONO does not work with looping samples: it plays at the default sample rate the first time round the loop, then double the second time, double again the third time, etc. It works fine with looping streams though.

What made me suggest stereo files and HW3D is it plays back without error or warning using the fmod software mixer (i.e. when there is no HW3D acceleration like on Linux or WinMM), though it does sound rather strange. However when switching to direct sound and an sblive/audigy/audigy2, FSOUND_CheckError says something about being unable to allocate a buffer and the sample does not load.

Lorien

  • You must to post comments
0
0

I tried FSOUND_FORCEMONO and it caused 3D sounds to give errors too, removing it, I only get errors when playing 2D sounds, because the sample isn’t valid, any other ideas?
thx

  • You must to post comments
0
0

It could well have been using FORCE_MONO on already mono samples. I’ll look into it on the weekend and get back to you if I can reproduce it.

  • You must to post comments
Showing 5 results
Your Answer

Please first to submit.