0
0

I am writing an mp3 player in VB6(sp5), Win 2000 (sp3), soundblaster live! 5.1., P4 1700Mhz. When I enable some dirextx effects like flanger, disortion, … and pause the channel opened by FSOUND_Stream_OpenFile with command FSOUND_SetPaused(Kanal,True) , the CPU usage grows to 100%, freezing whole app, system, mouse,… The only way I know to get cpu usage back to normal is to call FSOUND_Close or to play the channel again by FSOUND_SetPaused(Kanal,Fase). Am I doing something wrong? :( I am from Slovakia so excuse me for English. Thank you.

  • You must to post comments
0
0

I have the same problem, except it works fine on my home pc
and doesn’t on my work pc. I’ve tried all kinds of combinations of flags and directx settings when opening and playing but haven’t had any luck.
High CPU usage on pause and end of a song.
I’ve got no explanation but I’ll follow this post to see if anyone has a solution.

  • You must to post comments
0
0

First off, if you are enabling FX, why would you not play the channel
again? FX can only be initialized when the sound is paused. So, you
pause the channel and the CPU usage grows to 100%, but you don’t
unpause it?

Second, When you use FSOUND_Close you basically tell FMOD
to shutdown.

I’m assuming you’re using DirectX 8.0 or higher.

If you give me more details on how you load and play the file
I can help you better.

  • You must to post comments
0
0

Ok, here are more details:
At the start I open a file
StrOpenedF = FSOUND_Stream_OpenFile(Song, FSOUND_NORMAL, 0)
‘handle to stream
Then, I play that stream
Kanal = FSOUND_Stream_PlayEx(FSOUND_FREE, StrOpenedF, vbEmpty, False)
‘handle to channel
I am not enabling FX on channel opened by FSOUND_Stream_OpenFile but on FSOUND_SYSTEMCHANNEL (-1000), because I want to be able to draw spectrum, enable functions like StartNoise, change speed of the song, … So I first pause it by
Call FSOUND_SetPaused (FSOUND_SYSTEMCHANNEL, True), then enable some effect
FxId = FSOUND_FX_Enable(FSOUND_SYSTEMCHANNEL, FSOUND_FX_DISTORTION), and unpause it by
Call FSOUND_SetPaused (FSOUND_SYSTEMCHANNEL, False).
Fine, now the effect is enabled, music is playing,…

But command Call FSOUND_SetPaused(Kanal,True) results in that 100% cpu usge, … It also happens at the end of the song.
The more effects(like 10 FxId s for the eqalizer) are enabled, the more cpu it eats when paused. When there are 16 effects enabled my computer just freezes, playing beeps from the pc-speaker when you click somewhere. I am using DirectX 9.0 (4.09.0000.0900).

Ok, I think this is very detailed description.

  • You must to post comments
0
0

Hmm. Download X Media Lite
[url:1gy3j609]http://xmedia.sphosting.com/download.htm[/url:1gy3j609]
and see if it works. The source code is included. All you have to
do is uncomment the Enable FX stuff and watch the CPU Meter.

This program was designed for testing puroses only, so it
doesn’t do much.

Good luck.

  • You must to post comments
Showing 4 results
Your Answer

Please first to submit.