Skip to Main Content

Java SE (Java Platform, Standard Edition)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How do you output audio from a RAW audio stream (no formatting)

843802Apr 15 2009 — edited Apr 16 2009
Hi, I have spent some time playing around with the Java Sound api, but it seems it will only process 'audio files/streams' of a known format...

What we have is a 16bit 16kHz .RAW audio file, which is literally just 2-byte samples written one after the other, with no additional formatting/header.
The plan is to stream this 16bit 16kHz audio through a socket into our Java applet which will play it in real time.

Is it possible to do this using the standard Java sound library, or will I have to turn my attention to something like RTP?

I have yet to find any forum threads with similar intentions, so if anybody has any ideas they would be greatly appreciated.

Thanks in advance,
John Redford.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 14 2009
Added on Apr 15 2009
7 comments
488 views