Skip to main content
GameDev.net gamedev.net
🔒 Locked

[java] Best way to implement sound?

Started by CodeMachine Sep 23, 2006 at 7:10 AM 1 replies 700+ views
Original Post
CodeMachine
CodeMachine
Hi How do you implement sounds in an application the best way? I've seen several ways for how to implement sounds in general (both application and applets), but I dont know which is the "best"... For applications I've found: 1. javax.sound.sampled ? 2. javax.sound.midi ? 3. sun.audio.AudioPlayer ? Which solution should I use? If I have mid-files, then I guess javax.sound.midi is ALWAYS the best solution? And what is the difference between 1 and 3? WAV/AU, 1 or 3? Kind Regards [Edited by - CodeMachine on September 23, 2006 5:06:04 PM]
Son of Cain
Son of Cain
It depends on your game! I like OpenAL a lot, if it's available for you, give it a shot.. Otherwise, the packages you mentioned can be used to create a good sound management system... But it would give you quite a bit of work!

Take a look here and look for the "sound" chapter for insights.
a.k.a javabeats at yahoo.ca

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.