Compare commits
2
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
814c64cc52 | ||
|
|
c17ccb6563 |
@@ -153,6 +153,8 @@ def cut_recording(media: PreparedMedia, options: ProcessingOptions,
|
|||||||
except InvalidMediaError:
|
except InvalidMediaError:
|
||||||
raise InvalidMediaError("Impossible to retrieve timestamp of final i-frame.")
|
raise InvalidMediaError("Impossible to retrieve timestamp of final i-frame.")
|
||||||
|
|
||||||
|
assert head_iframe_ts <= tail_iframe_ts
|
||||||
|
|
||||||
checks.append(pos+head_iframe_ts-ts1)
|
checks.append(pos+head_iframe_ts-ts1)
|
||||||
|
|
||||||
subparts = []
|
subparts = []
|
||||||
@@ -199,6 +201,8 @@ def cut_recording(media: PreparedMedia, options: ProcessingOptions,
|
|||||||
if h264_head_ts is not None:
|
if h264_head_ts is not None:
|
||||||
h264_ts.append(h264_head_ts)
|
h264_ts.append(h264_head_ts)
|
||||||
|
|
||||||
|
if head_iframe_ts < tail_iframe_ts:
|
||||||
|
|
||||||
# Creating MKV file that corresponds to current part between I-frames
|
# Creating MKV file that corresponds to current part between I-frames
|
||||||
# Internal video with all streams (video, audio and subtitles)
|
# Internal video with all streams (video, audio and subtitles)
|
||||||
internal_mkv_name = f'part-{partnum:d}-internal.mkv'
|
internal_mkv_name = f'part-{partnum:d}-internal.mkv'
|
||||||
|
|||||||
@@ -241,7 +241,7 @@ def extract_all_streams(ffmpeg_path:str, ffprobe_path:str, input_file:IO[bytes],
|
|||||||
video_codec_params.extend([f'-c:v:{video_id:d}', codec, f'-level:v:{video_id:d}',
|
video_codec_params.extend([f'-c:v:{video_id:d}', codec, f'-level:v:{video_id:d}',
|
||||||
level, '-pix_fmt', pixel_format])
|
level, '-pix_fmt', pixel_format])
|
||||||
video_codec_params.extend(interlaced_options)
|
video_codec_params.extend(interlaced_options)
|
||||||
video_codec_params.extend([f'-colorspace:v:{video_id}', color_space,
|
video_codec_params.extend([f'-colorspace:v:{video_id:d}', color_space,
|
||||||
f'-color_primaries:v:{video_id:d}', color_primaries,
|
f'-color_primaries:v:{video_id:d}', color_primaries,
|
||||||
f'-color_trc:v:{video_id:d}', color_transfer,
|
f'-color_trc:v:{video_id:d}', color_transfer,
|
||||||
f'-color_range:v:{video_id:d}', color_range])
|
f'-color_range:v:{video_id:d}', color_range])
|
||||||
|
|||||||
Reference in New Issue
Block a user