1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
|
from fractions import Fraction
from typing import Any
from av.audio.format import AudioFormat
from av.audio.frame import AudioFrame
from av.audio.layout import AudioLayout
from av.audio.stream import AudioStream
from av.video.format import VideoFormat
from av.video.frame import VideoFrame
from av.video.stream import VideoStream
from .context import FilterContext
from .filter import Filter
class Graph:
configured: bool
def __init__(self) -> None: ...
def configure(self, auto_buffer: bool = True, force: bool = False) -> None: ...
def link_nodes(self, *nodes: FilterContext) -> Graph: ...
def add(
self, filter: str | Filter, args: Any = None, **kwargs: str
) -> FilterContext: ...
def add_buffer(
self,
template: VideoStream | None = None,
width: int | None = None,
height: int | None = None,
format: VideoFormat | None = None,
name: str | None = None,
time_base: Fraction | None = None,
) -> FilterContext: ...
def add_abuffer(
self,
template: AudioStream | None = None,
sample_rate: int | None = None,
format: AudioFormat | str | None = None,
layout: AudioLayout | str | None = None,
channels: int | None = None,
name: str | None = None,
time_base: Fraction | None = None,
) -> FilterContext: ...
def set_audio_frame_size(self, frame_size: int) -> None: ...
def push(self, frame: None | AudioFrame | VideoFrame) -> None: ...
def pull(self) -> VideoFrame | AudioFrame: ...
def vpush(self, frame: VideoFrame | None) -> None: ...
def vpull(self) -> VideoFrame: ...
|