Skip to content

Commit

Permalink
Add type definitions for CodecContext properties
Browse files Browse the repository at this point in the history
Add type definitions for `options` and `time_base`.
  • Loading branch information
jlaine committed Jun 22, 2024
1 parent 6369e37 commit 96a0527
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion av/codec/context.pyi
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from fractions import Fraction
from typing import Any, Literal

from av.enum import EnumFlag, EnumItem
from av.frame import Frame
from av.packet import Packet

from .codec import Codec
Expand Down Expand Up @@ -60,8 +60,10 @@ class CodecContext:
is_encoder: bool
is_decoder: bool
name: str
options: dict[str, str]
type: Literal["video", "audio", "data", "subtitle", "attachment"]
profile: str | None
time_base: Fraction
codec_tag: str
bit_rate: int | None
max_bit_rate: int | None
Expand Down

0 comments on commit 96a0527

Please sign in to comment.