Nodes/ComfyUI-MakkiTools/BooleanSplitter(mki-布尔值拆分)
ComfyUI Node

BooleanSplitter(mki-布尔值拆分)

One toggle in, two wires out

By MakkiShizu·Created about a year ago·Updated 7 months ago· 9
BooleanSplitter(mki-布尔值拆分)
    • input
    • opposite
    input_booltrue

    BooleanSplitter_makki (display name "BooleanSplitter(mki-布尔值拆分)") is a one-trick node: you feed it a boolean, and you get that boolean out twice - once as itself and once as its opposite. That's it. No settings beyond the input toggle, no math, no hidden behavior.

    Why that's actually useful

    ComfyUI has plenty of boolean switches, but most of them are "pick A or B" - one output selected by the flag. Sometimes you want to drive both branches of a graph from a single toggle: when the switch is on, path A runs and path B is dead, and when it's off the reverse. Without a splitter you end up with an extra Not node or a second switch you have to remember to keep in sync. This node gives you the raw value and its inverse in one place, so both paths stay wired to the same source of truth.

    Practical example: a face-restoration toggle. True → run the face detailer branch; False → run the plain upscale branch. Wire the input output to one branch's boolean input and the opposite output to the other's, and you never touch the graph again - one checkbox routes the whole flow.

    Inputs and outputs

    • input_bool (required) - the boolean value, default true. You can toggle it on the node or wire it from upstream logic.
    • Output input - the value unchanged.
    • Output opposite - its negation.

    That's the entire schema. Both outputs are plain BOOLEAN wires, so they connect to any boolean input in ComfyUI.

    A small honesty note

    If this node were the whole pack, nobody would install it - you could build the same thing with a couple of primitive nodes. But it's the kind of tiny convenience that earns its place once you've got a graph with several "if this, do that" branches. It's also a decent example of why small single-purpose nodes exist in this ecosystem at all: ComfyUI is a graph environment, and a trivial 5-line node can save you from stringing three primitives together for the same result.

    Install it with the rest of ComfyUI-MakkiTools via ComfyUI Manager, or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/MakkiShizu/ComfyUI-MakkiTools
    cd ComfyUI-MakkiTools
    pip install -r requirements.txt
    

    Restart, and it's under the MakkiTools category. There's genuinely nothing that can go wrong here - it's one not in Python. Reach for it when a single toggle should control two mutually exclusive paths and you're tired of keeping switches in sync.

    CategoryMakkiTools

    Inputs (1)

    NameTypeDefaultDescription
    input_boolBOOLEANtrueInput boolean value 输入布尔值

    Outputs (2)

    NameTypeDescription
    inputBOOLEAN
    oppositeBOOLEAN