I couldn't use wmcodec.exe from command line

Discussion about AudioCoder
Post Reply
AbuOways
Beginner
Beginner
Posts: 3
Joined: Sun Jul 06, 2008 8:46 am
Location: Cairo

I couldn't use wmcodec.exe from command line

Post by AbuOways » Wed Jul 09, 2008 4:14 am

Hi,

I want a utility that can convert wav file to wma of biterate 16 kbps and sample rate of 16Khz, i tried to use ffmpeg as follows:
=========================================
> ffmpeg -y -i "input.wav" -acodec wmav2 -ab 16000 -ar 16000 "output.wma"
=========================================
but it refuse:
=========================================
FFmpeg version SVN-r12665, Copyright (c) 2000-2008 Fabrice Bellard, et al.
configuration: --enable-gpl --enable-postproc --enable-swscale --enable-avfilt
er-lavf --enable-pthreads --enable-liba52 --enable-avisynth --enable-libfaac --e
nable-libfaad --enable-libgsm --enable-memalign-hack --enable-libmp3lame --enabl
e-libnut --enable-libtheora --enable-libvorbis --enable-libx264 --enable-libxvid
--cpu=i686 --extra-ldflags=-static
libavutil version: 49.6.0
libavcodec version: 51.54.0
libavformat version: 52.13.0
libavdevice version: 52.0.0
built on Apr 2 2008 22:35:11, gcc: 4.2.3
Input #0, wav, from 'input.wav':
Duration: 01:09:06.4, bitrate: 176 kb/s
Stream #0.0: Audio: pcm_alaw, 22050 Hz, mono, 176 kb/s
Output #0, asf, to 'output.wma':
Stream #0.0: Audio: wmav2, 16000 Hz, mono, 16 kb/s
Stream mapping:
Stream #0.0 -> #0.0
Error while opening codec for output stream #0.0 - maybe incorrect parameters such as bit_rate, rate, width or height
=========================================
but when i write the same syntax with 32 kbps it didn't return the error and begin with conversion, also with any biterate above 32 kbps.

Then i used the wmcodec.exe that came with mencoder audio edition but i can't write the right syntax, but i tried the syntax below:
=========================================
> wmcodec.exe -ai "input.wav" -m 2 -o "output.wma" -acodec "Windows Media Audio 8" -aformat "16 kbps, 16 kHz, mono CBR" -abuffer 3000
=========================================
and it begin conversion, then it stop with error:
=========================================
No matching audio codec/format found. Using the defaults.Audio codec: 0 Audio format: 0
Duration: 0
Output file: output.wma
Input Count: 1
Starting encoding...
Audio info: 44100Hz/2 channels/16 bits

then the computer hangs and return low virtual memory and return error:
Error when encoding audio sample 91429926

=========================================
and it appear that the parameter that i chosed is not the same in the audio info: Audio info: 44100Hz/2 channels/16 bits

Any one help me how can i use the wmcodec.exe or convert wav to 16kbps wma file using ffmpeg or any command line utility.

Thanks
Geo. Mahmoud

Post Reply