You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<codeclass="descclassname">ffmpeg.</code><codeclass="descname">filter_</code><spanclass="sig-paren">(</span><em>parent_node</em>, <em>filter_name</em>, <em>*args</em>, <em>**kwargs</em><spanclass="sig-paren">)</span><aclass="headerlink" href="#ffmpeg.filter_" title="Permalink to this definition">¶</a></dt>
127
+
<dd><p>Apply custom single-source filter.</p>
128
+
<p><codeclass="docutils literal"><spanclass="pre">filter_</span></code> is normally used by higher-level filter functions such as <codeclass="docutils literal"><spanclass="pre">hflip</span></code>, but if a filter implementation
129
+
is missing from <codeclass="docutils literal"><spanclass="pre">fmpeg-python</span></code>, you can call <codeclass="docutils literal"><spanclass="pre">filter_</span></code> directly to have <codeclass="docutils literal"><spanclass="pre">fmpeg-python</span></code> pass the filter name
<trclass="field-odd field"><thclass="field-name">Parameters:</th><tdclass="field-body"><ulclass="first last simple">
136
+
<li><strong>parent_node</strong> – Source stream to apply filter to.</li>
137
+
<li><strong>filter_name</strong> – ffmpeg filter name, e.g. <cite>colorchannelmixer</cite></li>
138
+
<li><strong>*args</strong> – list of args to pass to ffmpeg verbatim</li>
139
+
<li><strong>**kwargs</strong> – list of keyword-args to pass to ffmpeg verbatim</li>
140
+
</ul>
141
+
</td>
142
+
</tr>
143
+
</tbody>
144
+
</table>
145
+
<p>This function is used internally by all of the other single-source filters (e.g. <codeclass="docutils literal"><spanclass="pre">hflip</span></code>, <codeclass="docutils literal"><spanclass="pre">crop</span></code>, etc.).
146
+
For custom multi-source filters, see <codeclass="docutils literal"><spanclass="pre">filter_multi</span></code> instead.</p>
147
+
<p>The function name is suffixed with <codeclass="docutils literal"><spanclass="pre">_</span></code> in order avoid confusion with the standard python <codeclass="docutils literal"><spanclass="pre">filter</span></code> function.</p>
<codeclass="descclassname">ffmpeg.</code><codeclass="descname">filter_multi</code><spanclass="sig-paren">(</span><em>parent_nodes</em>, <em>filter_name</em>, <em>*args</em>, <em>**kwargs</em><spanclass="sig-paren">)</span><aclass="headerlink" href="#ffmpeg.filter_multi" title="Permalink to this definition">¶</a></dt>
155
+
<dd><p>Apply custom multi-source filter.</p>
156
+
<p>This is nearly identical to the <codeclass="docutils literal"><spanclass="pre">filter</span></code> function except that it allows filters to be applied to multiple
157
+
streams. It’s normally used by higher-level filter functions such as <codeclass="docutils literal"><spanclass="pre">concat</span></code>, but if a filter implementation
158
+
is missing from <codeclass="docutils literal"><spanclass="pre">fmpeg-python</span></code>, you can call <codeclass="docutils literal"><spanclass="pre">filter_multi</span></code> directly.</p>
159
+
<p>Note that because it applies to multiple streams, it can’t be used as an operator, unlike the <codeclass="docutils literal"><spanclass="pre">filter</span></code> function
<codeclass="descclassname">ffmpeg.</code><codeclass="descname">hflip</code><spanclass="sig-paren">(</span><em>parent_node</em><spanclass="sig-paren">)</span><aclass="headerlink" href="#ffmpeg.hflip" title="Permalink to this definition">¶</a></dt>
0 commit comments