Guyfawkes
Certified Idiot :)
Since I started coding on the GP2X I have noticed that the main SDL development area is the graphics side of things such as the Hardware SDL support by Payern. This is great, but now we have a bottleneck (in my opinion) with the audio side with music playback.
I have been testing MP3, OGG and MOD playback in my game to see which is the fastest and surprisingly MP3 works the best. The following is from a menu screen in my game:
No music playing = ~100 FPS
MP3 music playing (44100Hz Stereo) = ~60 FPS
OGG music playing (44100Hz Stereo) = ~53 FPS
MOD music playing (4 Channel) = ~49 FPS
As you can see its taking anything from over a third to half the FPS depending on the format, which is quite bad. I know the music could encoded to say 22,000Hz which may speed things up (I haven't checked) but why should quality be sacrificed?
I am aware that some work has been going on for OGG playback using the second CPU, but this is not for SDL and it is out of my depth to try and add it. So, and I bet you all knew this was coming is there anyone interested in trying to add support for it? I really think music playback being optimised or offloaded to the second CPU would improve things a great deal for both developers and the players.
Feel free to reply back with your thoughts on this and if you have you own results let me know. And more importantly if you would like to be involved with improving music playback reply here.
Thanks for your time!
I have been testing MP3, OGG and MOD playback in my game to see which is the fastest and surprisingly MP3 works the best. The following is from a menu screen in my game:
No music playing = ~100 FPS
MP3 music playing (44100Hz Stereo) = ~60 FPS
OGG music playing (44100Hz Stereo) = ~53 FPS
MOD music playing (4 Channel) = ~49 FPS
As you can see its taking anything from over a third to half the FPS depending on the format, which is quite bad. I know the music could encoded to say 22,000Hz which may speed things up (I haven't checked) but why should quality be sacrificed?
I am aware that some work has been going on for OGG playback using the second CPU, but this is not for SDL and it is out of my depth to try and add it. So, and I bet you all knew this was coming is there anyone interested in trying to add support for it? I really think music playback being optimised or offloaded to the second CPU would improve things a great deal for both developers and the players.
Feel free to reply back with your thoughts on this and if you have you own results let me know. And more importantly if you would like to be involved with improving music playback reply here.
Thanks for your time!