Nodes/ComfyUI_CineStyle/CS Load Video
ComfyUI Node

CS Load Video

Trim, resize and re-time your video without leaving ComfyUI

By chflame163·Created 26 days ago·Updated 3 days ago· 72
CS Load Video
    • VIDEO
    • IMAGE
    • frame_count
    • audio
    • video_info
    • fps
    video
    multiple32
    start_frame0
    end_frame-1
    width0
    height0
    fps0.00

    If you've ever tried to feed a video into a ComfyUI pipeline, you know the drill: pull it into Load Video, stare at a frame range you can't easily see, and pray the whole clip fits whatever your video model wants. CS Load Video from the CineStyle pack is the version of that node that actually respects your time. It loads a file, and then hands you a real little timeline editor right on the node - drag in/out handles, scrub, set a new resolution and FPS - so the clip that reaches your model is exactly the one you meant to feed it.

    It's part of chflame163's CineStyle pack, a set of video-workflow nodes from the author of the very popular LayerStyle pack. Same author, same vibe: polished UI on top of solid plumbing.

    What it does under the hood

    The node decodes your video with PyAV into frames plus audio plus the true frame rate. Then it applies whatever you set on the node: trims to the in/out range, resizes, and - if you changed fps - resamples the frames to the target rate, so a 30 fps clip becomes a 24 fps clip before anything downstream sees it. Audio gets trimmed to the same range. It outputs a standard ComfyUI VIDEO (the thing official video nodes understand), so you can chain it straight into your sampler or encoder.

    The inputs that matter

    The video combo lets you pick a file already in ComfyUI/input, or upload one directly. That's all a beginner needs to touch, honestly. The rest:

    • keep_aspect_ratio (default on) - change one of width/height and the other follows. Leave it on.
    • multiple (default 32) - rounds the output dimensions to the nearest multiple. Video models are picky about divisibility, and 32 is a safe target. Bump it to 64 if your model insists.
    • start_frame / end_frame - the range. end_frame = -1 means "until the last frame." The README is explicit that Edit Timeline is the preferred control, so don't hand-type these unless you're automating.
    • width / height / fps - 0 means "keep source." Set a real number only when you want to resample.

    There are also two proxy knobs: proxy_threshold (default 2.1 MPixels) and proxy_size (0.8 MPixels). When your source exceeds the threshold, the timeline UI generates a downscaled preview proxy so scrubbing a 4K clip doesn't melt your RAM. The proxy is preview-only - the actual output is always the full-res original.

    Outputs and where they go

    • VIDEO - the trimmed/resized/re-timed clip, audio included. Wire this into official video nodes.
    • IMAGE - the same frames as an image batch, for anything that wants [frames, H, W, C].
    • frame_count - how many frames actually came out (differs from the source range if you changed FPS).
    • audio - the selected audio track, empty if the source has none.
    • video_info - a dict with FPS, frame counts, dimensions, in/out points.
    • proxy_video - the preview proxy, for feeding a fast preview into downstream Selector/Preview UIs.

    Installing it

    ComfyUI Manager → search ComfyUI_CineStyle, or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/chflame163/ComfyUI_CineStyle.git
    

    Restart ComfyUI. You'll find the nodes under right-click → Add Node → 😺dzNodes/CineStyle, or just search "cinestyle". Note the pack is built on ComfyUI's newer node API, so it wants a reasonably current ComfyUI, and its requirements.txt pulls some heavy friends (av, transformers, funasr…) - let Manager install them.

    Where people get burned

    • Odd dimensions. This node can happily hand a 537-wide clip to the pack's own CS Save Video, and H.264 encoding refuses odd dimensions. The multiple default exists to save you from this - leave it alone.
    • Changing FPS silently changes your clip. frame_count is there so you can see it; check it once before you build a workflow that assumes a fixed length.
    • Proxy confusion. If your timeline preview looks soft, that's the proxy, not your video. It never touches the output.
    Category😺dzNodes/CineStyle

    Inputs (7)

    NameTypeDefaultDescription
    videoCOMBOVideo file in the ComfyUI input directory.
    multipleINT321–1024Round output dimensions to the nearest multiple.
    start_frameINT00–10000000Inclusive first frame. Edit Timeline is the preferred control.
    end_frameINT-1-1–10000000Inclusive last frame. -1 uses the final source frame.
    widthINT00–8192Output width. 0 keeps the source width.
    heightINT00–8192Output height. 0 keeps the source height.
    fpsFLOAT0.000–240Output frame rate. 0 keeps the source frame rate.

    Outputs (6)

    NameTypeDescription
    VIDEOVIDEO
    IMAGEIMAGE
    frame_countINT
    audioAUDIO
    video_infoDICT
    fpsFLOAT