improve comment

Authored by: bashonly
pull/12714/head
bashonly 4 weeks ago
parent c7a4e8d578
commit b7780f6719
No known key found for this signature in database
GPG Key ID: 783F096F253D15B0

@ -2319,6 +2319,7 @@ class InfoExtractor:
# Some audio-only formats only have a GROUP-ID without any other quality/bitrate/codec info
# Each audio GROUP-ID corresponds with one or more video-only formats' AUDIO attribute
# For sorting purposes, set source_preference based on the quality of the video formats they are grouped with
# See https://github.com/yt-dlp/yt-dlp/issues/11178
audio_groups_by_quality = orderedSet(f['_audio_group_id'] for f in sorted(
traverse_obj(formats, lambda _, v: v.get('vcodec') != 'none' and v['_audio_group_id']),
key=lambda x: (x.get('tbr') or 0, x.get('width') or 0)))

Loading…
Cancel
Save