Users upload WAV files to my service. I need to programmatically know the bit rate and sample rate of the WAV files.
How would I do this? Preferably on Windows, though a Unix tool would be fine too. A command line tool would be handy.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
See MediaInfo. This tool provides Graphical user interface, command line interface, and library (.dll/.so/.dylib). I prefer using library.
If you wanna try CLI, here’s a command line example.
Then I got a result.xml.
Just parse this file and find the string
<Sampling_rate>22.05 KHz</Sampling_rate>.