This commit is contained in:
ZtRXR 2024-05-04 12:14:56 +08:00
parent 8697b83dc0
commit adb3c409ee

View File

@ -1,6 +1,7 @@
import os
from typing import Any
from PIL import Image
def convert_webp_to_png(webp_dir:str, png_dir:str,window)->None:
def convert_webp_to_png(webp_dir:str, png_dir:str,window:Any)->None:
# 获取目录中以.webp结尾的文件列表
webp_files = [f for f in os.listdir(webp_dir) if f.endswith('.webp')]
# 获取文件总数