virtualbox - Can't play back .wav file I encoded and decoded with opus_demo -
i downloaded opus codec git repo, ran ./autogen.sh
, ./configure
, make
, , encoded sample file opus examples page ./opus_demo -e voip 48000 1 8000 -cbr -bandwidth nb -complexity 0 -forcemono speech_orig.wav speech_encoded.bit
.
i tried decode ./opus_demo -d 48000 1 speech_encoded.bit speech_48khz.wav
. when try play vlc, doesn't play (it shows playing less second no sound/feedback).
i running ubuntu 14.04 32-bit on virtual machine (virtualbox). link found remotely related problem this, relates else opus_demo
file.
this output opus_demo shell commands:
$ ./opus_demo -e voip 48000 1 8000 -cbr -bandwidth nb -complexity 0 -forcemono speech_orig.wav speech_encoded.bit libopus 1.1.1-beta-38-gfc0276f encoding 48000 hz input @ 8.000 kb/s in narrowband 960-sample frames. average bitrate: 8.000 kb/s maximum bitrate: 8.000 kb/s active bitrate: 8.000 kb/s bitrate standard deviation: 0.000 kb/s $ ./opus_demo -d 48000 1 speech_encoded.bit speech_48khz.wav libopus 1.1.1-beta-38-gfc0276f decoding 48000 hz output (1 channels) average bitrate: 8.000 kb/s maximum bitrate: 8.000 kb/s bitrate standard deviation: 0.000 kb/s
thanks in advance help!
solved it! posting did future readers, in case has same problem.
the problem files passing encoder (opus_demo -e
) .wav files. encoder strictly requires .pcm files, , decoder strictly outputs .pcm files. in order convert .wav files .pcm files, downloaded ffmpeg windows, , ran following commands:
to convert .wav file .pcm file:
ffmpeg -i input.wav -f s16le -acodec output.pcm
to convert .pcm file .wav file:
ffmpeg -f s16le -ar 48k -ac 1 -i input.pcm output.wav
Comments
Post a Comment