[FFmpeg-user] amix: Hard limit for number of inputs?

Paul B Mahol onemda at gmail.com
Tue Jul 16 19:56:22 EEST 2019

On 7/16/19, Reino Wijnsma <rwijnsma at xs4all.nl> wrote:
> On 16-7-2019 17:45, Paul B Mahol <onemda at gmail.com> wrote:
>> On 7/16/19, Reino Wijnsma <rwijnsma at xs4all.nl> wrote:
>>> I can't use these filters. Have a look at the Youtube video please.
>>> I wish it was a simple matter of just concatenating all segments, but it
>>> isn't, because the segments don't align perfectly.
>>> Each segments has to start at a very specific time.
>>> Then it's a matter of mixing everything at full volume(!), so there's no
>>> fading involved at all.
>> acrossfade can just *join* it with nofade curve, which basically disables
>> fading.
> But that's the point, I need to *mix*all segments, not join/concatthem.
>> On 7/16/19, Reino Wijnsma <rwijnsma at xs4all.nl> wrote:
>>> Do you happen to know why ffmpeg reports a completely wrong duration?
>>> Related question/suggestion:
>>> It's really cumbersome to always having to specify the delay for all(!)
>>> channels: [1]adelay=158792S|158792S[E2];
>>> How about a default behaviour where specifying an amount of
>>> milliseconds/samples once(!) applies to all channels:
>>> [1]adelay=158792S[E2];
>>> And if you want a specific delay for another channel, then you can do so
>>> as
>>> is already possible.
>>> This would make my commandline a lot shorter!
>> The thing with amix is that by *reducing volume* by mixing and adding it
>> back with volume,
>> you basically loose quality. It is more obvious with float sample
>> format then double one.
> I'm actually trying to prefend volume reduction. I only want to mix all
> segments.
> (I noticed I forgot to attach the Avisynth script I used years ago. Attached
> now.)
> In the Avisynth script I align all segments (with sample precision) and mix
> everything with full volume: MixAudio(clip1,clip2,1.0,1.0)
> ffmpeg.exe -h filter=amix
> [...]
>   weights           <string>     ..F.A.... Set weight for each input.
> (default "1 1")
> I figure "1 1" does the same as MixAudio(clip1,clip2,1.0,1.0), doesn't it?
> But amix still reduces the volume dramatically.
> Let me ask you this: How can I do MixAudio(clip1,clip2,1.0,1.0) with ffmpeg
> leaving the volume completely untouched?

There is currently no way.

>> Option could be added to amix filter to just sum samples as is.
> You mean the adelay filter, right?


>> Also what ffmpeg version you are using?
> Please see my first post.
> On 16-7-2019 18:36, Paul B Mahol <onemda at gmail.com> wrote:
>> Actually ffmpeg is behaving correctly, your [29]adelay is missing one S.
> Well I'll be darned. A typo. Thanks!
> That solves that problem, but the volume issue remains.
> -- Reino

More information about the ffmpeg-user mailing list