fix episode restore

This commit is contained in:
“christopheseux”
2023-05-04 12:24:48 +02:00
parent 706fcb2ee1
commit 2d24e3da7f
2 changed files with 18 additions and 3 deletions
+10 -3
View File
@@ -116,9 +116,10 @@ class VSETB_OT_set_sequencer(Operator):
scn = context.scene
set_channels()
movie = get_strips(channel='Movie')
if movie:
movie = movie[0]
movies = get_strips(channel='Movie')
movie = None
if movies:
movie = movies[0]
movie.transform.scale_x = movie.transform.scale_y = 1
elem = movie.strip_elem_from_frame(scn.frame_current)
scn.render.resolution_x = elem.orig_width
@@ -135,6 +136,12 @@ class VSETB_OT_set_sequencer(Operator):
scn.render.ffmpeg.audio_codec = 'MP3'
scn.render.ffmpeg.audio_mixrate = 44100
scn.render.ffmpeg.audio_bitrate = 128
shots = get_strips(channel='Shots')
if shots:
scn.frame_end = shots[-1].frame_final_end -1
elif movie:
scn.frame_end = movie.frame_final_end -1
return {"FINISHED"}