Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
    Bookmark Topic Watch Topic
  • New Topic

Saving sound as byte array

 
colin shuker
Ranch Hand
Posts: 750
  • Mark post as helpful
  • send pies
  • Report post to moderator
Hi I posted this question in the I/O streams section, but there was little response, and I have a little more info now:

I've ommitted try/catch blocks for clarity,
I am able to play a sound using...


Now, I can turn the file into bytes using..


So what I would like to do is play a sound given a byte[]
I attempted this..., but it threw an Exception

But AudioStram as=new AudioStream(is); throws an exception with message
-> "could not create audio stream from input stream"

Is there any way to solve this?
Thanks for any help
 
    Bookmark Topic Watch Topic
  • New Topic