Nodes related to video workflows
Converts a video file into a series of images
Loads all image files from a subfolder. Options are similar to Load Video.
A path variant of Load Image sequence also exists.
Combines a series of images into an output video
If the optional audio input is provided, it will also be combined into the output video
subfolder/video
%date:yyyy-MM-ddThh:mm:ss%
might become 2023-10-31T6:45:25VHS_FILENAMES
which consists of a boolean indicating if save_output is enabled and a list of the full filepaths of all generated outputs in the order created. Accordingly output[1][-1]
will be the most complete output.Depending on the format chosen, additional options may become available, including
yuv420p10le
has higher color quality, but won't work on all devices
Provides a way to load standalone audio files.
A number of utility nodes exist for managing latents. For each, there is an equivalent node which works on images.
Divides the latents into two sets. The first split_index
latents go to ouput A and the remainder to output B. If less then split_index
latents are provided as input, all are passed to output A and output B is empty.
Combines two groups of latents into a single output. The order of the output is the latents in A followed by the latents in B.
If the input groups are not the same size, the node provides options for rescaling the latents before merging.
The first of every select_every_nth
input is passed and the remainder are discarded
Load Video (Upload), Load Video (Path), Load Images (Upload), Load Images (Path) and Video Combine provide animated previews.
Nodes with previews provide additional functionality when right clicked
Advanced Previews must be manually enabled by clicking the settings gear next to Queue Prompt and checking the box for VHS Advanced Previews.
If enabled, videos which are displayed in the ui will be converted with ffmpeg on request. This has several benefits
VHS_STRICT_PATHS
is set as an environment variable.This fucntionality is disabled since it comes with several downsides
Those familiar with ffmpeg are able to add json files to the video_formats folders to add new output types to Video Combine. Consider the following example for av1-webm
{
"main_pass":
[
"-n", "-c:v", "libsvtav1",
"-pix_fmt", "yuv420p10le",
"-crf", ["crf","INT", {"default": 23, "min": 0, "max": 100, "step": 1}]
],
"audio_pass": ["-c:a", "libopus"],
"extension": "webm",
"environment": {"SVT_LOG": "1"}
}
Most configuration takes place in main_pass
, which is a list of arguments that are passed to ffmpeg.
"-n"
designates that the command should fail if a file of the same name already exists. This should never happen, but if some bug were to occur, it would ensure other files aren't overwritten."-c:v", "libsvtav1"
designates that the video should be encoded with an av1 codec using the new SVT-AV1 encoder. SVT-AV1 is much faster than libaom-av1, but may not exist in older versions of ffmpeg. Alternatively, av1_nvenc could be used for gpu encoding with newer nvidia cards. "-pix_fmt", "yuv420p10le"
designates the standard pixel format with 10-bit color. It's important that some pixel format be specified to ensure a nonconfigurable input pix_fmt isn't used.audio pass
contains a list of arguments which are passed to ffmpeg when audio is passed into Video Combine
extension
designates both the file extension and the container format that is used. If some of the above options are omitted from main_pass
it can affect what default options are chosen.
environment
can optionally be provided to set environment variables during execution. For av1 it's used to reduce the verbosity of logging so that only major errors are displayed.
input_color_depth
effects the format in which pixels are passed to the ffmpeg subprocess. Current valid options are 8bit
and 16bit
. The later will produce higher quality output, but is experimental.
Fields can be exposed in the webui as a widget using a format similar to what is used in the creation of custom nodes. In the above example, the argument for -crf
will be exposed as a format widget in the webui. Format widgets are a list of up to 3 terms