Skip to content
This repository has been archived by the owner on Jul 6, 2024. It is now read-only.

Commit

Permalink
fix: source_object_lengthがあるオブジェクトにobject_length: fitを指定できるよう修正
Browse files Browse the repository at this point in the history
  • Loading branch information
PigeonsHouse committed Dec 27, 2023
1 parent 66b4480 commit eccef3c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/converter/style_to_filter.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,15 @@ def object_length_filter(
"atrim",
end=audio_end,
)
elif object_length.unit == TimeUnit.FIT:
if video_process is not None:
video_process = ffmpeg.filter(
video_process, "loop", loop=-1, size=32767, start=0
)
if audio_process is not None:
audio_process = ffmpeg.filter(
audio_process, "aloop", loop=-1, size=2147483647, start=0
)
return video_process, audio_process


Expand Down
1 change: 1 addition & 0 deletions src/vsml.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ def element_to_content(
child_source_object_length = (
child_style.source_object_length.value
if child_style.source_object_length
and child_style.object_length.unit != TimeUnit.FIT
else 0.0
)
child_source_width = (
Expand Down

0 comments on commit eccef3c

Please sign in to comment.