🎬🖼️AGSoft Images To Video From Dir
Slideshow straight from a folder — no image wiring at all
- audio
- video_path
- duration_seconds
- duration_timecode
- file_size_mb
- width
- height
- fps
- frames_est
🎬🖼️AGSoft Images To Video From Dir is the lazy version of the slideshow node, and I mean that as a compliment. Instead of wiring image inputs into the graph, you point it at a folder and it builds the video from whatever's inside. Same xfade transitions, same Ken Burns effect, same desync-proof voiceover - just with filesystem instead of wires.
This is the node to reach for when the images already exist as files: a batch of exported frames, a storyboard you generated elsewhere, or a folder of stills you want turned into a montage without dragging a hundred inputs onto the canvas. If you're re-rendering a project where the frames don't change, it's also much tidier than keeping the whole image pipeline alive.
How it works
folder_path points at the directory. The loader filters by extension via filter_type (*.*, *.png, *.jpg, *.jpeg, *.webp, *.bmp, *.gif, or custom), and custom_filter accepts multiple patterns - *.png, *.jpg or even a bare png jpg, which gets normalized to *.png. Files are naturally sorted, and you can narrow the selection with start_index / end_index (0-based, end_index 0 = to the end) and cap it with max_images (0 = all).
From there it's the same engine as the socket-based version: each slide shows image_duration seconds, joined by transition_type over transition_duration, optional ken_burns zoom/pan (kb_motion, kb_zoom_start/kb_zoom_end), and resize_mode/fit_mode/custom_width/custom_height for output sizing.
The voiceover has a nice split personality: audio_path takes a direct file path (priority), or you can connect the audio AUDIO socket instead. Either way the video renders first and the audio is aligned to its real length in a fast second pass (video copied, not re-encoded), so you don't get the classic trailing-silence or desync problems.
The inputs that matter
folder_path+filter_type- where the images are and what counts as an image.start_index/end_index/max_images- grabbing a specific run of frames.- Everything else is the slideshow controls you know from the sibling node:
image_duration,transition_type,ken_burns,encoder_mode.
Outputs
The standard set: video_path (STRING), duration_seconds, duration_timecode, file_size_mb, width, height, fps, frames_est. Empty output_path → ComfyUI/output.
Install
Part of the comfyui-AGSoft pack. ComfyUI Manager → search "comfyui-AGSoft" → Install → restart, or:
cd ComfyUI/custom_nodes
git clone https://github.com/Art-xmaster/comfyui-AGSoft
Restart. No models, no heavy deps - it drives ComfyUI's bundled FFmpeg (or a system ffmpeg on PATH).
The one thing to double-check: start_index is 0-based and the sort is natural, so frame_10 comes after frame_9 (not after frame_1). If your slides come out in the wrong order, that's usually a naming scheme issue, not the node.
Inputs (28)
| Name | Type | Default | Description |
|---|---|---|---|
| output_name | STRING | slideshow.mp4 | Output filename. The extension is kept as entered (.mp4 by default). --- Имя итогового файла. Расширение сохраняется как введено (по умолчанию .mp4). |
| output_path | STRING | Output directory. If empty, ComfyUI/output is used. --- Папка сохранения. Если пусто, используется ComfyUI/output. | |
| folder_path | STRING | Path to the folder with images. --- Путь к папке с изображениями. | |
| audio_path | STRING | Optional direct path to an audio file (e.g. C:/temp/sample.mp3). If set and the file exists, it is used as the voiceover and takes priority over the AUDIO socket. Leave empty to ignore (then the AUDIO socket is used if connected). --- Опционально: прямой путь к аудиофайлу (например C:/temp/sample.mp3). Если задан и файл существует, он используется как озвучка и имеет приоритет над сокетом AUDIO. Оставьте пустым, чтобы игнорировать (тогда используется сокет AUDIO, если подключён). | |
| filter_type | COMBO | *.png | File extension filter. *.* = all files. custom = use custom_filter. --- Фильтр по расширению. *.* = все файлы. custom = использовать custom_filter. |
| custom_filter | STRING | *.png, *.jpg | Used when filter_type='custom'. One or more patterns separated by comma/semicolon/space. Examples: '*.png, *.jpg' or 'png jpg' or '*.webp'. A bare extension (png) becomes *.png. --- Используется при filter_type='custom'. Один или несколько паттернов через запятую/точку с запятой/пробел. Примеры: '*.png, *.jpg' или 'png jpg' или '*.webp'. Расширение без точки (png) превращается в *.png. |
| start_index | INT | 00–999999 | First file index (0-based, inclusive) in the sorted list. --- Индекс первого файла (с 0, включительно) в отсортированном списке. |
| end_index | INT | 00–999999 | Last file index (inclusive). 0 = to the end of the list. --- Индекс последнего файла (включительно). 0 = до конца списка. |
| max_images | INT | 00–999999 | Maximum number of images to use (from the selected range). 0 = all. --- Максимум изображений для видео (из выбранного диапазона). 0 = все. |
| image_duration | FLOAT | 3.00.1–60 | Display duration of each slide in seconds (global for all slides). --- Длительность показа каждого слайда в секундах (глобально для всех слайдов). |
| output_fps | COMBO | 30 | Output frame rate. --- Частота кадров результата. |
| resize_mode | COMBO | first_image | How to choose the output resolution. first_image = first image size. max_size/min_size = extremes. custom = custom_width/height. --- Как выбирать разрешение результата. first_image = по первому изображению. max_size/min_size = экстремумы. custom = вручную. |
| fit_mode | COMBO | letterbox | letterbox = fit with black bars. crop = fill and crop center. stretch = stretch. --- letterbox = вписать с чёрными полосами. crop = заполнить и обрезать центр. stretch = растянуть. |
| custom_width | INT | 00–8192 | Custom width for resize_mode=custom. 0 = fallback. |
| custom_height | INT | 00–8192 | Custom height for resize_mode=custom. 0 = fallback. |
| transition_type | COMBO | fade | Transition type between slides. cut = hard cut. random = random per junction. --- Тип перехода между слайдами. cut = жёсткая склейка. random = случайный на каждом стыке. |
| transition_duration | FLOAT | 0.80–10 | Transition duration in seconds. 0 = cut mode. Clamped if longer than a slide. --- Длительность перехода в секундах. 0 = режим cut. Ограничивается, если длиннее слайда. |
| ken_burns | COMBO | off | Enable Ken Burns (smooth zoom/pan) on the static slides. --- Включить Ken Burns (плавный zoom/pan) на статичных слайдах. |
| kb_motion | COMBO | in | Ken Burns motion. in/out = zoom in/out; pan_* = panning; random = random per slide. --- Движение Ken Burns. in/out = наезд/отъезд; pan_* = панорама; random = случайно на каждый слайд. |
| kb_zoom_start | FLOAT | 1.001–3 | Ken Burns start zoom (1.0 = no zoom). For pan modes a minimum of 1.2 is enforced. --- Начальный зум Ken Burns (1.0 = без зума). Для pan принудительно не меньше 1.2. |
| kb_zoom_end | FLOAT | 1.301–3 | Ken Burns end zoom (used by in/out motions). --- Конечный зум Ken Burns (для движений in/out). |
| audio_mode | COMBO | fit | fit = trim audio or pad with silence to match the video length. loop = repeat the audio track across the whole video length. --- fit = обрезать аудио или добить тишиной под длину видео. loop = зациклить трек на всю длину видео. |
| audio_volume | FLOAT | 1.000–2 | Voiceover volume multiplier. 1.0 = original. --- Множитель громкости озвучки. 1.0 = оригинал. |
| audio_fade_in | FLOAT | 0.00–60 | Voiceover fade-in in seconds. / Появление озвучки в секундах. |
| audio_fade_out | FLOAT | 0.00–60 | Voiceover fade-out in seconds. / Затухание озвучки в секундах. |
| encoder_mode | COMBO | auto | auto = NVENC if available, otherwise CPU. nvenc = force NVENC. cpu = force libx264. --- auto = NVENC, если доступен, иначе CPU. nvenc = принудительно NVENC. cpu = принудительно libx264. |
| quality_preset | COMBO | balanced | Encoding quality preset. / Пресет качества кодирования. |
| audioopt | AUDIO | Optional voiceover from Load Audio. Used only if audio_path is empty/invalid. If neither is provided, the output has no audio. --- Опциональная озвучка из Load Audio. Используется, только если audio_path пуст/неверен. Если не задано ни то, ни другое — выход без звука. |
Outputs (8)
| Name | Type | Description |
|---|---|---|
| video_path | STRING | — |
| duration_seconds | FLOAT | — |
| duration_timecode | STRING | — |
| file_size_mb | FLOAT | — |
| width | INT | — |
| height | INT | — |
| fps | FLOAT | — |
| frames_est | INT | — |