Cineform HD

From wiki.selur.net
Jump to navigation Jump to search

Cineform HD (GoPro CineForm, standardised as SMPTE VC-5) is a wavelet-based intra-frame intermediate codec for editing and archiving of camera material. It works with 10-bit 4:2:2 or 12-bit RGB and is visually lossless at its higher quality steps. Hybrid encodes it with ffmpeg's cfhd encoder.

Base → Video: Cineform HD, then the Cineform HD tab

Cineform HD tab in Hybrid
Cineform HD tab in Hybrid

What it does

CineForm transforms every frame on its own with a wavelet transform and quantizes the resulting bands; how coarse is set by the quality step. There is no prediction between frames, so every frame is a key frame and editing software can cut anywhere. There is no bit rate setting: the size results from the quality step and the content, and is large compared to delivery codecs.

Requirements

ffmpeg, which is part of Hybrid on every system. Hybrid only accepts MOV and AVI as output container for Cineform HD; with another container the job is refused.

Settings

Control ffmpeg option Range / values Hybrid default Meaning
Quality -quality Film Scan 3+, Film Scan 3, Film Scan 2+, Film Scan 2, Film Scan 1.5, Film Scan 1+, Film Scan 1, High+, High, Medium+, Medium, Low+, Low Film Scan 3+ Quality step, from the best and largest (Film Scan 3+, -quality 0) down to the smallest (Low, -quality 12). The Film Scan steps are meant for mastering and archiving, High and Medium for editing, Low for proxies.
Color Space -pix_fmt, -vf scale,format= i422, GBR i422 Color format of the output: i422 is 10-bit YUV 4:2:2 (yuv422p10le), GBR is 12-bit RGB (gbrp12le). The bit depth follows from the choice. Use GBR for RGB or 4:4:4 sources that should keep their full chroma resolution.

The Configuration row at the bottom saves, loads and deletes named sets of these settings.

Example

Quality Film Scan 3+ and color space i422 on a 10-bit YUV 4:2:0 source (640x352, 25 fps); Hybrid converts the video to 10-bit 4:2:2 in the script:

vspipe "encodingTempSynthSkript.vpy" - --outputindex 0 -c y4m --progress | ffmpeg -y -noautorotate -nostdin -threads 8 -color_primaries bt470bg -color_trc smpte170m -colorspace bt470bg -color_range tv -f yuv4mpegpipe -i - -an -sn -color_primaries bt470bg -color_trc smpte170m -colorspace bt470bg -color_range tv -strict -1 -fps_mode auto -r 25/1 -vcodec cfhd -quality 0 -vf scale,format=yuv422p10le -pix_fmt yuv422p10le -metadata encoding_tool="Hybrid 2026.11.22.1" "test.mkv"

With quality High and color space GBR the encoder part becomes:

-vcodec cfhd -quality 8 -vf scale,format=gbrp12le -pix_fmt gbrp12le

How Hybrid calls it

  • The filter script (Vapoursynth or AviSynth) is piped into ffmpeg; without a script ffmpeg reads the source itself.
  • -quality is always written, as the number of the entry in the list (0 – 12).
  • The pixel format is written twice, as -vf scale,format=… and as -pix_fmt, so ffmpeg delivers exactly the format the encoder accepts.
  • Color matrix, transfer, primaries and range of the video are passed to ffmpeg as -colorspace, -color_trc, -color_primaries and -color_range.
  • The number of ffmpeg threads follows Hybrid's general thread setting.

Sources