Houdini 18.5 Nodes TOP nodes

FFmpeg Encode Video TOP node

Encodes a sequence of still images as a video file.

On this page
Since 17.5

Note

For information about the opposite operation of extracting frame images from a video, see the FFmpeg extract images node documentation.

Installation

This node is a wrapper around the ffmpeg command line tool. For this node to work, you must have FFmpeg installed on each of your machines.

For the node to find the FFmpeg command line tool, the path to the tool’s executable binary must be available via one of the following methods:

  • The system path.

  • Specified in an environment variable PDG_FFMPEG.

  • Specified directly in the node by the FFmpeg Binary Path parameter.

Tip

The $HH/help/files/pdg_examples/top_multishot and $HH/help/files/pdg_examples/top_rop examples show how you can use this node to create a movie from rendered images.

TOP Attributes

fps

integer

The frames per second of the output video.

Parameters

Node

Generate When

Determines when this node will generate work items. You should generally leave this set to "Automatic" unless you know the node requires a specific generation mode, or that the work items need to be generated dynamically.

All Upstream Items are Generated

This node will generate work items once all of the input nodes have generated their work items.

All Upstream Items are Cooked

This node will generate work items once all of the input nodes have cooked their work items.

Each Upstream Item is Cooked

This node will generate work items each time a work item in an input node is cooked.

Automatic

The generation mode is selected based on the generation mode of the input nodes. If any of the input nodes are generating work items when their inputs cook, this node will be set to Each Upstream Item is Cooked. Otherwise, it will be set to All Upstream Items are Generated.

Cache Mode

How the processor node handles work items that report expected file results.

Automatic

If the expected result file exists on disk, the work item is marked as cooked without being scheduled. If the file does not exist, the item is scheduled as normal.

Read Files

If the expected result file exists on disk, the work item is marked as cooked without being scheduled. Otherwise the work item is marked as failed.

Write Files

Work items are always scheduled and the excepted result file is ignored, even if it exists on disk.

Tool Presets

Sets of pre-defined FFmpeg operations (presets) that automatically configure the node’s parameters and the FFmpeg command.

Create Video From Images

Allows you to create a video from a set of input images.

Convert File Format

Allows you to perform simple conversion operations. For example, like converting an audio or video file.

Convert Audio or Video File

Allows you to perform more complex conversion operations. For example, like changing the format of a video file and also changing its resolution.

Input

Input Source

Specifies the input source.

Upstream Output Images

Sets the input as the output files from the upstream work item with the tag specified by the File Tag parameter.

Upstream Output File

Sets the input as the first output file from the upstream work item with the tag specified by the File Tag parameter.

Custom File Path

Sets the input as the file path specified by the File Path parameter.

File Tag

Specifies the file tag of the input source.

This parameter is only available when Input Source is not set to Custom File Path.

File Path

Specifies the file path to the input source.

This parameter is only available when Input Source is set to Custom File Path.

Frame List File

The file path to the frame list file. The frame list file is a text file that contains an ordered list of all the input images that are used to construct the video.

FFmpeg requires that the paths of the images in this file are specified as relative paths. On Windows, that is why the frame list file must be placed on the same drive as the input images.

This parameter is only available when Input Source is set to Upstream Output Images.

Output

Output File Path

Specifies the file path of the output video.

File Tag

Specifies the file tag of the output video.

Options

Frames Per Second

When on, specifies the frames per second of the encoded video file.

Format

When on, specifies the value of the FFmpeg -f argument.

Size

When on, specifies the value of the FFmpeg -s argument.

-apply_trc

When on, specifies the value of the FFmpeg -apply_trc argument.

Video Codec

When on, specifies the value of the FFmpeg -c:v argument.

-movflags

When on, specifies the value of the FFmpeg -movflags argument.

Pixel Format

When on, specifies the pixel format.

FFmpeg

FFmpeg Binary

Determines how FFmpeg is called.

System Path

Calls FFmpeg from the system path (if available).

$PDG_FFMPEG

Calls FFmpeg using the path stored in the PDG_FFMPEG environment variable. This environment variable must be user-created.

Custom Path

Calls the FFmpeg binary using the path specified by the FFmpeg Binary Path parameter.

FFmpeg Binary Path

Specifies the path to the FFmpeg binary.

This parameter is only available when FFmpeg Binary is set to Custom Path.

FFmpeg Command

When on, specifies the FFmpeg command that is called when the work item cooks. You can modify this command, but it will not automatically update if the other parameters change.

Schedulers

TOP Scheduler Override

This parameter overrides the TOP scheduler for this node.

Work Item Priority

This parameter determines how the current scheduler prioritizes the work items in this node.

Inherit From Upstream Item

The work items inherit their priority from their parent items. If a work item has no parent, its priority is set to 0.

Custom Expression

The work item priority is set to the value of Priority Expression.

Node Defines Priority

The work item priority is set based on the node’s own internal priority calculations.

This option is only available on the Python Processor TOP, ROP Fetch TOP, and ROP Output TOP nodes. These nodes define their own prioritization schemes that are implemented in their node logic.

Priority Expression

This parameter specifies an expression for work item priority. The expression is evaluated for each work item in the node.

This parameter is only available when Work Item Priority is set to Custom Expression.

Examples

example_top_ffmpegencodevideo Example for FFmpeg Encode Video TOP node

This example demonstrates how to use FFmpeg Encode Video node to encode a sequence of images into a video file.

See also

TOP nodes