Nodes/ComfyUI-Apt_Preset/create_AD_mask
ComfyUI Node

create_AD_mask

Animated wipe/fade transition masks for video work

By cardenluo·Created 2 years ago·Updated a day ago· 324
create_AD_mask
    • mask
    width512
    height512
    frames16
    start_frame0
    end_frame9999
    transition_type
    method
    invertMaskfalse

    If you've ever wanted a mask that doesn't just sit there - one that wipes in like a circle expanding, or slides a bar across the frame, growing over a range of frames instead of appearing all at once on frame 1 - this is that node. It procedurally generates an animated mask sequence: a transition, rendered as a MASK batch across time.

    What it is and why you'd reach for it

    create_AD_mask lives in ComfyUI-Apt_Preset's mask utilities, and the "AD" in the name points at the obvious use: feeding a smoothly-animated mask into a masked/keyframed conditioning setup for video generation, rather than cutting an effect in with a hard, static mask that pops in abruptly on the first frame. Think classic video-editing wipe transitions - bars, circles, doors, fades - generated as a mask sequence you can drive AnimateDiff-style keyframe masking or any per-frame compositing with.

    One thing worth flagging honestly: this node sits under a "🚫backup" category in the pack's own node menu, which is how the author marks nodes kept around for workflow compatibility rather than the current front-line recommendation. Nothing in the README calls out a direct successor for this one specifically, so if it's doing what you need, there's no reason to avoid it - just know the pack ships new video/mask nodes every few weeks, so check the current node list before assuming this is the newest option.

    How it works

    You set canvas size (width, height) and a total frame count (frames), then bound the actual transition to a sub-range with start_frame/end_frame (default 0–9999, effectively "the whole clip" unless you narrow it). transition_type picks the shape of the wipe - nine options, from straightforward horizontal/vertical slides and bars to a center box, "door" opens (splitting from the center outward), a growing circle, or a plain fade. method controls the pacing curve: linear, in, out, or in-out - the same easing-curve vocabulary as animation software, controlling whether the transition accelerates, decelerates, or both.

    Inputs and outputs that matter

    • frames (1–9999, default 16) - total length of the mask sequence.
    • start_frame / end_frame - where within that sequence the transition actually happens.
    • transition_type (9 options) - the wipe shape.
    • method (linear/in/out/in-out) - the easing curve.
    • invertMask (bool, default false) - flips which side of the transition is masked.

    Output: a single mask - but a batched, animated one spanning frames, ready to wire into a masked sampler or compositing chain that expects a per-frame mask sequence.

    Installing it

    Through ComfyUI Manager: search ComfyUI-Apt_Preset, install, restart. Manually:

    cd ComfyUI/custom_nodes
    git clone https://github.com/cardenluo/ComfyUI-Apt_Preset.git
    

    Run install.bat on Windows for dependencies; on Linux/Mac install the requirements yourself. No model downloads needed for this node - it's procedural mask generation, no weights involved.

    Common issues

    If your transition looks abrupt instead of smooth, check start_frame/end_frame first - with the defaults left wide open, the whole frames range gets the transition stretched across it, which can look far more gradual than you want if you actually meant a quick 5-frame wipe partway through a 64-frame clip.

    Since this node is filed under the pack's "backup" category, treat it as stable-but-not-actively-showcased: it should keep working, but don't expect README changelog attention if something about it changes behavior in a future update - test after upgrading the pack. And as with the rest of ComfyUI-Apt_Preset: it's a large pack, and at least one user has reported an IMPORT FAILED error at ComfyUI startup after installing it - check the console log if this node doesn't appear.

    CategoryApt_Preset/mask/😺backup

    Inputs (8)

    NameTypeDefaultDescription
    widthINT5121–5120
    heightINT5121–5120
    framesINT161–9999
    start_frameINT0
    end_frameINT9999
    transition_typeCOMBO9 options: horizontal slide, vertical slide, horizontal bar, vertical bar, center box, horizontal door, +3
    methodCOMBO4 options: linear, in, out, in-out
    invertMaskBOOLEANfalse

    Outputs (1)

    NameTypeDescription
    maskMASK