Nodes/ComfyUI-LTXVideo-AVSplit/🅛🅣🅧 Stitch AV Latents
ComfyUI Node

🅛🅣🅧 Stitch AV Latents

Stitches two AV latents in two video modes: bridge insertion or linear overlap replacement. Audio stitching always keeps bridge behavior. vae/audio_vae optional (defaults: stride 8, ~25 audio latents/s). Time-based audio mask indices are clamped to actual latent length.

By PsypmP·Created 4 months ago·Updated 4 months ago· 0
🅛🅣🅧 Stitch AV Latents
  • av_latent_1
  • av_latent_2
  • model
  • vae
  • audio_vae
  • av_latent
video_fps24.0
bridge_latent_frames1
stitch_modebridge
overlap_latent_frames16
video_pre_frames0
video_post_frames0
video_slope_len0
mask_videotrue
video_mask_init_value0.0
audio_start_time0.0
audio_end_time10.0
audio_slope_len3
mask_audiotrue
audio_mask_init_value0.0
audio_mask_bridge_onlyfalse
bridge_init_modelerp
Categorylightricks/LTXV

Inputs (21)

NameTypeDefaultDescription
av_latent_1LATENT
av_latent_2LATENT
modelMODEL
video_fpsFLOAT24.00–500Decoded video FPS. Each video latent step spans (temporal_stride / fps) seconds; optional vae/audio_vae override stride and audio rate.
bridge_latent_framesINT11–4096Bridge length in video latent frames when stitch_mode='bridge'. In stitch_mode='overlap_linear_video' it does not affect video; it only controls audio bridge duration.
stitch_modeCOMBObridgeHow to stitch video latents: 'bridge' inserts transition latents between clips (existing behavior); 'overlap_linear_video' linearly blends overlapping tail/head and replaces overlap. Audio always uses bridge stitching.
overlap_latent_framesINT161–4096Overlap size for stitch_mode='overlap_linear_video', in video latent frames. Ignored when stitch_mode='bridge'.
video_pre_framesINT00–4096Video mask expansion before the transition region, in latent frames (used when mask_video=True).
video_post_framesINT00–4096Video mask expansion after the transition region, in latent frames (used when mask_video=True).
video_slope_lenINT00–100Video mask slope length around the transition window, in latent frames (used when mask_video=True).
mask_videoBOOLEANtrue
video_mask_init_valueFLOAT0.00–1
audio_start_timeFLOAT0.00–2000Audio mask start time in seconds (used when mask_audio=True).
audio_end_timeFLOAT10.00–2000Audio mask end time in seconds (used when mask_audio=True).
audio_slope_lenINT31–100Audio mask slope length in latent frames (used when mask_audio=True).
mask_audioBOOLEANtrue
audio_mask_init_valueFLOAT0.00–1
audio_mask_bridge_onlyBOOLEANfalseIf enabled, ignore audio_start_time/audio_end_time and mask exactly the inserted audio bridge so only bridge audio is denoised. audio_slope_len is applied inside the bridge and never bleeds into clip 1 / clip 2 audio.
bridge_init_modeCOMBOlerpHow to initialize bridge latents. For video this is used only when stitch_mode='bridge'. In stitch_mode='overlap_linear_video' it affects only audio bridge initialization. 'lerp': linear interpolation between endpoints (original). 'noise': random gaussian noise (model generates from scratch). 'zeros': zero-filled (neutral latent).
vaeoptVAEIf set, video temporal stride = downscale_index_formula[0]. If omitted, uses default 8 (LTX-2).
audio_vaeoptVAEIf set, audio latent steps/sec from the VAE. If omitted, uses ~25 (LTX-2). Wire both for exact sync if your VAE differs.

Outputs (1)

NameTypeDescription
av_latentLATENT