Explorar o código

disable avatar by 18

ming %!s(int64=3) %!d(string=hai) anos
pai
achega
9e4cbd216d
Modificáronse 1 ficheiros con 4 adicións e 2 borrados
  1. 4 2
      OpenshotService/openshot_video_generator.py

+ 4 - 2
OpenshotService/openshot_video_generator.py

@@ -793,7 +793,9 @@ def anchor_video_v2(name_hash,name,text_content, image_urls,multiLang,avatar,fre
         anchor_list[idx].Open()
         anchor_clip_list[idx] = video_photo_clip(vid=anchor_list[idx],layer=4,scale_x=0.65,scale_y=0.65,
                 location_x=0.35,location_y=0.25,position=main_timer, end=clip_duration,ck=ck_anchor,audio=False)
-        t.AddClip(anchor_clip_list[idx])
+        if avatar==18:
+            t.AddClip(anchor_clip_list[idx])
+        audio_list[idx].Close()
 
         img_list[idx] = openshot.FFmpegReader(dir_photo+name_hash+'/'+p)
         img_list[idx].Open()
@@ -811,7 +813,7 @@ def anchor_video_v2(name_hash,name,text_content, image_urls,multiLang,avatar,fre
 
         img_list[idx].Close()
         anchor_list[idx].Close()
-        audio_list[idx].Close()
+        
             
         sub_img_list[idx] = [None] * len(sub_list[idx])
         sub_clip_list[idx] = [None] * len(sub_list[idx])