Skip to content

Commit

Permalink
feat: Use by default VP9 with mp4
Browse files Browse the repository at this point in the history
  • Loading branch information
avelad committed Nov 11, 2024
1 parent 172b65c commit 5dce50e
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions streamer/bitrate_configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,13 +109,8 @@ def get_ffmpeg_codec_string(self, hwaccel_api: str) -> str:

def get_output_format(self) -> str:
"""Returns an FFmpeg output format suitable for this codec."""
# TODO: consider VP9 in mp4 by default
# TODO(#31): add support for configurable output format per-codec
if self == VideoCodec.VP9:
return 'webm'
elif self in {VideoCodec.H264, VideoCodec.HEVC}:
return 'mp4'
elif self == VideoCodec.AV1:
# TODO(#31): add support for configurable output format per-codec (mp4 or webm)
elif self in {VideoCodec.H264, VideoCodec.VP9, VideoCodec.HEVC, VideoCodec.AV1}:
return 'mp4'
else:
assert False, 'No mapping for output format for codec {}'.format(
Expand Down

0 comments on commit 5dce50e

Please sign in to comment.