PDA

View Full Version : Which takes more system resources, a .wav/.ogg sample or a MIDI note?


Corey
10-11-2005, 12:32 AM
Does anyone know what the real difference in overhead is between playing a small .wav/.ogg file of a note as compared to playing a MIDI note? I'm starting design on "the world's most advanced" metronome but I need to figure out my approach first. MIDI is tricky but do-able, if it will mean a significant savings in overhead or increase in performance then I'll go that route but if not, I'll probably make it sample based.

eric_darling
10-11-2005, 11:37 AM
Just guessing, Corey, but I would think that MIDI would take the least amount of system resources.

WAV, while uncompressed, is large, and requires lots of disk access and storage space.
MP3/OGG is heavily compressed, and requires a good bit of processing power.

MIDI, on the other hand, has been around since dirt, and taxes very low end computers hardly at all.

Lorne
10-12-2005, 09:21 AM
MIDI is normally handled by the sound card (hardware) and at one point I know that it used the least system resources. One caveat is that the sound banks on most consumer sound cards are really bad. Like, early 80s synthesizer bad. :)

(I had a sound card by Diamond that let you upgrade the sound bank memory chip. I think more recent cards allow you to store samples in system memory too.)

'Course, for a metronome the sound quality probably isn't a priority, but if you use MIDI just remember that it can sound very different between systems.

.wav needs to be loaded, .ogg needs to be loaded then decompressed, but for midi all it needs to know is what note to play.

I have no idea what actual real-world difference it makes, and I suspect on a modern system the differences would be negligible, but it's something you could determine with a bit of time and a sampling of your target hardware. (Build a test app and post it...)