Nodes/h3-relay/H3RelayInternalLoopTrim
ComfyUI Node

H3RelayInternalLoopTrim

Remove the leading pinned frames from a decoded H3 clip, trimming picture and sound by the same duration.

By akatz-ai·Created 8 days ago·Updated 4 days ago· 9
H3RelayInternalLoopTrim
  • images
  • audio
  • images
  • audio
  • images_with_overlap
  • overlap_frames
trim_frames0
fps24.000
match_tailtrue
retain_overlap_frames0
Categoryconditioning/minimax/contex_loop

Inputs (6)

NameTypeDefaultDescription
imagesIMAGEDecoded images from the CURRENT H3 sample. The leading pinned overlap is removed.
trim_framesINT00–4096Connect trim_frames from MiniMax H3 Contex Loop Context. In head mode this removes the repeated overlap; before mode supplies 0.
audiooptAUDIODecoded audio for the same clip. Trimmed by the matching duration so sound stays locked to picture. Leave unwired for silent clips.
fpsoptFLOAT24.0001–240Frame rate used to convert the trim into an audio duration. Must match what you feed Create Video.
match_tailoptBOOLEANtrueTruncate or zero-pad audio so its duration equals frames/fps exactly. H3 rounds its 40 Hz audio grid to the nearest step, producing about 8ms of excess or shortage on some lengths.
retain_overlap_framesoptINT00–4096Optional visual-only overlap for an external stitcher. 0 keeps the normal hard-trim output only. A positive value makes the extra image output retain up to that many of the final repeated context frames. Audio always removes the complete overlap.

Outputs (4)

NameTypeDescription
imagesIMAGEDelivered frames with the repeated leading context removed.
audioAUDIOAudio trimmed by the same duration and, when match_tail is enabled, fitted exactly to the delivered image duration.
images_with_overlapIMAGEOptional blend-ready image stream. When overlap_frames is positive, this retains only the final requested part of the repeated visual context before the delivered frames. Audio remains fully trimmed.
overlap_framesINTNumber of repeated leading frames retained in images_with_overlap. Use as an overlap count in a compatible video stitcher.