ffmpeg.wasm
ffmpeg.wasm copied to clipboard
Converting MP3 to Opus using libopus codec
I am trying to convert MP3 to Opus but I am getting a 0-byte Opus file. Also, the file is not working.
I am using this command:
ffmpeg_cmd = ['-i', 'audio.mp3', '-vn', '-c:a', 'libopus', '-b:a', '128k', 'audio.opus'];
I have even tried using the Playground of the documentation and have had the same result. But if I use libvorbis instead of libopus it's converting smoothly and the output file also works fine. But this method changes the output codec to vorbis which I don't want and I needed to make the libopus work.
Please help!!!
Note: I have also tried using 'opus' instead of 'libopus'