[FFmpeg-user] sendcmd and overlay

Gyan Doshi ffmpeg at gyani.pro
Sun Feb 2 06:44:26 EET 2020



On 02-02-2020 03:58 am, Michael Koch wrote:
> Am 01.02.2020 um 22:35 schrieb Paul B Mahol:
>> On 2/1/20, Michael Koch <astroelectronic at t-online.de> wrote:
>>>>>> Console output:
>>>>>>
>>>>>> F:\Test>c:\ffmpeg\ffmpeg -i main.mov -i lp.mp4 -filter_complex "[1
>>>>>> ]scale=100:100,sendcmd=f=test.cmd[2];[0][2]overlay=x='':y=''" 
>>>>>> -q:v 2 -t
>>>>>> 4 -y out
>>>>> x="":y="" are invalid arguments. They must be valid, even if they not
>>>>> gonna be used later.
>>>> now it works. Thank you!
>>>>
>>> Should be added to sendcmd documentation:
>>>
>>> -- An example which shows where to insert the sendcmd filter, if the
>>> target filter has more than one input.
>>> -- All arguments of filters must be initialized with valid values, even
>>> if they are never used because sendcmd overwrites them.
>>>
>> patch welcome
>
> sorry, I never figured out how git works. Too complicated for me.
>
> Another idea: Could sendcmd be modified so that it can be inserted at 
> any place in the filter chain, regardless of the number of inputs?

Not needed. sendcmd isn't tied to any specific filter, since it can be 
used to send commands to any or all filters in the graph at once.

I'll add an example showing sendcmd usage for multi-input filters.

Gyan


More information about the ffmpeg-user mailing list