Convert RGB Video to UT Video Using FFmpeg
This article provides a quick and direct guide on how to convert an uncompressed RGB video sequence into the lossless UT Video format using the FFmpeg command-line tool. You will learn the precise command syntax to perform this conversion while preserving perfect color accuracy and alpha channels.
Converting a Video File
To convert an existing uncompressed RGB video file (such as an AVI or MOV) to the UT Video format, use the following FFmpeg command:
ffmpeg -i input_rgb.avi -c:v utvideo -pix_fmt gbrp output.aviCommand Breakdown: *
-i input_rgb.avi: Specifies the input
uncompressed RGB video file. *
-c:v utvideo: Selects the UT Video
encoder. * -pix_fmt gbrp: Sets the pixel
format to planar RGB (8-bit). This is crucial because it prevents FFmpeg
from converting your RGB source into a lossy YUV color space, preserving
mathematical losslessness. * output.avi:
The resulting UT Video file (commonly stored in an AVI or MKV
container).
Converting an Image Sequence (RGB)
If your uncompressed RGB sequence is a folder of raw images (such as BMP, PNG, or TIFF files), you can compile them directly into a UT Video file using this command:
ffmpeg -framerate 30 -i frame_%04d.png -c:v utvideo -pix_fmt gbrp output.mkvCommand Breakdown: *
-framerate 30: Sets the playback speed of
the output video to 30 frames per second. *
-i frame_%04d.png: Specifies the input
naming pattern (e.g., frame_0001.png, frame_0002.png). *
-pix_fmt gbrp: Forces the output to remain
in the RGB color space.
Handling Alpha Channels (RGBA)
If your uncompressed RGB source contains transparency (an alpha
channel) that you want to preserve, you must use the gbrap
pixel format instead:
ffmpeg -i input_rgba.mov -c:v utvideo -pix_fmt gbrap output.avigbrap: Stands for planar RGB with an Alpha channel, ensuring your transparency maps are encoded losslessly alongside the color data.