赞
踩
- import yt_dlp
- from comtypes.client import CreateObject
- import sys
-
-
- url = input("请输入网址:")
- ydl_opts = {
- 'outtmpl': 'videos/%(title)s.%(ext)s', # 下载的视频将被存储到videos文件夹,文件名为视频标题
- }
-
- with yt_dlp.YoutubeDL(ydl_opts) as ydl:
- ydl.download([url])
-
- print("视频下载成功!已保存在videos文件夹中")
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。