bitstream-filters
Enums
BSF_ChromaLocation
Bases: IntEnum
Collection of known chroma sample location values.
For more documentation on these, check out the H265 Specification (Figure E.1) or JET Documentation.
Source code in .venv/lib/python3.11/site-packages/muxtools/helpers/bsf/bsf_generic.py
BSF_Matrix
Bases: IntEnum
Collection of known bitstream matrix values.
For more documentation on these, check out the H265 Specification (Table E.5) or JET Documentation.
Source code in .venv/lib/python3.11/site-packages/muxtools/helpers/bsf/bsf_generic.py
BSF_Transfer
Bases: IntEnum
Collection of known bitstream transfer values.
For more documentation on these, check out the H265 Specification (Table E.4) or JET Documentation.
Source code in .venv/lib/python3.11/site-packages/muxtools/helpers/bsf/bsf_generic.py
BSF_Primaries
Bases: IntEnum
Collection of known bitstream color primaries values.
For more documentation on these, check out the H265 Specification (Table E.3) or JET Documentation.
Source code in .venv/lib/python3.11/site-packages/muxtools/helpers/bsf/bsf_generic.py
BSF_Format
Bases: IntEnum
Collection of known bitstream video_format values.
For more documentation on these, check out the H265 Specification (Table E.2)
Source code in .venv/lib/python3.11/site-packages/muxtools/helpers/bsf/bsf_generic.py
Functions
apply_mpeg2_bsf(fileIn, dar=None, fps=None, format=None, primaries=None, transfer=None, matrix=None, quiet=True)
A helper for the FFMpeg mpeg2_metadata bitstream filter.
None
values will do nothing to the respective metadata flags.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
fileIn
|
PathLike
|
The file to modify |
required |
dar
|
MPEG2_DAR | str | None
|
Set the display aspect ratio in the stream |
None
|
fps
|
MPEG2_FPS | str | None
|
Set the frame rate in the stream |
None
|
format
|
BSF_Format | int | None
|
Set the video format in the stream |
None
|
primaries
|
BSF_Primaries | int | None
|
Set the color primaries in the stream |
None
|
transfer
|
BSF_Transfer | int | None
|
Set the transfer characteristics in the stream |
None
|
matrix
|
BSF_Matrix | int | None
|
Set the matrix coefficients in the stream |
None
|
quiet
|
bool
|
Suppresses the output of ffmpeg |
True
|
Source code in .venv/lib/python3.11/site-packages/muxtools/helpers/bsf/bsf_mpeg2.py
apply_avc_bsf(fileIn, sar=None, cloc_type=None, full_range=None, format=None, primaries=None, transfer=None, matrix=None, crop=None, quiet=True, **kwargs)
A helper for the FFMpeg h264_metadata bitstream filter.
None
values will do nothing to the respective metadata flags.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
fileIn
|
PathLike
|
The file to modify |
required |
sar
|
int | None
|
Set the sample aspect ratio in the stream |
None
|
cloc_type
|
BSF_ChromaLocation | int | None
|
Set the chroma sample location in the stream |
None
|
full_range
|
bool | int | None
|
Set the full range flag in the stream |
None
|
format
|
BSF_Format | int | None
|
Set the video format in the stream |
None
|
primaries
|
BSF_Primaries | int | None
|
Set the color primaries in the stream |
None
|
transfer
|
BSF_Transfer | int | None
|
Set the transfer characteristics in the stream |
None
|
matrix
|
BSF_Matrix | int | None
|
Set the matrix coefficients in the stream |
None
|
crop
|
int | tuple[int, int] | tuple[int, int, int, int] | None
|
Set the crop values in the stream |
None
|
quiet
|
bool
|
Suppresses the output of ffmpeg |
True
|
kwargs
|
bool | str
|
Additional options for the filter. For other available options, check the hyperlink to the filter above. |
{}
|
Source code in .venv/lib/python3.11/site-packages/muxtools/helpers/bsf/bsf_hevc_avc.py
apply_hevc_bsf(fileIn, sar=None, cloc_type=None, full_range=None, format=None, primaries=None, transfer=None, matrix=None, crop=None, quiet=True, **kwargs)
A helper for the FFMpeg hevc_metadata bitstream filter.
None
values will do nothing to the respective metadata flags.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
fileIn
|
PathLike
|
The file to modify |
required |
sar
|
int | None
|
Set the sample aspect ratio in the stream |
None
|
cloc_type
|
BSF_ChromaLocation | int | None
|
Set the chroma sample location in the stream |
None
|
full_range
|
bool | int | None
|
Set the full range flag in the stream |
None
|
format
|
BSF_Format | int | None
|
Set the video format in the stream |
None
|
primaries
|
BSF_Primaries | int | None
|
Set the color primaries in the stream |
None
|
transfer
|
BSF_Transfer | int | None
|
Set the transfer characteristics in the stream |
None
|
matrix
|
BSF_Matrix | int | None
|
Set the matrix coefficients in the stream |
None
|
crop
|
int | tuple[int, int] | tuple[int, int, int, int] | None
|
Set the crop values in the stream |
None
|
quiet
|
bool
|
Suppresses the output of ffmpeg |
True
|
kwargs
|
bool | str
|
Additional options for the filter. For available options, check the hyperlink to the filter above. |
{}
|