Skip to content

VideoStream dataclass

VideoStream(
    *,
    node: "FilterNode | InputNode",
    index: int | None = None
)

Bases: FilterableStream

hex cached property

hex: str

Get the hexadecimal hash of the object.

index class-attribute instance-attribute

index: int | None = None

Represents the index of the stream in the node's output streams.

Note

See Also: Stream specifiers stream_index

node instance-attribute

node: 'FilterNode | InputNode'

Represents the node that the stream is connected to in the upstream direction.

Note

In the context of a data stream, the 'upstream' refers to the source of the data, or where the data is coming from. Therefore, the 'upstream node' is the node that is providing the data to the current stream.

addroi

addroi(
    *,
    x: String = Default("0"),
    y: String = Default("0"),
    w: String = Default("0"),
    h: String = Default("0"),
    qoffset: Rational = Default("-1/10"),
    clear: Boolean = Default(False),
    **kwargs: Any
) -> VideoStream

Add region of interest to frame.

Parameters:

Name Type Description Default
x String

Region distance from left edge of frame. (default "0")

Default('0')
y String

Region distance from top edge of frame. (default "0")

Default('0')
w String

Region width. (default "0")

Default('0')
h String

Region height. (default "0")

Default('0')
qoffset Rational

Quantisation offset to apply in the region. (from -1 to 1) (default -1/10)

Default('-1/10')
clear Boolean

Remove any existing regions of interest before adding the new one. (default false)

Default(False)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

afilter

afilter(
    *streams: "FilterableStream",
    name: str,
    input_typings: tuple[StreamType, ...] = (
        StreamType.audio
    ),
    **kwargs: Any
) -> "AudioStream"

Apply a custom audio filter which has only one output to this stream

Parameters:

Name Type Description Default
*streams FilterableStream

the streams to apply the filter to

()
name str

the name of the filter

required
input_typings tuple[StreamType, ...]

the input typings

(audio)
**kwargs Any

the arguments for the filter

{}

Returns:

Type Description
'AudioStream'

the output stream

alphaextract

alphaextract(**kwargs: Any) -> VideoStream

Extract an alpha channel as a grayscale image component.

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

alphamerge

alphamerge(
    _alpha: VideoStream,
    *,
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Copy the luma value of the second input into the alpha channel of the first input.

Parameters:

Name Type Description Default
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

amplify

amplify(
    *,
    radius: Int = Default(2),
    factor: Float = Default(2.0),
    threshold: Float = Default(10.0),
    tolerance: Float = Default(0.0),
    low: Float = Default(65535.0),
    high: Float = Default(65535.0),
    planes: Flags = Default("7"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Amplify changes between successive video frames.

Parameters:

Name Type Description Default
radius Int

set radius (from 1 to 63) (default 2)

Default(2)
factor Float

set factor (from 0 to 65535) (default 2)

Default(2.0)
threshold Float

set threshold (from 0 to 65535) (default 10)

Default(10.0)
tolerance Float

set tolerance (from 0 to 65535) (default 0)

Default(0.0)
low Float

set low limit for amplification (from 0 to 65535) (default 65535)

Default(65535.0)
high Float

set high limit for amplification (from 0 to 65535) (default 65535)

Default(65535.0)
planes Flags

set what planes to filter (default 7)

Default('7')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

ass

ass(
    *,
    filename: String = Default(None),
    original_size: Image_size = Default(None),
    fontsdir: String = Default(None),
    alpha: Boolean = Default(False),
    shaping: (
        Int | Literal["auto", "simple", "complex"] | Default
    ) = Default("auto"),
    **kwargs: Any
) -> VideoStream

Render ASS subtitles onto input video using the libass library.

Parameters:

Name Type Description Default
filename String

set the filename of file to read

Default(None)
original_size Image_size

set the size of the original video (used to scale fonts)

Default(None)
fontsdir String

set the directory containing the fonts to read

Default(None)
alpha Boolean

enable processing of alpha channel (default false)

Default(False)
shaping Int | Literal['auto', 'simple', 'complex'] | Default

set shaping engine (from -1 to 1) (default auto)

Default('auto')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

atadenoise

atadenoise(
    *,
    _0a: Float = Default(0.02),
    _0b: Float = Default(0.04),
    _1a: Float = Default(0.02),
    _1b: Float = Default(0.04),
    _2a: Float = Default(0.02),
    _2b: Float = Default(0.04),
    s: Int = Default(9),
    p: Flags = Default("7"),
    a: Int | Literal["p", "s"] | Default = Default("p"),
    _0s: Float = Default(32767.0),
    _1s: Float = Default(32767.0),
    _2s: Float = Default(32767.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply an Adaptive Temporal Averaging Denoiser.

Parameters:

Name Type Description Default
_0a Float

set threshold A for 1st plane (from 0 to 0.3) (default 0.02)

Default(0.02)
_0b Float

set threshold B for 1st plane (from 0 to 5) (default 0.04)

Default(0.04)
_1a Float

set threshold A for 2nd plane (from 0 to 0.3) (default 0.02)

Default(0.02)
_1b Float

set threshold B for 2nd plane (from 0 to 5) (default 0.04)

Default(0.04)
_2a Float

set threshold A for 3rd plane (from 0 to 0.3) (default 0.02)

Default(0.02)
_2b Float

set threshold B for 3rd plane (from 0 to 5) (default 0.04)

Default(0.04)
s Int

set how many frames to use (from 5 to 129) (default 9)

Default(9)
p Flags

set what planes to filter (default 7)

Default('7')
a Int | Literal['p', 's'] | Default

set variant of algorithm (from 0 to 1) (default p)

Default('p')
_0s Float

set sigma for 1st plane (from 0 to 32767) (default 32767)

Default(32767.0)
_1s Float

set sigma for 2nd plane (from 0 to 32767) (default 32767)

Default(32767.0)
_2s Float

set sigma for 3rd plane (from 0 to 32767) (default 32767)

Default(32767.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

avgblur

avgblur(
    *,
    sizeX: Int = Default(1),
    planes: Int = Default(15),
    sizeY: Int = Default(0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply Average Blur filter.

Parameters:

Name Type Description Default
sizeX Int

set horizontal size (from 1 to 1024) (default 1)

Default(1)
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
sizeY Int

set vertical size (from 0 to 1024) (default 0)

Default(0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

backgroundkey

backgroundkey(
    *,
    threshold: Float = Default(0.08),
    similarity: Float = Default(0.1),
    blend: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Turns a static background into transparency.

Parameters:

Name Type Description Default
threshold Float

set the scene change threshold (from 0 to 1) (default 0.08)

Default(0.08)
similarity Float

set the similarity (from 0 to 1) (default 0.1)

Default(0.1)
blend Float

set the blend value (from 0 to 1) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

bbox

bbox(
    *,
    min_val: Int = Default(16),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Compute bounding box for each frame.

Parameters:

Name Type Description Default
min_val Int

set minimum luminance value for bounding box (from 0 to 65535) (default 16)

Default(16)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

bench

bench(
    *,
    action: (
        Int | Literal["start", "stop"] | Default
    ) = Default("start"),
    **kwargs: Any
) -> VideoStream

Benchmark part of a filtergraph.

Parameters:

Name Type Description Default
action Int | Literal['start', 'stop'] | Default

set action (from 0 to 1) (default start)

Default('start')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

bilateral

bilateral(
    *,
    sigmaS: Float = Default(0.1),
    sigmaR: Float = Default(0.1),
    planes: Int = Default(1),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply Bilateral filter.

Parameters:

Name Type Description Default
sigmaS Float

set spatial sigma (from 0 to 512) (default 0.1)

Default(0.1)
sigmaR Float

set range sigma (from 0 to 1) (default 0.1)

Default(0.1)
planes Int

set planes to filter (from 0 to 15) (default 1)

Default(1)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

bitplanenoise

bitplanenoise(
    *,
    bitplane: Int = Default(1),
    filter: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Measure bit plane noise.

Parameters:

Name Type Description Default
bitplane Int

set bit plane to use for measuring noise (from 1 to 16) (default 1)

Default(1)
filter Boolean

show noisy pixels (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

blackdetect

blackdetect(
    *,
    d: Double = Default(2.0),
    picture_black_ratio_th: Double = Default(0.98),
    pixel_black_th: Double = Default(0.1),
    **kwargs: Any
) -> VideoStream

Detect video intervals that are (almost) black.

Parameters:

Name Type Description Default
d Double

set minimum detected black duration in seconds (from 0 to DBL_MAX) (default 2)

Default(2.0)
picture_black_ratio_th Double

set the picture black ratio threshold (from 0 to 1) (default 0.98)

Default(0.98)
pixel_black_th Double

set the pixel black threshold (from 0 to 1) (default 0.1)

Default(0.1)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

blackframe

blackframe(
    *,
    amount: Int = Default(98),
    threshold: Int = Default(32),
    **kwargs: Any
) -> VideoStream

Detect frames that are (almost) black.

Parameters:

Name Type Description Default
amount Int

percentage of the pixels that have to be below the threshold for the frame to be considered black (from 0 to 100) (default 98)

Default(98)
threshold Int

threshold below which a pixel value is considered black (from 0 to 255) (default 32)

Default(32)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

blend

blend(
    _bottom: VideoStream,
    *,
    c0_mode: (
        Int
        | Literal[
            "addition",
            "addition128",
            "grainmerge",
            "and",
            "average",
            "burn",
            "darken",
            "difference",
            "difference128",
            "grainextract",
            "divide",
            "dodge",
            "exclusion",
            "extremity",
            "freeze",
            "glow",
            "hardlight",
            "hardmix",
            "heat",
            "lighten",
            "linearlight",
            "multiply",
            "multiply128",
            "negation",
            "normal",
            "or",
            "overlay",
            "phoenix",
            "pinlight",
            "reflect",
            "screen",
            "softlight",
            "subtract",
            "vividlight",
            "xor",
            "softdifference",
            "geometric",
            "harmonic",
            "bleach",
            "stain",
            "interpolate",
            "hardoverlay",
        ]
        | Default
    ) = Default("normal"),
    c1_mode: (
        Int
        | Literal[
            "addition",
            "addition128",
            "grainmerge",
            "and",
            "average",
            "burn",
            "darken",
            "difference",
            "difference128",
            "grainextract",
            "divide",
            "dodge",
            "exclusion",
            "extremity",
            "freeze",
            "glow",
            "hardlight",
            "hardmix",
            "heat",
            "lighten",
            "linearlight",
            "multiply",
            "multiply128",
            "negation",
            "normal",
            "or",
            "overlay",
            "phoenix",
            "pinlight",
            "reflect",
            "screen",
            "softlight",
            "subtract",
            "vividlight",
            "xor",
            "softdifference",
            "geometric",
            "harmonic",
            "bleach",
            "stain",
            "interpolate",
            "hardoverlay",
        ]
        | Default
    ) = Default("normal"),
    c2_mode: (
        Int
        | Literal[
            "addition",
            "addition128",
            "grainmerge",
            "and",
            "average",
            "burn",
            "darken",
            "difference",
            "difference128",
            "grainextract",
            "divide",
            "dodge",
            "exclusion",
            "extremity",
            "freeze",
            "glow",
            "hardlight",
            "hardmix",
            "heat",
            "lighten",
            "linearlight",
            "multiply",
            "multiply128",
            "negation",
            "normal",
            "or",
            "overlay",
            "phoenix",
            "pinlight",
            "reflect",
            "screen",
            "softlight",
            "subtract",
            "vividlight",
            "xor",
            "softdifference",
            "geometric",
            "harmonic",
            "bleach",
            "stain",
            "interpolate",
            "hardoverlay",
        ]
        | Default
    ) = Default("normal"),
    c3_mode: (
        Int
        | Literal[
            "addition",
            "addition128",
            "grainmerge",
            "and",
            "average",
            "burn",
            "darken",
            "difference",
            "difference128",
            "grainextract",
            "divide",
            "dodge",
            "exclusion",
            "extremity",
            "freeze",
            "glow",
            "hardlight",
            "hardmix",
            "heat",
            "lighten",
            "linearlight",
            "multiply",
            "multiply128",
            "negation",
            "normal",
            "or",
            "overlay",
            "phoenix",
            "pinlight",
            "reflect",
            "screen",
            "softlight",
            "subtract",
            "vividlight",
            "xor",
            "softdifference",
            "geometric",
            "harmonic",
            "bleach",
            "stain",
            "interpolate",
            "hardoverlay",
        ]
        | Default
    ) = Default("normal"),
    all_mode: (
        Int
        | Literal[
            "addition",
            "addition128",
            "grainmerge",
            "and",
            "average",
            "burn",
            "darken",
            "difference",
            "difference128",
            "grainextract",
            "divide",
            "dodge",
            "exclusion",
            "extremity",
            "freeze",
            "glow",
            "hardlight",
            "hardmix",
            "heat",
            "lighten",
            "linearlight",
            "multiply",
            "multiply128",
            "negation",
            "normal",
            "or",
            "overlay",
            "phoenix",
            "pinlight",
            "reflect",
            "screen",
            "softlight",
            "subtract",
            "vividlight",
            "xor",
            "softdifference",
            "geometric",
            "harmonic",
            "bleach",
            "stain",
            "interpolate",
            "hardoverlay",
        ]
        | Default
    ) = Default(-1),
    c0_expr: String = Default(None),
    c1_expr: String = Default(None),
    c2_expr: String = Default(None),
    c3_expr: String = Default(None),
    all_expr: String = Default(None),
    c0_opacity: Double = Default(1.0),
    c1_opacity: Double = Default(1.0),
    c2_opacity: Double = Default(1.0),
    c3_opacity: Double = Default(1.0),
    all_opacity: Double = Default(1.0),
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Blend two video frames into each other.

Parameters:

Name Type Description Default
c0_mode Int | Literal['addition', 'addition128', 'grainmerge', 'and', 'average', 'burn', 'darken', 'difference', 'difference128', 'grainextract', 'divide', 'dodge', 'exclusion', 'extremity', 'freeze', 'glow', 'hardlight', 'hardmix', 'heat', 'lighten', 'linearlight', 'multiply', 'multiply128', 'negation', 'normal', 'or', 'overlay', 'phoenix', 'pinlight', 'reflect', 'screen', 'softlight', 'subtract', 'vividlight', 'xor', 'softdifference', 'geometric', 'harmonic', 'bleach', 'stain', 'interpolate', 'hardoverlay'] | Default

set component #0 blend mode (from 0 to 39) (default normal)

Default('normal')
c1_mode Int | Literal['addition', 'addition128', 'grainmerge', 'and', 'average', 'burn', 'darken', 'difference', 'difference128', 'grainextract', 'divide', 'dodge', 'exclusion', 'extremity', 'freeze', 'glow', 'hardlight', 'hardmix', 'heat', 'lighten', 'linearlight', 'multiply', 'multiply128', 'negation', 'normal', 'or', 'overlay', 'phoenix', 'pinlight', 'reflect', 'screen', 'softlight', 'subtract', 'vividlight', 'xor', 'softdifference', 'geometric', 'harmonic', 'bleach', 'stain', 'interpolate', 'hardoverlay'] | Default

set component #1 blend mode (from 0 to 39) (default normal)

Default('normal')
c2_mode Int | Literal['addition', 'addition128', 'grainmerge', 'and', 'average', 'burn', 'darken', 'difference', 'difference128', 'grainextract', 'divide', 'dodge', 'exclusion', 'extremity', 'freeze', 'glow', 'hardlight', 'hardmix', 'heat', 'lighten', 'linearlight', 'multiply', 'multiply128', 'negation', 'normal', 'or', 'overlay', 'phoenix', 'pinlight', 'reflect', 'screen', 'softlight', 'subtract', 'vividlight', 'xor', 'softdifference', 'geometric', 'harmonic', 'bleach', 'stain', 'interpolate', 'hardoverlay'] | Default

set component #2 blend mode (from 0 to 39) (default normal)

Default('normal')
c3_mode Int | Literal['addition', 'addition128', 'grainmerge', 'and', 'average', 'burn', 'darken', 'difference', 'difference128', 'grainextract', 'divide', 'dodge', 'exclusion', 'extremity', 'freeze', 'glow', 'hardlight', 'hardmix', 'heat', 'lighten', 'linearlight', 'multiply', 'multiply128', 'negation', 'normal', 'or', 'overlay', 'phoenix', 'pinlight', 'reflect', 'screen', 'softlight', 'subtract', 'vividlight', 'xor', 'softdifference', 'geometric', 'harmonic', 'bleach', 'stain', 'interpolate', 'hardoverlay'] | Default

set component #3 blend mode (from 0 to 39) (default normal)

Default('normal')
all_mode Int | Literal['addition', 'addition128', 'grainmerge', 'and', 'average', 'burn', 'darken', 'difference', 'difference128', 'grainextract', 'divide', 'dodge', 'exclusion', 'extremity', 'freeze', 'glow', 'hardlight', 'hardmix', 'heat', 'lighten', 'linearlight', 'multiply', 'multiply128', 'negation', 'normal', 'or', 'overlay', 'phoenix', 'pinlight', 'reflect', 'screen', 'softlight', 'subtract', 'vividlight', 'xor', 'softdifference', 'geometric', 'harmonic', 'bleach', 'stain', 'interpolate', 'hardoverlay'] | Default

set blend mode for all components (from -1 to 39) (default -1)

Default(-1)
c0_expr String

set color component #0 expression

Default(None)
c1_expr String

set color component #1 expression

Default(None)
c2_expr String

set color component #2 expression

Default(None)
c3_expr String

set color component #3 expression

Default(None)
all_expr String

set expression for all color components

Default(None)
c0_opacity Double

set color component #0 opacity (from 0 to 1) (default 1)

Default(1.0)
c1_opacity Double

set color component #1 opacity (from 0 to 1) (default 1)

Default(1.0)
c2_opacity Double

set color component #2 opacity (from 0 to 1) (default 1)

Default(1.0)
c3_opacity Double

set color component #3 opacity (from 0 to 1) (default 1)

Default(1.0)
all_opacity Double

set opacity for all color components (from 0 to 1) (default 1)

Default(1.0)
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

blockdetect

blockdetect(
    *,
    period_min: Int = Default(3),
    period_max: Int = Default(24),
    planes: Int = Default(1),
    **kwargs: Any
) -> VideoStream

Blockdetect filter.

Parameters:

Name Type Description Default
period_min Int

Minimum period to search for (from 2 to 32) (default 3)

Default(3)
period_max Int

Maximum period to search for (from 2 to 64) (default 24)

Default(24)
planes Int

set planes to filter (from 0 to 15) (default 1)

Default(1)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

blurdetect

blurdetect(
    *,
    high: Float = Default(0.117647),
    low: Float = Default(0.0588235),
    radius: Int = Default(50),
    block_pct: Int = Default(80),
    block_width: Int = Default(-1),
    planes: Int = Default(1),
    **kwargs: Any
) -> VideoStream

Blurdetect filter.

Parameters:

Name Type Description Default
high Float

set high threshold (from 0 to 1) (default 0.117647)

Default(0.117647)
low Float

set low threshold (from 0 to 1) (default 0.0588235)

Default(0.0588235)
radius Int

search radius for maxima detection (from 1 to 100) (default 50)

Default(50)
block_pct Int

block pooling threshold when calculating blurriness (from 1 to 100) (default 80)

Default(80)
block_width Int

block size for block-based abbreviation of blurriness (from -1 to INT_MAX) (default -1)

Default(-1)
planes Int

set planes to filter (from 0 to 15) (default 1)

Default(1)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

boxblur

boxblur(
    *,
    luma_radius: String = Default("2"),
    luma_power: Int = Default(2),
    chroma_radius: String = Default(None),
    chroma_power: Int = Default(-1),
    alpha_radius: String = Default(None),
    alpha_power: Int = Default(-1),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Blur the input.

Parameters:

Name Type Description Default
luma_radius String

Radius of the luma blurring box (default "2")

Default('2')
luma_power Int

How many times should the boxblur be applied to luma (from 0 to INT_MAX) (default 2)

Default(2)
chroma_radius String

Radius of the chroma blurring box

Default(None)
chroma_power Int

How many times should the boxblur be applied to chroma (from -1 to INT_MAX) (default -1)

Default(-1)
alpha_radius String

Radius of the alpha blurring box

Default(None)
alpha_power Int

How many times should the boxblur be applied to alpha (from -1 to INT_MAX) (default -1)

Default(-1)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

bwdif

bwdif(
    *,
    mode: (
        Int | Literal["send_frame", "send_field"] | Default
    ) = Default("send_field"),
    parity: (
        Int | Literal["tff", "bff", "auto"] | Default
    ) = Default("auto"),
    deint: (
        Int | Literal["all", "interlaced"] | Default
    ) = Default("all"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Deinterlace the input image.

Parameters:

Name Type Description Default
mode Int | Literal['send_frame', 'send_field'] | Default

specify the interlacing mode (from 0 to 1) (default send_field)

Default('send_field')
parity Int | Literal['tff', 'bff', 'auto'] | Default

specify the assumed picture field parity (from -1 to 1) (default auto)

Default('auto')
deint Int | Literal['all', 'interlaced'] | Default

specify which frames to deinterlace (from 0 to 1) (default all)

Default('all')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

cas

cas(
    *,
    strength: Float = Default(0.0),
    planes: Flags = Default("7"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Contrast Adaptive Sharpen.

Parameters:

Name Type Description Default
strength Float

set the sharpening strength (from 0 to 1) (default 0)

Default(0.0)
planes Flags

set what planes to filter (default 7)

Default('7')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

chromahold

chromahold(
    *,
    color: Color = Default("black"),
    similarity: Float = Default(0.01),
    blend: Float = Default(0.0),
    yuv: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Turns a certain color range into gray.

Parameters:

Name Type Description Default
color Color

set the chromahold key color (default "black")

Default('black')
similarity Float

set the chromahold similarity value (from 1e-05 to 1) (default 0.01)

Default(0.01)
blend Float

set the chromahold blend value (from 0 to 1) (default 0)

Default(0.0)
yuv Boolean

color parameter is in yuv instead of rgb (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

chromakey

chromakey(
    *,
    color: Color = Default("black"),
    similarity: Float = Default(0.01),
    blend: Float = Default(0.0),
    yuv: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Turns a certain color into transparency. Operates on YUV colors.

Parameters:

Name Type Description Default
color Color

set the chromakey key color (default "black")

Default('black')
similarity Float

set the chromakey similarity value (from 1e-05 to 1) (default 0.01)

Default(0.01)
blend Float

set the chromakey key blend value (from 0 to 1) (default 0)

Default(0.0)
yuv Boolean

color parameter is in yuv instead of rgb (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

chromanr

chromanr(
    *,
    thres: Float = Default(30.0),
    sizew: Int = Default(5),
    sizeh: Int = Default(5),
    stepw: Int = Default(1),
    steph: Int = Default(1),
    threy: Float = Default(200.0),
    threu: Float = Default(200.0),
    threv: Float = Default(200.0),
    distance: (
        Int | Literal["manhattan", "euclidean"] | Default
    ) = Default("manhattan"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Reduce chrominance noise.

Parameters:

Name Type Description Default
thres Float

set y+u+v threshold (from 1 to 200) (default 30)

Default(30.0)
sizew Int

set horizontal patch size (from 1 to 100) (default 5)

Default(5)
sizeh Int

set vertical patch size (from 1 to 100) (default 5)

Default(5)
stepw Int

set horizontal step (from 1 to 50) (default 1)

Default(1)
steph Int

set vertical step (from 1 to 50) (default 1)

Default(1)
threy Float

set y threshold (from 1 to 200) (default 200)

Default(200.0)
threu Float

set u threshold (from 1 to 200) (default 200)

Default(200.0)
threv Float

set v threshold (from 1 to 200) (default 200)

Default(200.0)
distance Int | Literal['manhattan', 'euclidean'] | Default

set distance type (from 0 to 1) (default manhattan)

Default('manhattan')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

chromashift

chromashift(
    *,
    cbh: Int = Default(0),
    cbv: Int = Default(0),
    crh: Int = Default(0),
    crv: Int = Default(0),
    edge: (
        Int | Literal["smear", "wrap"] | Default
    ) = Default("smear"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Shift chroma.

Parameters:

Name Type Description Default
cbh Int

shift chroma-blue horizontally (from -255 to 255) (default 0)

Default(0)
cbv Int

shift chroma-blue vertically (from -255 to 255) (default 0)

Default(0)
crh Int

shift chroma-red horizontally (from -255 to 255) (default 0)

Default(0)
crv Int

shift chroma-red vertically (from -255 to 255) (default 0)

Default(0)
edge Int | Literal['smear', 'wrap'] | Default

set edge operation (from 0 to 1) (default smear)

Default('smear')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

ciescope

ciescope(
    *,
    system: (
        Int
        | Literal[
            "ntsc",
            "470m",
            "ebu",
            "470bg",
            "smpte",
            "240m",
            "apple",
            "widergb",
            "cie1931",
            "hdtv",
            "rec709",
            "uhdtv",
            "rec2020",
            "dcip3",
        ]
        | Default
    ) = Default("hdtv"),
    cie: (
        Int | Literal["xyy", "ucs", "luv"] | Default
    ) = Default("xyy"),
    gamuts: (
        Flags
        | Literal[
            "ntsc",
            "470m",
            "ebu",
            "470bg",
            "smpte",
            "240m",
            "apple",
            "widergb",
            "cie1931",
            "hdtv",
            "rec709",
            "uhdtv",
            "rec2020",
            "dcip3",
        ]
        | Default
    ) = Default("0"),
    size: Int = Default(512),
    intensity: Float = Default(0.001),
    contrast: Float = Default(0.75),
    corrgamma: Boolean = Default(True),
    showwhite: Boolean = Default(False),
    gamma: Double = Default(2.6),
    fill: Boolean = Default(True),
    **kwargs: Any
) -> VideoStream

Video CIE scope.

Parameters:

Name Type Description Default
system Int | Literal['ntsc', '470m', 'ebu', '470bg', 'smpte', '240m', 'apple', 'widergb', 'cie1931', 'hdtv', 'rec709', 'uhdtv', 'rec2020', 'dcip3'] | Default

set color system (from 0 to 9) (default hdtv)

Default('hdtv')
cie Int | Literal['xyy', 'ucs', 'luv'] | Default

set cie system (from 0 to 2) (default xyy)

Default('xyy')
gamuts Flags | Literal['ntsc', '470m', 'ebu', '470bg', 'smpte', '240m', 'apple', 'widergb', 'cie1931', 'hdtv', 'rec709', 'uhdtv', 'rec2020', 'dcip3'] | Default

set what gamuts to draw (default 0)

Default('0')
size Int

set ciescope size (from 256 to 8192) (default 512)

Default(512)
intensity Float

set ciescope intensity (from 0 to 1) (default 0.001)

Default(0.001)
contrast Float

(from 0 to 1) (default 0.75)

Default(0.75)
corrgamma Boolean

(default true)

Default(True)
showwhite Boolean

(default false)

Default(False)
gamma Double

(from 0.1 to 6) (default 2.6)

Default(2.6)
fill Boolean

fill with CIE colors (default true)

Default(True)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

codecview

codecview(
    *,
    mv: (
        Flags | Literal["pf", "bf", "bb"] | Default
    ) = Default("0"),
    qp: Boolean = Default(False),
    mv_type: (
        Flags | Literal["fp", "bp"] | Default
    ) = Default("0"),
    frame_type: (
        Flags | Literal["if", "pf", "bf"] | Default
    ) = Default("0"),
    block: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Visualize information about some codecs.

Parameters:

Name Type Description Default
mv Flags | Literal['pf', 'bf', 'bb'] | Default

set motion vectors to visualize (default 0)

Default('0')
qp Boolean

(default false)

Default(False)
mv_type Flags | Literal['fp', 'bp'] | Default

set motion vectors type (default 0)

Default('0')
frame_type Flags | Literal['if', 'pf', 'bf'] | Default

set frame types to visualize motion vectors of (default 0)

Default('0')
block Boolean

set block partitioning structure to visualize (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

colorbalance

colorbalance(
    *,
    rs: Float = Default(0.0),
    gs: Float = Default(0.0),
    bs: Float = Default(0.0),
    rm: Float = Default(0.0),
    gm: Float = Default(0.0),
    bm: Float = Default(0.0),
    rh: Float = Default(0.0),
    gh: Float = Default(0.0),
    bh: Float = Default(0.0),
    pl: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Adjust the color balance.

Parameters:

Name Type Description Default
rs Float

set red shadows (from -1 to 1) (default 0)

Default(0.0)
gs Float

set green shadows (from -1 to 1) (default 0)

Default(0.0)
bs Float

set blue shadows (from -1 to 1) (default 0)

Default(0.0)
rm Float

set red midtones (from -1 to 1) (default 0)

Default(0.0)
gm Float

set green midtones (from -1 to 1) (default 0)

Default(0.0)
bm Float

set blue midtones (from -1 to 1) (default 0)

Default(0.0)
rh Float

set red highlights (from -1 to 1) (default 0)

Default(0.0)
gh Float

set green highlights (from -1 to 1) (default 0)

Default(0.0)
bh Float

set blue highlights (from -1 to 1) (default 0)

Default(0.0)
pl Boolean

preserve lightness (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

colorchannelmixer

colorchannelmixer(
    *,
    rr: Double = Default(1.0),
    rg: Double = Default(0.0),
    rb: Double = Default(0.0),
    ra: Double = Default(0.0),
    gr: Double = Default(0.0),
    gg: Double = Default(1.0),
    gb: Double = Default(0.0),
    ga: Double = Default(0.0),
    br: Double = Default(0.0),
    bg: Double = Default(0.0),
    bb: Double = Default(1.0),
    ba: Double = Default(0.0),
    ar: Double = Default(0.0),
    ag: Double = Default(0.0),
    ab: Double = Default(0.0),
    aa: Double = Default(1.0),
    pc: (
        Int
        | Literal[
            "none", "lum", "max", "avg", "sum", "nrm", "pwr"
        ]
        | Default
    ) = Default("none"),
    pa: Double = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Adjust colors by mixing color channels.

Parameters:

Name Type Description Default
rr Double

set the red gain for the red channel (from -2 to 2) (default 1)

Default(1.0)
rg Double

set the green gain for the red channel (from -2 to 2) (default 0)

Default(0.0)
rb Double

set the blue gain for the red channel (from -2 to 2) (default 0)

Default(0.0)
ra Double

set the alpha gain for the red channel (from -2 to 2) (default 0)

Default(0.0)
gr Double

set the red gain for the green channel (from -2 to 2) (default 0)

Default(0.0)
gg Double

set the green gain for the green channel (from -2 to 2) (default 1)

Default(1.0)
gb Double

set the blue gain for the green channel (from -2 to 2) (default 0)

Default(0.0)
ga Double

set the alpha gain for the green channel (from -2 to 2) (default 0)

Default(0.0)
br Double

set the red gain for the blue channel (from -2 to 2) (default 0)

Default(0.0)
bg Double

set the green gain for the blue channel (from -2 to 2) (default 0)

Default(0.0)
bb Double

set the blue gain for the blue channel (from -2 to 2) (default 1)

Default(1.0)
ba Double

set the alpha gain for the blue channel (from -2 to 2) (default 0)

Default(0.0)
ar Double

set the red gain for the alpha channel (from -2 to 2) (default 0)

Default(0.0)
ag Double

set the green gain for the alpha channel (from -2 to 2) (default 0)

Default(0.0)
ab Double

set the blue gain for the alpha channel (from -2 to 2) (default 0)

Default(0.0)
aa Double

set the alpha gain for the alpha channel (from -2 to 2) (default 1)

Default(1.0)
pc Int | Literal['none', 'lum', 'max', 'avg', 'sum', 'nrm', 'pwr'] | Default

set the preserve color mode (from 0 to 6) (default none)

Default('none')
pa Double

set the preserve color amount (from 0 to 1) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

colorcontrast

colorcontrast(
    *,
    rc: Float = Default(0.0),
    gm: Float = Default(0.0),
    by: Float = Default(0.0),
    rcw: Float = Default(0.0),
    gmw: Float = Default(0.0),
    byw: Float = Default(0.0),
    pl: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Adjust color contrast between RGB components.

Parameters:

Name Type Description Default
rc Float

set the red-cyan contrast (from -1 to 1) (default 0)

Default(0.0)
gm Float

set the green-magenta contrast (from -1 to 1) (default 0)

Default(0.0)
by Float

set the blue-yellow contrast (from -1 to 1) (default 0)

Default(0.0)
rcw Float

set the red-cyan weight (from 0 to 1) (default 0)

Default(0.0)
gmw Float

set the green-magenta weight (from 0 to 1) (default 0)

Default(0.0)
byw Float

set the blue-yellow weight (from 0 to 1) (default 0)

Default(0.0)
pl Float

set the amount of preserving lightness (from 0 to 1) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

colorcorrect

colorcorrect(
    *,
    rl: Float = Default(0.0),
    bl: Float = Default(0.0),
    rh: Float = Default(0.0),
    bh: Float = Default(0.0),
    saturation: Float = Default(1.0),
    analyze: (
        Int
        | Literal["manual", "average", "minmax", "median"]
        | Default
    ) = Default("manual"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Adjust color white balance selectively for blacks and whites.

Parameters:

Name Type Description Default
rl Float

set the red shadow spot (from -1 to 1) (default 0)

Default(0.0)
bl Float

set the blue shadow spot (from -1 to 1) (default 0)

Default(0.0)
rh Float

set the red highlight spot (from -1 to 1) (default 0)

Default(0.0)
bh Float

set the blue highlight spot (from -1 to 1) (default 0)

Default(0.0)
saturation Float

set the amount of saturation (from -3 to 3) (default 1)

Default(1.0)
analyze Int | Literal['manual', 'average', 'minmax', 'median'] | Default

set the analyze mode (from 0 to 3) (default manual)

Default('manual')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

colorhold

colorhold(
    *,
    color: Color = Default("black"),
    similarity: Float = Default(0.01),
    blend: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Turns a certain color range into gray. Operates on RGB colors.

Parameters:

Name Type Description Default
color Color

set the colorhold key color (default "black")

Default('black')
similarity Float

set the colorhold similarity value (from 1e-05 to 1) (default 0.01)

Default(0.01)
blend Float

set the colorhold blend value (from 0 to 1) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

colorize

colorize(
    *,
    hue: Float = Default(0.0),
    saturation: Float = Default(0.5),
    lightness: Float = Default(0.5),
    mix: Float = Default(1.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Overlay a solid color on the video stream.

Parameters:

Name Type Description Default
hue Float

set the hue (from 0 to 360) (default 0)

Default(0.0)
saturation Float

set the saturation (from 0 to 1) (default 0.5)

Default(0.5)
lightness Float

set the lightness (from 0 to 1) (default 0.5)

Default(0.5)
mix Float

set the mix of source lightness (from 0 to 1) (default 1)

Default(1.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

colorkey

colorkey(
    *,
    color: Color = Default("black"),
    similarity: Float = Default(0.01),
    blend: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Turns a certain color into transparency. Operates on RGB colors.

Parameters:

Name Type Description Default
color Color

set the colorkey key color (default "black")

Default('black')
similarity Float

set the colorkey similarity value (from 1e-05 to 1) (default 0.01)

Default(0.01)
blend Float

set the colorkey key blend value (from 0 to 1) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

colorlevels

colorlevels(
    *,
    rimin: Double = Default(0.0),
    gimin: Double = Default(0.0),
    bimin: Double = Default(0.0),
    aimin: Double = Default(0.0),
    rimax: Double = Default(1.0),
    gimax: Double = Default(1.0),
    bimax: Double = Default(1.0),
    aimax: Double = Default(1.0),
    romin: Double = Default(0.0),
    gomin: Double = Default(0.0),
    bomin: Double = Default(0.0),
    aomin: Double = Default(0.0),
    romax: Double = Default(1.0),
    gomax: Double = Default(1.0),
    bomax: Double = Default(1.0),
    aomax: Double = Default(1.0),
    preserve: (
        Int
        | Literal[
            "none", "lum", "max", "avg", "sum", "nrm", "pwr"
        ]
        | Default
    ) = Default("none"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Adjust the color levels.

Parameters:

Name Type Description Default
rimin Double

set input red black point (from -1 to 1) (default 0)

Default(0.0)
gimin Double

set input green black point (from -1 to 1) (default 0)

Default(0.0)
bimin Double

set input blue black point (from -1 to 1) (default 0)

Default(0.0)
aimin Double

set input alpha black point (from -1 to 1) (default 0)

Default(0.0)
rimax Double

set input red white point (from -1 to 1) (default 1)

Default(1.0)
gimax Double

set input green white point (from -1 to 1) (default 1)

Default(1.0)
bimax Double

set input blue white point (from -1 to 1) (default 1)

Default(1.0)
aimax Double

set input alpha white point (from -1 to 1) (default 1)

Default(1.0)
romin Double

set output red black point (from 0 to 1) (default 0)

Default(0.0)
gomin Double

set output green black point (from 0 to 1) (default 0)

Default(0.0)
bomin Double

set output blue black point (from 0 to 1) (default 0)

Default(0.0)
aomin Double

set output alpha black point (from 0 to 1) (default 0)

Default(0.0)
romax Double

set output red white point (from 0 to 1) (default 1)

Default(1.0)
gomax Double

set output green white point (from 0 to 1) (default 1)

Default(1.0)
bomax Double

set output blue white point (from 0 to 1) (default 1)

Default(1.0)
aomax Double

set output alpha white point (from 0 to 1) (default 1)

Default(1.0)
preserve Int | Literal['none', 'lum', 'max', 'avg', 'sum', 'nrm', 'pwr'] | Default

set preserve color mode (from 0 to 6) (default none)

Default('none')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

colormap

colormap(
    _source: VideoStream,
    _target: VideoStream,
    *,
    patch_size: Image_size = Default("64x64"),
    nb_patches: Int = Default(0),
    type: (
        Int | Literal["relative", "absolute"] | Default
    ) = Default("absolute"),
    kernel: (
        Int | Literal["euclidean", "weuclidean"] | Default
    ) = Default("euclidean"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply custom Color Maps to video stream.

Parameters:

Name Type Description Default
patch_size Image_size

set patch size (default "64x64")

Default('64x64')
nb_patches Int

set number of patches (from 0 to 64) (default 0)

Default(0)
type Int | Literal['relative', 'absolute'] | Default

set the target type used (from 0 to 1) (default absolute)

Default('absolute')
kernel Int | Literal['euclidean', 'weuclidean'] | Default

set the kernel used for measuring color difference (from 0 to 1) (default euclidean)

Default('euclidean')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

colormatrix

colormatrix(
    *,
    src: (
        Int
        | Literal[
            "bt709",
            "fcc",
            "bt601",
            "bt470",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "bt2020",
        ]
        | Default
    ) = Default(-1),
    dst: (
        Int
        | Literal[
            "bt709",
            "fcc",
            "bt601",
            "bt470",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "bt2020",
        ]
        | Default
    ) = Default(-1),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Convert color matrix.

Parameters:

Name Type Description Default
src Int | Literal['bt709', 'fcc', 'bt601', 'bt470', 'bt470bg', 'smpte170m', 'smpte240m', 'bt2020'] | Default

set source color matrix (from -1 to 4) (default -1)

Default(-1)
dst Int | Literal['bt709', 'fcc', 'bt601', 'bt470', 'bt470bg', 'smpte170m', 'smpte240m', 'bt2020'] | Default

set destination color matrix (from -1 to 4) (default -1)

Default(-1)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

colorspace

colorspace(
    *,
    all: (
        Int
        | Literal[
            "bt470m",
            "bt470bg",
            "525",
            "625",
            "bt709",
            "smpte170m",
            "smpte240m",
            "bt2020",
        ]
        | Default
    ) = Default(0),
    space: (
        Int
        | Literal[
            "bt709",
            "fcc",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "ycgco",
            "gbr",
            "bt2020nc",
            "bt2020ncl",
        ]
        | Default
    ) = Default(2),
    range: (
        Int | Literal["tv", "mpeg", "pc", "jpeg"] | Default
    ) = Default(0),
    primaries: (
        Int
        | Literal[
            "bt709",
            "bt470m",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "smpte428",
            "film",
            "smpte431",
            "smpte432",
            "bt2020",
            "p22",
            "ebu3213",
        ]
        | Default
    ) = Default(2),
    trc: (
        Int
        | Literal[
            "bt709",
            "bt470m",
            "gamma22",
            "bt470bg",
            "gamma28",
            "smpte170m",
            "smpte240m",
            "linear",
            "srgb",
            "1",
            "xvycc",
            "4",
            "10",
            "12",
        ]
        | Default
    ) = Default(2),
    format: (
        Int
        | Literal[
            "yuv420p",
            "yuv420p10",
            "yuv420p12",
            "yuv422p",
            "yuv422p10",
            "yuv422p12",
            "yuv444p",
            "yuv444p10",
            "yuv444p12",
        ]
        | Default
    ) = Default(-1),
    fast: Boolean = Default(False),
    dither: (
        Int | Literal["none", "fsb"] | Default
    ) = Default("none"),
    wpadapt: (
        Int
        | Literal["bradford", "vonkries", "identity"]
        | Default
    ) = Default("bradford"),
    iall: (
        Int
        | Literal[
            "bt470m",
            "bt470bg",
            "525",
            "625",
            "bt709",
            "smpte170m",
            "smpte240m",
            "bt2020",
        ]
        | Default
    ) = Default(0),
    ispace: (
        Int
        | Literal[
            "bt709",
            "fcc",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "ycgco",
            "gbr",
            "bt2020nc",
            "bt2020ncl",
        ]
        | Default
    ) = Default(2),
    irange: (
        Int | Literal["tv", "mpeg", "pc", "jpeg"] | Default
    ) = Default(0),
    iprimaries: (
        Int
        | Literal[
            "bt709",
            "bt470m",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "smpte428",
            "film",
            "smpte431",
            "smpte432",
            "bt2020",
            "p22",
            "ebu3213",
        ]
        | Default
    ) = Default(2),
    itrc: (
        Int
        | Literal[
            "bt709",
            "bt470m",
            "gamma22",
            "bt470bg",
            "gamma28",
            "smpte170m",
            "smpte240m",
            "linear",
            "srgb",
            "1",
            "xvycc",
            "4",
            "10",
            "12",
        ]
        | Default
    ) = Default(2),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Convert between colorspaces.

Parameters:

Name Type Description Default
all Int | Literal['bt470m', 'bt470bg', '525', '625', 'bt709', 'smpte170m', 'smpte240m', 'bt2020'] | Default

Set all color properties together (from 0 to 8) (default 0)

Default(0)
space Int | Literal['bt709', 'fcc', 'bt470bg', 'smpte170m', 'smpte240m', 'ycgco', 'gbr', 'bt2020nc', 'bt2020ncl'] | Default

Output colorspace (from 0 to 14) (default 2)

Default(2)
range Int | Literal['tv', 'mpeg', 'pc', 'jpeg'] | Default

Output color range (from 0 to 2) (default 0)

Default(0)
primaries Int | Literal['bt709', 'bt470m', 'bt470bg', 'smpte170m', 'smpte240m', 'smpte428', 'film', 'smpte431', 'smpte432', 'bt2020', 'p22', 'ebu3213'] | Default

Output color primaries (from 0 to 22) (default 2)

Default(2)
trc Int | Literal['bt709', 'bt470m', 'gamma22', 'bt470bg', 'gamma28', 'smpte170m', 'smpte240m', 'linear', 'srgb', '1', 'xvycc', '4', '10', '12'] | Default

Output transfer characteristics (from 0 to 18) (default 2)

Default(2)
format Int | Literal['yuv420p', 'yuv420p10', 'yuv420p12', 'yuv422p', 'yuv422p10', 'yuv422p12', 'yuv444p', 'yuv444p10', 'yuv444p12'] | Default

Output pixel format (from -1 to 162) (default -1)

Default(-1)
fast Boolean

Ignore primary chromaticity and gamma correction (default false)

Default(False)
dither Int | Literal['none', 'fsb'] | Default

Dithering mode (from 0 to 1) (default none)

Default('none')
wpadapt Int | Literal['bradford', 'vonkries', 'identity'] | Default

Whitepoint adaptation method (from 0 to 2) (default bradford)

Default('bradford')
iall Int | Literal['bt470m', 'bt470bg', '525', '625', 'bt709', 'smpte170m', 'smpte240m', 'bt2020'] | Default

Set all input color properties together (from 0 to 8) (default 0)

Default(0)
ispace Int | Literal['bt709', 'fcc', 'bt470bg', 'smpte170m', 'smpte240m', 'ycgco', 'gbr', 'bt2020nc', 'bt2020ncl'] | Default

Input colorspace (from 0 to 22) (default 2)

Default(2)
irange Int | Literal['tv', 'mpeg', 'pc', 'jpeg'] | Default

Input color range (from 0 to 2) (default 0)

Default(0)
iprimaries Int | Literal['bt709', 'bt470m', 'bt470bg', 'smpte170m', 'smpte240m', 'smpte428', 'film', 'smpte431', 'smpte432', 'bt2020', 'p22', 'ebu3213'] | Default

Input color primaries (from 0 to 22) (default 2)

Default(2)
itrc Int | Literal['bt709', 'bt470m', 'gamma22', 'bt470bg', 'gamma28', 'smpte170m', 'smpte240m', 'linear', 'srgb', '1', 'xvycc', '4', '10', '12'] | Default

Input transfer characteristics (from 0 to 18) (default 2)

Default(2)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

colortemperature

colortemperature(
    *,
    temperature: Float = Default(6500.0),
    mix: Float = Default(1.0),
    pl: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Adjust color temperature of video.

Parameters:

Name Type Description Default
temperature Float

set the temperature in Kelvin (from 1000 to 40000) (default 6500)

Default(6500.0)
mix Float

set the mix with filtered output (from 0 to 1) (default 1)

Default(1.0)
pl Float

set the amount of preserving lightness (from 0 to 1) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

convolution

convolution(
    *,
    _0m: String = Default("0 0 0 0 1 0 0 0 0"),
    _1m: String = Default("0 0 0 0 1 0 0 0 0"),
    _2m: String = Default("0 0 0 0 1 0 0 0 0"),
    _3m: String = Default("0 0 0 0 1 0 0 0 0"),
    _0rdiv: Float = Default(0.0),
    _1rdiv: Float = Default(0.0),
    _2rdiv: Float = Default(0.0),
    _3rdiv: Float = Default(0.0),
    _0bias: Float = Default(0.0),
    _1bias: Float = Default(0.0),
    _2bias: Float = Default(0.0),
    _3bias: Float = Default(0.0),
    _0mode: (
        Int | Literal["square", "row", "column"] | Default
    ) = Default("square"),
    _1mode: (
        Int | Literal["square", "row", "column"] | Default
    ) = Default("square"),
    _2mode: (
        Int | Literal["square", "row", "column"] | Default
    ) = Default("square"),
    _3mode: (
        Int | Literal["square", "row", "column"] | Default
    ) = Default("square"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply convolution filter.

Parameters:

Name Type Description Default
_0m String

set matrix for 1st plane (default "0 0 0 0 1 0 0 0 0")

Default('0 0 0 0 1 0 0 0 0')
_1m String

set matrix for 2nd plane (default "0 0 0 0 1 0 0 0 0")

Default('0 0 0 0 1 0 0 0 0')
_2m String

set matrix for 3rd plane (default "0 0 0 0 1 0 0 0 0")

Default('0 0 0 0 1 0 0 0 0')
_3m String

set matrix for 4th plane (default "0 0 0 0 1 0 0 0 0")

Default('0 0 0 0 1 0 0 0 0')
_0rdiv Float

set rdiv for 1st plane (from 0 to INT_MAX) (default 0)

Default(0.0)
_1rdiv Float

set rdiv for 2nd plane (from 0 to INT_MAX) (default 0)

Default(0.0)
_2rdiv Float

set rdiv for 3rd plane (from 0 to INT_MAX) (default 0)

Default(0.0)
_3rdiv Float

set rdiv for 4th plane (from 0 to INT_MAX) (default 0)

Default(0.0)
_0bias Float

set bias for 1st plane (from 0 to INT_MAX) (default 0)

Default(0.0)
_1bias Float

set bias for 2nd plane (from 0 to INT_MAX) (default 0)

Default(0.0)
_2bias Float

set bias for 3rd plane (from 0 to INT_MAX) (default 0)

Default(0.0)
_3bias Float

set bias for 4th plane (from 0 to INT_MAX) (default 0)

Default(0.0)
_0mode Int | Literal['square', 'row', 'column'] | Default

set matrix mode for 1st plane (from 0 to 2) (default square)

Default('square')
_1mode Int | Literal['square', 'row', 'column'] | Default

set matrix mode for 2nd plane (from 0 to 2) (default square)

Default('square')
_2mode Int | Literal['square', 'row', 'column'] | Default

set matrix mode for 3rd plane (from 0 to 2) (default square)

Default('square')
_3mode Int | Literal['square', 'row', 'column'] | Default

set matrix mode for 4th plane (from 0 to 2) (default square)

Default('square')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

convolve

convolve(
    _impulse: VideoStream,
    *,
    planes: Int = Default(7),
    impulse: (
        Int | Literal["first", "all"] | Default
    ) = Default("all"),
    noise: Float = Default(1e-07),
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Convolve first video stream with second video stream.

Parameters:

Name Type Description Default
planes Int

set planes to convolve (from 0 to 15) (default 7)

Default(7)
impulse Int | Literal['first', 'all'] | Default

when to process impulses (from 0 to 1) (default all)

Default('all')
noise Float

set noise (from 0 to 1) (default 1e-07)

Default(1e-07)
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

copy

copy(**kwargs: Any) -> VideoStream

Copy the input video unchanged to the output.

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

corr

corr(
    _reference: VideoStream,
    *,
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Calculate the correlation between two video streams.

Parameters:

Name Type Description Default
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

cover_rect

cover_rect(
    *,
    cover: String = Default(None),
    mode: (
        Int | Literal["cover", "blur"] | Default
    ) = Default("blur"),
    **kwargs: Any
) -> VideoStream

Find and cover a user specified object.

Parameters:

Name Type Description Default
cover String

cover bitmap filename

Default(None)
mode Int | Literal['cover', 'blur'] | Default

set removal mode (from 0 to 1) (default blur)

Default('blur')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

crop

crop(
    *,
    out_w: String = Default("iw"),
    out_h: String = Default("ih"),
    x: String = Default("(in_w-out_w"),
    y: String = Default("(in_h-out_h"),
    keep_aspect: Boolean = Default(False),
    exact: Boolean = Default(False),
    **kwargs: Any
) -> VideoStream

Crop the input video.

Parameters:

Name Type Description Default
out_w String

set the width crop area expression (default "iw")

Default('iw')
out_h String

set the height crop area expression (default "ih")

Default('ih')
x String

set the x crop area expression (default "(in_w-out_w)/2")

Default('(in_w-out_w')
y String

set the y crop area expression (default "(in_h-out_h)/2")

Default('(in_h-out_h')
keep_aspect Boolean

keep aspect ratio (default false)

Default(False)
exact Boolean

do exact cropping (default false)

Default(False)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

cropdetect

cropdetect(
    *,
    limit: Float = Default(0.0941176),
    round: Int = Default(16),
    reset: Int = Default(0),
    skip: Int = Default(2),
    reset_count: Int = Default(0),
    max_outliers: Int = Default(0),
    mode: (
        Int | Literal["black", "mvedges"] | Default
    ) = Default("black"),
    high: Float = Default(0.0980392),
    low: Float = Default(0.0588235),
    mv_threshold: Int = Default(8),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Auto-detect crop size.

Parameters:

Name Type Description Default
limit Float

Threshold below which the pixel is considered black (from 0 to 65535) (default 0.0941176)

Default(0.0941176)
round Int

Value by which the width/height should be divisible (from 0 to INT_MAX) (default 16)

Default(16)
reset Int

Recalculate the crop area after this many frames (from 0 to INT_MAX) (default 0)

Default(0)
skip Int

Number of initial frames to skip (from 0 to INT_MAX) (default 2)

Default(2)
reset_count Int

Recalculate the crop area after this many frames (from 0 to INT_MAX) (default 0)

Default(0)
max_outliers Int

Threshold count of outliers (from 0 to INT_MAX) (default 0)

Default(0)
mode Int | Literal['black', 'mvedges'] | Default

set mode (from 0 to 1) (default black)

Default('black')
high Float

Set high threshold for edge detection (from 0 to 1) (default 0.0980392)

Default(0.0980392)
low Float

Set low threshold for edge detection (from 0 to 1) (default 0.0588235)

Default(0.0588235)
mv_threshold Int

motion vector threshold when estimating video window size (from 0 to 100) (default 8)

Default(8)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

cue

cue(
    *,
    cue: Int64 = Default(0),
    preroll: Duration = Default(0.0),
    buffer: Duration = Default(0.0),
    **kwargs: Any
) -> VideoStream

Delay filtering to match a cue.

Parameters:

Name Type Description Default
cue Int64

cue unix timestamp in microseconds (from 0 to I64_MAX) (default 0)

Default(0)
preroll Duration

preroll duration in seconds (default 0)

Default(0.0)
buffer Duration

buffer duration in seconds (default 0)

Default(0.0)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

curves

curves(
    *,
    preset: (
        Int
        | Literal[
            "none",
            "color_negative",
            "cross_process",
            "darker",
            "increase_contrast",
            "lighter",
            "linear_contrast",
            "medium_contrast",
            "negative",
            "strong_contrast",
            "vintage",
        ]
        | Default
    ) = Default("none"),
    master: String = Default(None),
    red: String = Default(None),
    green: String = Default(None),
    blue: String = Default(None),
    all: String = Default(None),
    psfile: String = Default(None),
    plot: String = Default(None),
    interp: (
        Int | Literal["natural", "pchip"] | Default
    ) = Default("natural"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Adjust components curves.

Parameters:

Name Type Description Default
preset Int | Literal['none', 'color_negative', 'cross_process', 'darker', 'increase_contrast', 'lighter', 'linear_contrast', 'medium_contrast', 'negative', 'strong_contrast', 'vintage'] | Default

select a color curves preset (from 0 to 10) (default none)

Default('none')
master String

set master points coordinates

Default(None)
red String

set red points coordinates

Default(None)
green String

set green points coordinates

Default(None)
blue String

set blue points coordinates

Default(None)
all String

set points coordinates for all components

Default(None)
psfile String

set Photoshop curves file name

Default(None)
plot String

save Gnuplot script of the curves in specified file

Default(None)
interp Int | Literal['natural', 'pchip'] | Default

specify the kind of interpolation (from 0 to 1) (default natural)

Default('natural')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

datascope

datascope(
    *,
    size: Image_size = Default("hd720"),
    x: Int = Default(0),
    y: Int = Default(0),
    mode: (
        Int | Literal["mono", "color", "color2"] | Default
    ) = Default("mono"),
    axis: Boolean = Default(False),
    opacity: Float = Default(0.75),
    format: Int | Literal["hex", "dec"] | Default = Default(
        "hex"
    ),
    components: Int = Default(15),
    **kwargs: Any
) -> VideoStream

Video data analysis.

Parameters:

Name Type Description Default
size Image_size

set output size (default "hd720")

Default('hd720')
x Int

set x offset (from 0 to INT_MAX) (default 0)

Default(0)
y Int

set y offset (from 0 to INT_MAX) (default 0)

Default(0)
mode Int | Literal['mono', 'color', 'color2'] | Default

set scope mode (from 0 to 2) (default mono)

Default('mono')
axis Boolean

draw column/row numbers (default false)

Default(False)
opacity Float

set background opacity (from 0 to 1) (default 0.75)

Default(0.75)
format Int | Literal['hex', 'dec'] | Default

set display number format (from 0 to 1) (default hex)

Default('hex')
components Int

set components to display (from 1 to 15) (default 15)

Default(15)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

dblur

dblur(
    *,
    angle: Float = Default(45.0),
    radius: Float = Default(5.0),
    planes: Int = Default(15),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply Directional Blur filter.

Parameters:

Name Type Description Default
angle Float

set angle (from 0 to 360) (default 45)

Default(45.0)
radius Float

set radius (from 0 to 8192) (default 5)

Default(5.0)
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

dctdnoiz

dctdnoiz(
    *,
    sigma: Float = Default(0.0),
    overlap: Int = Default(-1),
    expr: String = Default(None),
    n: Int = Default(3),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Denoise frames using 2D DCT.

Parameters:

Name Type Description Default
sigma Float

set noise sigma constant (from 0 to 999) (default 0)

Default(0.0)
overlap Int

set number of block overlapping pixels (from -1 to 15) (default -1)

Default(-1)
expr String

set coefficient factor expression

Default(None)
n Int

set the block size, expressed in bits (from 3 to 4) (default 3)

Default(3)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

deband

deband(
    *,
    _1thr: Float = Default(0.02),
    _2thr: Float = Default(0.02),
    _3thr: Float = Default(0.02),
    _4thr: Float = Default(0.02),
    range: Int = Default(16),
    direction: Float = Default(6.28319),
    blur: Boolean = Default(True),
    coupling: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Debands video.

Parameters:

Name Type Description Default
_1thr Float

set 1st plane threshold (from 3e-05 to 0.5) (default 0.02)

Default(0.02)
_2thr Float

set 2nd plane threshold (from 3e-05 to 0.5) (default 0.02)

Default(0.02)
_3thr Float

set 3rd plane threshold (from 3e-05 to 0.5) (default 0.02)

Default(0.02)
_4thr Float

set 4th plane threshold (from 3e-05 to 0.5) (default 0.02)

Default(0.02)
range Int

set range (from INT_MIN to INT_MAX) (default 16)

Default(16)
direction Float

set direction (from -6.28319 to 6.28319) (default 6.28319)

Default(6.28319)
blur Boolean

set blur (default true)

Default(True)
coupling Boolean

set plane coupling (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

deblock

deblock(
    *,
    filter: (
        Int | Literal["weak", "strong"] | Default
    ) = Default("strong"),
    block: Int = Default(8),
    alpha: Float = Default(0.098),
    beta: Float = Default(0.05),
    gamma: Float = Default(0.05),
    delta: Float = Default(0.05),
    planes: Int = Default(15),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Deblock video.

Parameters:

Name Type Description Default
filter Int | Literal['weak', 'strong'] | Default

set type of filter (from 0 to 1) (default strong)

Default('strong')
block Int

set size of block (from 4 to 512) (default 8)

Default(8)
alpha Float

set 1st detection threshold (from 0 to 1) (default 0.098)

Default(0.098)
beta Float

set 2nd detection threshold (from 0 to 1) (default 0.05)

Default(0.05)
gamma Float

set 3rd detection threshold (from 0 to 1) (default 0.05)

Default(0.05)
delta Float

set 4th detection threshold (from 0 to 1) (default 0.05)

Default(0.05)
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

deconvolve

deconvolve(
    _impulse: VideoStream,
    *,
    planes: Int = Default(7),
    impulse: (
        Int | Literal["first", "all"] | Default
    ) = Default("all"),
    noise: Float = Default(1e-07),
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Deconvolve first video stream with second video stream.

Parameters:

Name Type Description Default
planes Int

set planes to deconvolve (from 0 to 15) (default 7)

Default(7)
impulse Int | Literal['first', 'all'] | Default

when to process impulses (from 0 to 1) (default all)

Default('all')
noise Float

set noise (from 0 to 1) (default 1e-07)

Default(1e-07)
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

dedot

dedot(
    *,
    m: (
        Flags | Literal["dotcrawl", "rainbows"] | Default
    ) = Default("dotcrawl+rainbows"),
    lt: Float = Default(0.079),
    tl: Float = Default(0.079),
    tc: Float = Default(0.058),
    ct: Float = Default(0.019),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Reduce cross-luminance and cross-color.

Parameters:

Name Type Description Default
m Flags | Literal['dotcrawl', 'rainbows'] | Default

set filtering mode (default dotcrawl+rainbows)

Default('dotcrawl+rainbows')
lt Float

set spatial luma threshold (from 0 to 1) (default 0.079)

Default(0.079)
tl Float

set tolerance for temporal luma (from 0 to 1) (default 0.079)

Default(0.079)
tc Float

set tolerance for chroma temporal variation (from 0 to 1) (default 0.058)

Default(0.058)
ct Float

set temporal chroma threshold (from 0 to 1) (default 0.019)

Default(0.019)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

deflate

deflate(
    *,
    threshold0: Int = Default(65535),
    threshold1: Int = Default(65535),
    threshold2: Int = Default(65535),
    threshold3: Int = Default(65535),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply deflate effect.

Parameters:

Name Type Description Default
threshold0 Int

set threshold for 1st plane (from 0 to 65535) (default 65535)

Default(65535)
threshold1 Int

set threshold for 2nd plane (from 0 to 65535) (default 65535)

Default(65535)
threshold2 Int

set threshold for 3rd plane (from 0 to 65535) (default 65535)

Default(65535)
threshold3 Int

set threshold for 4th plane (from 0 to 65535) (default 65535)

Default(65535)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

deflicker

deflicker(
    *,
    size: Int = Default(5),
    mode: (
        Int
        | Literal[
            "am", "gm", "hm", "qm", "cm", "pm", "median"
        ]
        | Default
    ) = Default("am"),
    bypass: Boolean = Default(False),
    **kwargs: Any
) -> VideoStream

Remove temporal frame luminance variations.

Parameters:

Name Type Description Default
size Int

set how many frames to use (from 2 to 129) (default 5)

Default(5)
mode Int | Literal['am', 'gm', 'hm', 'qm', 'cm', 'pm', 'median'] | Default

set how to smooth luminance (from 0 to 6) (default am)

Default('am')
bypass Boolean

leave frames unchanged (default false)

Default(False)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

dejudder

dejudder(
    *, cycle: Int = Default(4), **kwargs: Any
) -> VideoStream

Remove judder produced by pullup.

Parameters:

Name Type Description Default
cycle Int

set the length of the cycle to use for dejuddering (from 2 to 240) (default 4)

Default(4)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

delogo(
    *,
    x: String = Default("-1"),
    y: String = Default("-1"),
    w: String = Default("-1"),
    h: String = Default("-1"),
    show: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Remove logo from input video.

Parameters:

Name Type Description Default
x String

set logo x position (default "-1")

Default('-1')
y String

set logo y position (default "-1")

Default('-1')
w String

set logo width (default "-1")

Default('-1')
h String

set logo height (default "-1")

Default('-1')
show Boolean

show delogo area (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

derain

derain(
    *,
    filter_type: (
        Int | Literal["derain", "dehaze"] | Default
    ) = Default("derain"),
    dnn_backend: (
        Int | Literal["native"] | Default
    ) = Default("native"),
    model: String = Default(None),
    input: String = Default("x"),
    output: String = Default("y"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply derain filter to the input.

Parameters:

Name Type Description Default
filter_type Int | Literal['derain', 'dehaze'] | Default

filter type(derain/dehaze) (from 0 to 1) (default derain)

Default('derain')
dnn_backend Int | Literal['native'] | Default

DNN backend (from 0 to 1) (default native)

Default('native')
model String

path to model file

Default(None)
input String

input name of the model (default "x")

Default('x')
output String

output name of the model (default "y")

Default('y')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

deshake

deshake(
    *,
    x: Int = Default(-1),
    y: Int = Default(-1),
    w: Int = Default(-1),
    h: Int = Default(-1),
    rx: Int = Default(16),
    ry: Int = Default(16),
    edge: (
        Int
        | Literal["blank", "original", "clamp", "mirror"]
        | Default
    ) = Default("mirror"),
    blocksize: Int = Default(8),
    contrast: Int = Default(125),
    search: (
        Int | Literal["exhaustive", "less"] | Default
    ) = Default("exhaustive"),
    filename: String = Default(None),
    opencl: Boolean = Default(False),
    **kwargs: Any
) -> VideoStream

Stabilize shaky video.

Parameters:

Name Type Description Default
x Int

set x for the rectangular search area (from -1 to INT_MAX) (default -1)

Default(-1)
y Int

set y for the rectangular search area (from -1 to INT_MAX) (default -1)

Default(-1)
w Int

set width for the rectangular search area (from -1 to INT_MAX) (default -1)

Default(-1)
h Int

set height for the rectangular search area (from -1 to INT_MAX) (default -1)

Default(-1)
rx Int

set x for the rectangular search area (from 0 to 64) (default 16)

Default(16)
ry Int

set y for the rectangular search area (from 0 to 64) (default 16)

Default(16)
edge Int | Literal['blank', 'original', 'clamp', 'mirror'] | Default

set edge mode (from 0 to 3) (default mirror)

Default('mirror')
blocksize Int

set motion search blocksize (from 4 to 128) (default 8)

Default(8)
contrast Int

set contrast threshold for blocks (from 1 to 255) (default 125)

Default(125)
search Int | Literal['exhaustive', 'less'] | Default

set search strategy (from 0 to 1) (default exhaustive)

Default('exhaustive')
filename String

set motion search detailed log file name

Default(None)
opencl Boolean

ignored (default false)

Default(False)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

despill

despill(
    *,
    type: (
        Int | Literal["green", "blue"] | Default
    ) = Default("green"),
    mix: Float = Default(0.5),
    expand: Float = Default(0.0),
    red: Float = Default(0.0),
    green: Float = Default(-1.0),
    blue: Float = Default(0.0),
    brightness: Float = Default(0.0),
    alpha: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Despill video.

Parameters:

Name Type Description Default
type Int | Literal['green', 'blue'] | Default

set the screen type (from 0 to 1) (default green)

Default('green')
mix Float

set the spillmap mix (from 0 to 1) (default 0.5)

Default(0.5)
expand Float

set the spillmap expand (from 0 to 1) (default 0)

Default(0.0)
red Float

set red scale (from -100 to 100) (default 0)

Default(0.0)
green Float

set green scale (from -100 to 100) (default -1)

Default(-1.0)
blue Float

set blue scale (from -100 to 100) (default 0)

Default(0.0)
brightness Float

set brightness (from -10 to 10) (default 0)

Default(0.0)
alpha Boolean

change alpha component (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

detelecine

detelecine(
    *,
    first_field: (
        Int | Literal["top", "t", "bottom", "b"] | Default
    ) = Default("top"),
    pattern: String = Default("23"),
    start_frame: Int = Default(0),
    **kwargs: Any
) -> VideoStream

Apply an inverse telecine pattern.

Parameters:

Name Type Description Default
first_field Int | Literal['top', 't', 'bottom', 'b'] | Default

select first field (from 0 to 1) (default top)

Default('top')
pattern String

pattern that describe for how many fields a frame is to be displayed (default "23")

Default('23')
start_frame Int

position of first frame with respect to the pattern if stream is cut (from 0 to 13) (default 0)

Default(0)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

dilation

dilation(
    *,
    coordinates: Int = Default(255),
    threshold0: Int = Default(65535),
    threshold1: Int = Default(65535),
    threshold2: Int = Default(65535),
    threshold3: Int = Default(65535),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply dilation effect.

Parameters:

Name Type Description Default
coordinates Int

set coordinates (from 0 to 255) (default 255)

Default(255)
threshold0 Int

set threshold for 1st plane (from 0 to 65535) (default 65535)

Default(65535)
threshold1 Int

set threshold for 2nd plane (from 0 to 65535) (default 65535)

Default(65535)
threshold2 Int

set threshold for 3rd plane (from 0 to 65535) (default 65535)

Default(65535)
threshold3 Int

set threshold for 4th plane (from 0 to 65535) (default 65535)

Default(65535)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

displace

displace(
    _xmap: VideoStream,
    _ymap: VideoStream,
    *,
    edge: (
        Int
        | Literal["blank", "smear", "wrap", "mirror"]
        | Default
    ) = Default("smear"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Displace pixels.

Parameters:

Name Type Description Default
edge Int | Literal['blank', 'smear', 'wrap', 'mirror'] | Default

set edge mode (from 0 to 3) (default smear)

Default('smear')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

dnn_classify

dnn_classify(
    *,
    dnn_backend: Int = Default(2),
    model: String = Default(None),
    input: String = Default(None),
    output: String = Default(None),
    backend_configs: String = Default(None),
    options: String = Default(None),
    _async: Boolean = Default(True),
    confidence: Float = Default(0.5),
    labels: String = Default(None),
    target: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply DNN classify filter to the input.

Parameters:

Name Type Description Default
dnn_backend Int

DNN backend (from INT_MIN to INT_MAX) (default 2)

Default(2)
model String

path to model file

Default(None)
input String

input name of the model

Default(None)
output String

output name of the model

Default(None)
backend_configs String

backend configs

Default(None)
options String

backend configs (deprecated, use backend_configs)

Default(None)
_async Boolean

use DNN async inference (ignored, use backend_configs='async=1') (default true)

Default(True)
confidence Float

threshold of confidence (from 0 to 1) (default 0.5)

Default(0.5)
labels String

path to labels file

Default(None)
target String

which one to be classified

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

dnn_detect

dnn_detect(
    *,
    dnn_backend: Int = Default(2),
    model: String = Default(None),
    input: String = Default(None),
    output: String = Default(None),
    backend_configs: String = Default(None),
    options: String = Default(None),
    _async: Boolean = Default(True),
    confidence: Float = Default(0.5),
    labels: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply DNN detect filter to the input.

Parameters:

Name Type Description Default
dnn_backend Int

DNN backend (from INT_MIN to INT_MAX) (default 2)

Default(2)
model String

path to model file

Default(None)
input String

input name of the model

Default(None)
output String

output name of the model

Default(None)
backend_configs String

backend configs

Default(None)
options String

backend configs (deprecated, use backend_configs)

Default(None)
_async Boolean

use DNN async inference (ignored, use backend_configs='async=1') (default true)

Default(True)
confidence Float

threshold of confidence (from 0 to 1) (default 0.5)

Default(0.5)
labels String

path to labels file

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

dnn_processing

dnn_processing(
    *,
    dnn_backend: (
        Int | Literal["native"] | Default
    ) = Default("native"),
    model: String = Default(None),
    input: String = Default(None),
    output: String = Default(None),
    backend_configs: String = Default(None),
    options: String = Default(None),
    _async: Boolean = Default(True),
    **kwargs: Any
) -> VideoStream

Apply DNN processing filter to the input.

Parameters:

Name Type Description Default
dnn_backend Int | Literal['native'] | Default

DNN backend (from INT_MIN to INT_MAX) (default native)

Default('native')
model String

path to model file

Default(None)
input String

input name of the model

Default(None)
output String

output name of the model

Default(None)
backend_configs String

backend configs

Default(None)
options String

backend configs (deprecated, use backend_configs)

Default(None)
_async Boolean

use DNN async inference (ignored, use backend_configs='async=1') (default true)

Default(True)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

doubleweave

doubleweave(
    *,
    first_field: (
        Int | Literal["top", "t", "bottom", "b"] | Default
    ) = Default("top"),
    **kwargs: Any
) -> VideoStream

Weave input video fields into double number of frames.

Parameters:

Name Type Description Default
first_field Int | Literal['top', 't', 'bottom', 'b'] | Default

set first field (from 0 to 1) (default top)

Default('top')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

drawbox

drawbox(
    *,
    x: String = Default("0"),
    y: String = Default("0"),
    width: String = Default("0"),
    height: String = Default("0"),
    color: String = Default("black"),
    thickness: String = Default("3"),
    replace: Boolean = Default(False),
    box_source: String = Default(None),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Draw a colored box on the input video.

Parameters:

Name Type Description Default
x String

set horizontal position of the left box edge (default "0")

Default('0')
y String

set vertical position of the top box edge (default "0")

Default('0')
width String

set width of the box (default "0")

Default('0')
height String

set height of the box (default "0")

Default('0')
color String

set color of the box (default "black")

Default('black')
thickness String

set the box thickness (default "3")

Default('3')
replace Boolean

replace color & alpha (default false)

Default(False)
box_source String

use datas from bounding box in side data

Default(None)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

drawgraph

drawgraph(
    *,
    m1: String = Default(""),
    fg1: String = Default("0xffff0000"),
    m2: String = Default(""),
    fg2: String = Default("0xff00ff00"),
    m3: String = Default(""),
    fg3: String = Default("0xffff00ff"),
    m4: String = Default(""),
    fg4: String = Default("0xffffff00"),
    bg: Color = Default("white"),
    min: Float = Default(-1.0),
    max: Float = Default(1.0),
    mode: (
        Int | Literal["bar", "dot", "line"] | Default
    ) = Default("line"),
    slide: (
        Int
        | Literal[
            "frame",
            "replace",
            "scroll",
            "rscroll",
            "picture",
        ]
        | Default
    ) = Default("frame"),
    size: Image_size = Default("900x256"),
    rate: Video_rate = Default("25"),
    **kwargs: Any
) -> VideoStream

Draw a graph using input video metadata.

Parameters:

Name Type Description Default
m1 String

set 1st metadata key (default "")

Default('')
fg1 String

set 1st foreground color expression (default "0xffff0000")

Default('0xffff0000')
m2 String

set 2nd metadata key (default "")

Default('')
fg2 String

set 2nd foreground color expression (default "0xff00ff00")

Default('0xff00ff00')
m3 String

set 3rd metadata key (default "")

Default('')
fg3 String

set 3rd foreground color expression (default "0xffff00ff")

Default('0xffff00ff')
m4 String

set 4th metadata key (default "")

Default('')
fg4 String

set 4th foreground color expression (default "0xffffff00")

Default('0xffffff00')
bg Color

set background color (default "white")

Default('white')
min Float

set minimal value (from INT_MIN to INT_MAX) (default -1)

Default(-1.0)
max Float

set maximal value (from INT_MIN to INT_MAX) (default 1)

Default(1.0)
mode Int | Literal['bar', 'dot', 'line'] | Default

set graph mode (from 0 to 2) (default line)

Default('line')
slide Int | Literal['frame', 'replace', 'scroll', 'rscroll', 'picture'] | Default

set slide mode (from 0 to 4) (default frame)

Default('frame')
size Image_size

set graph size (default "900x256")

Default('900x256')
rate Video_rate

set video rate (default "25")

Default('25')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

drawgrid

drawgrid(
    *,
    x: String = Default("0"),
    y: String = Default("0"),
    width: String = Default("0"),
    height: String = Default("0"),
    color: String = Default("black"),
    thickness: String = Default("1"),
    replace: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Draw a colored grid on the input video.

Parameters:

Name Type Description Default
x String

set horizontal offset (default "0")

Default('0')
y String

set vertical offset (default "0")

Default('0')
width String

set width of grid cell (default "0")

Default('0')
height String

set height of grid cell (default "0")

Default('0')
color String

set color of the grid (default "black")

Default('black')
thickness String

set grid line thickness (default "1")

Default('1')
replace Boolean

replace color & alpha (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

drawtext

drawtext(
    *,
    fontfile: String = Default(None),
    text: String = Default(None),
    textfile: String = Default(None),
    fontcolor: Color = Default("black"),
    fontcolor_expr: String = Default(""),
    boxcolor: Color = Default("white"),
    bordercolor: Color = Default("black"),
    shadowcolor: Color = Default("black"),
    box: Boolean = Default(False),
    boxborderw: Int = Default(0),
    line_spacing: Int = Default(0),
    fontsize: String = Default(None),
    x: String = Default("0"),
    y: String = Default("0"),
    shadowx: Int = Default(0),
    shadowy: Int = Default(0),
    borderw: Int = Default(0),
    tabsize: Int = Default(4),
    basetime: Int64 = Default("I64_MIN"),
    font: String = Default("Sans"),
    expansion: (
        Int
        | Literal["none", "normal", "strftime"]
        | Default
    ) = Default("normal"),
    timecode: String = Default(None),
    tc24hmax: Boolean = Default(False),
    timecode_rate: Rational = Default("0/1"),
    reload: Int = Default(0),
    alpha: String = Default("1"),
    fix_bounds: Boolean = Default(False),
    start_number: Int = Default(0),
    text_source: String = Default(None),
    text_shaping: Boolean = Default(True),
    ft_load_flags: (
        Flags
        | Literal[
            "default",
            "no_scale",
            "no_hinting",
            "render",
            "no_bitmap",
            "vertical_layout",
            "force_autohint",
            "crop_bitmap",
            "pedantic",
            "ignore_global_advance_width",
            "no_recurse",
            "ignore_transform",
            "monochrome",
            "linear_design",
            "no_autohint",
        ]
        | Default
    ) = Default("0"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Draw text on top of video frames using libfreetype library.

Parameters:

Name Type Description Default
fontfile String

set font file

Default(None)
text String

set text

Default(None)
textfile String

set text file

Default(None)
fontcolor Color

set foreground color (default "black")

Default('black')
fontcolor_expr String

set foreground color expression (default "")

Default('')
boxcolor Color

set box color (default "white")

Default('white')
bordercolor Color

set border color (default "black")

Default('black')
shadowcolor Color

set shadow color (default "black")

Default('black')
box Boolean

set box (default false)

Default(False)
boxborderw Int

set box border width (from INT_MIN to INT_MAX) (default 0)

Default(0)
line_spacing Int

set line spacing in pixels (from INT_MIN to INT_MAX) (default 0)

Default(0)
fontsize String

set font size

Default(None)
x String

set x expression (default "0")

Default('0')
y String

set y expression (default "0")

Default('0')
shadowx Int

set shadow x offset (from INT_MIN to INT_MAX) (default 0)

Default(0)
shadowy Int

set shadow y offset (from INT_MIN to INT_MAX) (default 0)

Default(0)
borderw Int

set border width (from INT_MIN to INT_MAX) (default 0)

Default(0)
tabsize Int

set tab size (from 0 to INT_MAX) (default 4)

Default(4)
basetime Int64

set base time (from I64_MIN to I64_MAX) (default I64_MIN)

Default('I64_MIN')
font String

Font name (default "Sans")

Default('Sans')
expansion Int | Literal['none', 'normal', 'strftime'] | Default

set the expansion mode (from 0 to 2) (default normal)

Default('normal')
timecode String

set initial timecode

Default(None)
tc24hmax Boolean

set 24 hours max (timecode only) (default false)

Default(False)
timecode_rate Rational

set rate (timecode only) (from 0 to INT_MAX) (default 0/1)

Default('0/1')
reload Int

reload text file at specified frame interval (from 0 to INT_MAX) (default 0)

Default(0)
alpha String

apply alpha while rendering (default "1")

Default('1')
fix_bounds Boolean

check and fix text coords to avoid clipping (default false)

Default(False)
start_number Int

start frame number for n/frame_num variable (from 0 to INT_MAX) (default 0)

Default(0)
text_source String

the source of text

Default(None)
text_shaping Boolean

attempt to shape text before drawing (default true)

Default(True)
ft_load_flags Flags | Literal['default', 'no_scale', 'no_hinting', 'render', 'no_bitmap', 'vertical_layout', 'force_autohint', 'crop_bitmap', 'pedantic', 'ignore_global_advance_width', 'no_recurse', 'ignore_transform', 'monochrome', 'linear_design', 'no_autohint'] | Default

set font loading flags for libfreetype (default 0)

Default('0')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

edgedetect

edgedetect(
    *,
    high: Double = Default(0.196078),
    low: Double = Default(0.0784314),
    mode: (
        Int
        | Literal["wires", "colormix", "canny"]
        | Default
    ) = Default("wires"),
    planes: (
        Flags
        | Literal["y", "u", "v", "r", "g", "b"]
        | Default
    ) = Default("y+u+v+r+g+b"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Detect and draw edge.

Parameters:

Name Type Description Default
high Double

set high threshold (from 0 to 1) (default 0.196078)

Default(0.196078)
low Double

set low threshold (from 0 to 1) (default 0.0784314)

Default(0.0784314)
mode Int | Literal['wires', 'colormix', 'canny'] | Default

set mode (from 0 to 2) (default wires)

Default('wires')
planes Flags | Literal['y', 'u', 'v', 'r', 'g', 'b'] | Default

set planes to filter (default y+u+v+r+g+b)

Default('y+u+v+r+g+b')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

elbg

elbg(
    *,
    codebook_length: Int = Default(256),
    nb_steps: Int = Default(1),
    seed: Int64 = Default(-1),
    pal8: Boolean = Default(False),
    use_alpha: Boolean = Default(False),
    **kwargs: Any
) -> VideoStream

Apply posterize effect, using the ELBG algorithm.

Parameters:

Name Type Description Default
codebook_length Int

set codebook length (from 1 to INT_MAX) (default 256)

Default(256)
nb_steps Int

set max number of steps used to compute the mapping (from 1 to INT_MAX) (default 1)

Default(1)
seed Int64

set the random seed (from -1 to UINT32_MAX) (default -1)

Default(-1)
pal8 Boolean

set the pal8 output (default false)

Default(False)
use_alpha Boolean

use alpha channel for mapping (default false)

Default(False)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

entropy

entropy(
    *,
    mode: (
        Int | Literal["normal", "diff"] | Default
    ) = Default("normal"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Measure video frames entropy.

Parameters:

Name Type Description Default
mode Int | Literal['normal', 'diff'] | Default

set kind of histogram entropy measurement (from 0 to 1) (default normal)

Default('normal')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

epx

epx(*, n: Int = Default(3), **kwargs: Any) -> VideoStream

Scale the input using EPX algorithm.

Parameters:

Name Type Description Default
n Int

set scale factor (from 2 to 3) (default 3)

Default(3)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

eq

eq(
    *,
    contrast: String = Default("1.0"),
    brightness: String = Default("0.0"),
    saturation: String = Default("1.0"),
    gamma: String = Default("1.0"),
    gamma_r: String = Default("1.0"),
    gamma_g: String = Default("1.0"),
    gamma_b: String = Default("1.0"),
    gamma_weight: String = Default("1.0"),
    eval: (
        Int | Literal["init", "frame"] | Default
    ) = Default("init"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Adjust brightness, contrast, gamma, and saturation.

Parameters:

Name Type Description Default
contrast String

set the contrast adjustment, negative values give a negative image (default "1.0")

Default('1.0')
brightness String

set the brightness adjustment (default "0.0")

Default('0.0')
saturation String

set the saturation adjustment (default "1.0")

Default('1.0')
gamma String

set the initial gamma value (default "1.0")

Default('1.0')
gamma_r String

gamma value for red (default "1.0")

Default('1.0')
gamma_g String

gamma value for green (default "1.0")

Default('1.0')
gamma_b String

gamma value for blue (default "1.0")

Default('1.0')
gamma_weight String

set the gamma weight which reduces the effect of gamma on bright areas (default "1.0")

Default('1.0')
eval Int | Literal['init', 'frame'] | Default

specify when to evaluate expressions (from 0 to 1) (default init)

Default('init')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

erosion

erosion(
    *,
    coordinates: Int = Default(255),
    threshold0: Int = Default(65535),
    threshold1: Int = Default(65535),
    threshold2: Int = Default(65535),
    threshold3: Int = Default(65535),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply erosion effect.

Parameters:

Name Type Description Default
coordinates Int

set coordinates (from 0 to 255) (default 255)

Default(255)
threshold0 Int

set threshold for 1st plane (from 0 to 65535) (default 65535)

Default(65535)
threshold1 Int

set threshold for 2nd plane (from 0 to 65535) (default 65535)

Default(65535)
threshold2 Int

set threshold for 3rd plane (from 0 to 65535) (default 65535)

Default(65535)
threshold3 Int

set threshold for 4th plane (from 0 to 65535) (default 65535)

Default(65535)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

estdif

estdif(
    *,
    mode: (
        Int | Literal["frame", "field"] | Default
    ) = Default("field"),
    parity: (
        Int | Literal["tff", "bff", "auto"] | Default
    ) = Default("auto"),
    deint: (
        Int | Literal["all", "interlaced"] | Default
    ) = Default("all"),
    rslope: Int = Default(1),
    redge: Int = Default(2),
    ecost: Float = Default(1.0),
    mcost: Float = Default(0.5),
    dcost: Float = Default(0.5),
    interp: (
        Int | Literal["2p", "4p", "6p"] | Default
    ) = Default("4p"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply Edge Slope Tracing deinterlace.

Parameters:

Name Type Description Default
mode Int | Literal['frame', 'field'] | Default

specify the mode (from 0 to 1) (default field)

Default('field')
parity Int | Literal['tff', 'bff', 'auto'] | Default

specify the assumed picture field parity (from -1 to 1) (default auto)

Default('auto')
deint Int | Literal['all', 'interlaced'] | Default

specify which frames to deinterlace (from 0 to 1) (default all)

Default('all')
rslope Int

specify the search radius for edge slope tracing (from 1 to 15) (default 1)

Default(1)
redge Int

specify the search radius for best edge matching (from 0 to 15) (default 2)

Default(2)
ecost Float

specify the edge cost for edge matching (from 0 to 9) (default 1)

Default(1.0)
mcost Float

specify the middle cost for edge matching (from 0 to 1) (default 0.5)

Default(0.5)
dcost Float

specify the distance cost for edge matching (from 0 to 1) (default 0.5)

Default(0.5)
interp Int | Literal['2p', '4p', '6p'] | Default

specify the type of interpolation (from 0 to 2) (default 4p)

Default('4p')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

exposure

exposure(
    *,
    exposure: Float = Default(0.0),
    black: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Adjust exposure of the video stream.

Parameters:

Name Type Description Default
exposure Float

set the exposure correction (from -3 to 3) (default 0)

Default(0.0)
black Float

set the black level correction (from -1 to 1) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

extractplanes

extractplanes(
    *,
    planes: (
        Flags
        | Literal["y", "u", "v", "r", "g", "b", "a"]
        | Default
    ) = Default("r"),
    **kwargs: Any
) -> FilterNode

Extract planes as grayscale frames.

Parameters:

Name Type Description Default
planes Flags | Literal['y', 'u', 'v', 'r', 'g', 'b', 'a'] | Default

set planes (default r)

Default('r')

Returns:

Name Type Description
filter_node FilterNode

the filter node

References

FFmpeg Documentation

fade

fade(
    *,
    type: Int | Literal["in", "out"] | Default = Default(
        "in"
    ),
    start_frame: Int = Default(0),
    nb_frames: Int = Default(25),
    alpha: Boolean = Default(False),
    start_time: Duration = Default(0.0),
    duration: Duration = Default(0.0),
    color: Color = Default("black"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Fade in/out input video.

Parameters:

Name Type Description Default
type Int | Literal['in', 'out'] | Default

set the fade direction (from 0 to 1) (default in)

Default('in')
start_frame Int

Number of the first frame to which to apply the effect. (from 0 to INT_MAX) (default 0)

Default(0)
nb_frames Int

Number of frames to which the effect should be applied. (from 1 to INT_MAX) (default 25)

Default(25)
alpha Boolean

fade alpha if it is available on the input (default false)

Default(False)
start_time Duration

Number of seconds of the beginning of the effect. (default 0)

Default(0.0)
duration Duration

Duration of the effect in seconds. (default 0)

Default(0.0)
color Color

set color (default "black")

Default('black')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

feedback

feedback(
    _feedin: VideoStream,
    *,
    x: Int = Default(0),
    w: Int = Default(0),
    **kwargs: Any
) -> tuple[VideoStream, VideoStream]

Apply feedback video filter.

Parameters:

Name Type Description Default
x Int

set top left crop position (from 0 to INT_MAX) (default 0)

Default(0)
w Int

set crop size (from 0 to INT_MAX) (default 0)

Default(0)

Returns:

Name Type Description
default VideoStream

the video stream

feedout VideoStream

the video stream

References

FFmpeg Documentation

fftdnoiz

fftdnoiz(
    *,
    sigma: Float = Default(1.0),
    amount: Float = Default(1.0),
    block: Int = Default(32),
    overlap: Float = Default(0.5),
    method: (
        Int | Literal["wiener", "hard"] | Default
    ) = Default("wiener"),
    prev: Int = Default(0),
    next: Int = Default(0),
    planes: Int = Default(7),
    window: (
        Int
        | Literal[
            "rect",
            "bartlett",
            "hann",
            "hanning",
            "hamming",
            "blackman",
            "welch",
            "flattop",
            "bharris",
            "bnuttall",
            "bhann",
            "sine",
            "nuttall",
            "lanczos",
            "gauss",
            "tukey",
            "dolph",
            "cauchy",
            "parzen",
            "poisson",
            "bohman",
            "kaiser",
        ]
        | Default
    ) = Default("hann"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Denoise frames using 3D FFT.

Parameters:

Name Type Description Default
sigma Float

set denoise strength (from 0 to 100) (default 1)

Default(1.0)
amount Float

set amount of denoising (from 0.01 to 1) (default 1)

Default(1.0)
block Int

set block size (from 8 to 256) (default 32)

Default(32)
overlap Float

set block overlap (from 0.2 to 0.8) (default 0.5)

Default(0.5)
method Int | Literal['wiener', 'hard'] | Default

set method of denoising (from 0 to 1) (default wiener)

Default('wiener')
prev Int

set number of previous frames for temporal denoising (from 0 to 1) (default 0)

Default(0)
next Int

set number of next frames for temporal denoising (from 0 to 1) (default 0)

Default(0)
planes Int

set planes to filter (from 0 to 15) (default 7)

Default(7)
window Int | Literal['rect', 'bartlett', 'hann', 'hanning', 'hamming', 'blackman', 'welch', 'flattop', 'bharris', 'bnuttall', 'bhann', 'sine', 'nuttall', 'lanczos', 'gauss', 'tukey', 'dolph', 'cauchy', 'parzen', 'poisson', 'bohman', 'kaiser'] | Default

set window function (from 0 to 20) (default hann)

Default('hann')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

fftfilt

fftfilt(
    *,
    dc_Y: Int = Default(0),
    dc_U: Int = Default(0),
    dc_V: Int = Default(0),
    weight_Y: String = Default("1"),
    weight_U: String = Default(None),
    weight_V: String = Default(None),
    eval: (
        Int | Literal["init", "frame"] | Default
    ) = Default("init"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply arbitrary expressions to pixels in frequency domain.

Parameters:

Name Type Description Default
dc_Y Int

adjust gain in Y plane (from 0 to 1000) (default 0)

Default(0)
dc_U Int

adjust gain in U plane (from 0 to 1000) (default 0)

Default(0)
dc_V Int

adjust gain in V plane (from 0 to 1000) (default 0)

Default(0)
weight_Y String

set luminance expression in Y plane (default "1")

Default('1')
weight_U String

set chrominance expression in U plane

Default(None)
weight_V String

set chrominance expression in V plane

Default(None)
eval Int | Literal['init', 'frame'] | Default

specify when to evaluate expressions (from 0 to 1) (default init)

Default('init')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

field

field(
    *,
    type: (
        Int | Literal["top", "bottom"] | Default
    ) = Default("top"),
    **kwargs: Any
) -> VideoStream

Extract a field from the input video.

Parameters:

Name Type Description Default
type Int | Literal['top', 'bottom'] | Default

set field type (top or bottom) (from 0 to 1) (default top)

Default('top')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

fieldhint

fieldhint(
    *,
    hint: String = Default(None),
    mode: (
        Int
        | Literal["absolute", "relative", "pattern"]
        | Default
    ) = Default("absolute"),
    **kwargs: Any
) -> VideoStream

Field matching using hints.

Parameters:

Name Type Description Default
hint String

set hint file

Default(None)
mode Int | Literal['absolute', 'relative', 'pattern'] | Default

set hint mode (from 0 to 2) (default absolute)

Default('absolute')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

fieldorder

fieldorder(
    *,
    order: Int | Literal["bff", "tff"] | Default = Default(
        "tff"
    ),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Set the field order.

Parameters:

Name Type Description Default
order Int | Literal['bff', 'tff'] | Default

output field order (from 0 to 1) (default tff)

Default('tff')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

fillborders

fillborders(
    *,
    left: Int = Default(0),
    right: Int = Default(0),
    top: Int = Default(0),
    bottom: Int = Default(0),
    mode: (
        Int
        | Literal[
            "smear",
            "mirror",
            "fixed",
            "reflect",
            "wrap",
            "fade",
            "margins",
        ]
        | Default
    ) = Default("smear"),
    color: Color = Default("black"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Fill borders of the input video.

Parameters:

Name Type Description Default
left Int

set the left fill border (from 0 to INT_MAX) (default 0)

Default(0)
right Int

set the right fill border (from 0 to INT_MAX) (default 0)

Default(0)
top Int

set the top fill border (from 0 to INT_MAX) (default 0)

Default(0)
bottom Int

set the bottom fill border (from 0 to INT_MAX) (default 0)

Default(0)
mode Int | Literal['smear', 'mirror', 'fixed', 'reflect', 'wrap', 'fade', 'margins'] | Default

set the fill borders mode (from 0 to 6) (default smear)

Default('smear')
color Color

set the color for the fixed/fade mode (default "black")

Default('black')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

filter_multi_output

filter_multi_output(
    *streams: "FilterableStream",
    name: str,
    input_typings: tuple[StreamType, ...] = (),
    output_typings: tuple[StreamType, ...] = (),
    **kwargs: Any
) -> "FilterNode"

Apply a custom filter which has multiple outputs to this stream

Parameters:

Name Type Description Default
*streams FilterableStream

the streams to apply the filter to

()
name str

the name of the filter

required
input_typings tuple[StreamType, ...]

the input typings

()
output_typings tuple[StreamType, ...]

the output typings

()
**kwargs Any

the arguments for the filter

{}

Returns:

Type Description
'FilterNode'

the FilterNode

find_rect

find_rect(
    *,
    object: String = Default(None),
    threshold: Float = Default(0.5),
    mipmaps: Int = Default(3),
    xmin: Int = Default(0),
    discard: Boolean = Default(False),
    **kwargs: Any
) -> VideoStream

Find a user specified object.

Parameters:

Name Type Description Default
object String

object bitmap filename

Default(None)
threshold Float

set threshold (from 0 to 1) (default 0.5)

Default(0.5)
mipmaps Int

set mipmaps (from 1 to 5) (default 3)

Default(3)
xmin Int

(from 0 to INT_MAX) (default 0)

Default(0)
discard Boolean

(default false)

Default(False)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

floodfill

floodfill(
    *,
    x: Int = Default(0),
    y: Int = Default(0),
    s0: Int = Default(0),
    s1: Int = Default(0),
    s2: Int = Default(0),
    s3: Int = Default(0),
    d0: Int = Default(0),
    d1: Int = Default(0),
    d2: Int = Default(0),
    d3: Int = Default(0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Fill area with same color with another color.

Parameters:

Name Type Description Default
x Int

set pixel x coordinate (from 0 to 65535) (default 0)

Default(0)
y Int

set pixel y coordinate (from 0 to 65535) (default 0)

Default(0)
s0 Int

set source #0 component value (from -1 to 65535) (default 0)

Default(0)
s1 Int

set source #1 component value (from -1 to 65535) (default 0)

Default(0)
s2 Int

set source #2 component value (from -1 to 65535) (default 0)

Default(0)
s3 Int

set source #3 component value (from -1 to 65535) (default 0)

Default(0)
d0 Int

set destination #0 component value (from 0 to 65535) (default 0)

Default(0)
d1 Int

set destination #1 component value (from 0 to 65535) (default 0)

Default(0)
d2 Int

set destination #2 component value (from 0 to 65535) (default 0)

Default(0)
d3 Int

set destination #3 component value (from 0 to 65535) (default 0)

Default(0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

format

format(
    *, pix_fmts: String = Default(None), **kwargs: Any
) -> VideoStream

Convert the input video to one of the specified pixel formats.

Parameters:

Name Type Description Default
pix_fmts String

A '|'-separated list of pixel formats

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

fps

fps(
    *,
    fps: String = Default("25"),
    start_time: Double = Default("DBL_MAX"),
    round: (
        Int
        | Literal["zero", "inf", "down", "up", "near"]
        | Default
    ) = Default("near"),
    eof_action: (
        Int | Literal["round", "pass"] | Default
    ) = Default("round"),
    **kwargs: Any
) -> VideoStream

Force constant framerate.

Parameters:

Name Type Description Default
fps String

A string describing desired output framerate (default "25")

Default('25')
start_time Double

Assume the first PTS should be this value. (from -DBL_MAX to DBL_MAX) (default DBL_MAX)

Default('DBL_MAX')
round Int | Literal['zero', 'inf', 'down', 'up', 'near'] | Default

set rounding method for timestamps (from 0 to 5) (default near)

Default('near')
eof_action Int | Literal['round', 'pass'] | Default

action performed for last frame (from 0 to 1) (default round)

Default('round')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

framepack

framepack(
    _right: VideoStream,
    *,
    format: (
        Int
        | Literal[
            "sbs", "tab", "frameseq", "lines", "columns"
        ]
        | Default
    ) = Default("sbs"),
    **kwargs: Any
) -> VideoStream

Generate a frame packed stereoscopic video.

Parameters:

Name Type Description Default
format Int | Literal['sbs', 'tab', 'frameseq', 'lines', 'columns'] | Default

Frame pack output format (from 0 to INT_MAX) (default sbs)

Default('sbs')

Returns:

Name Type Description
packed VideoStream

the video stream

References

FFmpeg Documentation

framerate

framerate(
    *,
    fps: Video_rate = Default("50"),
    interp_start: Int = Default(15),
    interp_end: Int = Default(240),
    scene: Double = Default(8.2),
    flags: (
        Flags
        | Literal["scene_change_detect", "scd"]
        | Default
    ) = Default("scene_change_detect+scd"),
    **kwargs: Any
) -> VideoStream

Upsamples or downsamples progressive source between specified frame rates.

Parameters:

Name Type Description Default
fps Video_rate

required output frames per second rate (default "50")

Default('50')
interp_start Int

point to start linear interpolation (from 0 to 255) (default 15)

Default(15)
interp_end Int

point to end linear interpolation (from 0 to 255) (default 240)

Default(240)
scene Double

scene change level (from 0 to 100) (default 8.2)

Default(8.2)
flags Flags | Literal['scene_change_detect', 'scd'] | Default

set flags (default scene_change_detect+scd)

Default('scene_change_detect+scd')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

framestep

framestep(
    *,
    step: Int = Default(1),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Select one frame every N frames.

Parameters:

Name Type Description Default
step Int

set frame step (from 1 to INT_MAX) (default 1)

Default(1)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

freezedetect

freezedetect(
    *,
    n: Double = Default(0.001),
    d: Duration = Default(2.0),
    **kwargs: Any
) -> VideoStream

Detects frozen video input.

Parameters:

Name Type Description Default
n Double

set noise tolerance (from 0 to 1) (default 0.001)

Default(0.001)
d Duration

set minimum duration in seconds (default 2)

Default(2.0)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

freezeframes

freezeframes(
    _replace: VideoStream,
    *,
    first: Int64 = Default(0),
    last: Int64 = Default(0),
    replace: Int64 = Default(0),
    **kwargs: Any
) -> VideoStream

Freeze video frames.

Parameters:

Name Type Description Default
first Int64

set first frame to freeze (from 0 to I64_MAX) (default 0)

Default(0)
last Int64

set last frame to freeze (from 0 to I64_MAX) (default 0)

Default(0)
replace Int64

set frame to replace (from 0 to I64_MAX) (default 0)

Default(0)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

frei0r

frei0r(
    *,
    filter_name: String = Default(None),
    filter_params: String = Default(None),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply a frei0r effect.

Parameters:

Name Type Description Default
filter_name String
Default(None)
filter_params String
Default(None)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

fspp

fspp(
    *,
    quality: Int = Default(4),
    qp: Int = Default(0),
    strength: Int = Default(0),
    use_bframe_qp: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply Fast Simple Post-processing filter.

Parameters:

Name Type Description Default
quality Int

set quality (from 4 to 5) (default 4)

Default(4)
qp Int

force a constant quantizer parameter (from 0 to 64) (default 0)

Default(0)
strength Int

set filter strength (from -15 to 32) (default 0)

Default(0)
use_bframe_qp Boolean

use B-frames' QP (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

gblur

gblur(
    *,
    sigma: Float = Default(0.5),
    steps: Int = Default(1),
    planes: Int = Default(15),
    sigmaV: Float = Default(-1.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply Gaussian Blur filter.

Parameters:

Name Type Description Default
sigma Float

set sigma (from 0 to 1024) (default 0.5)

Default(0.5)
steps Int

set number of steps (from 1 to 6) (default 1)

Default(1)
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
sigmaV Float

set vertical sigma (from -1 to 1024) (default -1)

Default(-1.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

geq

geq(
    *,
    lum_expr: String = Default(None),
    cb_expr: String = Default(None),
    cr_expr: String = Default(None),
    alpha_expr: String = Default(None),
    red_expr: String = Default(None),
    green_expr: String = Default(None),
    blue_expr: String = Default(None),
    interpolation: (
        Int
        | Literal["nearest", "n", "bilinear", "b"]
        | Default
    ) = Default("bilinear"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply generic equation to each pixel.

Parameters:

Name Type Description Default
lum_expr String

set luminance expression

Default(None)
cb_expr String

set chroma blue expression

Default(None)
cr_expr String

set chroma red expression

Default(None)
alpha_expr String

set alpha expression

Default(None)
red_expr String

set red expression

Default(None)
green_expr String

set green expression

Default(None)
blue_expr String

set blue expression

Default(None)
interpolation Int | Literal['nearest', 'n', 'bilinear', 'b'] | Default

set interpolation method (from 0 to 1) (default bilinear)

Default('bilinear')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

gradfun

gradfun(
    *,
    strength: Float = Default(1.2),
    radius: Int = Default(16),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Debands video quickly using gradients.

Parameters:

Name Type Description Default
strength Float

The maximum amount by which the filter will change any one pixel. (from 0.51 to 64) (default 1.2)

Default(1.2)
radius Int

The neighborhood to fit the gradient to. (from 4 to 32) (default 16)

Default(16)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

graphmonitor

graphmonitor(
    *,
    size: Image_size = Default("hd720"),
    opacity: Float = Default(0.9),
    mode: (
        Int | Literal["full", "compact"] | Default
    ) = Default("full"),
    flags: (
        Flags
        | Literal[
            "queue",
            "frame_count_in",
            "frame_count_out",
            "frame_count_delta",
            "pts",
            "pts_delta",
            "time",
            "time_delta",
            "timebase",
            "format",
            "size",
            "rate",
            "eof",
            "sample_count_in",
            "sample_count_out",
            "sample_count_delta",
        ]
        | Default
    ) = Default("queue"),
    rate: Video_rate = Default("25"),
    **kwargs: Any
) -> VideoStream

Show various filtergraph stats.

Parameters:

Name Type Description Default
size Image_size

set monitor size (default "hd720")

Default('hd720')
opacity Float

set video opacity (from 0 to 1) (default 0.9)

Default(0.9)
mode Int | Literal['full', 'compact'] | Default

set mode (from 0 to 1) (default full)

Default('full')
flags Flags | Literal['queue', 'frame_count_in', 'frame_count_out', 'frame_count_delta', 'pts', 'pts_delta', 'time', 'time_delta', 'timebase', 'format', 'size', 'rate', 'eof', 'sample_count_in', 'sample_count_out', 'sample_count_delta'] | Default

set flags (default queue)

Default('queue')
rate Video_rate

set video rate (default "25")

Default('25')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

grayworld

grayworld(
    *, enable: String = Default(None), **kwargs: Any
) -> VideoStream

Adjust white balance using LAB gray world algorithm

Parameters:

Name Type Description Default
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

greyedge

greyedge(
    *,
    difford: Int = Default(1),
    minknorm: Int = Default(1),
    sigma: Double = Default(1.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Estimates scene illumination by grey edge assumption.

Parameters:

Name Type Description Default
difford Int

set differentiation order (from 0 to 2) (default 1)

Default(1)
minknorm Int

set Minkowski norm (from 0 to 20) (default 1)

Default(1)
sigma Double

set sigma (from 0 to 1024) (default 1)

Default(1.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

haldclut

haldclut(
    _clut: VideoStream,
    *,
    clut: Int | Literal["first", "all"] | Default = Default(
        "all"
    ),
    interp: (
        Int
        | Literal[
            "nearest",
            "trilinear",
            "tetrahedral",
            "pyramid",
            "prism",
        ]
        | Default
    ) = Default("tetrahedral"),
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Adjust colors using a Hald CLUT.

Parameters:

Name Type Description Default
clut Int | Literal['first', 'all'] | Default

when to process CLUT (from 0 to 1) (default all)

Default('all')
interp Int | Literal['nearest', 'trilinear', 'tetrahedral', 'pyramid', 'prism'] | Default

select interpolation mode (from 0 to 4) (default tetrahedral)

Default('tetrahedral')
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

hflip

hflip(
    *, enable: String = Default(None), **kwargs: Any
) -> VideoStream

Horizontally flip the input video.

Parameters:

Name Type Description Default
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

histeq

histeq(
    *,
    strength: Float = Default(0.2),
    intensity: Float = Default(0.21),
    antibanding: (
        Int | Literal["none", "weak", "strong"] | Default
    ) = Default("none"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply global color histogram equalization.

Parameters:

Name Type Description Default
strength Float

set the strength (from 0 to 1) (default 0.2)

Default(0.2)
intensity Float

set the intensity (from 0 to 1) (default 0.21)

Default(0.21)
antibanding Int | Literal['none', 'weak', 'strong'] | Default

set the antibanding level (from 0 to 2) (default none)

Default('none')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

histogram

histogram(
    *,
    level_height: Int = Default(200),
    scale_height: Int = Default(12),
    display_mode: (
        Int
        | Literal["overlay", "parade", "stack"]
        | Default
    ) = Default("stack"),
    levels_mode: (
        Int | Literal["linear", "logarithmic"] | Default
    ) = Default("linear"),
    components: Int = Default(7),
    fgopacity: Float = Default(0.7),
    bgopacity: Float = Default(0.5),
    colors_mode: (
        Int
        | Literal[
            "whiteonblack",
            "blackonwhite",
            "whiteongray",
            "blackongray",
            "coloronblack",
            "coloronwhite",
            "colorongray",
            "blackoncolor",
            "whiteoncolor",
            "grayoncolor",
        ]
        | Default
    ) = Default("whiteonblack"),
    **kwargs: Any
) -> VideoStream

Compute and draw a histogram.

Parameters:

Name Type Description Default
level_height Int

set level height (from 50 to 2048) (default 200)

Default(200)
scale_height Int

set scale height (from 0 to 40) (default 12)

Default(12)
display_mode Int | Literal['overlay', 'parade', 'stack'] | Default

set display mode (from 0 to 2) (default stack)

Default('stack')
levels_mode Int | Literal['linear', 'logarithmic'] | Default

set levels mode (from 0 to 1) (default linear)

Default('linear')
components Int

set color components to display (from 1 to 15) (default 7)

Default(7)
fgopacity Float

set foreground opacity (from 0 to 1) (default 0.7)

Default(0.7)
bgopacity Float

set background opacity (from 0 to 1) (default 0.5)

Default(0.5)
colors_mode Int | Literal['whiteonblack', 'blackonwhite', 'whiteongray', 'blackongray', 'coloronblack', 'coloronwhite', 'colorongray', 'blackoncolor', 'whiteoncolor', 'grayoncolor'] | Default

set colors mode (from 0 to 9) (default whiteonblack)

Default('whiteonblack')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

hqdn3d

hqdn3d(
    *,
    luma_spatial: Double = Default(0.0),
    chroma_spatial: Double = Default(0.0),
    luma_tmp: Double = Default(0.0),
    chroma_tmp: Double = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply a High Quality 3D Denoiser.

Parameters:

Name Type Description Default
luma_spatial Double

spatial luma strength (from 0 to DBL_MAX) (default 0)

Default(0.0)
chroma_spatial Double

spatial chroma strength (from 0 to DBL_MAX) (default 0)

Default(0.0)
luma_tmp Double

temporal luma strength (from 0 to DBL_MAX) (default 0)

Default(0.0)
chroma_tmp Double

temporal chroma strength (from 0 to DBL_MAX) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

hqx

hqx(*, n: Int = Default(3), **kwargs: Any) -> VideoStream

Scale the input by 2, 3 or 4 using the hq*x magnification algorithm.

Parameters:

Name Type Description Default
n Int

set scale factor (from 2 to 4) (default 3)

Default(3)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

hsvhold

hsvhold(
    *,
    hue: Float = Default(0.0),
    sat: Float = Default(0.0),
    val: Float = Default(0.0),
    similarity: Float = Default(0.01),
    blend: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Turns a certain HSV range into gray.

Parameters:

Name Type Description Default
hue Float

set the hue value (from -360 to 360) (default 0)

Default(0.0)
sat Float

set the saturation value (from -1 to 1) (default 0)

Default(0.0)
val Float

set the value value (from -1 to 1) (default 0)

Default(0.0)
similarity Float

set the hsvhold similarity value (from 1e-05 to 1) (default 0.01)

Default(0.01)
blend Float

set the hsvhold blend value (from 0 to 1) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

hsvkey

hsvkey(
    *,
    hue: Float = Default(0.0),
    sat: Float = Default(0.0),
    val: Float = Default(0.0),
    similarity: Float = Default(0.01),
    blend: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Turns a certain HSV range into transparency. Operates on YUV colors.

Parameters:

Name Type Description Default
hue Float

set the hue value (from -360 to 360) (default 0)

Default(0.0)
sat Float

set the saturation value (from -1 to 1) (default 0)

Default(0.0)
val Float

set the value value (from -1 to 1) (default 0)

Default(0.0)
similarity Float

set the hsvkey similarity value (from 1e-05 to 1) (default 0.01)

Default(0.01)
blend Float

set the hsvkey blend value (from 0 to 1) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

hue

hue(
    *,
    h: String = Default(None),
    s: String = Default("1"),
    H: String = Default(None),
    b: String = Default("0"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Adjust the hue and saturation of the input video.

Parameters:

Name Type Description Default
h String

set the hue angle degrees expression

Default(None)
s String

set the saturation expression (default "1")

Default('1')
H String

set the hue angle radians expression

Default(None)
b String

set the brightness expression (default "0")

Default('0')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

huesaturation

huesaturation(
    *,
    hue: Float = Default(0.0),
    saturation: Float = Default(0.0),
    intensity: Float = Default(0.0),
    colors: (
        Flags
        | Literal["r", "y", "g", "c", "b", "m", "a"]
        | Default
    ) = Default("r+y+g+c+b+m+a"),
    strength: Float = Default(1.0),
    rw: Float = Default(0.333),
    gw: Float = Default(0.334),
    bw: Float = Default(0.333),
    lightness: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply hue-saturation-intensity adjustments.

Parameters:

Name Type Description Default
hue Float

set the hue shift (from -180 to 180) (default 0)

Default(0.0)
saturation Float

set the saturation shift (from -1 to 1) (default 0)

Default(0.0)
intensity Float

set the intensity shift (from -1 to 1) (default 0)

Default(0.0)
colors Flags | Literal['r', 'y', 'g', 'c', 'b', 'm', 'a'] | Default

set colors range (default r+y+g+c+b+m+a)

Default('r+y+g+c+b+m+a')
strength Float

set the filtering strength (from 0 to 100) (default 1)

Default(1.0)
rw Float

set the red weight (from 0 to 1) (default 0.333)

Default(0.333)
gw Float

set the green weight (from 0 to 1) (default 0.334)

Default(0.334)
bw Float

set the blue weight (from 0 to 1) (default 0.333)

Default(0.333)
lightness Boolean

set the preserve lightness (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

hwdownload

hwdownload(**kwargs: Any) -> VideoStream

Download a hardware frame to a normal frame

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

hwmap

hwmap(
    *,
    mode: (
        Flags
        | Literal["read", "write", "overwrite", "direct"]
        | Default
    ) = Default("read+write"),
    derive_device: String = Default(None),
    reverse: Int = Default(0),
    **kwargs: Any
) -> VideoStream

Map hardware frames

Parameters:

Name Type Description Default
mode Flags | Literal['read', 'write', 'overwrite', 'direct'] | Default

Frame mapping mode (default read+write)

Default('read+write')
derive_device String

Derive a new device of this type

Default(None)
reverse Int

Map in reverse (create and allocate in the sink) (from 0 to 1) (default 0)

Default(0)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

hwupload

hwupload(
    *, derive_device: String = Default(None), **kwargs: Any
) -> VideoStream

Upload a normal frame to a hardware frame

Parameters:

Name Type Description Default
derive_device String

Derive a new device of this type

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

hysteresis

hysteresis(
    _alt: VideoStream,
    *,
    planes: Int = Default(15),
    threshold: Int = Default(0),
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Grow first stream into second stream by connecting components.

Parameters:

Name Type Description Default
planes Int

set planes (from 0 to 15) (default 15)

Default(15)
threshold Int

set threshold (from 0 to 65535) (default 0)

Default(0)
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

identity

identity(
    _reference: VideoStream,
    *,
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Calculate the Identity between two video streams.

Parameters:

Name Type Description Default
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

idet

idet(
    *,
    intl_thres: Float = Default(1.04),
    prog_thres: Float = Default(1.5),
    rep_thres: Float = Default(3.0),
    half_life: Float = Default(0.0),
    analyze_interlaced_flag: Int = Default(0),
    **kwargs: Any
) -> VideoStream

Interlace detect Filter.

Parameters:

Name Type Description Default
intl_thres Float

set interlacing threshold (from -1 to FLT_MAX) (default 1.04)

Default(1.04)
prog_thres Float

set progressive threshold (from -1 to FLT_MAX) (default 1.5)

Default(1.5)
rep_thres Float

set repeat threshold (from -1 to FLT_MAX) (default 3)

Default(3.0)
half_life Float

half life of cumulative statistics (from -1 to INT_MAX) (default 0)

Default(0.0)
analyze_interlaced_flag Int

set number of frames to use to determine if the interlace flag is accurate (from 0 to INT_MAX) (default 0)

Default(0)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

il

il(
    *,
    luma_mode: (
        Int
        | Literal[
            "none", "interleave", "i", "deinterleave", "d"
        ]
        | Default
    ) = Default("none"),
    chroma_mode: (
        Int
        | Literal[
            "none", "interleave", "i", "deinterleave", "d"
        ]
        | Default
    ) = Default("none"),
    alpha_mode: (
        Int
        | Literal[
            "none", "interleave", "i", "deinterleave", "d"
        ]
        | Default
    ) = Default("none"),
    luma_swap: Boolean = Default(False),
    chroma_swap: Boolean = Default(False),
    alpha_swap: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Deinterleave or interleave fields.

Parameters:

Name Type Description Default
luma_mode Int | Literal['none', 'interleave', 'i', 'deinterleave', 'd'] | Default

select luma mode (from 0 to 2) (default none)

Default('none')
chroma_mode Int | Literal['none', 'interleave', 'i', 'deinterleave', 'd'] | Default

select chroma mode (from 0 to 2) (default none)

Default('none')
alpha_mode Int | Literal['none', 'interleave', 'i', 'deinterleave', 'd'] | Default

select alpha mode (from 0 to 2) (default none)

Default('none')
luma_swap Boolean

swap luma fields (default false)

Default(False)
chroma_swap Boolean

swap chroma fields (default false)

Default(False)
alpha_swap Boolean

swap alpha fields (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

inflate

inflate(
    *,
    threshold0: Int = Default(65535),
    threshold1: Int = Default(65535),
    threshold2: Int = Default(65535),
    threshold3: Int = Default(65535),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply inflate effect.

Parameters:

Name Type Description Default
threshold0 Int

set threshold for 1st plane (from 0 to 65535) (default 65535)

Default(65535)
threshold1 Int

set threshold for 2nd plane (from 0 to 65535) (default 65535)

Default(65535)
threshold2 Int

set threshold for 3rd plane (from 0 to 65535) (default 65535)

Default(65535)
threshold3 Int

set threshold for 4th plane (from 0 to 65535) (default 65535)

Default(65535)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

interlace

interlace(
    *,
    scan: Int | Literal["tff", "bff"] | Default = Default(
        "tff"
    ),
    lowpass: (
        Int | Literal["off", "linear", "complex"] | Default
    ) = Default("linear"),
    **kwargs: Any
) -> VideoStream

Convert progressive video into interlaced.

Parameters:

Name Type Description Default
scan Int | Literal['tff', 'bff'] | Default

scanning mode (from 0 to 1) (default tff)

Default('tff')
lowpass Int | Literal['off', 'linear', 'complex'] | Default

set vertical low-pass filter (from 0 to 2) (default linear)

Default('linear')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

kerndeint

kerndeint(
    *,
    thresh: Int = Default(10),
    map: Boolean = Default(False),
    order: Boolean = Default(False),
    sharp: Boolean = Default(False),
    twoway: Boolean = Default(False),
    **kwargs: Any
) -> VideoStream

Apply kernel deinterlacing to the input.

Parameters:

Name Type Description Default
thresh Int

set the threshold (from 0 to 255) (default 10)

Default(10)
map Boolean

set the map (default false)

Default(False)
order Boolean

set the order (default false)

Default(False)
sharp Boolean

set sharpening (default false)

Default(False)
twoway Boolean

set twoway (default false)

Default(False)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

kirsch

kirsch(
    *,
    planes: Int = Default(15),
    scale: Float = Default(1.0),
    delta: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply kirsch operator.

Parameters:

Name Type Description Default
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
scale Float

set scale (from 0 to 65535) (default 1)

Default(1.0)
delta Float

set delta (from -65535 to 65535) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

label

label(context: DAGContext = None) -> str

Return the label for this stream

Parameters:

Name Type Description Default
context DAGContext

the DAG context

None

Returns:

Type Description
str

the label for this stream

lagfun

lagfun(
    *,
    decay: Float = Default(0.95),
    planes: Flags = Default("F"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Slowly update darker pixels.

Parameters:

Name Type Description Default
decay Float

set decay (from 0 to 1) (default 0.95)

Default(0.95)
planes Flags

set what planes to filter (default F)

Default('F')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

latency

latency(
    *, enable: String = Default(None), **kwargs: Any
) -> VideoStream

Report video filtering latency.

Parameters:

Name Type Description Default
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

lenscorrection

lenscorrection(
    *,
    cx: Double = Default(0.5),
    cy: Double = Default(0.5),
    k1: Double = Default(0.0),
    k2: Double = Default(0.0),
    i: (
        Int | Literal["nearest", "bilinear"] | Default
    ) = Default("nearest"),
    fc: Color = Default("black@0"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Rectify the image by correcting for lens distortion.

Parameters:

Name Type Description Default
cx Double

set relative center x (from 0 to 1) (default 0.5)

Default(0.5)
cy Double

set relative center y (from 0 to 1) (default 0.5)

Default(0.5)
k1 Double

set quadratic distortion factor (from -1 to 1) (default 0)

Default(0.0)
k2 Double

set double quadratic distortion factor (from -1 to 1) (default 0)

Default(0.0)
i Int | Literal['nearest', 'bilinear'] | Default

set interpolation type (from 0 to 64) (default nearest)

Default('nearest')
fc Color

set the color of the unmapped pixels (default "black@0")

Default('black@0')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

libvmaf

libvmaf(
    _reference: VideoStream,
    *,
    model_path: String = Default(None),
    log_path: String = Default(None),
    log_fmt: String = Default("xml"),
    enable_transform: Boolean = Default(False),
    psnr: Boolean = Default(False),
    ssim: Boolean = Default(False),
    ms_ssim: Boolean = Default(False),
    pool: String = Default(None),
    n_threads: Int = Default(0),
    n_subsample: Int = Default(1),
    enable_conf_interval: Boolean = Default(False),
    model: String = Default("version=vmaf_v0.6.1"),
    feature: String = Default(None),
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    **kwargs: Any
) -> VideoStream

Calculate the VMAF between two video streams.

Parameters:

Name Type Description Default
model_path String

use model='path=...'.

Default(None)
log_path String

Set the file path to be used to write log.

Default(None)
log_fmt String

Set the format of the log (csv, json, xml, or sub). (default "xml")

Default('xml')
enable_transform Boolean

use model='enable_transform=true'. (default false)

Default(False)
psnr Boolean

use feature='name=psnr'. (default false)

Default(False)
ssim Boolean

use feature='name=float_ssim'. (default false)

Default(False)
ms_ssim Boolean

use feature='name=float_ms_ssim'. (default false)

Default(False)
pool String

Set the pool method to be used for computing vmaf.

Default(None)
n_threads Int

Set number of threads to be used when computing vmaf. (from 0 to UINT32_MAX) (default 0)

Default(0)
n_subsample Int

Set interval for frame subsampling used when computing vmaf. (from 1 to UINT32_MAX) (default 1)

Default(1)
enable_conf_interval Boolean

model='enable_conf_interval=true'. (default false)

Default(False)
model String

Set the model to be used for computing vmaf. (default "version=vmaf_v0.6.1")

Default('version=vmaf_v0.6.1')
feature String

Set the feature to be used for computing vmaf.

Default(None)
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

limiter

limiter(
    *,
    min: Int = Default(0),
    max: Int = Default(65535),
    planes: Int = Default(15),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Limit pixels components to the specified range.

Parameters:

Name Type Description Default
min Int

set min value (from 0 to 65535) (default 0)

Default(0)
max Int

set max value (from 0 to 65535) (default 65535)

Default(65535)
planes Int

set planes (from 0 to 15) (default 15)

Default(15)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

loop

loop(
    *,
    loop: Int = Default(0),
    size: Int64 = Default(0),
    start: Int64 = Default(0),
    **kwargs: Any
) -> VideoStream

Loop video frames.

Parameters:

Name Type Description Default
loop Int

number of loops (from -1 to INT_MAX) (default 0)

Default(0)
size Int64

max number of frames to loop (from 0 to 32767) (default 0)

Default(0)
start Int64

set the loop start frame (from 0 to I64_MAX) (default 0)

Default(0)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

lumakey

lumakey(
    *,
    threshold: Double = Default(0.0),
    tolerance: Double = Default(0.01),
    softness: Double = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Turns a certain luma into transparency.

Parameters:

Name Type Description Default
threshold Double

set the threshold value (from 0 to 1) (default 0)

Default(0.0)
tolerance Double

set the tolerance value (from 0 to 1) (default 0.01)

Default(0.01)
softness Double

set the softness value (from 0 to 1) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

lut

lut(
    *,
    c0: String = Default("clipval"),
    c1: String = Default("clipval"),
    c2: String = Default("clipval"),
    c3: String = Default("clipval"),
    y: String = Default("clipval"),
    u: String = Default("clipval"),
    v: String = Default("clipval"),
    r: String = Default("clipval"),
    g: String = Default("clipval"),
    b: String = Default("clipval"),
    a: String = Default("clipval"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Compute and apply a lookup table to the RGB/YUV input video.

Parameters:

Name Type Description Default
c0 String

set component #0 expression (default "clipval")

Default('clipval')
c1 String

set component #1 expression (default "clipval")

Default('clipval')
c2 String

set component #2 expression (default "clipval")

Default('clipval')
c3 String

set component #3 expression (default "clipval")

Default('clipval')
y String

set Y expression (default "clipval")

Default('clipval')
u String

set U expression (default "clipval")

Default('clipval')
v String

set V expression (default "clipval")

Default('clipval')
r String

set R expression (default "clipval")

Default('clipval')
g String

set G expression (default "clipval")

Default('clipval')
b String

set B expression (default "clipval")

Default('clipval')
a String

set A expression (default "clipval")

Default('clipval')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

lut1d

lut1d(
    *,
    file: String = Default(None),
    interp: (
        Int
        | Literal[
            "nearest", "linear", "cosine", "cubic", "spline"
        ]
        | Default
    ) = Default("linear"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Adjust colors using a 1D LUT.

Parameters:

Name Type Description Default
file String

set 1D LUT file name

Default(None)
interp Int | Literal['nearest', 'linear', 'cosine', 'cubic', 'spline'] | Default

select interpolation mode (from 0 to 4) (default linear)

Default('linear')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

lut2

lut2(
    _srcy: VideoStream,
    *,
    c0: String = Default("x"),
    c1: String = Default("x"),
    c2: String = Default("x"),
    c3: String = Default("x"),
    d: Int = Default(0),
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Compute and apply a lookup table from two video inputs.

Parameters:

Name Type Description Default
c0 String

set component #0 expression (default "x")

Default('x')
c1 String

set component #1 expression (default "x")

Default('x')
c2 String

set component #2 expression (default "x")

Default('x')
c3 String

set component #3 expression (default "x")

Default('x')
d Int

set output depth (from 0 to 16) (default 0)

Default(0)
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

lut3d

lut3d(
    *,
    file: String = Default(None),
    clut: Int | Literal["first", "all"] | Default = Default(
        "all"
    ),
    interp: (
        Int
        | Literal[
            "nearest",
            "trilinear",
            "tetrahedral",
            "pyramid",
            "prism",
        ]
        | Default
    ) = Default("tetrahedral"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Adjust colors using a 3D LUT.

Parameters:

Name Type Description Default
file String

set 3D LUT file name

Default(None)
clut Int | Literal['first', 'all'] | Default

when to process CLUT (from 0 to 1) (default all)

Default('all')
interp Int | Literal['nearest', 'trilinear', 'tetrahedral', 'pyramid', 'prism'] | Default

select interpolation mode (from 0 to 4) (default tetrahedral)

Default('tetrahedral')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

lutrgb

lutrgb(
    *,
    c0: String = Default("clipval"),
    c1: String = Default("clipval"),
    c2: String = Default("clipval"),
    c3: String = Default("clipval"),
    y: String = Default("clipval"),
    u: String = Default("clipval"),
    v: String = Default("clipval"),
    r: String = Default("clipval"),
    g: String = Default("clipval"),
    b: String = Default("clipval"),
    a: String = Default("clipval"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Compute and apply a lookup table to the RGB input video.

Parameters:

Name Type Description Default
c0 String

set component #0 expression (default "clipval")

Default('clipval')
c1 String

set component #1 expression (default "clipval")

Default('clipval')
c2 String

set component #2 expression (default "clipval")

Default('clipval')
c3 String

set component #3 expression (default "clipval")

Default('clipval')
y String

set Y expression (default "clipval")

Default('clipval')
u String

set U expression (default "clipval")

Default('clipval')
v String

set V expression (default "clipval")

Default('clipval')
r String

set R expression (default "clipval")

Default('clipval')
g String

set G expression (default "clipval")

Default('clipval')
b String

set B expression (default "clipval")

Default('clipval')
a String

set A expression (default "clipval")

Default('clipval')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

lutyuv

lutyuv(
    *,
    c0: String = Default("clipval"),
    c1: String = Default("clipval"),
    c2: String = Default("clipval"),
    c3: String = Default("clipval"),
    y: String = Default("clipval"),
    u: String = Default("clipval"),
    v: String = Default("clipval"),
    r: String = Default("clipval"),
    g: String = Default("clipval"),
    b: String = Default("clipval"),
    a: String = Default("clipval"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Compute and apply a lookup table to the YUV input video.

Parameters:

Name Type Description Default
c0 String

set component #0 expression (default "clipval")

Default('clipval')
c1 String

set component #1 expression (default "clipval")

Default('clipval')
c2 String

set component #2 expression (default "clipval")

Default('clipval')
c3 String

set component #3 expression (default "clipval")

Default('clipval')
y String

set Y expression (default "clipval")

Default('clipval')
u String

set U expression (default "clipval")

Default('clipval')
v String

set V expression (default "clipval")

Default('clipval')
r String

set R expression (default "clipval")

Default('clipval')
g String

set G expression (default "clipval")

Default('clipval')
b String

set B expression (default "clipval")

Default('clipval')
a String

set A expression (default "clipval")

Default('clipval')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

maskedclamp

maskedclamp(
    _dark: VideoStream,
    _bright: VideoStream,
    *,
    undershoot: Int = Default(0),
    overshoot: Int = Default(0),
    planes: Int = Default(15),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Clamp first stream with second stream and third stream.

Parameters:

Name Type Description Default
undershoot Int

set undershoot (from 0 to 65535) (default 0)

Default(0)
overshoot Int

set overshoot (from 0 to 65535) (default 0)

Default(0)
planes Int

set planes (from 0 to 15) (default 15)

Default(15)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

maskedmax

maskedmax(
    _filter1: VideoStream,
    _filter2: VideoStream,
    *,
    planes: Int = Default(15),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply filtering with maximum difference of two streams.

Parameters:

Name Type Description Default
planes Int

set planes (from 0 to 15) (default 15)

Default(15)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

maskedmerge

maskedmerge(
    _overlay: VideoStream,
    _mask: VideoStream,
    *,
    planes: Int = Default(15),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Merge first stream with second stream using third stream as mask.

Parameters:

Name Type Description Default
planes Int

set planes (from 0 to 15) (default 15)

Default(15)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

maskedmin

maskedmin(
    _filter1: VideoStream,
    _filter2: VideoStream,
    *,
    planes: Int = Default(15),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply filtering with minimum difference of two streams.

Parameters:

Name Type Description Default
planes Int

set planes (from 0 to 15) (default 15)

Default(15)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

maskedthreshold

maskedthreshold(
    _reference: VideoStream,
    *,
    threshold: Int = Default(1),
    planes: Int = Default(15),
    mode: Int | Literal["abs", "diff"] | Default = Default(
        "abs"
    ),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Pick pixels comparing absolute difference of two streams with threshold.

Parameters:

Name Type Description Default
threshold Int

set threshold (from 0 to 65535) (default 1)

Default(1)
planes Int

set planes (from 0 to 15) (default 15)

Default(15)
mode Int | Literal['abs', 'diff'] | Default

set mode (from 0 to 1) (default abs)

Default('abs')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

maskfun

maskfun(
    *,
    low: Int = Default(10),
    high: Int = Default(10),
    planes: Int = Default(15),
    fill: Int = Default(0),
    sum: Int = Default(10),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Create Mask.

Parameters:

Name Type Description Default
low Int

set low threshold (from 0 to 65535) (default 10)

Default(10)
high Int

set high threshold (from 0 to 65535) (default 10)

Default(10)
planes Int

set planes (from 0 to 15) (default 15)

Default(15)
fill Int

set fill value (from 0 to 65535) (default 0)

Default(0)
sum Int

set sum value (from 0 to 65535) (default 10)

Default(10)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

median

median(
    *,
    radius: Int = Default(1),
    planes: Int = Default(15),
    radiusV: Int = Default(0),
    percentile: Float = Default(0.5),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply Median filter.

Parameters:

Name Type Description Default
radius Int

set median radius (from 1 to 127) (default 1)

Default(1)
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
radiusV Int

set median vertical radius (from 0 to 127) (default 0)

Default(0)
percentile Float

set median percentile (from 0 to 1) (default 0.5)

Default(0.5)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

mestimate

mestimate(
    *,
    method: (
        Int
        | Literal[
            "esa",
            "tss",
            "tdls",
            "ntss",
            "fss",
            "ds",
            "hexbs",
            "epzs",
            "umh",
        ]
        | Default
    ) = Default("esa"),
    mb_size: Int = Default(16),
    search_param: Int = Default(7),
    **kwargs: Any
) -> VideoStream

Generate motion vectors.

Parameters:

Name Type Description Default
method Int | Literal['esa', 'tss', 'tdls', 'ntss', 'fss', 'ds', 'hexbs', 'epzs', 'umh'] | Default

motion estimation method (from 1 to 9) (default esa)

Default('esa')
mb_size Int

macroblock size (from 8 to INT_MAX) (default 16)

Default(16)
search_param Int

search parameter (from 4 to INT_MAX) (default 7)

Default(7)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

metadata

metadata(
    *,
    mode: (
        Int
        | Literal[
            "select", "add", "modify", "delete", "print"
        ]
        | Default
    ) = Default("select"),
    key: String = Default(None),
    value: String = Default(None),
    function: (
        Int
        | Literal[
            "same_str",
            "starts_with",
            "less",
            "equal",
            "greater",
            "expr",
            "ends_with",
        ]
        | Default
    ) = Default("same_str"),
    expr: String = Default(None),
    file: String = Default(None),
    direct: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Manipulate video frame metadata.

Parameters:

Name Type Description Default
mode Int | Literal['select', 'add', 'modify', 'delete', 'print'] | Default

set a mode of operation (from 0 to 4) (default select)

Default('select')
key String

set metadata key

Default(None)
value String

set metadata value

Default(None)
function Int | Literal['same_str', 'starts_with', 'less', 'equal', 'greater', 'expr', 'ends_with'] | Default

function for comparing values (from 0 to 6) (default same_str)

Default('same_str')
expr String

set expression for expr function

Default(None)
file String

set file where to print metadata information

Default(None)
direct Boolean

reduce buffering when printing to user-set file or pipe (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

midequalizer

midequalizer(
    _in1: VideoStream,
    *,
    planes: Int = Default(15),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply Midway Equalization.

Parameters:

Name Type Description Default
planes Int

set planes (from 0 to 15) (default 15)

Default(15)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

minterpolate

minterpolate(
    *,
    fps: Video_rate = Default("60"),
    mi_mode: (
        Int | Literal["dup", "blend", "mci"] | Default
    ) = Default("mci"),
    mc_mode: (
        Int | Literal["obmc", "aobmc"] | Default
    ) = Default("obmc"),
    me_mode: (
        Int | Literal["bidir", "bilat"] | Default
    ) = Default("bilat"),
    me: (
        Int
        | Literal[
            "esa",
            "tss",
            "tdls",
            "ntss",
            "fss",
            "ds",
            "hexbs",
            "epzs",
            "umh",
        ]
        | Default
    ) = Default("epzs"),
    mb_size: Int = Default(16),
    search_param: Int = Default(32),
    vsbmc: Int = Default(0),
    scd: Int | Literal["none", "fdiff"] | Default = Default(
        "fdiff"
    ),
    scd_threshold: Double = Default(10.0),
    **kwargs: Any
) -> VideoStream

Frame rate conversion using Motion Interpolation.

Parameters:

Name Type Description Default
fps Video_rate

output's frame rate (default "60")

Default('60')
mi_mode Int | Literal['dup', 'blend', 'mci'] | Default

motion interpolation mode (from 0 to 2) (default mci)

Default('mci')
mc_mode Int | Literal['obmc', 'aobmc'] | Default

motion compensation mode (from 0 to 1) (default obmc)

Default('obmc')
me_mode Int | Literal['bidir', 'bilat'] | Default

motion estimation mode (from 0 to 1) (default bilat)

Default('bilat')
me Int | Literal['esa', 'tss', 'tdls', 'ntss', 'fss', 'ds', 'hexbs', 'epzs', 'umh'] | Default

motion estimation method (from 1 to 9) (default epzs)

Default('epzs')
mb_size Int

macroblock size (from 4 to 16) (default 16)

Default(16)
search_param Int

search parameter (from 4 to INT_MAX) (default 32)

Default(32)
vsbmc Int

variable-size block motion compensation (from 0 to 1) (default 0)

Default(0)
scd Int | Literal['none', 'fdiff'] | Default

scene change detection method (from 0 to 1) (default fdiff)

Default('fdiff')
scd_threshold Double

scene change threshold (from 0 to 100) (default 10)

Default(10.0)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

monochrome

monochrome(
    *,
    cb: Float = Default(0.0),
    cr: Float = Default(0.0),
    size: Float = Default(1.0),
    high: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Convert video to gray using custom color filter.

Parameters:

Name Type Description Default
cb Float

set the chroma blue spot (from -1 to 1) (default 0)

Default(0.0)
cr Float

set the chroma red spot (from -1 to 1) (default 0)

Default(0.0)
size Float

set the color filter size (from 0.1 to 10) (default 1)

Default(1.0)
high Float

set the highlights strength (from 0 to 1) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

morpho

morpho(
    _structure: VideoStream,
    *,
    mode: (
        Int
        | Literal[
            "erode",
            "dilate",
            "open",
            "close",
            "gradient",
            "tophat",
            "blackhat",
        ]
        | Default
    ) = Default("erode"),
    planes: Int = Default(7),
    structure: (
        Int | Literal["first", "all"] | Default
    ) = Default("all"),
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply Morphological filter.

Parameters:

Name Type Description Default
mode Int | Literal['erode', 'dilate', 'open', 'close', 'gradient', 'tophat', 'blackhat'] | Default

set morphological transform (from 0 to 6) (default erode)

Default('erode')
planes Int

set planes to filter (from 0 to 15) (default 7)

Default(7)
structure Int | Literal['first', 'all'] | Default

when to process structures (from 0 to 1) (default all)

Default('all')
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

mpdecimate

mpdecimate(
    *,
    max: Int = Default(0),
    hi: Int = Default(768),
    lo: Int = Default(320),
    frac: Float = Default(0.33),
    **kwargs: Any
) -> VideoStream

Remove near-duplicate frames.

Parameters:

Name Type Description Default
max Int

set the maximum number of consecutive dropped frames (positive), or the minimum interval between dropped frames (negative) (from INT_MIN to INT_MAX) (default 0)

Default(0)
hi Int

set high dropping threshold (from INT_MIN to INT_MAX) (default 768)

Default(768)
lo Int

set low dropping threshold (from INT_MIN to INT_MAX) (default 320)

Default(320)
frac Float

set fraction dropping threshold (from 0 to 1) (default 0.33)

Default(0.33)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

msad

msad(
    _reference: VideoStream,
    *,
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Calculate the MSAD between two video streams.

Parameters:

Name Type Description Default
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

multiply

multiply(
    _factor: VideoStream,
    *,
    scale: Float = Default(1.0),
    offset: Float = Default(0.5),
    planes: Flags = Default("F"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Multiply first video stream with second video stream.

Parameters:

Name Type Description Default
scale Float

set scale (from 0 to 9) (default 1)

Default(1.0)
offset Float

set offset (from -1 to 1) (default 0.5)

Default(0.5)
planes Flags

set planes (default F)

Default('F')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

negate

negate(
    *,
    components: (
        Flags
        | Literal["y", "u", "v", "r", "g", "b", "a"]
        | Default
    ) = Default("y+u+v+r+g+b"),
    negate_alpha: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Negate input video.

Parameters:

Name Type Description Default
components Flags | Literal['y', 'u', 'v', 'r', 'g', 'b', 'a'] | Default

set components to negate (default y+u+v+r+g+b)

Default('y+u+v+r+g+b')
negate_alpha Boolean

(default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

nlmeans

nlmeans(
    *,
    s: Double = Default(1.0),
    p: Int = Default(7),
    pc: Int = Default(0),
    r: Int = Default(15),
    rc: Int = Default(0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Non-local means denoiser.

Parameters:

Name Type Description Default
s Double

denoising strength (from 1 to 30) (default 1)

Default(1.0)
p Int

patch size (from 0 to 99) (default 7)

Default(7)
pc Int

patch size for chroma planes (from 0 to 99) (default 0)

Default(0)
r Int

research window (from 0 to 99) (default 15)

Default(15)
rc Int

research window for chroma planes (from 0 to 99) (default 0)

Default(0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

nnedi

nnedi(
    *,
    weights: String = Default("nnedi3_weights.bin"),
    deint: (
        Int | Literal["all", "interlaced"] | Default
    ) = Default("all"),
    field: (
        Int
        | Literal["af", "a", "t", "b", "tf", "bf"]
        | Default
    ) = Default("a"),
    planes: Int = Default(7),
    nsize: (
        Int
        | Literal[
            "s8x6",
            "s16x6",
            "s32x6",
            "s48x6",
            "s8x4",
            "s16x4",
            "s32x4",
        ]
        | Default
    ) = Default("s32x4"),
    nns: (
        Int
        | Literal["n16", "n32", "n64", "n128", "n256"]
        | Default
    ) = Default("n32"),
    qual: Int | Literal["fast", "slow"] | Default = Default(
        "fast"
    ),
    etype: (
        Int | Literal["a", "abs", "s", "mse"] | Default
    ) = Default("a"),
    pscrn: (
        Int
        | Literal["none", "original", "new", "new2", "new3"]
        | Default
    ) = Default("new"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply neural network edge directed interpolation intra-only deinterlacer.

Parameters:

Name Type Description Default
weights String

set weights file (default "nnedi3_weights.bin")

Default('nnedi3_weights.bin')
deint Int | Literal['all', 'interlaced'] | Default

set which frames to deinterlace (from 0 to 1) (default all)

Default('all')
field Int | Literal['af', 'a', 't', 'b', 'tf', 'bf'] | Default

set mode of operation (from -2 to 3) (default a)

Default('a')
planes Int

set which planes to process (from 0 to 15) (default 7)

Default(7)
nsize Int | Literal['s8x6', 's16x6', 's32x6', 's48x6', 's8x4', 's16x4', 's32x4'] | Default

set size of local neighborhood around each pixel, used by the predictor neural network (from 0 to 6) (default s32x4)

Default('s32x4')
nns Int | Literal['n16', 'n32', 'n64', 'n128', 'n256'] | Default

set number of neurons in predictor neural network (from 0 to 4) (default n32)

Default('n32')
qual Int | Literal['fast', 'slow'] | Default

set quality (from 1 to 2) (default fast)

Default('fast')
etype Int | Literal['a', 'abs', 's', 'mse'] | Default

set which set of weights to use in the predictor (from 0 to 1) (default a)

Default('a')
pscrn Int | Literal['none', 'original', 'new', 'new2', 'new3'] | Default

set prescreening (from 0 to 4) (default new)

Default('new')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

noformat

noformat(
    *, pix_fmts: String = Default(None), **kwargs: Any
) -> VideoStream

Force libavfilter not to use any of the specified pixel formats for the input to the next filter.

Parameters:

Name Type Description Default
pix_fmts String

A '|'-separated list of pixel formats

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

noise

noise(
    *,
    all_seed: Int = Default(-1),
    all_strength: Int = Default(0),
    all_flags: (
        Flags | Literal["a", "p", "t", "u"] | Default
    ) = Default("0"),
    c0_seed: Int = Default(-1),
    c0_strength: Int = Default(0),
    c0_flags: (
        Flags | Literal["a", "p", "t", "u"] | Default
    ) = Default("0"),
    c1_seed: Int = Default(-1),
    c1_strength: Int = Default(0),
    c1_flags: (
        Flags | Literal["a", "p", "t", "u"] | Default
    ) = Default("0"),
    c2_seed: Int = Default(-1),
    c2_strength: Int = Default(0),
    c2_flags: (
        Flags | Literal["a", "p", "t", "u"] | Default
    ) = Default("0"),
    c3_seed: Int = Default(-1),
    c3_strength: Int = Default(0),
    c3_flags: (
        Flags | Literal["a", "p", "t", "u"] | Default
    ) = Default("0"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Add noise.

Parameters:

Name Type Description Default
all_seed Int

set component #0 noise seed (from -1 to INT_MAX) (default -1)

Default(-1)
all_strength Int

set component #0 strength (from 0 to 100) (default 0)

Default(0)
all_flags Flags | Literal['a', 'p', 't', 'u'] | Default

set component #0 flags (default 0)

Default('0')
c0_seed Int

set component #0 noise seed (from -1 to INT_MAX) (default -1)

Default(-1)
c0_strength Int

set component #0 strength (from 0 to 100) (default 0)

Default(0)
c0_flags Flags | Literal['a', 'p', 't', 'u'] | Default

set component #0 flags (default 0)

Default('0')
c1_seed Int

set component #1 noise seed (from -1 to INT_MAX) (default -1)

Default(-1)
c1_strength Int

set component #1 strength (from 0 to 100) (default 0)

Default(0)
c1_flags Flags | Literal['a', 'p', 't', 'u'] | Default

set component #1 flags (default 0)

Default('0')
c2_seed Int

set component #2 noise seed (from -1 to INT_MAX) (default -1)

Default(-1)
c2_strength Int

set component #2 strength (from 0 to 100) (default 0)

Default(0)
c2_flags Flags | Literal['a', 'p', 't', 'u'] | Default

set component #2 flags (default 0)

Default('0')
c3_seed Int

set component #3 noise seed (from -1 to INT_MAX) (default -1)

Default(-1)
c3_strength Int

set component #3 strength (from 0 to 100) (default 0)

Default(0)
c3_flags Flags | Literal['a', 'p', 't', 'u'] | Default

set component #3 flags (default 0)

Default('0')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

normalize

normalize(
    *,
    blackpt: Color = Default("black"),
    whitept: Color = Default("white"),
    smoothing: Int = Default(0),
    independence: Float = Default(1.0),
    strength: Float = Default(1.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Normalize RGB video.

Parameters:

Name Type Description Default
blackpt Color

output color to which darkest input color is mapped (default "black")

Default('black')
whitept Color

output color to which brightest input color is mapped (default "white")

Default('white')
smoothing Int

amount of temporal smoothing of the input range, to reduce flicker (from 0 to 2.68435e+08) (default 0)

Default(0)
independence Float

proportion of independent to linked channel normalization (from 0 to 1) (default 1)

Default(1.0)
strength Float

strength of filter, from no effect to full normalization (from 0 to 1) (default 1)

Default(1.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

null

null(**kwargs: Any) -> VideoStream

Pass the source unchanged to the output.

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

oscilloscope

oscilloscope(
    *,
    x: Float = Default(0.5),
    y: Float = Default(0.5),
    s: Float = Default(0.8),
    t: Float = Default(0.5),
    o: Float = Default(0.8),
    tx: Float = Default(0.5),
    ty: Float = Default(0.9),
    tw: Float = Default(0.8),
    th: Float = Default(0.3),
    c: Int = Default(7),
    g: Boolean = Default(True),
    st: Boolean = Default(True),
    sc: Boolean = Default(True),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

2D Video Oscilloscope.

Parameters:

Name Type Description Default
x Float

set scope x position (from 0 to 1) (default 0.5)

Default(0.5)
y Float

set scope y position (from 0 to 1) (default 0.5)

Default(0.5)
s Float

set scope size (from 0 to 1) (default 0.8)

Default(0.8)
t Float

set scope tilt (from 0 to 1) (default 0.5)

Default(0.5)
o Float

set trace opacity (from 0 to 1) (default 0.8)

Default(0.8)
tx Float

set trace x position (from 0 to 1) (default 0.5)

Default(0.5)
ty Float

set trace y position (from 0 to 1) (default 0.9)

Default(0.9)
tw Float

set trace width (from 0.1 to 1) (default 0.8)

Default(0.8)
th Float

set trace height (from 0.1 to 1) (default 0.3)

Default(0.3)
c Int

set components to trace (from 0 to 15) (default 7)

Default(7)
g Boolean

draw trace grid (default true)

Default(True)
st Boolean

draw statistics (default true)

Default(True)
sc Boolean

draw scope (default true)

Default(True)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

output

output(
    *streams: "FilterableStream",
    filename: str | Path,
    f: String = None,
    c: String = None,
    codec: String = None,
    pre: String = None,
    map: Func = None,
    map_metadata: String = None,
    map_chapters: Int = None,
    t: Time = None,
    to: Time = None,
    fs: Int64 = None,
    ss: Time = None,
    timestamp: Func = None,
    metadata: String = None,
    program: String = None,
    stream_group: String = None,
    dframes: Int64 = None,
    target: Func = None,
    shortest: Boolean = None,
    shortest_buf_duration: Float = None,
    bitexact: Boolean = None,
    apad: String = None,
    copyinkf: Boolean = None,
    copypriorss: Int = None,
    frames: Int64 = None,
    tag: String = None,
    q: Func = None,
    qscale: Func = None,
    profile: Func = None,
    filter: String = None,
    filter_script: String = None,
    attach: Func = None,
    disposition: String = None,
    thread_queue_size: Int = None,
    bits_per_raw_sample: Int = None,
    stats_enc_pre: String = None,
    stats_enc_post: String = None,
    stats_mux_pre: String = None,
    stats_enc_pre_fmt: String = None,
    stats_enc_post_fmt: String = None,
    stats_mux_pre_fmt: String = None,
    vframes: Int64 = None,
    r: String = None,
    fpsmax: String = None,
    s: String = None,
    aspect: String = None,
    pix_fmt: String = None,
    vn: Boolean = None,
    rc_override: String = None,
    vcodec: String = None,
    timecode: Func = None,
    _pass: Int = None,
    passlogfile: String = None,
    vf: String = None,
    intra_matrix: String = None,
    inter_matrix: String = None,
    chroma_intra_matrix: String = None,
    vtag: String = None,
    fps_mode: String = None,
    force_fps: Boolean = None,
    streamid: Func = None,
    force_key_frames: String = None,
    b: Func = None,
    autoscale: Boolean = None,
    fix_sub_duration_heartbeat: Boolean = None,
    aframes: Int64 = None,
    aq: Func = None,
    ar: Int = None,
    ac: Int = None,
    an: Boolean = None,
    acodec: String = None,
    ab: Func = None,
    atag: String = None,
    sample_fmt: String = None,
    channel_layout: String = None,
    ch_layout: String = None,
    af: String = None,
    sn: Boolean = None,
    scodec: String = None,
    stag: String = None,
    muxdelay: Float = None,
    muxpreload: Float = None,
    sdp_file: Func = None,
    time_base: String = None,
    enc_time_base: String = None,
    bsf: String = None,
    apre: String = None,
    vpre: String = None,
    spre: String = None,
    fpre: String = None,
    max_muxing_queue_size: Int = None,
    muxing_queue_data_threshold: Int = None,
    dcodec: String = None,
    dn: Boolean = None,
    top: Int = None,
    **kwargs: Any
) -> OutputStream

Output file URL

Parameters:

Name Type Description Default
*streams 'FilterableStream'

the streams to output

()
filename str | Path

the filename to output to

required
f String

force container format (auto-detected otherwise)

None
c String

select encoder/decoder ('copy' to copy stream without reencoding)

None
codec String

alias for -c (select encoder/decoder)

None
pre String

preset name

None
map Func

set input stream mapping

None
map_metadata String

set metadata information of outfile from infile

None
map_chapters Int

set chapters mapping

None
t Time

stop transcoding after specified duration

None
to Time

stop transcoding after specified time is reached

None
fs Int64

set the limit file size in bytes

None
ss Time

start transcoding at specified time

None
timestamp Func

set the recording timestamp ('now' to set the current time)

None
metadata String

add metadata

None
program String

add program with specified streams

None
stream_group String

add stream group with specified streams and group type-specific arguments

None
dframes Int64

set the number of data frames to output

None
target Func

specify target file type ("vcd", "svcd", "dvd", "dv" or "dv50 "with optional prefixes "pal-", "ntsc-" or "film-")

None
shortest Boolean

finish encoding within shortest input

None
shortest_buf_duration Float

maximum buffering duration (in seconds) for the -shortest option

None
bitexact Boolean

bitexact mode

None
apad String

audio pad

None
copyinkf Boolean

copy initial non-keyframes

None
copypriorss Int

copy or discard frames before start time

None
frames Int64

set the number of frames to output

None
tag String

force codec tag/fourcc

None
q Func

use fixed quality scale (VBR)

None
qscale Func

use fixed quality scale (VBR)

None
profile Func

set profile

None
filter String

apply specified filters to audio/video

None
filter_script String

deprecated, use -/filter

None
attach Func

add an attachment to the output file

None
disposition String

disposition

None
thread_queue_size Int

set the maximum number of queued packets from the demuxer

None
bits_per_raw_sample Int

set the number of bits per raw sample

None
stats_enc_pre String

write encoding stats before encoding

None
stats_enc_post String

write encoding stats after encoding

None
stats_mux_pre String

write packets stats before muxing

None
stats_enc_pre_fmt String

format of the stats written with -stats_enc_pre

None
stats_enc_post_fmt String

format of the stats written with -stats_enc_post

None
stats_mux_pre_fmt String

format of the stats written with -stats_mux_pre

None
vframes Int64

set the number of video frames to output

None
r String

override input framerate/convert to given output framerate (Hz value, fraction or abbreviation)

None
fpsmax String

set max frame rate (Hz value, fraction or abbreviation)

None
s String

set frame size (WxH or abbreviation)

None
aspect String

set aspect ratio (4:3, 16:9 or 1.3333, 1.7777)

None
pix_fmt String

set pixel format

None
vn Boolean

disable video

None
rc_override String

rate control override for specific intervals

None
vcodec String

alias for -c:v (select encoder/decoder for video streams)

None
timecode Func

set initial TimeCode value.

None
_pass Int

select the pass number (1 to 3)

None
passlogfile String

select two pass log file name prefix

None
vf String

alias for -filter:v (apply filters to video streams)

None
intra_matrix String

specify intra matrix coeffs

None
inter_matrix String

specify inter matrix coeffs

None
chroma_intra_matrix String

specify intra matrix coeffs

None
vtag String

force video tag/fourcc

None
fps_mode String

set framerate mode for matching video streams; overrides vsync

None
force_fps Boolean

force the selected framerate, disable the best supported framerate selection

None
streamid Func

set the value of an outfile streamid

None
force_key_frames String

force key frames at specified timestamps

None
b Func

video bitrate (please use -b:v)

None
autoscale Boolean

automatically insert a scale filter at the end of the filter graph

None
fix_sub_duration_heartbeat Boolean

set this video output stream to be a heartbeat stream for fix_sub_duration, according to which subtitles should be split at random access points

None
aframes Int64

set the number of audio frames to output

None
aq Func

set audio quality (codec-specific)

None
ar Int

set audio sampling rate (in Hz)

None
ac Int

set number of audio channels

None
an Boolean

disable audio

None
acodec String

alias for -c:a (select encoder/decoder for audio streams)

None
ab Func

alias for -b:a (select bitrate for audio streams)

None
atag String

force audio tag/fourcc

None
sample_fmt String

set sample format

None
channel_layout String

set channel layout

None
ch_layout String

set channel layout

None
af String

alias for -filter:a (apply filters to audio streams)

None
sn Boolean

disable subtitle

None
scodec String

alias for -c:s (select encoder/decoder for subtitle streams)

None
stag String

force subtitle tag/fourcc

None
muxdelay Float

set the maximum demux-decode delay

None
muxpreload Float

set the initial demux-decode delay

None
sdp_file Func

specify a file in which to print sdp information

None
time_base String

set the desired time base hint for output stream (1:24, 1:48000 or 0.04166, 2.0833e-5)

None
enc_time_base String

set the desired time base for the encoder (1:24, 1:48000 or 0.04166, 2.0833e-5). two special values are defined - 0 = use frame rate (video) or sample rate (audio),-1 = match source time base

None
bsf String

A comma-separated list of bitstream filters

None
apre String

set the audio options to the indicated preset

None
vpre String

set the video options to the indicated preset

None
spre String

set the subtitle options to the indicated preset

None
fpre String

set options from indicated preset file

None
max_muxing_queue_size Int

maximum number of packets that can be buffered while waiting for all streams to initialize

None
muxing_queue_data_threshold Int

set the threshold after which max_muxing_queue_size is taken into account

None
dcodec String

alias for -c:d (select encoder/decoder for data streams)

None
dn Boolean

disable data

None
top Int

deprecated, use the setfield video filter

None
**kwargs Any

the arguments for the output

{}

Returns:

Type Description
OutputStream

the output stream

overlay

overlay(
    _overlay: VideoStream,
    *,
    x: String = Default("0"),
    y: String = Default("0"),
    eof_action: (
        Int
        | Literal[
            "repeat",
            "endall",
            "pass",
            "repeat",
            "endall",
            "pass",
        ]
        | Default
    ) = Default("repeat"),
    eval: (
        Int | Literal["init", "frame"] | Default
    ) = Default("frame"),
    shortest: Boolean = Default(False),
    format: (
        Int
        | Literal[
            "yuv420",
            "yuv420p10",
            "yuv422",
            "yuv422p10",
            "yuv444",
            "rgb",
            "gbrp",
            "auto",
        ]
        | Default
    ) = Default("yuv420"),
    repeatlast: Boolean = Default(True),
    alpha: (
        Int | Literal["straight", "premultiplied"] | Default
    ) = Default("straight"),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Overlay a video source on top of the input.

Parameters:

Name Type Description Default
x String

set the x expression (default "0")

Default('0')
y String

set the y expression (default "0")

Default('0')
eof_action Int | Literal['repeat', 'endall', 'pass', 'repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
eval Int | Literal['init', 'frame'] | Default

specify when to evaluate expressions (from 0 to 1) (default frame)

Default('frame')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
format Int | Literal['yuv420', 'yuv420p10', 'yuv422', 'yuv422p10', 'yuv444', 'rgb', 'gbrp', 'auto'] | Default

set output format (from 0 to 7) (default yuv420)

Default('yuv420')
repeatlast Boolean

repeat overlay of the last overlay frame (default true)

Default(True)
alpha Int | Literal['straight', 'premultiplied'] | Default

alpha format (from 0 to 1) (default straight)

Default('straight')
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

owdenoise

owdenoise(
    *,
    depth: Int = Default(8),
    luma_strength: Double = Default(1.0),
    chroma_strength: Double = Default(1.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Denoise using wavelets.

Parameters:

Name Type Description Default
depth Int

set depth (from 8 to 16) (default 8)

Default(8)
luma_strength Double

set luma strength (from 0 to 1000) (default 1)

Default(1.0)
chroma_strength Double

set chroma strength (from 0 to 1000) (default 1)

Default(1.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

pad

pad(
    *,
    width: String = Default("iw"),
    height: String = Default("ih"),
    x: String = Default("0"),
    y: String = Default("0"),
    color: Color = Default("black"),
    eval: (
        Int | Literal["init", "frame"] | Default
    ) = Default("init"),
    aspect: Rational = Default("0/1"),
    **kwargs: Any
) -> VideoStream

Pad the input video.

Parameters:

Name Type Description Default
width String

set the pad area width expression (default "iw")

Default('iw')
height String

set the pad area height expression (default "ih")

Default('ih')
x String

set the x offset expression for the input image position (default "0")

Default('0')
y String

set the y offset expression for the input image position (default "0")

Default('0')
color Color

set the color of the padded area border (default "black")

Default('black')
eval Int | Literal['init', 'frame'] | Default

specify when to evaluate expressions (from 0 to 1) (default init)

Default('init')
aspect Rational

pad to fit an aspect instead of a resolution (from 0 to DBL_MAX) (default 0/1)

Default('0/1')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

palettegen

palettegen(
    *,
    max_colors: Int = Default(256),
    reserve_transparent: Boolean = Default(True),
    transparency_color: Color = Default("lime"),
    stats_mode: (
        Int | Literal["full", "diff", "single"] | Default
    ) = Default("full"),
    **kwargs: Any
) -> VideoStream

Find the optimal palette for a given stream.

Parameters:

Name Type Description Default
max_colors Int

set the maximum number of colors to use in the palette (from 2 to 256) (default 256)

Default(256)
reserve_transparent Boolean

reserve a palette entry for transparency (default true)

Default(True)
transparency_color Color

set a background color for transparency (default "lime")

Default('lime')
stats_mode Int | Literal['full', 'diff', 'single'] | Default

set statistics mode (from 0 to 2) (default full)

Default('full')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

paletteuse

paletteuse(
    _palette: VideoStream,
    *,
    dither: (
        Int
        | Literal[
            "bayer",
            "heckbert",
            "floyd_steinberg",
            "sierra2",
            "sierra2_4a",
            "sierra3",
            "burkes",
            "atkinson",
        ]
        | Default
    ) = Default("sierra2_4a"),
    bayer_scale: Int = Default(2),
    diff_mode: (
        Int | Literal["rectangle"] | Default
    ) = Default(0),
    new: Boolean = Default(False),
    alpha_threshold: Int = Default(128),
    debug_kdtree: String = Default(None),
    **kwargs: Any
) -> VideoStream

Use a palette to downsample an input video stream.

Parameters:

Name Type Description Default
dither Int | Literal['bayer', 'heckbert', 'floyd_steinberg', 'sierra2', 'sierra2_4a', 'sierra3', 'burkes', 'atkinson'] | Default

select dithering mode (from 0 to 8) (default sierra2_4a)

Default('sierra2_4a')
bayer_scale Int

set scale for bayer dithering (from 0 to 5) (default 2)

Default(2)
diff_mode Int | Literal['rectangle'] | Default

set frame difference mode (from 0 to 1) (default 0)

Default(0)
new Boolean

take new palette for each output frame (default false)

Default(False)
alpha_threshold Int

set the alpha threshold for transparency (from 0 to 255) (default 128)

Default(128)
debug_kdtree String

save Graphviz graph of the kdtree in specified file

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

perms

perms(
    *,
    mode: (
        Int
        | Literal["none", "ro", "rw", "toggle", "random"]
        | Default
    ) = Default("none"),
    seed: Int64 = Default(-1),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Set permissions for the output video frame.

Parameters:

Name Type Description Default
mode Int | Literal['none', 'ro', 'rw', 'toggle', 'random'] | Default

select permissions mode (from 0 to 4) (default none)

Default('none')
seed Int64

set the seed for the random mode (from -1 to UINT32_MAX) (default -1)

Default(-1)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

perspective

perspective(
    *,
    x0: String = Default("0"),
    y0: String = Default("0"),
    x1: String = Default("W"),
    y1: String = Default("0"),
    x2: String = Default("0"),
    y2: String = Default("H"),
    x3: String = Default("W"),
    y3: String = Default("H"),
    interpolation: (
        Int | Literal["linear", "cubic"] | Default
    ) = Default("linear"),
    sense: (
        Int | Literal["source", "destination"] | Default
    ) = Default("source"),
    eval: (
        Int | Literal["init", "frame"] | Default
    ) = Default("init"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Correct the perspective of video.

Parameters:

Name Type Description Default
x0 String

set top left x coordinate (default "0")

Default('0')
y0 String

set top left y coordinate (default "0")

Default('0')
x1 String

set top right x coordinate (default "W")

Default('W')
y1 String

set top right y coordinate (default "0")

Default('0')
x2 String

set bottom left x coordinate (default "0")

Default('0')
y2 String

set bottom left y coordinate (default "H")

Default('H')
x3 String

set bottom right x coordinate (default "W")

Default('W')
y3 String

set bottom right y coordinate (default "H")

Default('H')
interpolation Int | Literal['linear', 'cubic'] | Default

set interpolation (from 0 to 1) (default linear)

Default('linear')
sense Int | Literal['source', 'destination'] | Default

specify the sense of the coordinates (from 0 to 1) (default source)

Default('source')
eval Int | Literal['init', 'frame'] | Default

specify when to evaluate expressions (from 0 to 1) (default init)

Default('init')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

phase

phase(
    *,
    mode: (
        Int
        | Literal[
            "p", "t", "b", "T", "B", "u", "U", "a", "A"
        ]
        | Default
    ) = Default("A"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Phase shift fields.

Parameters:

Name Type Description Default
mode Int | Literal['p', 't', 'b', 'T', 'B', 'u', 'U', 'a', 'A'] | Default

set phase mode (from 0 to 8) (default A)

Default('A')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

photosensitivity

photosensitivity(
    *,
    frames: Int = Default(30),
    threshold: Float = Default(1.0),
    skip: Int = Default(1),
    bypass: Boolean = Default(False),
    **kwargs: Any
) -> VideoStream

Filter out photosensitive epilepsy seizure-inducing flashes.

Parameters:

Name Type Description Default
frames Int

set how many frames to use (from 2 to 240) (default 30)

Default(30)
threshold Float

set detection threshold factor (lower is stricter) (from 0.1 to FLT_MAX) (default 1)

Default(1.0)
skip Int

set pixels to skip when sampling frames (from 1 to 1024) (default 1)

Default(1)
bypass Boolean

leave frames unchanged (default false)

Default(False)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

pixdesctest

pixdesctest(**kwargs: Any) -> VideoStream

Test pixel format definitions.

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

pixelize

pixelize(
    *,
    width: Int = Default(16),
    height: Int = Default(16),
    mode: (
        Int | Literal["avg", "min", "max"] | Default
    ) = Default("avg"),
    planes: Flags = Default("F"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Pixelize video.

Parameters:

Name Type Description Default
width Int

set block width (from 1 to 1024) (default 16)

Default(16)
height Int

set block height (from 1 to 1024) (default 16)

Default(16)
mode Int | Literal['avg', 'min', 'max'] | Default

set the pixelize mode (from 0 to 2) (default avg)

Default('avg')
planes Flags

set what planes to filter (default F)

Default('F')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

pixscope

pixscope(
    *,
    x: Float = Default(0.5),
    y: Float = Default(0.5),
    w: Int = Default(7),
    h: Int = Default(7),
    o: Float = Default(0.5),
    wx: Float = Default(-1.0),
    wy: Float = Default(-1.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Pixel data analysis.

Parameters:

Name Type Description Default
x Float

set scope x offset (from 0 to 1) (default 0.5)

Default(0.5)
y Float

set scope y offset (from 0 to 1) (default 0.5)

Default(0.5)
w Int

set scope width (from 1 to 80) (default 7)

Default(7)
h Int

set scope height (from 1 to 80) (default 7)

Default(7)
o Float

set window opacity (from 0 to 1) (default 0.5)

Default(0.5)
wx Float

set window x offset (from -1 to 1) (default -1)

Default(-1.0)
wy Float

set window y offset (from -1 to 1) (default -1)

Default(-1.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

pp

pp(
    *,
    subfilters: String = Default("de"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Filter video using libpostproc.

Parameters:

Name Type Description Default
subfilters String

set postprocess subfilters (default "de")

Default('de')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

pp7

pp7(
    *,
    qp: Int = Default(0),
    mode: (
        Int | Literal["hard", "soft", "medium"] | Default
    ) = Default("medium"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply Postprocessing 7 filter.

Parameters:

Name Type Description Default
qp Int

force a constant quantizer parameter (from 0 to 64) (default 0)

Default(0)
mode Int | Literal['hard', 'soft', 'medium'] | Default

set thresholding mode (from 0 to 2) (default medium)

Default('medium')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

prewitt

prewitt(
    *,
    planes: Int = Default(15),
    scale: Float = Default(1.0),
    delta: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply prewitt operator.

Parameters:

Name Type Description Default
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
scale Float

set scale (from 0 to 65535) (default 1)

Default(1.0)
delta Float

set delta (from -65535 to 65535) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

pseudocolor

pseudocolor(
    *,
    c0: String = Default("val"),
    c1: String = Default("val"),
    c2: String = Default("val"),
    c3: String = Default("val"),
    index: Int = Default(0),
    preset: (
        Int
        | Literal[
            "none",
            "magma",
            "inferno",
            "plasma",
            "viridis",
            "turbo",
            "cividis",
            "range1",
            "range2",
            "shadows",
            "highlights",
            "solar",
            "nominal",
            "preferred",
            "total",
            "spectral",
        ]
        | Default
    ) = Default("none"),
    opacity: Float = Default(1.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Make pseudocolored video frames.

Parameters:

Name Type Description Default
c0 String

set component #0 expression (default "val")

Default('val')
c1 String

set component #1 expression (default "val")

Default('val')
c2 String

set component #2 expression (default "val")

Default('val')
c3 String

set component #3 expression (default "val")

Default('val')
index Int

set component as base (from 0 to 3) (default 0)

Default(0)
preset Int | Literal['none', 'magma', 'inferno', 'plasma', 'viridis', 'turbo', 'cividis', 'range1', 'range2', 'shadows', 'highlights', 'solar', 'nominal', 'preferred', 'total', 'spectral'] | Default

set preset (from -1 to 14) (default none)

Default('none')
opacity Float

set pseudocolor opacity (from 0 to 1) (default 1)

Default(1.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

psnr

psnr(
    _reference: VideoStream,
    *,
    stats_file: String = Default(None),
    stats_version: Int = Default(1),
    output_max: Boolean = Default(False),
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Calculate the PSNR between two video streams.

Parameters:

Name Type Description Default
stats_file String

Set file where to store per-frame difference information

Default(None)
stats_version Int

Set the format version for the stats file. (from 1 to 2) (default 1)

Default(1)
output_max Boolean

Add raw stats (max values) to the output log. (default false)

Default(False)
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

pullup

pullup(
    *,
    jl: Int = Default(1),
    jr: Int = Default(1),
    jt: Int = Default(4),
    jb: Int = Default(4),
    sb: Boolean = Default(False),
    mp: Int | Literal["y", "u", "v"] | Default = Default(
        "y"
    ),
    **kwargs: Any
) -> VideoStream

Pullup from field sequence to frames.

Parameters:

Name Type Description Default
jl Int

set left junk size (from 0 to INT_MAX) (default 1)

Default(1)
jr Int

set right junk size (from 0 to INT_MAX) (default 1)

Default(1)
jt Int

set top junk size (from 1 to INT_MAX) (default 4)

Default(4)
jb Int

set bottom junk size (from 1 to INT_MAX) (default 4)

Default(4)
sb Boolean

set strict breaks (default false)

Default(False)
mp Int | Literal['y', 'u', 'v'] | Default

set metric plane (from 0 to 2) (default y)

Default('y')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

qp

qp(
    *,
    qp: String = Default(None),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Change video quantization parameters.

Parameters:

Name Type Description Default
qp String

set qp expression

Default(None)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

random

random(
    *,
    frames: Int = Default(30),
    seed: Int64 = Default(-1),
    **kwargs: Any
) -> VideoStream

Return random frames.

Parameters:

Name Type Description Default
frames Int

set number of frames in cache (from 2 to 512) (default 30)

Default(30)
seed Int64

set the seed (from -1 to UINT32_MAX) (default -1)

Default(-1)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

readeia608

readeia608(
    *,
    scan_min: Int = Default(0),
    scan_max: Int = Default(29),
    spw: Float = Default(0.27),
    chp: Boolean = Default(False),
    lp: Boolean = Default(True),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Read EIA-608 Closed Caption codes from input video and write them to frame metadata.

Parameters:

Name Type Description Default
scan_min Int

set from which line to scan for codes (from 0 to INT_MAX) (default 0)

Default(0)
scan_max Int

set to which line to scan for codes (from 0 to INT_MAX) (default 29)

Default(29)
spw Float

set ratio of width reserved for sync code detection (from 0.1 to 0.7) (default 0.27)

Default(0.27)
chp Boolean

check and apply parity bit (default false)

Default(False)
lp Boolean

lowpass line prior to processing (default true)

Default(True)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

readvitc

readvitc(
    *,
    scan_max: Int = Default(45),
    thr_b: Double = Default(0.2),
    thr_w: Double = Default(0.6),
    **kwargs: Any
) -> VideoStream

Read vertical interval timecode and write it to frame metadata.

Parameters:

Name Type Description Default
scan_max Int

maximum line numbers to scan for VITC data (from -1 to INT_MAX) (default 45)

Default(45)
thr_b Double

black color threshold (from 0 to 1) (default 0.2)

Default(0.2)
thr_w Double

white color threshold (from 0 to 1) (default 0.6)

Default(0.6)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

realtime

realtime(
    *,
    limit: Duration = Default(2.0),
    speed: Double = Default(1.0),
    **kwargs: Any
) -> VideoStream

Slow down filtering to match realtime.

Parameters:

Name Type Description Default
limit Duration

sleep time limit (default 2)

Default(2.0)
speed Double

speed factor (from DBL_MIN to DBL_MAX) (default 1)

Default(1.0)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

remap

remap(
    _xmap: VideoStream,
    _ymap: VideoStream,
    *,
    format: (
        Int | Literal["color", "gray"] | Default
    ) = Default("color"),
    fill: Color = Default("black"),
    **kwargs: Any
) -> VideoStream

Remap pixels.

Parameters:

Name Type Description Default
format Int | Literal['color', 'gray'] | Default

set output format (from 0 to 1) (default color)

Default('color')
fill Color

set the color of the unmapped pixels (default "black")

Default('black')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

removegrain

removegrain(
    *,
    m0: Int = Default(0),
    m1: Int = Default(0),
    m2: Int = Default(0),
    m3: Int = Default(0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Remove grain.

Parameters:

Name Type Description Default
m0 Int

set mode for 1st plane (from 0 to 24) (default 0)

Default(0)
m1 Int

set mode for 2nd plane (from 0 to 24) (default 0)

Default(0)
m2 Int

set mode for 3rd plane (from 0 to 24) (default 0)

Default(0)
m3 Int

set mode for 4th plane (from 0 to 24) (default 0)

Default(0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

removelogo(
    *,
    filename: String = Default(None),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Remove a TV logo based on a mask image.

Parameters:

Name Type Description Default
filename String

set bitmap filename

Default(None)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

repeatfields

repeatfields(**kwargs: Any) -> VideoStream

Hard repeat fields based on MPEG repeat field flag.

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

reverse

reverse(**kwargs: Any) -> VideoStream

Reverse a clip.

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

rgbashift

rgbashift(
    *,
    rh: Int = Default(0),
    rv: Int = Default(0),
    gh: Int = Default(0),
    gv: Int = Default(0),
    bh: Int = Default(0),
    bv: Int = Default(0),
    ah: Int = Default(0),
    av: Int = Default(0),
    edge: (
        Int | Literal["smear", "wrap"] | Default
    ) = Default("smear"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Shift RGBA.

Parameters:

Name Type Description Default
rh Int

shift red horizontally (from -255 to 255) (default 0)

Default(0)
rv Int

shift red vertically (from -255 to 255) (default 0)

Default(0)
gh Int

shift green horizontally (from -255 to 255) (default 0)

Default(0)
gv Int

shift green vertically (from -255 to 255) (default 0)

Default(0)
bh Int

shift blue horizontally (from -255 to 255) (default 0)

Default(0)
bv Int

shift blue vertically (from -255 to 255) (default 0)

Default(0)
ah Int

shift alpha horizontally (from -255 to 255) (default 0)

Default(0)
av Int

shift alpha vertically (from -255 to 255) (default 0)

Default(0)
edge Int | Literal['smear', 'wrap'] | Default

set edge operation (from 0 to 1) (default smear)

Default('smear')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

roberts

roberts(
    *,
    planes: Int = Default(15),
    scale: Float = Default(1.0),
    delta: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply roberts cross operator.

Parameters:

Name Type Description Default
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
scale Float

set scale (from 0 to 65535) (default 1)

Default(1.0)
delta Float

set delta (from -65535 to 65535) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

rotate

rotate(
    *,
    angle: String = Default("0"),
    out_w: String = Default("iw"),
    out_h: String = Default("ih"),
    fillcolor: String = Default("black"),
    bilinear: Boolean = Default(True),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Rotate the input image.

Parameters:

Name Type Description Default
angle String

set angle (in radians) (default "0")

Default('0')
out_w String

set output width expression (default "iw")

Default('iw')
out_h String

set output height expression (default "ih")

Default('ih')
fillcolor String

set background fill color (default "black")

Default('black')
bilinear Boolean

use bilinear interpolation (default true)

Default(True)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

sab

sab(
    *,
    luma_radius: Float = Default(1.0),
    luma_pre_filter_radius: Float = Default(1.0),
    luma_strength: Float = Default(1.0),
    chroma_radius: Float = Default(-0.9),
    chroma_pre_filter_radius: Float = Default(-0.9),
    chroma_strength: Float = Default(-0.9),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply shape adaptive blur.

Parameters:

Name Type Description Default
luma_radius Float

set luma radius (from 0.1 to 4) (default 1)

Default(1.0)
luma_pre_filter_radius Float

set luma pre-filter radius (from 0.1 to 2) (default 1)

Default(1.0)
luma_strength Float

set luma strength (from 0.1 to 100) (default 1)

Default(1.0)
chroma_radius Float

set chroma radius (from -0.9 to 4) (default -0.9)

Default(-0.9)
chroma_pre_filter_radius Float

set chroma pre-filter radius (from -0.9 to 2) (default -0.9)

Default(-0.9)
chroma_strength Float

set chroma strength (from -0.9 to 100) (default -0.9)

Default(-0.9)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

scale

scale(
    *,
    w: String = Default(None),
    h: String = Default(None),
    flags: String = Default(""),
    interl: Boolean = Default(False),
    in_color_matrix: (
        String
        | Literal[
            "auto",
            "bt601",
            "bt470",
            "smpte170m",
            "bt709",
            "fcc",
            "smpte240m",
            "bt2020",
        ]
        | Default
    ) = Default("auto"),
    out_color_matrix: (
        String
        | Literal[
            "auto",
            "bt601",
            "bt470",
            "smpte170m",
            "bt709",
            "fcc",
            "smpte240m",
            "bt2020",
        ]
        | Default
    ) = Default(None),
    in_range: (
        Int
        | Literal[
            "auto",
            "unknown",
            "full",
            "limited",
            "jpeg",
            "mpeg",
            "tv",
            "pc",
        ]
        | Default
    ) = Default("auto"),
    out_range: (
        Int
        | Literal[
            "auto",
            "unknown",
            "full",
            "limited",
            "jpeg",
            "mpeg",
            "tv",
            "pc",
        ]
        | Default
    ) = Default("auto"),
    in_v_chr_pos: Int = Default(-513),
    in_h_chr_pos: Int = Default(-513),
    out_v_chr_pos: Int = Default(-513),
    out_h_chr_pos: Int = Default(-513),
    force_original_aspect_ratio: (
        Int
        | Literal["disable", "decrease", "increase"]
        | Default
    ) = Default("disable"),
    force_divisible_by: Int = Default(1),
    param0: Double = Default("DBL_MAX"),
    param1: Double = Default("DBL_MAX"),
    eval: (
        Int | Literal["init", "frame"] | Default
    ) = Default("init"),
    **kwargs: Any
) -> VideoStream

Scale the input video size and/or convert the image format.

Parameters:

Name Type Description Default
w String

Output video width

Default(None)
h String

Output video height

Default(None)
flags String

Flags to pass to libswscale (default "")

Default('')
interl Boolean

set interlacing (default false)

Default(False)
in_color_matrix String | Literal['auto', 'bt601', 'bt470', 'smpte170m', 'bt709', 'fcc', 'smpte240m', 'bt2020'] | Default

set input YCbCr type (default "auto")

Default('auto')
out_color_matrix String | Literal['auto', 'bt601', 'bt470', 'smpte170m', 'bt709', 'fcc', 'smpte240m', 'bt2020'] | Default

set output YCbCr type

Default(None)
in_range Int | Literal['auto', 'unknown', 'full', 'limited', 'jpeg', 'mpeg', 'tv', 'pc'] | Default

set input color range (from 0 to 2) (default auto)

Default('auto')
out_range Int | Literal['auto', 'unknown', 'full', 'limited', 'jpeg', 'mpeg', 'tv', 'pc'] | Default

set output color range (from 0 to 2) (default auto)

Default('auto')
in_v_chr_pos Int

input vertical chroma position in luma grid/256 (from -513 to 512) (default -513)

Default(-513)
in_h_chr_pos Int

input horizontal chroma position in luma grid/256 (from -513 to 512) (default -513)

Default(-513)
out_v_chr_pos Int

output vertical chroma position in luma grid/256 (from -513 to 512) (default -513)

Default(-513)
out_h_chr_pos Int

output horizontal chroma position in luma grid/256 (from -513 to 512) (default -513)

Default(-513)
force_original_aspect_ratio Int | Literal['disable', 'decrease', 'increase'] | Default

decrease or increase w/h if necessary to keep the original AR (from 0 to 2) (default disable)

Default('disable')
force_divisible_by Int

enforce that the output resolution is divisible by a defined integer when force_original_aspect_ratio is used (from 1 to 256) (default 1)

Default(1)
param0 Double

Scaler param 0 (from -DBL_MAX to DBL_MAX) (default DBL_MAX)

Default('DBL_MAX')
param1 Double

Scaler param 1 (from -DBL_MAX to DBL_MAX) (default DBL_MAX)

Default('DBL_MAX')
eval Int | Literal['init', 'frame'] | Default

specify when to evaluate expressions (from 0 to 1) (default init)

Default('init')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

scale2ref

scale2ref(
    _ref: VideoStream,
    *,
    w: String = Default(None),
    h: String = Default(None),
    flags: String = Default(""),
    interl: Boolean = Default(False),
    in_color_matrix: (
        String
        | Literal[
            "auto",
            "bt601",
            "bt470",
            "smpte170m",
            "bt709",
            "fcc",
            "smpte240m",
            "bt2020",
        ]
        | Default
    ) = Default("auto"),
    out_color_matrix: (
        String
        | Literal[
            "auto",
            "bt601",
            "bt470",
            "smpte170m",
            "bt709",
            "fcc",
            "smpte240m",
            "bt2020",
        ]
        | Default
    ) = Default(None),
    in_range: (
        Int
        | Literal[
            "auto",
            "unknown",
            "full",
            "limited",
            "jpeg",
            "mpeg",
            "tv",
            "pc",
        ]
        | Default
    ) = Default("auto"),
    out_range: (
        Int
        | Literal[
            "auto",
            "unknown",
            "full",
            "limited",
            "jpeg",
            "mpeg",
            "tv",
            "pc",
        ]
        | Default
    ) = Default("auto"),
    in_v_chr_pos: Int = Default(-513),
    in_h_chr_pos: Int = Default(-513),
    out_v_chr_pos: Int = Default(-513),
    out_h_chr_pos: Int = Default(-513),
    force_original_aspect_ratio: (
        Int
        | Literal["disable", "decrease", "increase"]
        | Default
    ) = Default("disable"),
    force_divisible_by: Int = Default(1),
    param0: Double = Default("DBL_MAX"),
    param1: Double = Default("DBL_MAX"),
    eval: (
        Int | Literal["init", "frame"] | Default
    ) = Default("init"),
    **kwargs: Any
) -> tuple[VideoStream, VideoStream]

Scale the input video size and/or convert the image format to the given reference.

Parameters:

Name Type Description Default
w String

Output video width

Default(None)
h String

Output video height

Default(None)
flags String

Flags to pass to libswscale (default "")

Default('')
interl Boolean

set interlacing (default false)

Default(False)
in_color_matrix String | Literal['auto', 'bt601', 'bt470', 'smpte170m', 'bt709', 'fcc', 'smpte240m', 'bt2020'] | Default

set input YCbCr type (default "auto")

Default('auto')
out_color_matrix String | Literal['auto', 'bt601', 'bt470', 'smpte170m', 'bt709', 'fcc', 'smpte240m', 'bt2020'] | Default

set output YCbCr type

Default(None)
in_range Int | Literal['auto', 'unknown', 'full', 'limited', 'jpeg', 'mpeg', 'tv', 'pc'] | Default

set input color range (from 0 to 2) (default auto)

Default('auto')
out_range Int | Literal['auto', 'unknown', 'full', 'limited', 'jpeg', 'mpeg', 'tv', 'pc'] | Default

set output color range (from 0 to 2) (default auto)

Default('auto')
in_v_chr_pos Int

input vertical chroma position in luma grid/256 (from -513 to 512) (default -513)

Default(-513)
in_h_chr_pos Int

input horizontal chroma position in luma grid/256 (from -513 to 512) (default -513)

Default(-513)
out_v_chr_pos Int

output vertical chroma position in luma grid/256 (from -513 to 512) (default -513)

Default(-513)
out_h_chr_pos Int

output horizontal chroma position in luma grid/256 (from -513 to 512) (default -513)

Default(-513)
force_original_aspect_ratio Int | Literal['disable', 'decrease', 'increase'] | Default

decrease or increase w/h if necessary to keep the original AR (from 0 to 2) (default disable)

Default('disable')
force_divisible_by Int

enforce that the output resolution is divisible by a defined integer when force_original_aspect_ratio is used (from 1 to 256) (default 1)

Default(1)
param0 Double

Scaler param 0 (from -DBL_MAX to DBL_MAX) (default DBL_MAX)

Default('DBL_MAX')
param1 Double

Scaler param 1 (from -DBL_MAX to DBL_MAX) (default DBL_MAX)

Default('DBL_MAX')
eval Int | Literal['init', 'frame'] | Default

specify when to evaluate expressions (from 0 to 1) (default init)

Default('init')

Returns:

Name Type Description
default VideoStream

the video stream

ref VideoStream

the video stream

References

FFmpeg Documentation

scdet

scdet(
    *,
    threshold: Double = Default(10.0),
    sc_pass: Boolean = Default(False),
    **kwargs: Any
) -> VideoStream

Detect video scene change

Parameters:

Name Type Description Default
threshold Double

set scene change detect threshold (from 0 to 100) (default 10)

Default(10.0)
sc_pass Boolean

Set the flag to pass scene change frames (default false)

Default(False)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

scharr

scharr(
    *,
    planes: Int = Default(15),
    scale: Float = Default(1.0),
    delta: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply scharr operator.

Parameters:

Name Type Description Default
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
scale Float

set scale (from 0 to 65535) (default 1)

Default(1.0)
delta Float

set delta (from -65535 to 65535) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

scroll

scroll(
    *,
    horizontal: Float = Default(0.0),
    vertical: Float = Default(0.0),
    hpos: Float = Default(0.0),
    vpos: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Scroll input video.

Parameters:

Name Type Description Default
horizontal Float

set the horizontal scrolling speed (from -1 to 1) (default 0)

Default(0.0)
vertical Float

set the vertical scrolling speed (from -1 to 1) (default 0)

Default(0.0)
hpos Float

set initial horizontal position (from 0 to 1) (default 0)

Default(0.0)
vpos Float

set initial vertical position (from 0 to 1) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

segment

segment(
    *,
    timestamps: String = Default(None),
    frames: String = Default(None),
    **kwargs: Any
) -> FilterNode

Segment video stream.

Parameters:

Name Type Description Default
timestamps String

timestamps of input at which to split input

Default(None)
frames String

frames at which to split input

Default(None)

Returns:

Name Type Description
filter_node FilterNode

the filter node

References

FFmpeg Documentation

select

select(
    *,
    expr: String = Default("1"),
    outputs: Int = Default(1),
    **kwargs: Any
) -> FilterNode

Select video frames to pass in output.

Parameters:

Name Type Description Default
expr String

set an expression to use for selecting frames (default "1")

Default('1')
outputs Int

set the number of outputs (from 1 to INT_MAX) (default 1)

Default(1)

Returns:

Name Type Description
filter_node FilterNode

the filter node

References

FFmpeg Documentation

selectivecolor

selectivecolor(
    *,
    correction_method: (
        Int | Literal["absolute", "relative"] | Default
    ) = Default("absolute"),
    reds: String = Default(None),
    yellows: String = Default(None),
    greens: String = Default(None),
    cyans: String = Default(None),
    blues: String = Default(None),
    magentas: String = Default(None),
    whites: String = Default(None),
    neutrals: String = Default(None),
    blacks: String = Default(None),
    psfile: String = Default(None),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply CMYK adjustments to specific color ranges.

Parameters:

Name Type Description Default
correction_method Int | Literal['absolute', 'relative'] | Default

select correction method (from 0 to 1) (default absolute)

Default('absolute')
reds String

adjust red regions

Default(None)
yellows String

adjust yellow regions

Default(None)
greens String

adjust green regions

Default(None)
cyans String

adjust cyan regions

Default(None)
blues String

adjust blue regions

Default(None)
magentas String

adjust magenta regions

Default(None)
whites String

adjust white regions

Default(None)
neutrals String

adjust neutral regions

Default(None)
blacks String

adjust black regions

Default(None)
psfile String

set Photoshop selectivecolor file name

Default(None)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

sendcmd

sendcmd(
    *,
    commands: String = Default(None),
    filename: String = Default(None),
    **kwargs: Any
) -> VideoStream

Send commands to filters.

Parameters:

Name Type Description Default
commands String

set commands

Default(None)
filename String

set commands file

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

separatefields

separatefields(**kwargs: Any) -> VideoStream

Split input video frames into fields.

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

setdar

setdar(
    *,
    dar: String = Default("0"),
    max: Int = Default(100),
    **kwargs: Any
) -> VideoStream

Set the frame display aspect ratio.

Parameters:

Name Type Description Default
dar String

set display aspect ratio (default "0")

Default('0')
max Int

set max value for nominator or denominator in the ratio (from 1 to INT_MAX) (default 100)

Default(100)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

setfield

setfield(
    *,
    mode: (
        Int
        | Literal["auto", "bff", "tff", "prog"]
        | Default
    ) = Default("auto"),
    **kwargs: Any
) -> VideoStream

Force field for the output video frame.

Parameters:

Name Type Description Default
mode Int | Literal['auto', 'bff', 'tff', 'prog'] | Default

select interlace mode (from -1 to 2) (default auto)

Default('auto')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

setparams

setparams(
    *,
    field_mode: (
        Int
        | Literal["auto", "bff", "tff", "prog"]
        | Default
    ) = Default("auto"),
    range: (
        Int
        | Literal[
            "auto",
            "unspecified",
            "unknown",
            "limited",
            "tv",
            "mpeg",
            "full",
            "pc",
            "jpeg",
        ]
        | Default
    ) = Default("auto"),
    color_primaries: (
        Int
        | Literal[
            "auto",
            "bt709",
            "unknown",
            "bt470m",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "film",
            "bt2020",
            "smpte428",
            "smpte431",
            "smpte432",
            "p22",
            "ebu3213",
        ]
        | Default
    ) = Default("auto"),
    color_trc: (
        Int
        | Literal[
            "auto",
            "bt709",
            "unknown",
            "bt470m",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "linear",
            "log100",
            "log316",
            "4",
            "bt1361e",
            "1",
            "10",
            "12",
            "smpte2084",
            "smpte428",
            "b67",
        ]
        | Default
    ) = Default("auto"),
    colorspace: (
        Int
        | Literal[
            "auto",
            "gbr",
            "bt709",
            "unknown",
            "fcc",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "ycgco",
            "bt2020nc",
            "bt2020c",
            "smpte2085",
            "nc",
            "c",
            "ictcp",
        ]
        | Default
    ) = Default("auto"),
    **kwargs: Any
) -> VideoStream

Force field, or color property for the output video frame.

Parameters:

Name Type Description Default
field_mode Int | Literal['auto', 'bff', 'tff', 'prog'] | Default

select interlace mode (from -1 to 2) (default auto)

Default('auto')
range Int | Literal['auto', 'unspecified', 'unknown', 'limited', 'tv', 'mpeg', 'full', 'pc', 'jpeg'] | Default

select color range (from -1 to 2) (default auto)

Default('auto')
color_primaries Int | Literal['auto', 'bt709', 'unknown', 'bt470m', 'bt470bg', 'smpte170m', 'smpte240m', 'film', 'bt2020', 'smpte428', 'smpte431', 'smpte432', 'p22', 'ebu3213'] | Default

select color primaries (from -1 to 22) (default auto)

Default('auto')
color_trc Int | Literal['auto', 'bt709', 'unknown', 'bt470m', 'bt470bg', 'smpte170m', 'smpte240m', 'linear', 'log100', 'log316', '4', 'bt1361e', '1', '10', '12', 'smpte2084', 'smpte428', 'b67'] | Default

select color transfer (from -1 to 18) (default auto)

Default('auto')
colorspace Int | Literal['auto', 'gbr', 'bt709', 'unknown', 'fcc', 'bt470bg', 'smpte170m', 'smpte240m', 'ycgco', 'bt2020nc', 'bt2020c', 'smpte2085', 'nc', 'c', 'ictcp'] | Default

select colorspace (from -1 to 14) (default auto)

Default('auto')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

setpts

setpts(
    *, expr: String = Default("PTS"), **kwargs: Any
) -> VideoStream

Set PTS for the output video frame.

Parameters:

Name Type Description Default
expr String

Expression determining the frame timestamp (default "PTS")

Default('PTS')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

setrange

setrange(
    *,
    range: (
        Int
        | Literal[
            "auto",
            "unspecified",
            "unknown",
            "limited",
            "tv",
            "mpeg",
            "full",
            "pc",
            "jpeg",
        ]
        | Default
    ) = Default("auto"),
    **kwargs: Any
) -> VideoStream

Force color range for the output video frame.

Parameters:

Name Type Description Default
range Int | Literal['auto', 'unspecified', 'unknown', 'limited', 'tv', 'mpeg', 'full', 'pc', 'jpeg'] | Default

select color range (from -1 to 2) (default auto)

Default('auto')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

setsar

setsar(
    *,
    sar: String = Default("0"),
    max: Int = Default(100),
    **kwargs: Any
) -> VideoStream

Set the pixel sample aspect ratio.

Parameters:

Name Type Description Default
sar String

set sample (pixel) aspect ratio (default "0")

Default('0')
max Int

set max value for nominator or denominator in the ratio (from 1 to INT_MAX) (default 100)

Default(100)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

settb

settb(
    *, expr: String = Default("intb"), **kwargs: Any
) -> VideoStream

Set timebase for the video output link.

Parameters:

Name Type Description Default
expr String

set expression determining the output timebase (default "intb")

Default('intb')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

shear

shear(
    *,
    shx: Float = Default(0.0),
    shy: Float = Default(0.0),
    fillcolor: String = Default("black"),
    interp: (
        Int | Literal["nearest", "bilinear"] | Default
    ) = Default("bilinear"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Shear transform the input image.

Parameters:

Name Type Description Default
shx Float

set x shear factor (from -2 to 2) (default 0)

Default(0.0)
shy Float

set y shear factor (from -2 to 2) (default 0)

Default(0.0)
fillcolor String

set background fill color (default "black")

Default('black')
interp Int | Literal['nearest', 'bilinear'] | Default

set interpolation (from 0 to 1) (default bilinear)

Default('bilinear')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

showinfo

showinfo(
    *, checksum: Boolean = Default(True), **kwargs: Any
) -> VideoStream

Show textual information for each video frame.

Parameters:

Name Type Description Default
checksum Boolean

calculate checksums (default true)

Default(True)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

showpalette

showpalette(
    *, s: Int = Default(30), **kwargs: Any
) -> VideoStream

Display frame palette.

Parameters:

Name Type Description Default
s Int

set pixel box size (from 1 to 100) (default 30)

Default(30)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

shuffleframes

shuffleframes(
    *,
    mapping: String = Default("0"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Shuffle video frames.

Parameters:

Name Type Description Default
mapping String

set destination indexes of input frames (default "0")

Default('0')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

shufflepixels

shufflepixels(
    *,
    direction: (
        Int | Literal["forward", "inverse"] | Default
    ) = Default("forward"),
    mode: (
        Int
        | Literal["horizontal", "vertical", "block"]
        | Default
    ) = Default("horizontal"),
    width: Int = Default(10),
    height: Int = Default(10),
    seed: Int64 = Default(-1),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Shuffle video pixels.

Parameters:

Name Type Description Default
direction Int | Literal['forward', 'inverse'] | Default

set shuffle direction (from 0 to 1) (default forward)

Default('forward')
mode Int | Literal['horizontal', 'vertical', 'block'] | Default

set shuffle mode (from 0 to 2) (default horizontal)

Default('horizontal')
width Int

set block width (from 1 to 8000) (default 10)

Default(10)
height Int

set block height (from 1 to 8000) (default 10)

Default(10)
seed Int64

set random seed (from -1 to UINT32_MAX) (default -1)

Default(-1)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

shuffleplanes

shuffleplanes(
    *,
    map0: Int = Default(0),
    map1: Int = Default(1),
    map2: Int = Default(2),
    map3: Int = Default(3),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Shuffle video planes.

Parameters:

Name Type Description Default
map0 Int

Index of the input plane to be used as the first output plane (from 0 to 3) (default 0)

Default(0)
map1 Int

Index of the input plane to be used as the second output plane (from 0 to 3) (default 1)

Default(1)
map2 Int

Index of the input plane to be used as the third output plane (from 0 to 3) (default 2)

Default(2)
map3 Int

Index of the input plane to be used as the fourth output plane (from 0 to 3) (default 3)

Default(3)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

sidedata

sidedata(
    *,
    mode: (
        Int | Literal["select", "delete"] | Default
    ) = Default("select"),
    type: (
        Int
        | Literal[
            "PANSCAN",
            "A53_CC",
            "STEREO3D",
            "MATRIXENCODING",
            "DOWNMIX_INFO",
            "REPLAYGAIN",
            "DISPLAYMATRIX",
            "AFD",
            "MOTION_VECTORS",
            "SKIP_SAMPLES",
            "AUDIO_SERVICE_TYPE",
            "MASTERING_DISPLAY_METADATA",
            "GOP_TIMECODE",
            "SPHERICAL",
            "CONTENT_LIGHT_LEVEL",
            "ICC_PROFILE",
            "S12M_TIMECOD",
            "DYNAMIC_HDR_PLUS",
            "REGIONS_OF_INTEREST",
            "DETECTION_BOUNDING_BOXES",
            "SEI_UNREGISTERED",
        ]
        | Default
    ) = Default(-1),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Manipulate video frame side data.

Parameters:

Name Type Description Default
mode Int | Literal['select', 'delete'] | Default

set a mode of operation (from 0 to 1) (default select)

Default('select')
type Int | Literal['PANSCAN', 'A53_CC', 'STEREO3D', 'MATRIXENCODING', 'DOWNMIX_INFO', 'REPLAYGAIN', 'DISPLAYMATRIX', 'AFD', 'MOTION_VECTORS', 'SKIP_SAMPLES', 'AUDIO_SERVICE_TYPE', 'MASTERING_DISPLAY_METADATA', 'GOP_TIMECODE', 'SPHERICAL', 'CONTENT_LIGHT_LEVEL', 'ICC_PROFILE', 'S12M_TIMECOD', 'DYNAMIC_HDR_PLUS', 'REGIONS_OF_INTEREST', 'DETECTION_BOUNDING_BOXES', 'SEI_UNREGISTERED'] | Default

set side data type (from -1 to INT_MAX) (default -1)

Default(-1)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

signalstats

signalstats(
    *,
    stat: (
        Flags | Literal["tout", "vrep", "brng"] | Default
    ) = Default("0"),
    out: (
        Int | Literal["tout", "vrep", "brng"] | Default
    ) = Default(-1),
    c: Color = Default("yellow"),
    **kwargs: Any
) -> VideoStream

Generate statistics from video analysis.

Parameters:

Name Type Description Default
stat Flags | Literal['tout', 'vrep', 'brng'] | Default

set statistics filters (default 0)

Default('0')
out Int | Literal['tout', 'vrep', 'brng'] | Default

set video filter (from -1 to 2) (default -1)

Default(-1)
c Color

set highlight color (default "yellow")

Default('yellow')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

siti

siti(
    *,
    print_summary: Boolean = Default(False),
    **kwargs: Any
) -> VideoStream

Calculate spatial information (SI) and temporal information (TI).

Parameters:

Name Type Description Default
print_summary Boolean

Print summary showing average values (default false)

Default(False)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

smartblur

smartblur(
    *,
    luma_radius: Float = Default(1.0),
    luma_strength: Float = Default(1.0),
    luma_threshold: Int = Default(0),
    chroma_radius: Float = Default(-0.9),
    chroma_strength: Float = Default(-2.0),
    chroma_threshold: Int = Default(-31),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Blur the input video without impacting the outlines.

Parameters:

Name Type Description Default
luma_radius Float

set luma radius (from 0.1 to 5) (default 1)

Default(1.0)
luma_strength Float

set luma strength (from -1 to 1) (default 1)

Default(1.0)
luma_threshold Int

set luma threshold (from -30 to 30) (default 0)

Default(0)
chroma_radius Float

set chroma radius (from -0.9 to 5) (default -0.9)

Default(-0.9)
chroma_strength Float

set chroma strength (from -2 to 1) (default -2)

Default(-2.0)
chroma_threshold Int

set chroma threshold (from -31 to 30) (default -31)

Default(-31)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

sobel

sobel(
    *,
    planes: Int = Default(15),
    scale: Float = Default(1.0),
    delta: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply sobel operator.

Parameters:

Name Type Description Default
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
scale Float

set scale (from 0 to 65535) (default 1)

Default(1.0)
delta Float

set delta (from -65535 to 65535) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

spectrumsynth

spectrumsynth(
    _phase: VideoStream,
    *,
    sample_rate: Int = Default(44100),
    channels: Int = Default(1),
    scale: Int | Literal["lin", "log"] | Default = Default(
        "log"
    ),
    slide: (
        Int
        | Literal[
            "replace", "scroll", "fullframe", "rscroll"
        ]
        | Default
    ) = Default("fullframe"),
    win_func: (
        Int
        | Literal[
            "rect",
            "bartlett",
            "hann",
            "hanning",
            "hamming",
            "blackman",
            "welch",
            "flattop",
            "bharris",
            "bnuttall",
            "bhann",
            "sine",
            "nuttall",
            "lanczos",
            "gauss",
            "tukey",
            "dolph",
            "cauchy",
            "parzen",
            "poisson",
            "bohman",
            "kaiser",
        ]
        | Default
    ) = Default("rect"),
    overlap: Float = Default(1.0),
    orientation: (
        Int | Literal["vertical", "horizontal"] | Default
    ) = Default("vertical"),
    **kwargs: Any
) -> AudioStream

Convert input spectrum videos to audio output.

Parameters:

Name Type Description Default
sample_rate Int

set sample rate (from 15 to INT_MAX) (default 44100)

Default(44100)
channels Int

set channels (from 1 to 8) (default 1)

Default(1)
scale Int | Literal['lin', 'log'] | Default

set input amplitude scale (from 0 to 1) (default log)

Default('log')
slide Int | Literal['replace', 'scroll', 'fullframe', 'rscroll'] | Default

set input sliding mode (from 0 to 3) (default fullframe)

Default('fullframe')
win_func Int | Literal['rect', 'bartlett', 'hann', 'hanning', 'hamming', 'blackman', 'welch', 'flattop', 'bharris', 'bnuttall', 'bhann', 'sine', 'nuttall', 'lanczos', 'gauss', 'tukey', 'dolph', 'cauchy', 'parzen', 'poisson', 'bohman', 'kaiser'] | Default

set window function (from 0 to 20) (default rect)

Default('rect')
overlap Float

set window overlap (from 0 to 1) (default 1)

Default(1.0)
orientation Int | Literal['vertical', 'horizontal'] | Default

set orientation (from 0 to 1) (default vertical)

Default('vertical')

Returns:

Name Type Description
default AudioStream

the audio stream

References

FFmpeg Documentation

split

split(
    *, outputs: Int = Default(2), **kwargs: Any
) -> FilterNode

Pass on the input to N video outputs.

Parameters:

Name Type Description Default
outputs Int

set number of outputs (from 1 to INT_MAX) (default 2)

Default(2)

Returns:

Name Type Description
filter_node FilterNode

the filter node

References

FFmpeg Documentation

spp

spp(
    *,
    quality: Int = Default(3),
    qp: Int = Default(0),
    mode: Int | Literal["hard", "soft"] | Default = Default(
        "hard"
    ),
    use_bframe_qp: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply a simple post processing filter.

Parameters:

Name Type Description Default
quality Int

set quality (from 0 to 6) (default 3)

Default(3)
qp Int

force a constant quantizer parameter (from 0 to 63) (default 0)

Default(0)
mode Int | Literal['hard', 'soft'] | Default

set thresholding mode (from 0 to 1) (default hard)

Default('hard')
use_bframe_qp Boolean

use B-frames' QP (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

sr

sr(
    *,
    dnn_backend: (
        Int | Literal["native"] | Default
    ) = Default("native"),
    scale_factor: Int = Default(2),
    model: String = Default(None),
    input: String = Default("x"),
    output: String = Default("y"),
    **kwargs: Any
) -> VideoStream

Apply DNN-based image super resolution to the input.

Parameters:

Name Type Description Default
dnn_backend Int | Literal['native'] | Default

DNN backend used for model execution (from 0 to 1) (default native)

Default('native')
scale_factor Int

scale factor for SRCNN model (from 2 to 4) (default 2)

Default(2)
model String

path to model file specifying network architecture and its parameters

Default(None)
input String

input name of the model (default "x")

Default('x')
output String

output name of the model (default "y")

Default('y')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

ssim

ssim(
    _reference: VideoStream,
    *,
    stats_file: String = Default(None),
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Calculate the SSIM between two video streams.

Parameters:

Name Type Description Default
stats_file String

Set file where to store per-frame difference information

Default(None)
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

stereo3d

stereo3d(
    *,
    _in: (
        Int
        | Literal[
            "ab2l",
            "tb2l",
            "ab2r",
            "tb2r",
            "abl",
            "tbl",
            "abr",
            "tbr",
            "al",
            "ar",
            "sbs2l",
            "sbs2r",
            "sbsl",
            "sbsr",
            "irl",
            "irr",
            "icl",
            "icr",
        ]
        | Default
    ) = Default("sbsl"),
    out: (
        Int
        | Literal[
            "ab2l",
            "tb2l",
            "ab2r",
            "tb2r",
            "abl",
            "tbl",
            "abr",
            "tbr",
            "agmc",
            "agmd",
            "agmg",
            "agmh",
            "al",
            "ar",
            "arbg",
            "arcc",
            "arcd",
            "arcg",
            "arch",
            "argg",
            "aybc",
            "aybd",
            "aybg",
            "aybh",
            "irl",
            "irr",
            "ml",
            "mr",
            "sbs2l",
            "sbs2r",
            "sbsl",
            "sbsr",
            "chl",
            "chr",
            "icl",
            "icr",
            "hdmi",
        ]
        | Default
    ) = Default("arcd"),
    **kwargs: Any
) -> VideoStream

Convert video stereoscopic 3D view.

Parameters:

Name Type Description Default
_in Int | Literal['ab2l', 'tb2l', 'ab2r', 'tb2r', 'abl', 'tbl', 'abr', 'tbr', 'al', 'ar', 'sbs2l', 'sbs2r', 'sbsl', 'sbsr', 'irl', 'irr', 'icl', 'icr'] | Default

set input format (from 16 to 32) (default sbsl)

Default('sbsl')
out Int | Literal['ab2l', 'tb2l', 'ab2r', 'tb2r', 'abl', 'tbl', 'abr', 'tbr', 'agmc', 'agmd', 'agmg', 'agmh', 'al', 'ar', 'arbg', 'arcc', 'arcd', 'arcg', 'arch', 'argg', 'aybc', 'aybd', 'aybg', 'aybh', 'irl', 'irr', 'ml', 'mr', 'sbs2l', 'sbs2r', 'sbsl', 'sbsr', 'chl', 'chr', 'icl', 'icr', 'hdmi'] | Default

set output format (from 0 to 32) (default arcd)

Default('arcd')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

subtitles

subtitles(
    *,
    filename: String = Default(None),
    original_size: Image_size = Default(None),
    fontsdir: String = Default(None),
    alpha: Boolean = Default(False),
    charenc: String = Default(None),
    stream_index: Int = Default(-1),
    force_style: String = Default(None),
    **kwargs: Any
) -> VideoStream

Render text subtitles onto input video using the libass library.

Parameters:

Name Type Description Default
filename String

set the filename of file to read

Default(None)
original_size Image_size

set the size of the original video (used to scale fonts)

Default(None)
fontsdir String

set the directory containing the fonts to read

Default(None)
alpha Boolean

enable processing of alpha channel (default false)

Default(False)
charenc String

set input character encoding

Default(None)
stream_index Int

set stream index (from -1 to INT_MAX) (default -1)

Default(-1)
force_style String

force subtitle style

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

super2xsai

super2xsai(**kwargs: Any) -> VideoStream

Scale the input by 2x using the Super2xSaI pixel art algorithm.

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

swaprect

swaprect(
    *,
    w: String = Default("w/2"),
    h: String = Default("h/2"),
    x1: String = Default("w/2"),
    y1: String = Default("h/2"),
    x2: String = Default("0"),
    y2: String = Default("0"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Swap 2 rectangular objects in video.

Parameters:

Name Type Description Default
w String

set rect width (default "w/2")

Default('w/2')
h String

set rect height (default "h/2")

Default('h/2')
x1 String

set 1st rect x top left coordinate (default "w/2")

Default('w/2')
y1 String

set 1st rect y top left coordinate (default "h/2")

Default('h/2')
x2 String

set 2nd rect x top left coordinate (default "0")

Default('0')
y2 String

set 2nd rect y top left coordinate (default "0")

Default('0')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

swapuv

swapuv(
    *, enable: String = Default(None), **kwargs: Any
) -> VideoStream

Swap U and V components.

Parameters:

Name Type Description Default
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

tblend

tblend(
    *,
    c0_mode: (
        Int
        | Literal[
            "addition",
            "addition128",
            "grainmerge",
            "and",
            "average",
            "burn",
            "darken",
            "difference",
            "difference128",
            "grainextract",
            "divide",
            "dodge",
            "exclusion",
            "extremity",
            "freeze",
            "glow",
            "hardlight",
            "hardmix",
            "heat",
            "lighten",
            "linearlight",
            "multiply",
            "multiply128",
            "negation",
            "normal",
            "or",
            "overlay",
            "phoenix",
            "pinlight",
            "reflect",
            "screen",
            "softlight",
            "subtract",
            "vividlight",
            "xor",
            "softdifference",
            "geometric",
            "harmonic",
            "bleach",
            "stain",
            "interpolate",
            "hardoverlay",
        ]
        | Default
    ) = Default("normal"),
    c1_mode: (
        Int
        | Literal[
            "addition",
            "addition128",
            "grainmerge",
            "and",
            "average",
            "burn",
            "darken",
            "difference",
            "difference128",
            "grainextract",
            "divide",
            "dodge",
            "exclusion",
            "extremity",
            "freeze",
            "glow",
            "hardlight",
            "hardmix",
            "heat",
            "lighten",
            "linearlight",
            "multiply",
            "multiply128",
            "negation",
            "normal",
            "or",
            "overlay",
            "phoenix",
            "pinlight",
            "reflect",
            "screen",
            "softlight",
            "subtract",
            "vividlight",
            "xor",
            "softdifference",
            "geometric",
            "harmonic",
            "bleach",
            "stain",
            "interpolate",
            "hardoverlay",
        ]
        | Default
    ) = Default("normal"),
    c2_mode: (
        Int
        | Literal[
            "addition",
            "addition128",
            "grainmerge",
            "and",
            "average",
            "burn",
            "darken",
            "difference",
            "difference128",
            "grainextract",
            "divide",
            "dodge",
            "exclusion",
            "extremity",
            "freeze",
            "glow",
            "hardlight",
            "hardmix",
            "heat",
            "lighten",
            "linearlight",
            "multiply",
            "multiply128",
            "negation",
            "normal",
            "or",
            "overlay",
            "phoenix",
            "pinlight",
            "reflect",
            "screen",
            "softlight",
            "subtract",
            "vividlight",
            "xor",
            "softdifference",
            "geometric",
            "harmonic",
            "bleach",
            "stain",
            "interpolate",
            "hardoverlay",
        ]
        | Default
    ) = Default("normal"),
    c3_mode: (
        Int
        | Literal[
            "addition",
            "addition128",
            "grainmerge",
            "and",
            "average",
            "burn",
            "darken",
            "difference",
            "difference128",
            "grainextract",
            "divide",
            "dodge",
            "exclusion",
            "extremity",
            "freeze",
            "glow",
            "hardlight",
            "hardmix",
            "heat",
            "lighten",
            "linearlight",
            "multiply",
            "multiply128",
            "negation",
            "normal",
            "or",
            "overlay",
            "phoenix",
            "pinlight",
            "reflect",
            "screen",
            "softlight",
            "subtract",
            "vividlight",
            "xor",
            "softdifference",
            "geometric",
            "harmonic",
            "bleach",
            "stain",
            "interpolate",
            "hardoverlay",
        ]
        | Default
    ) = Default("normal"),
    all_mode: (
        Int
        | Literal[
            "addition",
            "addition128",
            "grainmerge",
            "and",
            "average",
            "burn",
            "darken",
            "difference",
            "difference128",
            "grainextract",
            "divide",
            "dodge",
            "exclusion",
            "extremity",
            "freeze",
            "glow",
            "hardlight",
            "hardmix",
            "heat",
            "lighten",
            "linearlight",
            "multiply",
            "multiply128",
            "negation",
            "normal",
            "or",
            "overlay",
            "phoenix",
            "pinlight",
            "reflect",
            "screen",
            "softlight",
            "subtract",
            "vividlight",
            "xor",
            "softdifference",
            "geometric",
            "harmonic",
            "bleach",
            "stain",
            "interpolate",
            "hardoverlay",
        ]
        | Default
    ) = Default(-1),
    c0_expr: String = Default(None),
    c1_expr: String = Default(None),
    c2_expr: String = Default(None),
    c3_expr: String = Default(None),
    all_expr: String = Default(None),
    c0_opacity: Double = Default(1.0),
    c1_opacity: Double = Default(1.0),
    c2_opacity: Double = Default(1.0),
    c3_opacity: Double = Default(1.0),
    all_opacity: Double = Default(1.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Blend successive frames.

Parameters:

Name Type Description Default
c0_mode Int | Literal['addition', 'addition128', 'grainmerge', 'and', 'average', 'burn', 'darken', 'difference', 'difference128', 'grainextract', 'divide', 'dodge', 'exclusion', 'extremity', 'freeze', 'glow', 'hardlight', 'hardmix', 'heat', 'lighten', 'linearlight', 'multiply', 'multiply128', 'negation', 'normal', 'or', 'overlay', 'phoenix', 'pinlight', 'reflect', 'screen', 'softlight', 'subtract', 'vividlight', 'xor', 'softdifference', 'geometric', 'harmonic', 'bleach', 'stain', 'interpolate', 'hardoverlay'] | Default

set component #0 blend mode (from 0 to 39) (default normal)

Default('normal')
c1_mode Int | Literal['addition', 'addition128', 'grainmerge', 'and', 'average', 'burn', 'darken', 'difference', 'difference128', 'grainextract', 'divide', 'dodge', 'exclusion', 'extremity', 'freeze', 'glow', 'hardlight', 'hardmix', 'heat', 'lighten', 'linearlight', 'multiply', 'multiply128', 'negation', 'normal', 'or', 'overlay', 'phoenix', 'pinlight', 'reflect', 'screen', 'softlight', 'subtract', 'vividlight', 'xor', 'softdifference', 'geometric', 'harmonic', 'bleach', 'stain', 'interpolate', 'hardoverlay'] | Default

set component #1 blend mode (from 0 to 39) (default normal)

Default('normal')
c2_mode Int | Literal['addition', 'addition128', 'grainmerge', 'and', 'average', 'burn', 'darken', 'difference', 'difference128', 'grainextract', 'divide', 'dodge', 'exclusion', 'extremity', 'freeze', 'glow', 'hardlight', 'hardmix', 'heat', 'lighten', 'linearlight', 'multiply', 'multiply128', 'negation', 'normal', 'or', 'overlay', 'phoenix', 'pinlight', 'reflect', 'screen', 'softlight', 'subtract', 'vividlight', 'xor', 'softdifference', 'geometric', 'harmonic', 'bleach', 'stain', 'interpolate', 'hardoverlay'] | Default

set component #2 blend mode (from 0 to 39) (default normal)

Default('normal')
c3_mode Int | Literal['addition', 'addition128', 'grainmerge', 'and', 'average', 'burn', 'darken', 'difference', 'difference128', 'grainextract', 'divide', 'dodge', 'exclusion', 'extremity', 'freeze', 'glow', 'hardlight', 'hardmix', 'heat', 'lighten', 'linearlight', 'multiply', 'multiply128', 'negation', 'normal', 'or', 'overlay', 'phoenix', 'pinlight', 'reflect', 'screen', 'softlight', 'subtract', 'vividlight', 'xor', 'softdifference', 'geometric', 'harmonic', 'bleach', 'stain', 'interpolate', 'hardoverlay'] | Default

set component #3 blend mode (from 0 to 39) (default normal)

Default('normal')
all_mode Int | Literal['addition', 'addition128', 'grainmerge', 'and', 'average', 'burn', 'darken', 'difference', 'difference128', 'grainextract', 'divide', 'dodge', 'exclusion', 'extremity', 'freeze', 'glow', 'hardlight', 'hardmix', 'heat', 'lighten', 'linearlight', 'multiply', 'multiply128', 'negation', 'normal', 'or', 'overlay', 'phoenix', 'pinlight', 'reflect', 'screen', 'softlight', 'subtract', 'vividlight', 'xor', 'softdifference', 'geometric', 'harmonic', 'bleach', 'stain', 'interpolate', 'hardoverlay'] | Default

set blend mode for all components (from -1 to 39) (default -1)

Default(-1)
c0_expr String

set color component #0 expression

Default(None)
c1_expr String

set color component #1 expression

Default(None)
c2_expr String

set color component #2 expression

Default(None)
c3_expr String

set color component #3 expression

Default(None)
all_expr String

set expression for all color components

Default(None)
c0_opacity Double

set color component #0 opacity (from 0 to 1) (default 1)

Default(1.0)
c1_opacity Double

set color component #1 opacity (from 0 to 1) (default 1)

Default(1.0)
c2_opacity Double

set color component #2 opacity (from 0 to 1) (default 1)

Default(1.0)
c3_opacity Double

set color component #3 opacity (from 0 to 1) (default 1)

Default(1.0)
all_opacity Double

set opacity for all color components (from 0 to 1) (default 1)

Default(1.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

telecine

telecine(
    *,
    first_field: (
        Int | Literal["top", "t", "bottom", "b"] | Default
    ) = Default("top"),
    pattern: String = Default("23"),
    **kwargs: Any
) -> VideoStream

Apply a telecine pattern.

Parameters:

Name Type Description Default
first_field Int | Literal['top', 't', 'bottom', 'b'] | Default

select first field (from 0 to 1) (default top)

Default('top')
pattern String

pattern that describe for how many fields a frame is to be displayed (default "23")

Default('23')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

thistogram

thistogram(
    *,
    width: Int = Default(0),
    display_mode: (
        Int
        | Literal["overlay", "parade", "stack"]
        | Default
    ) = Default("stack"),
    levels_mode: (
        Int | Literal["linear", "logarithmic"] | Default
    ) = Default("linear"),
    components: Int = Default(7),
    bgopacity: Float = Default(0.9),
    envelope: Boolean = Default(False),
    ecolor: Color = Default("gold"),
    slide: (
        Int
        | Literal[
            "frame",
            "replace",
            "scroll",
            "rscroll",
            "picture",
        ]
        | Default
    ) = Default("replace"),
    **kwargs: Any
) -> VideoStream

Compute and draw a temporal histogram.

Parameters:

Name Type Description Default
width Int

set width (from 0 to 8192) (default 0)

Default(0)
display_mode Int | Literal['overlay', 'parade', 'stack'] | Default

set display mode (from 0 to 2) (default stack)

Default('stack')
levels_mode Int | Literal['linear', 'logarithmic'] | Default

set levels mode (from 0 to 1) (default linear)

Default('linear')
components Int

set color components to display (from 1 to 15) (default 7)

Default(7)
bgopacity Float

set background opacity (from 0 to 1) (default 0.9)

Default(0.9)
envelope Boolean

display envelope (default false)

Default(False)
ecolor Color

set envelope color (default "gold")

Default('gold')
slide Int | Literal['frame', 'replace', 'scroll', 'rscroll', 'picture'] | Default

set slide mode (from 0 to 4) (default replace)

Default('replace')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

threshold

threshold(
    _threshold: VideoStream,
    _min: VideoStream,
    _max: VideoStream,
    *,
    planes: Int = Default(15),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Threshold first video stream using other video streams.

Parameters:

Name Type Description Default
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

thumbnail

thumbnail(
    *,
    n: Int = Default(100),
    log: (
        Int | Literal["quiet", "info", "verbose"] | Default
    ) = Default("info"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Select the most representative frame in a given sequence of consecutive frames.

Parameters:

Name Type Description Default
n Int

set the frames batch size (from 2 to INT_MAX) (default 100)

Default(100)
log Int | Literal['quiet', 'info', 'verbose'] | Default

force stats logging level (from INT_MIN to INT_MAX) (default info)

Default('info')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

tile

tile(
    *,
    layout: Image_size = Default("6x5"),
    nb_frames: Int = Default(0),
    margin: Int = Default(0),
    padding: Int = Default(0),
    color: Color = Default("black"),
    overlap: Int = Default(0),
    init_padding: Int = Default(0),
    **kwargs: Any
) -> VideoStream

Tile several successive frames together.

Parameters:

Name Type Description Default
layout Image_size

set grid size (default "6x5")

Default('6x5')
nb_frames Int

set maximum number of frame to render (from 0 to INT_MAX) (default 0)

Default(0)
margin Int

set outer border margin in pixels (from 0 to 1024) (default 0)

Default(0)
padding Int

set inner border thickness in pixels (from 0 to 1024) (default 0)

Default(0)
color Color

set the color of the unused area (default "black")

Default('black')
overlap Int

set how many frames to overlap for each render (from 0 to INT_MAX) (default 0)

Default(0)
init_padding Int

set how many frames to initially pad (from 0 to INT_MAX) (default 0)

Default(0)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

tinterlace

tinterlace(
    *,
    mode: (
        Int
        | Literal[
            "merge",
            "drop_even",
            "drop_odd",
            "pad",
            "interleave_top",
            "interleave_bottom",
            "interlacex2",
            "mergex2",
        ]
        | Default
    ) = Default("merge"),
    **kwargs: Any
) -> VideoStream

Perform temporal field interlacing.

Parameters:

Name Type Description Default
mode Int | Literal['merge', 'drop_even', 'drop_odd', 'pad', 'interleave_top', 'interleave_bottom', 'interlacex2', 'mergex2'] | Default

select interlace mode (from 0 to 7) (default merge)

Default('merge')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

tlut2

tlut2(
    *,
    c0: String = Default("x"),
    c1: String = Default("x"),
    c2: String = Default("x"),
    c3: String = Default("x"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Compute and apply a lookup table from two successive frames.

Parameters:

Name Type Description Default
c0 String

set component #0 expression (default "x")

Default('x')
c1 String

set component #1 expression (default "x")

Default('x')
c2 String

set component #2 expression (default "x")

Default('x')
c3 String

set component #3 expression (default "x")

Default('x')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

tmedian

tmedian(
    *,
    radius: Int = Default(1),
    planes: Int = Default(15),
    percentile: Float = Default(0.5),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Pick median pixels from successive frames.

Parameters:

Name Type Description Default
radius Int

set median filter radius (from 1 to 127) (default 1)

Default(1)
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
percentile Float

set percentile (from 0 to 1) (default 0.5)

Default(0.5)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

tmidequalizer

tmidequalizer(
    *,
    radius: Int = Default(5),
    sigma: Float = Default(0.5),
    planes: Int = Default(15),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply Temporal Midway Equalization.

Parameters:

Name Type Description Default
radius Int

set radius (from 1 to 127) (default 5)

Default(5)
sigma Float

set sigma (from 0 to 1) (default 0.5)

Default(0.5)
planes Int

set planes (from 0 to 15) (default 15)

Default(15)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

tmix

tmix(
    *,
    frames: Int = Default(3),
    weights: String = Default("1 1 1"),
    scale: Float = Default(0.0),
    planes: Flags = Default("F"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Mix successive video frames.

Parameters:

Name Type Description Default
frames Int

set number of successive frames to mix (from 1 to 1024) (default 3)

Default(3)
weights String

set weight for each frame (default "1 1 1")

Default('1 1 1')
scale Float

set scale (from 0 to 32767) (default 0)

Default(0.0)
planes Flags

set what planes to filter (default F)

Default('F')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

tonemap

tonemap(
    *,
    tonemap: (
        Int
        | Literal[
            "none",
            "linear",
            "gamma",
            "clip",
            "reinhard",
            "hable",
            "mobius",
        ]
        | Default
    ) = Default("none"),
    param: Double = Default("nan"),
    desat: Double = Default(2.0),
    peak: Double = Default(0.0),
    **kwargs: Any
) -> VideoStream

Conversion to/from different dynamic ranges.

Parameters:

Name Type Description Default
tonemap Int | Literal['none', 'linear', 'gamma', 'clip', 'reinhard', 'hable', 'mobius'] | Default

tonemap algorithm selection (from 0 to 6) (default none)

Default('none')
param Double

tonemap parameter (from DBL_MIN to DBL_MAX) (default nan)

Default('nan')
desat Double

desaturation strength (from 0 to DBL_MAX) (default 2)

Default(2.0)
peak Double

signal peak override (from 0 to DBL_MAX) (default 0)

Default(0.0)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

tpad

tpad(
    *,
    start: Int = Default(0),
    stop: Int = Default(0),
    start_mode: (
        Int | Literal["add", "clone"] | Default
    ) = Default("add"),
    stop_mode: (
        Int | Literal["add", "clone"] | Default
    ) = Default("add"),
    start_duration: Duration = Default(0.0),
    stop_duration: Duration = Default(0.0),
    color: Color = Default("black"),
    **kwargs: Any
) -> VideoStream

Temporarily pad video frames.

Parameters:

Name Type Description Default
start Int

set the number of frames to delay input (from 0 to INT_MAX) (default 0)

Default(0)
stop Int

set the number of frames to add after input finished (from -1 to INT_MAX) (default 0)

Default(0)
start_mode Int | Literal['add', 'clone'] | Default

set the mode of added frames to start (from 0 to 1) (default add)

Default('add')
stop_mode Int | Literal['add', 'clone'] | Default

set the mode of added frames to end (from 0 to 1) (default add)

Default('add')
start_duration Duration

set the duration to delay input (default 0)

Default(0.0)
stop_duration Duration

set the duration to pad input (default 0)

Default(0.0)
color Color

set the color of the added frames (default "black")

Default('black')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

transpose

transpose(
    *,
    dir: (
        Int
        | Literal[
            "cclock_flip", "clock", "cclock", "clock_flip"
        ]
        | Default
    ) = Default("cclock_flip"),
    passthrough: (
        Int
        | Literal["none", "portrait", "landscape"]
        | Default
    ) = Default("none"),
    **kwargs: Any
) -> VideoStream

Transpose input video.

Parameters:

Name Type Description Default
dir Int | Literal['cclock_flip', 'clock', 'cclock', 'clock_flip'] | Default

set transpose direction (from 0 to 7) (default cclock_flip)

Default('cclock_flip')
passthrough Int | Literal['none', 'portrait', 'landscape'] | Default

do not apply transposition if the input matches the specified geometry (from 0 to INT_MAX) (default none)

Default('none')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

trim

trim(
    *,
    start: Duration = Default("INT64_MAX"),
    end: Duration = Default("INT64_MAX"),
    start_pts: Int64 = Default("I64_MIN"),
    end_pts: Int64 = Default("I64_MIN"),
    duration: Duration = Default(0.0),
    start_frame: Int64 = Default(-1),
    end_frame: Int64 = Default("I64_MAX"),
    **kwargs: Any
) -> VideoStream

Pick one continuous section from the input, drop the rest.

Parameters:

Name Type Description Default
start Duration

Timestamp of the first frame that should be passed (default INT64_MAX)

Default('INT64_MAX')
end Duration

Timestamp of the first frame that should be dropped again (default INT64_MAX)

Default('INT64_MAX')
start_pts Int64

Timestamp of the first frame that should be passed (from I64_MIN to I64_MAX) (default I64_MIN)

Default('I64_MIN')
end_pts Int64

Timestamp of the first frame that should be dropped again (from I64_MIN to I64_MAX) (default I64_MIN)

Default('I64_MIN')
duration Duration

Maximum duration of the output (default 0)

Default(0.0)
start_frame Int64

Number of the first frame that should be passed to the output (from -1 to I64_MAX) (default -1)

Default(-1)
end_frame Int64

Number of the first frame that should be dropped again (from 0 to I64_MAX) (default I64_MAX)

Default('I64_MAX')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

unsharp

unsharp(
    *,
    luma_msize_x: Int = Default(5),
    luma_msize_y: Int = Default(5),
    luma_amount: Float = Default(1.0),
    chroma_msize_x: Int = Default(5),
    chroma_msize_y: Int = Default(5),
    chroma_amount: Float = Default(0.0),
    alpha_msize_x: Int = Default(5),
    alpha_msize_y: Int = Default(5),
    alpha_amount: Float = Default(0.0),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Sharpen or blur the input video.

Parameters:

Name Type Description Default
luma_msize_x Int

set luma matrix horizontal size (from 3 to 23) (default 5)

Default(5)
luma_msize_y Int

set luma matrix vertical size (from 3 to 23) (default 5)

Default(5)
luma_amount Float

set luma effect strength (from -2 to 5) (default 1)

Default(1.0)
chroma_msize_x Int

set chroma matrix horizontal size (from 3 to 23) (default 5)

Default(5)
chroma_msize_y Int

set chroma matrix vertical size (from 3 to 23) (default 5)

Default(5)
chroma_amount Float

set chroma effect strength (from -2 to 5) (default 0)

Default(0.0)
alpha_msize_x Int

set alpha matrix horizontal size (from 3 to 23) (default 5)

Default(5)
alpha_msize_y Int

set alpha matrix vertical size (from 3 to 23) (default 5)

Default(5)
alpha_amount Float

set alpha effect strength (from -2 to 5) (default 0)

Default(0.0)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

untile

untile(
    *, layout: Image_size = Default("6x5"), **kwargs: Any
) -> VideoStream

Untile a frame into a sequence of frames.

Parameters:

Name Type Description Default
layout Image_size

set grid size (default "6x5")

Default('6x5')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

v360

v360(
    *,
    input: (
        Int
        | Literal[
            "e",
            "equirect",
            "c3x2",
            "c6x1",
            "eac",
            "dfisheye",
            "flat",
            "rectilinear",
            "gnomonic",
            "barrel",
            "fb",
            "c1x6",
            "sg",
            "mercator",
            "ball",
            "hammer",
            "sinusoidal",
            "fisheye",
            "pannini",
            "cylindrical",
            "tetrahedron",
            "barrelsplit",
            "tsp",
            "hequirect",
            "he",
            "equisolid",
            "og",
            "octahedron",
            "cylindricalea",
        ]
        | Default
    ) = Default("e"),
    output: (
        Int
        | Literal[
            "e",
            "equirect",
            "c3x2",
            "c6x1",
            "eac",
            "dfisheye",
            "flat",
            "rectilinear",
            "gnomonic",
            "barrel",
            "fb",
            "c1x6",
            "sg",
            "mercator",
            "ball",
            "hammer",
            "sinusoidal",
            "fisheye",
            "pannini",
            "cylindrical",
            "perspective",
            "tetrahedron",
            "barrelsplit",
            "tsp",
            "hequirect",
            "he",
            "equisolid",
            "og",
            "octahedron",
            "cylindricalea",
        ]
        | Default
    ) = Default("c3x2"),
    interp: (
        Int
        | Literal[
            "near",
            "nearest",
            "line",
            "linear",
            "lagrange9",
            "cube",
            "cubic",
            "lanc",
            "lanczos",
            "sp16",
            "spline16",
            "gauss",
            "gaussian",
            "mitchell",
        ]
        | Default
    ) = Default("line"),
    w: Int = Default(0),
    h: Int = Default(0),
    in_stereo: (
        Int | Literal["2d", "sbs", "tb"] | Default
    ) = Default("2d"),
    out_stereo: (
        Int | Literal["2d", "sbs", "tb"] | Default
    ) = Default("2d"),
    in_forder: String = Default("rludfb"),
    out_forder: String = Default("rludfb"),
    in_frot: String = Default("000000"),
    out_frot: String = Default("000000"),
    in_pad: Float = Default(0.0),
    out_pad: Float = Default(0.0),
    fin_pad: Int = Default(0),
    fout_pad: Int = Default(0),
    yaw: Float = Default(0.0),
    pitch: Float = Default(0.0),
    roll: Float = Default(0.0),
    rorder: String = Default("ypr"),
    h_fov: Float = Default(0.0),
    v_fov: Float = Default(0.0),
    d_fov: Float = Default(0.0),
    h_flip: Boolean = Default(False),
    v_flip: Boolean = Default(False),
    d_flip: Boolean = Default(False),
    ih_flip: Boolean = Default(False),
    iv_flip: Boolean = Default(False),
    in_trans: Boolean = Default(False),
    out_trans: Boolean = Default(False),
    ih_fov: Float = Default(0.0),
    iv_fov: Float = Default(0.0),
    id_fov: Float = Default(0.0),
    h_offset: Float = Default(0.0),
    v_offset: Float = Default(0.0),
    alpha_mask: Boolean = Default(False),
    reset_rot: Boolean = Default(False),
    **kwargs: Any
) -> VideoStream

Convert 360 projection of video.

Parameters:

Name Type Description Default
input Int | Literal['e', 'equirect', 'c3x2', 'c6x1', 'eac', 'dfisheye', 'flat', 'rectilinear', 'gnomonic', 'barrel', 'fb', 'c1x6', 'sg', 'mercator', 'ball', 'hammer', 'sinusoidal', 'fisheye', 'pannini', 'cylindrical', 'tetrahedron', 'barrelsplit', 'tsp', 'hequirect', 'he', 'equisolid', 'og', 'octahedron', 'cylindricalea'] | Default

set input projection (from 0 to 24) (default e)

Default('e')
output Int | Literal['e', 'equirect', 'c3x2', 'c6x1', 'eac', 'dfisheye', 'flat', 'rectilinear', 'gnomonic', 'barrel', 'fb', 'c1x6', 'sg', 'mercator', 'ball', 'hammer', 'sinusoidal', 'fisheye', 'pannini', 'cylindrical', 'perspective', 'tetrahedron', 'barrelsplit', 'tsp', 'hequirect', 'he', 'equisolid', 'og', 'octahedron', 'cylindricalea'] | Default

set output projection (from 0 to 24) (default c3x2)

Default('c3x2')
interp Int | Literal['near', 'nearest', 'line', 'linear', 'lagrange9', 'cube', 'cubic', 'lanc', 'lanczos', 'sp16', 'spline16', 'gauss', 'gaussian', 'mitchell'] | Default

set interpolation method (from 0 to 7) (default line)

Default('line')
w Int

output width (from 0 to 32767) (default 0)

Default(0)
h Int

output height (from 0 to 32767) (default 0)

Default(0)
in_stereo Int | Literal['2d', 'sbs', 'tb'] | Default

input stereo format (from 0 to 2) (default 2d)

Default('2d')
out_stereo Int | Literal['2d', 'sbs', 'tb'] | Default

output stereo format (from 0 to 2) (default 2d)

Default('2d')
in_forder String

input cubemap face order (default "rludfb")

Default('rludfb')
out_forder String

output cubemap face order (default "rludfb")

Default('rludfb')
in_frot String

input cubemap face rotation (default "000000")

Default('000000')
out_frot String

output cubemap face rotation (default "000000")

Default('000000')
in_pad Float

percent input cubemap pads (from 0 to 0.1) (default 0)

Default(0.0)
out_pad Float

percent output cubemap pads (from 0 to 0.1) (default 0)

Default(0.0)
fin_pad Int

fixed input cubemap pads (from 0 to 100) (default 0)

Default(0)
fout_pad Int

fixed output cubemap pads (from 0 to 100) (default 0)

Default(0)
yaw Float

yaw rotation (from -180 to 180) (default 0)

Default(0.0)
pitch Float

pitch rotation (from -180 to 180) (default 0)

Default(0.0)
roll Float

roll rotation (from -180 to 180) (default 0)

Default(0.0)
rorder String

rotation order (default "ypr")

Default('ypr')
h_fov Float

output horizontal field of view (from 0 to 360) (default 0)

Default(0.0)
v_fov Float

output vertical field of view (from 0 to 360) (default 0)

Default(0.0)
d_fov Float

output diagonal field of view (from 0 to 360) (default 0)

Default(0.0)
h_flip Boolean

flip out video horizontally (default false)

Default(False)
v_flip Boolean

flip out video vertically (default false)

Default(False)
d_flip Boolean

flip out video indepth (default false)

Default(False)
ih_flip Boolean

flip in video horizontally (default false)

Default(False)
iv_flip Boolean

flip in video vertically (default false)

Default(False)
in_trans Boolean

transpose video input (default false)

Default(False)
out_trans Boolean

transpose video output (default false)

Default(False)
ih_fov Float

input horizontal field of view (from 0 to 360) (default 0)

Default(0.0)
iv_fov Float

input vertical field of view (from 0 to 360) (default 0)

Default(0.0)
id_fov Float

input diagonal field of view (from 0 to 360) (default 0)

Default(0.0)
h_offset Float

output horizontal off-axis offset (from -1 to 1) (default 0)

Default(0.0)
v_offset Float

output vertical off-axis offset (from -1 to 1) (default 0)

Default(0.0)
alpha_mask Boolean

build mask in alpha plane (default false)

Default(False)
reset_rot Boolean

reset rotation (default false)

Default(False)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

vaguedenoiser

vaguedenoiser(
    *,
    threshold: Float = Default(2.0),
    method: (
        Int | Literal["hard", "soft", "garrote"] | Default
    ) = Default("garrote"),
    nsteps: Int = Default(6),
    percent: Float = Default(85.0),
    planes: Int = Default(15),
    type: (
        Int | Literal["universal", "bayes"] | Default
    ) = Default("universal"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply a Wavelet based Denoiser.

Parameters:

Name Type Description Default
threshold Float

set filtering strength (from 0 to DBL_MAX) (default 2)

Default(2.0)
method Int | Literal['hard', 'soft', 'garrote'] | Default

set filtering method (from 0 to 2) (default garrote)

Default('garrote')
nsteps Int

set number of steps (from 1 to 32) (default 6)

Default(6)
percent Float

set percent of full denoising (from 0 to 100) (default 85)

Default(85.0)
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
type Int | Literal['universal', 'bayes'] | Default

set threshold type (from 0 to 1) (default universal)

Default('universal')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

varblur

varblur(
    _radius: VideoStream,
    *,
    min_r: Int = Default(0),
    max_r: Int = Default(8),
    planes: Int = Default(15),
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply Variable Blur filter.

Parameters:

Name Type Description Default
min_r Int

set min blur radius (from 0 to 254) (default 0)

Default(0)
max_r Int

set max blur radius (from 1 to 255) (default 8)

Default(8)
planes Int

set planes to filter (from 0 to 15) (default 15)

Default(15)
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

vectorscope

vectorscope(
    *,
    mode: (
        Int
        | Literal[
            "gray",
            "tint",
            "color",
            "color2",
            "color3",
            "color4",
            "color5",
        ]
        | Default
    ) = Default("gray"),
    x: Int = Default(1),
    y: Int = Default(2),
    intensity: Float = Default(0.004),
    envelope: (
        Int
        | Literal["none", "instant", "peak", "instant"]
        | Default
    ) = Default("none"),
    graticule: (
        Int
        | Literal["none", "green", "color", "invert"]
        | Default
    ) = Default("none"),
    opacity: Float = Default(0.75),
    flags: (
        Flags | Literal["white", "black", "name"] | Default
    ) = Default("name"),
    bgopacity: Float = Default(0.3),
    lthreshold: Float = Default(0.0),
    hthreshold: Float = Default(1.0),
    colorspace: (
        Int | Literal["auto", "601", "709"] | Default
    ) = Default("auto"),
    tint0: Float = Default(0.0),
    tint1: Float = Default(0.0),
    **kwargs: Any
) -> VideoStream

Video vectorscope.

Parameters:

Name Type Description Default
mode Int | Literal['gray', 'tint', 'color', 'color2', 'color3', 'color4', 'color5'] | Default

set vectorscope mode (from 0 to 5) (default gray)

Default('gray')
x Int

set color component on X axis (from 0 to 2) (default 1)

Default(1)
y Int

set color component on Y axis (from 0 to 2) (default 2)

Default(2)
intensity Float

set intensity (from 0 to 1) (default 0.004)

Default(0.004)
envelope Int | Literal['none', 'instant', 'peak', 'instant'] | Default

set envelope (from 0 to 3) (default none)

Default('none')
graticule Int | Literal['none', 'green', 'color', 'invert'] | Default

set graticule (from 0 to 3) (default none)

Default('none')
opacity Float

set graticule opacity (from 0 to 1) (default 0.75)

Default(0.75)
flags Flags | Literal['white', 'black', 'name'] | Default

set graticule flags (default name)

Default('name')
bgopacity Float

set background opacity (from 0 to 1) (default 0.3)

Default(0.3)
lthreshold Float

set low threshold (from 0 to 1) (default 0)

Default(0.0)
hthreshold Float

set high threshold (from 0 to 1) (default 1)

Default(1.0)
colorspace Int | Literal['auto', '601', '709'] | Default

set colorspace (from 0 to 2) (default auto)

Default('auto')
tint0 Float

set 1st tint (from -1 to 1) (default 0)

Default(0.0)
tint1 Float

set 2nd tint (from -1 to 1) (default 0)

Default(0.0)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

vfilter

vfilter(
    *streams: "FilterableStream",
    name: str,
    input_typings: tuple[StreamType, ...] = (
        StreamType.video
    ),
    **kwargs: Any
) -> "VideoStream"

Apply a custom video filter which has only one output to this stream

Parameters:

Name Type Description Default
*streams FilterableStream

the streams to apply the filter to

()
name str

the name of the filter

required
input_typings tuple[StreamType, ...]

the input typings

(video)
**kwargs Any

the arguments for the filter

{}

Returns:

Type Description
'VideoStream'

the output stream

vflip

vflip(
    *, enable: String = Default(None), **kwargs: Any
) -> VideoStream

Flip the input video vertically.

Parameters:

Name Type Description Default
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

vfrdet

vfrdet(**kwargs: Any) -> VideoStream

Variable frame rate detect filter.

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

vibrance

vibrance(
    *,
    intensity: Float = Default(0.0),
    rbal: Float = Default(1.0),
    gbal: Float = Default(1.0),
    bbal: Float = Default(1.0),
    rlum: Float = Default(0.072186),
    glum: Float = Default(0.715158),
    blum: Float = Default(0.212656),
    alternate: Boolean = Default(False),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Boost or alter saturation.

Parameters:

Name Type Description Default
intensity Float

set the intensity value (from -2 to 2) (default 0)

Default(0.0)
rbal Float

set the red balance value (from -10 to 10) (default 1)

Default(1.0)
gbal Float

set the green balance value (from -10 to 10) (default 1)

Default(1.0)
bbal Float

set the blue balance value (from -10 to 10) (default 1)

Default(1.0)
rlum Float

set the red luma coefficient (from 0 to 1) (default 0.072186)

Default(0.072186)
glum Float

set the green luma coefficient (from 0 to 1) (default 0.715158)

Default(0.715158)
blum Float

set the blue luma coefficient (from 0 to 1) (default 0.212656)

Default(0.212656)
alternate Boolean

use alternate colors (default false)

Default(False)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

vidstabdetect

vidstabdetect(
    *,
    result: String = Default("transforms.trf"),
    shakiness: Int = Default(5),
    accuracy: Int = Default(15),
    stepsize: Int = Default(6),
    mincontrast: Double = Default(0.25),
    show: Int = Default(0),
    tripod: Int = Default(0),
    **kwargs: Any
) -> VideoStream

Extract relative transformations, pass 1 of 2 for stabilization (see vidstabtransform for pass 2).

Parameters:

Name Type Description Default
result String

path to the file used to write the transforms (default "transforms.trf")

Default('transforms.trf')
shakiness Int

how shaky is the video and how quick is the camera? 1: little (fast) 10: very strong/quick (slow) (from 1 to 10) (default 5)

Default(5)
accuracy Int

(>=shakiness) 1: low 15: high (slow) (from 1 to 15) (default 15)

Default(15)
stepsize Int

region around minimum is scanned with 1 pixel resolution (from 1 to 32) (default 6)

Default(6)
mincontrast Double

below this contrast a field is discarded (0-1) (from 0 to 1) (default 0.25)

Default(0.25)
show Int

0: draw nothing; 1,2: show fields and transforms (from 0 to 2) (default 0)

Default(0)
tripod Int

virtual tripod mode (if >0): motion is compared to a reference reference frame (frame # is the value) (from 0 to INT_MAX) (default 0)

Default(0)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

vidstabtransform

vidstabtransform(
    *,
    input: String = Default("transforms.trf"),
    smoothing: Int = Default(15),
    optalgo: (
        Int | Literal["opt", "gauss", "avg"] | Default
    ) = Default("opt"),
    maxshift: Int = Default(-1),
    maxangle: Double = Default(-1.0),
    crop: (
        Int | Literal["keep", "black"] | Default
    ) = Default("keep"),
    invert: Int = Default(0),
    relative: Int = Default(1),
    zoom: Double = Default(0.0),
    optzoom: Int = Default(1),
    zoomspeed: Double = Default(0.25),
    interpol: (
        Int
        | Literal["no", "linear", "bilinear", "bicubic"]
        | Default
    ) = Default("bilinear"),
    tripod: Boolean = Default(False),
    debug: Boolean = Default(False),
    **kwargs: Any
) -> VideoStream

Transform the frames, pass 2 of 2 for stabilization (see vidstabdetect for pass 1).

Parameters:

Name Type Description Default
input String

set path to the file storing the transforms (default "transforms.trf")

Default('transforms.trf')
smoothing Int

set number of frames*2 + 1 used for lowpass filtering (from 0 to 1000) (default 15)

Default(15)
optalgo Int | Literal['opt', 'gauss', 'avg'] | Default

set camera path optimization algo (from 0 to 2) (default opt)

Default('opt')
maxshift Int

set maximal number of pixels to translate image (from -1 to 500) (default -1)

Default(-1)
maxangle Double

set maximal angle in rad to rotate image (from -1 to 3.14) (default -1)

Default(-1.0)
crop Int | Literal['keep', 'black'] | Default

set cropping mode (from 0 to 1) (default keep)

Default('keep')
invert Int

invert transforms (from 0 to 1) (default 0)

Default(0)
relative Int

consider transforms as relative (from 0 to 1) (default 1)

Default(1)
zoom Double

set percentage to zoom (>0: zoom in, <0: zoom out (from -100 to 100) (default 0)

Default(0.0)
optzoom Int

set optimal zoom (0: nothing, 1: optimal static zoom, 2: optimal dynamic zoom) (from 0 to 2) (default 1)

Default(1)
zoomspeed Double

for adative zoom: percent to zoom maximally each frame (from 0 to 5) (default 0.25)

Default(0.25)
interpol Int | Literal['no', 'linear', 'bilinear', 'bicubic'] | Default

set type of interpolation (from 0 to 3) (default bilinear)

Default('bilinear')
tripod Boolean

enable virtual tripod mode (same as relative=0:smoothing=0) (default false)

Default(False)
debug Boolean

enable debug mode and writer global motions information to file (default false)

Default(False)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

view

view(format: Literal['png', 'svg', 'dot'] = 'png') -> str

Visualize the stream.

Parameters:

Name Type Description Default
format Literal['png', 'svg', 'dot']

The format of the view.

'png'

Returns:

Type Description
str

The file path of the visualization.

vif

vif(
    _reference: VideoStream,
    *,
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Calculate the VIF between two video streams.

Parameters:

Name Type Description Default
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

vignette

vignette(
    *,
    angle: String = Default("PI/5"),
    x0: String = Default("w/2"),
    y0: String = Default("h/2"),
    mode: (
        Int | Literal["forward", "backward"] | Default
    ) = Default("forward"),
    eval: (
        Int | Literal["init", "frame"] | Default
    ) = Default("init"),
    dither: Boolean = Default(True),
    aspect: Rational = Default("1/1"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Make or reverse a vignette effect.

Parameters:

Name Type Description Default
angle String

set lens angle (default "PI/5")

Default('PI/5')
x0 String

set circle center position on x-axis (default "w/2")

Default('w/2')
y0 String

set circle center position on y-axis (default "h/2")

Default('h/2')
mode Int | Literal['forward', 'backward'] | Default

set forward/backward mode (from 0 to 1) (default forward)

Default('forward')
eval Int | Literal['init', 'frame'] | Default

specify when to evaluate expressions (from 0 to 1) (default init)

Default('init')
dither Boolean

set dithering (default true)

Default(True)
aspect Rational

set aspect ratio (from 0 to DBL_MAX) (default 1/1)

Default('1/1')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

vmafmotion

vmafmotion(
    *, stats_file: String = Default(None), **kwargs: Any
) -> VideoStream

Calculate the VMAF Motion score.

Parameters:

Name Type Description Default
stats_file String

Set file where to store per-frame difference information

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

w3fdif

w3fdif(
    *,
    filter: (
        Int | Literal["simple", "complex"] | Default
    ) = Default("complex"),
    mode: (
        Int | Literal["frame", "field"] | Default
    ) = Default("field"),
    parity: (
        Int | Literal["tff", "bff", "auto"] | Default
    ) = Default("auto"),
    deint: (
        Int | Literal["all", "interlaced"] | Default
    ) = Default("all"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Apply Martin Weston three field deinterlace.

Parameters:

Name Type Description Default
filter Int | Literal['simple', 'complex'] | Default

specify the filter (from 0 to 1) (default complex)

Default('complex')
mode Int | Literal['frame', 'field'] | Default

specify the interlacing mode (from 0 to 1) (default field)

Default('field')
parity Int | Literal['tff', 'bff', 'auto'] | Default

specify the assumed picture field parity (from -1 to 1) (default auto)

Default('auto')
deint Int | Literal['all', 'interlaced'] | Default

specify which frames to deinterlace (from 0 to 1) (default all)

Default('all')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

waveform

waveform(
    *,
    mode: (
        Int | Literal["row", "column"] | Default
    ) = Default("column"),
    intensity: Float = Default(0.04),
    mirror: Boolean = Default(True),
    display: (
        Int
        | Literal["overlay", "stack", "parade"]
        | Default
    ) = Default("stack"),
    components: Int = Default(1),
    envelope: (
        Int
        | Literal["none", "instant", "peak", "instant"]
        | Default
    ) = Default("none"),
    filter: (
        Int
        | Literal[
            "lowpass",
            "flat",
            "aflat",
            "chroma",
            "color",
            "acolor",
            "xflat",
            "yflat",
        ]
        | Default
    ) = Default("lowpass"),
    graticule: (
        Int
        | Literal["none", "green", "orange", "invert"]
        | Default
    ) = Default("none"),
    opacity: Float = Default(0.75),
    flags: (
        Flags | Literal["numbers", "dots"] | Default
    ) = Default("numbers"),
    scale: (
        Int
        | Literal["digital", "millivolts", "ire"]
        | Default
    ) = Default("digital"),
    bgopacity: Float = Default(0.75),
    tint0: Float = Default(0.0),
    tint1: Float = Default(0.0),
    fitmode: (
        Int | Literal["none", "size"] | Default
    ) = Default("none"),
    **kwargs: Any
) -> VideoStream

Video waveform monitor.

Parameters:

Name Type Description Default
mode Int | Literal['row', 'column'] | Default

set mode (from 0 to 1) (default column)

Default('column')
intensity Float

set intensity (from 0 to 1) (default 0.04)

Default(0.04)
mirror Boolean

set mirroring (default true)

Default(True)
display Int | Literal['overlay', 'stack', 'parade'] | Default

set display mode (from 0 to 2) (default stack)

Default('stack')
components Int

set components to display (from 1 to 15) (default 1)

Default(1)
envelope Int | Literal['none', 'instant', 'peak', 'instant'] | Default

set envelope to display (from 0 to 3) (default none)

Default('none')
filter Int | Literal['lowpass', 'flat', 'aflat', 'chroma', 'color', 'acolor', 'xflat', 'yflat'] | Default

set filter (from 0 to 7) (default lowpass)

Default('lowpass')
graticule Int | Literal['none', 'green', 'orange', 'invert'] | Default

set graticule (from 0 to 3) (default none)

Default('none')
opacity Float

set graticule opacity (from 0 to 1) (default 0.75)

Default(0.75)
flags Flags | Literal['numbers', 'dots'] | Default

set graticule flags (default numbers)

Default('numbers')
scale Int | Literal['digital', 'millivolts', 'ire'] | Default

set scale (from 0 to 2) (default digital)

Default('digital')
bgopacity Float

set background opacity (from 0 to 1) (default 0.75)

Default(0.75)
tint0 Float

set 1st tint (from -1 to 1) (default 0)

Default(0.0)
tint1 Float

set 2nd tint (from -1 to 1) (default 0)

Default(0.0)
fitmode Int | Literal['none', 'size'] | Default

set fit mode (from 0 to 1) (default none)

Default('none')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

weave

weave(
    *,
    first_field: (
        Int | Literal["top", "t", "bottom", "b"] | Default
    ) = Default("top"),
    **kwargs: Any
) -> VideoStream

Weave input video fields into frames.

Parameters:

Name Type Description Default
first_field Int | Literal['top', 't', 'bottom', 'b'] | Default

set first field (from 0 to 1) (default top)

Default('top')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

xbr

xbr(*, n: Int = Default(3), **kwargs: Any) -> VideoStream

Scale the input using xBR algorithm.

Parameters:

Name Type Description Default
n Int

set scale factor (from 2 to 4) (default 3)

Default(3)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

xcorrelate

xcorrelate(
    _secondary: VideoStream,
    *,
    planes: Int = Default(7),
    secondary: (
        Int | Literal["first", "all"] | Default
    ) = Default("all"),
    eof_action: (
        Int | Literal["repeat", "endall", "pass"] | Default
    ) = Default("repeat"),
    shortest: Boolean = Default(False),
    repeatlast: Boolean = Default(True),
    ts_sync_mode: (
        Int | Literal["default", "nearest"] | Default
    ) = Default("default"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Cross-correlate first video stream with second video stream.

Parameters:

Name Type Description Default
planes Int

set planes to cross-correlate (from 0 to 15) (default 7)

Default(7)
secondary Int | Literal['first', 'all'] | Default

when to process secondary frame (from 0 to 1) (default all)

Default('all')
eof_action Int | Literal['repeat', 'endall', 'pass'] | Default

Action to take when encountering EOF from secondary input (from 0 to 2) (default repeat)

Default('repeat')
shortest Boolean

force termination when the shortest input terminates (default false)

Default(False)
repeatlast Boolean

extend last frame of secondary streams beyond EOF (default true)

Default(True)
ts_sync_mode Int | Literal['default', 'nearest'] | Default

How strictly to sync streams based on secondary input timestamps (from 0 to 1) (default default)

Default('default')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

xfade

xfade(
    _xfade: VideoStream,
    *,
    transition: (
        Int
        | Literal[
            "custom",
            "fade",
            "wipeleft",
            "wiperight",
            "wipeup",
            "wipedown",
            "slideleft",
            "slideright",
            "slideup",
            "slidedown",
            "circlecrop",
            "rectcrop",
            "distance",
            "fadeblack",
            "fadewhite",
            "radial",
            "smoothleft",
            "smoothright",
            "smoothup",
            "smoothdown",
            "circleopen",
            "circleclose",
            "vertopen",
            "vertclose",
            "horzopen",
            "horzclose",
            "dissolve",
            "pixelize",
            "diagtl",
            "diagtr",
            "diagbl",
            "diagbr",
            "hlslice",
            "hrslice",
            "vuslice",
            "vdslice",
            "hblur",
            "fadegrays",
            "wipetl",
            "wipetr",
            "wipebl",
            "wipebr",
            "squeezeh",
            "squeezev",
            "zoomin",
            "fadefast",
            "fadeslow",
        ]
        | Default
    ) = Default("fade"),
    duration: Duration = Default(1.0),
    offset: Duration = Default(0.0),
    expr: String = Default(None),
    **kwargs: Any
) -> VideoStream

Cross fade one video with another video.

Parameters:

Name Type Description Default
transition Int | Literal['custom', 'fade', 'wipeleft', 'wiperight', 'wipeup', 'wipedown', 'slideleft', 'slideright', 'slideup', 'slidedown', 'circlecrop', 'rectcrop', 'distance', 'fadeblack', 'fadewhite', 'radial', 'smoothleft', 'smoothright', 'smoothup', 'smoothdown', 'circleopen', 'circleclose', 'vertopen', 'vertclose', 'horzopen', 'horzclose', 'dissolve', 'pixelize', 'diagtl', 'diagtr', 'diagbl', 'diagbr', 'hlslice', 'hrslice', 'vuslice', 'vdslice', 'hblur', 'fadegrays', 'wipetl', 'wipetr', 'wipebl', 'wipebr', 'squeezeh', 'squeezev', 'zoomin', 'fadefast', 'fadeslow'] | Default

set cross fade transition (from -1 to 45) (default fade)

Default('fade')
duration Duration

set cross fade duration (default 1)

Default(1.0)
offset Duration

set cross fade start relative to first input stream (default 0)

Default(0.0)
expr String

set expression for custom transition

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

yadif

yadif(
    *,
    mode: (
        Int
        | Literal[
            "send_frame",
            "send_field",
            "send_frame_nospatial",
            "send_field_nospatial",
        ]
        | Default
    ) = Default("send_frame"),
    parity: (
        Int | Literal["tff", "bff", "auto"] | Default
    ) = Default("auto"),
    deint: (
        Int | Literal["all", "interlaced"] | Default
    ) = Default("all"),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Deinterlace the input image.

Parameters:

Name Type Description Default
mode Int | Literal['send_frame', 'send_field', 'send_frame_nospatial', 'send_field_nospatial'] | Default

specify the interlacing mode (from 0 to 3) (default send_frame)

Default('send_frame')
parity Int | Literal['tff', 'bff', 'auto'] | Default

specify the assumed picture field parity (from -1 to 1) (default auto)

Default('auto')
deint Int | Literal['all', 'interlaced'] | Default

specify which frames to deinterlace (from 0 to 1) (default all)

Default('all')
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

yaepblur

yaepblur(
    *,
    radius: Int = Default(3),
    planes: Int = Default(1),
    sigma: Int = Default(128),
    enable: String = Default(None),
    **kwargs: Any
) -> VideoStream

Yet another edge preserving blur filter.

Parameters:

Name Type Description Default
radius Int

set window radius (from 0 to INT_MAX) (default 3)

Default(3)
planes Int

set planes to filter (from 0 to 15) (default 1)

Default(1)
sigma Int

set blur strength (from 1 to INT_MAX) (default 128)

Default(128)
enable String

timeline editing

Default(None)

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

zoompan

zoompan(
    *,
    zoom: String = Default("1"),
    x: String = Default("0"),
    y: String = Default("0"),
    d: String = Default("90"),
    s: Image_size = Default("hd720"),
    fps: Video_rate = Default("25"),
    **kwargs: Any
) -> VideoStream

Apply Zoom & Pan effect.

Parameters:

Name Type Description Default
zoom String

set the zoom expression (default "1")

Default('1')
x String

set the x expression (default "0")

Default('0')
y String

set the y expression (default "0")

Default('0')
d String

set the duration expression (default "90")

Default('90')
s Image_size

set the output image size (default "hd720")

Default('hd720')
fps Video_rate

set the output framerate (default "25")

Default('25')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation

zscale

zscale(
    *,
    w: String = Default(None),
    h: String = Default(None),
    size: String = Default(None),
    dither: (
        Int
        | Literal[
            "none", "ordered", "random", "error_diffusion"
        ]
        | Default
    ) = Default("none"),
    filter: (
        Int
        | Literal[
            "point",
            "bilinear",
            "bicubic",
            "spline16",
            "spline36",
            "lanczos",
        ]
        | Default
    ) = Default("bilinear"),
    out_range: (
        Int
        | Literal[
            "input",
            "limited",
            "full",
            "unknown",
            "tv",
            "pc",
        ]
        | Default
    ) = Default("input"),
    primaries: (
        Int
        | Literal[
            "input",
            "709",
            "unspecified",
            "170m",
            "240m",
            "2020",
            "unknown",
            "bt709",
            "bt470m",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "film",
            "bt2020",
            "smpte428",
            "smpte431",
            "smpte432",
            "p22",
            "ebu3213",
        ]
        | Default
    ) = Default("input"),
    transfer: (
        Int
        | Literal[
            "input",
            "709",
            "unspecified",
            "601",
            "linear",
            "2020_10",
            "2020_12",
            "unknown",
            "bt470m",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "bt709",
            "linear",
            "log100",
            "log316",
            "10",
            "12",
            "smpte2084",
            "4",
            "1",
            "b67",
        ]
        | Default
    ) = Default("input"),
    matrix: (
        Int
        | Literal[
            "input",
            "709",
            "unspecified",
            "470bg",
            "170m",
            "2020_ncl",
            "2020_cl",
            "unknown",
            "gbr",
            "bt709",
            "fcc",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "ycgco",
            "bt2020nc",
            "bt2020c",
            "nc",
            "c",
            "ictcp",
        ]
        | Default
    ) = Default("input"),
    in_range: (
        Int
        | Literal[
            "input",
            "limited",
            "full",
            "unknown",
            "tv",
            "pc",
        ]
        | Default
    ) = Default("input"),
    primariesin: (
        Int
        | Literal[
            "input",
            "709",
            "unspecified",
            "170m",
            "240m",
            "2020",
            "unknown",
            "bt709",
            "bt470m",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "film",
            "bt2020",
            "smpte428",
            "smpte431",
            "smpte432",
            "p22",
            "ebu3213",
        ]
        | Default
    ) = Default("input"),
    transferin: (
        Int
        | Literal[
            "input",
            "709",
            "unspecified",
            "601",
            "linear",
            "2020_10",
            "2020_12",
            "unknown",
            "bt470m",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "bt709",
            "linear",
            "log100",
            "log316",
            "10",
            "12",
            "smpte2084",
            "4",
            "1",
            "b67",
        ]
        | Default
    ) = Default("input"),
    matrixin: (
        Int
        | Literal[
            "input",
            "709",
            "unspecified",
            "470bg",
            "170m",
            "2020_ncl",
            "2020_cl",
            "unknown",
            "gbr",
            "bt709",
            "fcc",
            "bt470bg",
            "smpte170m",
            "smpte240m",
            "ycgco",
            "bt2020nc",
            "bt2020c",
            "nc",
            "c",
            "ictcp",
        ]
        | Default
    ) = Default("input"),
    chromal: (
        Int
        | Literal[
            "input",
            "left",
            "center",
            "topleft",
            "top",
            "bottomleft",
            "bottom",
        ]
        | Default
    ) = Default("input"),
    chromalin: (
        Int
        | Literal[
            "input",
            "left",
            "center",
            "topleft",
            "top",
            "bottomleft",
            "bottom",
        ]
        | Default
    ) = Default("input"),
    npl: Double = Default("nan"),
    agamma: Boolean = Default(True),
    param_a: Double = Default("nan"),
    param_b: Double = Default("nan"),
    **kwargs: Any
) -> VideoStream

Apply resizing, colorspace and bit depth conversion.

Parameters:

Name Type Description Default
w String

Output video width

Default(None)
h String

Output video height

Default(None)
size String

set video size

Default(None)
dither Int | Literal['none', 'ordered', 'random', 'error_diffusion'] | Default

set dither type (from 0 to 3) (default none)

Default('none')
filter Int | Literal['point', 'bilinear', 'bicubic', 'spline16', 'spline36', 'lanczos'] | Default

set filter type (from 0 to 5) (default bilinear)

Default('bilinear')
out_range Int | Literal['input', 'limited', 'full', 'unknown', 'tv', 'pc'] | Default

set color range (from -1 to 1) (default input)

Default('input')
primaries Int | Literal['input', '709', 'unspecified', '170m', '240m', '2020', 'unknown', 'bt709', 'bt470m', 'bt470bg', 'smpte170m', 'smpte240m', 'film', 'bt2020', 'smpte428', 'smpte431', 'smpte432', 'p22', 'ebu3213'] | Default

set color primaries (from -1 to INT_MAX) (default input)

Default('input')
transfer Int | Literal['input', '709', 'unspecified', '601', 'linear', '2020_10', '2020_12', 'unknown', 'bt470m', 'bt470bg', 'smpte170m', 'smpte240m', 'bt709', 'linear', 'log100', 'log316', '10', '12', 'smpte2084', '4', '1', 'b67'] | Default

set transfer characteristic (from -1 to INT_MAX) (default input)

Default('input')
matrix Int | Literal['input', '709', 'unspecified', '470bg', '170m', '2020_ncl', '2020_cl', 'unknown', 'gbr', 'bt709', 'fcc', 'bt470bg', 'smpte170m', 'smpte240m', 'ycgco', 'bt2020nc', 'bt2020c', 'nc', 'c', 'ictcp'] | Default

set colorspace matrix (from -1 to INT_MAX) (default input)

Default('input')
in_range Int | Literal['input', 'limited', 'full', 'unknown', 'tv', 'pc'] | Default

set input color range (from -1 to 1) (default input)

Default('input')
primariesin Int | Literal['input', '709', 'unspecified', '170m', '240m', '2020', 'unknown', 'bt709', 'bt470m', 'bt470bg', 'smpte170m', 'smpte240m', 'film', 'bt2020', 'smpte428', 'smpte431', 'smpte432', 'p22', 'ebu3213'] | Default

set input color primaries (from -1 to INT_MAX) (default input)

Default('input')
transferin Int | Literal['input', '709', 'unspecified', '601', 'linear', '2020_10', '2020_12', 'unknown', 'bt470m', 'bt470bg', 'smpte170m', 'smpte240m', 'bt709', 'linear', 'log100', 'log316', '10', '12', 'smpte2084', '4', '1', 'b67'] | Default

set input transfer characteristic (from -1 to INT_MAX) (default input)

Default('input')
matrixin Int | Literal['input', '709', 'unspecified', '470bg', '170m', '2020_ncl', '2020_cl', 'unknown', 'gbr', 'bt709', 'fcc', 'bt470bg', 'smpte170m', 'smpte240m', 'ycgco', 'bt2020nc', 'bt2020c', 'nc', 'c', 'ictcp'] | Default

set input colorspace matrix (from -1 to INT_MAX) (default input)

Default('input')
chromal Int | Literal['input', 'left', 'center', 'topleft', 'top', 'bottomleft', 'bottom'] | Default

set output chroma location (from -1 to 5) (default input)

Default('input')
chromalin Int | Literal['input', 'left', 'center', 'topleft', 'top', 'bottomleft', 'bottom'] | Default

set input chroma location (from -1 to 5) (default input)

Default('input')
npl Double

set nominal peak luminance (from 0 to DBL_MAX) (default nan)

Default('nan')
agamma Boolean

allow approximate gamma (default true)

Default(True)
param_a Double

parameter A, which is parameter "b" for bicubic, and the number of filter taps for lanczos (from -DBL_MAX to DBL_MAX) (default nan)

Default('nan')
param_b Double

parameter B, which is parameter "c" for bicubic (from -DBL_MAX to DBL_MAX) (default nan)

Default('nan')

Returns:

Name Type Description
default VideoStream

the video stream

References

FFmpeg Documentation