1
1
mirror of https://github.com/neosubhamoy/pytubepp.git synced 2025-12-19 08:53:01 +05:30

(fixed): non hdr higher fps videos showing lower fps 720p stream itag in short info

This commit is contained in:
2025-01-25 13:07:18 +05:30
parent 584aba0712
commit e4b662f352

View File

@@ -288,6 +288,12 @@ class YouTubeDownloader:
hdr_stream = self.stream.get_by_itag(hdr_itags.get(res))
matching_stream = hdr_stream if hdr_stream else self.stream.filter(res=res).first()
if res == '720p' and not hdr_stream:
high_fps_stream = self.stream.get_by_itag(298)
if high_fps_stream:
matching_stream = high_fps_stream
audio_stream = self.stream.get_by_itag(_select_suitable_audio_stream(matching_stream))
print(f"Selected: Video [{res} ({matching_stream.itag})] + Audio [{audio_stream.abr} ({audio_stream.itag})]{f' + Caption [{chosen_caption}]' if chosen_caption else ''}")