MiniMax H3 Segment Queue + Concat
The node that renders MiniMax H3 in segments, then stitches the master
- video
- images
- audio
- bridge_images
MiniMax H3 gives you long, continuous, audio-native shots - but it doesn't hand you the whole timeline at once. Long-form video in ComfyUI is still chunked generation: render a segment, carry continuity into the next, repeat, then join. IAMCCS_MiniMaxH3SegmentQueueLoop is the piece of the IAMCCS Shotboard pipeline that turns "render this segment" into "render all the segments, save them as files, and concat the finished master." It's an output node with a side effect: it re-queues the workflow for you.
How it works
You feed it the current segment index and the total, plus the rendered segment's frames. It saves that segment as an MP4 named with your render_id (e.g. ..._seg_0001.mp4), writes a last-frame "bridge" image that the next segment's continuity path can read, and then - the clever part - it rewrites the queued prompt: every node with a segment_index input gets bumped to the next value, and the workflow is automatically re-queued. Run the graph once, walk away, come back to N saved segments. On the final segment it concats all the MP4s into one _full.mp4 master.
The trim-overlap logic is where this gets subtle. trim_head_frames controls how many frames are shared between segments for a clean stitch. If it's more than 1, the node treats it as an overlap and trims the head of each saved segment so the concat uses a blending pass instead of a hard cut. That's why it wants the images input (plus audio for sync) rather than an opaque video container when you're using overlap - a VIDEO input is accepted, but only for the non-overlap path.
The inputs that matter
current_segment/total_segments- the loop counter. Both areforceInput, so wire them from your plan, don't just click.images+audio- the rendered segment to save. Connectvideoinstead only if you're not trimming.bridge_images- optional; the node falls back to your last frame if you don't supply it.merge_segments- true and the last pass concats everything into_full.mp4.keep_segments- false deletes the individual segment files after the merge.render_id- the name prefix that keeps a multi-segment render together.
There are no typed outputs; this is a terminal node that reports through the UI and the preview widget.
Where people get burned
The validation is strict on purpose. It refuses to run if current_segment is negative, if it's past total_segments, or - the classic - if you try to resume a render from segment 2+ without a render_id that ties it to the earlier segments. The message effectively tells you to reset segment_index to 0 before a new run. And if no node in the graph has a segment_index input to advance, the loop raises instead of silently doing nothing - that's your cue that the workflow isn't wired for looping.
Install
It ships inside IAMCCS-nodes, so install the pack once: ComfyUI Manager → search "IAMCCS", or cd ComfyUI/custom_nodes && git clone https://github.com/IAMCCS/IAMCCS-nodes.git, then restart ComfyUI. No extra Python deps for this node specifically - the pack handles its own ffmpeg shim on import.
Inputs (14)
| Name | Type | Default | Description |
|---|---|---|---|
| current_segment | INT | — | |
| total_segments | INT | — | |
| videoopt | VIDEO | — | |
| imagesopt | IMAGE | — | |
| audioopt | AUDIO | — | |
| bridge_imagesopt | IMAGE | — | |
| trim_head_framesopt | INT | — | |
| enabledopt | BOOLEAN | true | — |
| filename_prefixopt | STRING | IAMCCS/MiniMaxH3/segment | — |
| merge_segmentsopt | BOOLEAN | true | — |
| keep_segmentsopt | BOOLEAN | true | — |
| render_idopt | STRING | minimax_h3_render | — |
| segment_base_nameopt | STRING | — | |
| resolved_render_idopt | STRING | — |
Outputs (0)
No outputs