extract_frames_from_video
Extract frames from a video at specified intervals or total count, saving them in PNG, JPG, or WebP formats. Ideal for creating still images, thumbnails, or analyzing video content.
Instructions
提取视频中的图像。
参数:
video_path(str) - 视频路径。
fps(int) - 每多少秒抽一帧,如果传0,代表全部都抽,传1,代表每一秒抽1帧。
output_folder(str) - 把图片输出到哪个目录
format(int) - 抽取的图片格式,0:代表png 1:jpg 2:webp
total_frames(int) - 最多抽取多少张,0代表不限制
Input Schema
Name | Required | Description | Default |
---|---|---|---|
format | No | ||
fps | No | ||
output_folder | No | ||
total_frames | No | ||
video_path | Yes |
Input Schema (JSON Schema)
{
"properties": {
"format": {
"default": 0,
"title": "format",
"type": "string"
},
"fps": {
"default": 0,
"title": "fps",
"type": "string"
},
"output_folder": {
"default": null,
"title": "output_folder",
"type": "string"
},
"total_frames": {
"default": 0,
"title": "total_frames",
"type": "string"
},
"video_path": {
"title": "video_path",
"type": "string"
}
},
"required": [
"video_path"
],
"title": "extract_frames_from_videoArguments",
"type": "object"
}