소스 검색

add image display test

ming 3 년 전
부모
커밋
72f209c4a6
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      OpenshotService/openshot_video_generator.py

+ 2 - 2
OpenshotService/openshot_video_generator.py

@@ -652,8 +652,8 @@ def video_gen(name_hash,name,text_content, image_urls,multiLang,avatar):
     img_dict_ls = tp.image_clip_info(sub_dict)
     #if 'image_idx' in dic:
     #            new_dic['image_obj'] = {'start':dic['start'],'idx':dic['image_idx']}
-    img_clip_list = [None]*len(text_content)
-    img_list = [None]*len(text_content)
+    img_clip_list = [None]*len(listdir(dir_photo+name_hash))
+    img_list = [None]*len(img_clip_list)
     for p in listdir(dir_photo+name_hash):
         img_list[idx] = openshot.FFmpegReader(dir_photo+name_hash+'/'+p)
         img_list[idx].Open()