WMA to MP3 in Linux

 

WMA to MP3

#!/bin/bash


# Dump wma to mp3 
for i in *.wma 
do 
  if [ -f "$i" ]; then 
  rm -f "$i.wav" 
  mkfifo "$i.wav" 
  mplayer -quiet -vo null -vc dummy -af volume=0,resample=44100:0:1 -ao pcm:waveheader:file="$i.wav" "$i" & 
  dest=`echo "$i"|sed -e 's/wma$/mp3/'` 
  lame -V0 -h -b 160 --vbr-new "$i.wav" "$dest" 
  rm -f "$i.wav" 
fi 
done 

-------------------------

MP3 to WAV 
Using mpg321 

mpg321 is a free MP3 player (drop-in replacement for mpg123). 
for i in *.mp3; do  
  mpg321 -w `basename $i .mp3`.wav $i 
done

from http://en.linuxreviews.org/MPlayer

 

 

你可能感兴趣的:(linux,F#,bash,vc++)