ComfyUI Node
LTX Chunk Writer (TJ 2.5)
Writes a chunk of a long video out as PNG frames instead of encoding video, and copies the last N frames into ComfyUI's input folder so they can be dropped straight onto the timeline as guides for the next chunk. Passes images through unchanged, so it can sit in front of Video Combine rather than replacing it.
LTX Chunk Writer (TJ 2.5)
- images
- audio
- images
- handoff_folder
- info
◄run_namerun01►
◄chunk_index1►
◄handoff_frames8►
◄runs_folderltx25_one_runs►
◄save_all_framestrue►
◄clear_chunk_firsttrue►
◄total_chunks1►
◄auto_assembletrue►
◄write_videotrue►
◄video_fps25.00►
◄video_crf18►
◄match_to_previousfalse►
◄frame_formatjpeg►
◄jpeg_quality95►
◄write_final_framesfalse►
◄seam_modeearly_cut►
◄seam_blend_frames3►
◄assemble_match_levelstrue►
CategoryWhatDreamsCost CS 2.5
Inputs (20)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | — | |
| run_name | STRING | run01 | Folder name for this whole long-video run. Keep it the same across every chunk of the same video. |
| chunk_index | INT | 11–999 | Which chunk this is. 1 for the first, 2 for the next, and so on. |
| handoff_frames | INT | 80–64 | How many frames from the END of this chunk to copy into the input folder, ready to guide the next chunk. Snapped to a multiple of 8 because the LTX VAE packs 8 pixel frames into 1 latent frame — an unaligned handoff lands mid-latent and causes a hitch. 0 disables the handoff. |
| runs_folder | STRING | ltx25_one_runs | Subfolder of ComfyUI's output directory where full chunk frames are written. |
| save_all_frames | BOOLEAN | true | Off = only write the handoff frames. Useful for testing the seam without filling a disk. |
| clear_chunk_first | BOOLEAN | true | Wipe this chunk's folder before writing, so re-running a chunk doesn't leave stale frames behind. Only ever touches this one chunk folder. |
| total_chunks | INT | 11–999 | How many chunks this run has in total. Set automatically by Render All. When chunk_index reaches this number the run is assembled. |
| auto_assemble | BOOLEAN | true | After writing the final chunk, join every chunk into <run>/final/ with a cross-dissolve across the overlap. Uses handoff_frames as the overlap width. |
| write_video | BOOLEAN | true | After assembling the final chunk, also encode <run>_final.mp4 next to the final/ folder. The PNGs are written either way - the video is a convenience copy, not the master. |
| video_fps | FLOAT | 25.001–240 | Frame rate for the assembled video. Render All sets this from the timeline automatically; only set it by hand if you're queueing chunks yourself. |
| video_crf | INT | 180–51 | h264 quality. Lower is better and bigger; 18 is visually near-lossless. |
| match_to_previous | BOOLEAN | false | Level-match this chunk to the previous one. Compares this chunk's first frame against the previous chunk's last handoff frame - the same moment, regenerated - and applies that per-channel correction to every frame. Off for chunk 1, or when you'd rather grade in your editor. |
| frame_format | COMBO | jpeg | Format for the chunk frames, which are intermediates on their way to the mp4. JPEG is about 30x faster to write and several times smaller; measured end to end, q95 4:4:4 lands within 0.2dB of lossless PNG because the h264 encode that follows loses far more than the JPEG does. Handoff frames are ALWAYS PNG regardless - those go back into LTX as guides and must stay clean. |
| jpeg_quality | INT | 9570–100 | Only used when frame_format is jpeg. 95 is visually identical to PNG once the video is encoded. 100 is near-lossless but roughly PNG-sized, so it buys speed rather than space. Chroma is never subsampled. |
| write_final_frames | BOOLEAN | false | Also write the assembled sequence as stills in <run>/final/. Off by default because the mp4 is the deliverable. Forced on if write_video is off, so an assembly always produces something. |
| seam_mode | COMBO | early_cut | Used by auto_assemble. Where to join two chunks: early_cut switches at the frame the two chunks share (the handoff guide, reproduced), so there is nothing to ghost. early_scurve ramps across seam_blend_frames with an S-curve, which smooths a velocity difference between chunks; early_blend is the straight-line version. dissolve and hard_cut are the old behaviour. |
| seam_blend_frames | INT | 31–32 | How many frames the early_scurve / early_blend seam covers. Clamped to handoff_frames. Short is usually right: the chunks only agree near the start of the overlap, so a long blend reaches into frames that have already diverged. |
| assemble_match_levels | BOOLEAN | true | Used by auto_assemble. Corrects each chunk's brightness to the one before it, carried forward so chunk 3 matches corrected chunk 2. With early_cut the correction is measured from the single frame the two chunks share, which makes it exact. Unrelated to match_to_previous above, which is per-frame and unreliable. |
| audioopt | AUDIO | Optional. Wire this chunk's audio in - normally the LTXV Audio VAE Decode hanging off the FIRST pass. Saved next to the chunk's frames and crossfaded into one continuous track when the run is assembled. Leave unconnected for a silent run. |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| images | IMAGE | — |
| handoff_folder | STRING | — |
| info | STRING | — |