Fix before chunking v2.0
ZZ
This commit is contained in:
+10
-1
@@ -1321,7 +1321,13 @@ def _extract_video_events(
|
||||
# end_on is None and marker_type == "narration": runs to end
|
||||
end_time = total_duration
|
||||
|
||||
# Filter by time range
|
||||
# Filter by time range.
|
||||
# CHUNKING v1 LIMITATION: this keeps only clips whose START is inside the
|
||||
# window, so a clip that began in an earlier chunk and is still playing
|
||||
# across the boundary is DROPPED here — the chunked output then differs from
|
||||
# a full render. cli._chunk_boundary_span_warnings surfaces this. The v2 fix
|
||||
# is overlap-inclusion + a per-event seek (skip_override); see
|
||||
# docs/chunking_v2.md.
|
||||
if start_time < range_start or start_time >= range_end:
|
||||
continue
|
||||
end_time = min(end_time, range_end)
|
||||
@@ -1361,6 +1367,9 @@ def _extract_audio_events(
|
||||
elif marker_id.startswith("audio:"):
|
||||
audio_id = marker_id[6:]
|
||||
if audio_id is not None and audio_id in audio:
|
||||
# CHUNKING v1 LIMITATION (same as video, worse for looping background
|
||||
# music): a clip started before the window is dropped from later chunks.
|
||||
# v2 = overlap-inclusion + audio seek; see docs/chunking_v2.md.
|
||||
if timing.timestamp < range_start or timing.timestamp >= range_end:
|
||||
continue
|
||||
start_time = max(0, timing.timestamp - AUDIO_OFFSET_SECONDS)
|
||||
|
||||
Reference in New Issue
Block a user