• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Getting soundwave from a sound file

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I have a project running in which I need to do some mathematical analysis on a soundwave. And this soundwave needs to come from a file, say, an MP3 one. I have spent the day looking in and out of API's, but everything seems to be built towards _playing_ the sound, which isn't what I want. I want the "physical" wave data.

So before I get a headache I wonder if anyone who has worked with something similar before may know where I can go. Maybe JMF actually got what I want, but I seem to be unable to find it?

Many thanks,
Eivind Fonn
 
Bartender
Posts: 9626
16
Mac OS X Linux Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I haven't looked at JMS in a year or so, but I remember Player objects can have custom Control types which have additional functionality. You can get these controls by calling player.getControls(); (more info here in the JMF guide) You may be able to find a waveform control but I don't know how you'd go from displaying the waveform to getting the actual wave data.
 
Eivind Fonn
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I believe I found a code which works for WAV files:

http://www.cs.princeton.edu/introcs/22inout/StdAudio.java.html
 
reply
    Bookmark Topic Watch Topic
  • New Topic