2011년 12월 5일 월요일

sox Sound eXchange : universal sound sample translator

터미널에서 음악 파일을 변환하는 방법

wav 파일을 raw 파일로 변환 (8000Hz 모노로)

sox -V input.wav -r 8000 -c 1 -s output.raw

옵션 

-v|--volume FACTOR             Input file volume adjustment factor (real number)
--ignore-length                        Ignore input file length given in header; read to EOF
-t|--type FILETYPE                 File type of audio
-s/-u/-f/-U/-A/-i/-a/-g                 Encoding type=signed-integer/unsigned-integer/floating point/mu-law/a-law/ima-adpcm/ms-adpcm/gsm-full-rate
-e|--encoding ENCODING    Set encoding (ENCODING in above list)
-b|--bits BITS                           Encoded sample size in bits
-1/-2/-3/-4/-8                             Encoded sample size in bytes
-N|--reverse-nibbles               Encoded nibble-order
-X|--reverse-bits                      Encoded bit-order
--endian little|big|swap          Encoded byte-order; swap means opposite to default
-L/-B/-x                                      Short options for the above
-c|--channels CHANNELS    Number of channels of audio data; e.g. 2 = stereo
-r|--rate RATE                          Sample rate of audio
-C|--compression FACTOR  Compression factor for output format
--add-comment TEXT            Append output file comment
--comment TEXT                    Specify comment text for the output file
--comment-file FILENAME    File containing comment text for the output file
--no-glob                                  Don't `glob' wildcard match the following filename


댓글 없음:

댓글 쓰기

GDB

변수 값 출력 명령 출력 명령 p [변수명] p [함수명] p /[출력형식] [변수명]  출력 형식 t : binary o: octal d: decimal u: unsigned decimal x: hexadecimal c: ...