WebM export mono audio


#1

Please, how may I export project to WebM with MONO audio? Is there any paramater to do it? I mean I’ve got in “other” tab stuff like this:

rc_lookahead=16
quality=good
speed=0
vprofile=0
qmax=51
qmin=11
slices=4
maxrate=24M
minrate=100k
arnr_max_frames=7
arnr_strength=5
arnr_type=3

What to add to export MONO (using vorbis)
Thank you


#2

Add to that list:

channels=1


#3

Thanks for a hint, I’ll give it a try.

Please, where to find a list of available parameters such as this one for cases where there is no GUI element available?

Or some websites to look for?


#4

Here is the list of parameters:
https://mltframework.org/plugins/ConsumerAvformat/
Most of those are FFMpeg parameters because Shotcut uses FFMpeg for encoding.


#5

Thanks.

Unfortunately, adding “channels=1” produces a .WEBM file without any audio at all :confused:


#6

maybe try “ac=1”. Also try both “ac=1” and “channels=1” together.

Sorry, I haven’t tried this myself.


#7

This post piqued my interest.

I tried to export a clip with the WebM preset and mono audio. Added channels=1. Did not work. The video exported with no audio.

Tried this as well. Did not work. Video exported with no audio.

Tried the same clip with the Shotcut default mp4 export. The result is a video with really poor audio.:frowning:


#8

It seems to work for some formats but not others. Here is what I tried and the corresponding result:

DNxHD + PCM: mono
MP4+ AAC: stereo
WebM + vorbis: no audio

Looks like it needs some work to be fully supported.


#9

Update: I just tried WebM + opus and it works. Here are the steps:

  1. Select the WebM export preset.
  2. On the Audio tab, change the codec to “libopus”.
  3. On the Other tab, add “channels=1”

#10

Just tried these. Audio quality is poor.
For now it seems best to use Audacity to convert audio to mono then attach it to the video.


#11

Tried it. It works but the audio quality is poor.:disappointed:

When I used Audacity to convert the audio to mono and exported the file the audio quality was very good.

I can upload the videos for comparison.


#12

Sure. Or maybe just describe what you mean by “poor”. Is it distorted? Does it sound like an echo?


#13

Here are the videos.

WebM with libopus.

Mp4 with Audacity.


#14

It is difficult for me to hear much difference between the two clips. They both have some high-frequency distortions.

Some additional thoughts to help figure this out:

  • How many channels are in the original content? I noticed in the source code that when two channels are converted to one channel, it just throws away the second channel. So if the original content is stereo, that might be a problem.

  • When you export, what settings are you using for “Sample Rate” and “Bitrate”?


#15

?? Wow Brian, the difference is extreme - I can’t believe you find it difficult to hear!
Are you listening on a mobile device?


#16

2 channel stereo.

Video
ID : 1
Format : Sorenson 3
Codec ID : SVQ3
Codec ID/Info : Sorenson Media Video 3 (Apple QuickTime 5)
Duration : 3 min 38 s
Bit rate : 2 109 kb/s
Width : 640 pixels
Height : 360 pixels
Display aspect ratio : 16:9
Frame rate mode : Constant
Frame rate : 25.000 FPS
Bits/(Pixel*Frame) : 0.366
Stream size : 54.9 MiB (85%)
Language : English
Encoded date : UTC 2005-01-11 15:33:32
Tagged date : UTC 2005-01-11 16:21:21

Audio
ID : 2
Format : ADPCM
Format settings, Firm : IMA
Codec ID : ima4
Duration : 3 min 38 s
Bit rate mode : Constant
Bit rate : 375 kb/s
Channel(s) : 2 channels
Sampling rate : 44.1 kHz
Bit depth : 16 bits
Stream size : 9.76 MiB (15%)
Language : English

I’m using defaults.
For the WebM export
image

For the mp4 export.

image


#17

Please be aware there is a bug in MLT when trying to output mono that I have not been able to solve yet. Sorry, but mono is not much of a priority for me.


#18

I fixed the bug that Dan was referring to:

Hopefully that will solve the quality problem in the next release.


#19

Thanks to all