Nodes/ComfyUI-Desert-Pixel-Nodes/DP Condition Switch
ComfyUI Node

DP Condition Switch

Swap between five positive/negative conditioning pairs

By DesertPixelAi·Created 2 years ago·Updated about a year ago· 25
DP Condition Switch
  • condition_positive_01
  • condition_negative_01
  • condition_positive_02
  • condition_negative_02
  • condition_positive_03
  • condition_negative_03
  • condition_positive_04
  • condition_negative_04
  • condition_positive_05
  • condition_negative_05
  • condition_positive
  • condition_negative
selected_pair

Most switches in this pack move images or text around. This one moves conditioning - the encoded output of a CLIP Text Encode, after your prompt has already been turned into vectors the sampler can use. You wire up to five positive/negative pairs, pick one with a dropdown, and that pair is what reaches your KSampler. No rewiring, no muting nodes, just a clean selection.

It's part of DesertPixelAi's Desert-Pixel-Nodes, a large quality-of-life pack. Like rgthree's utilities, it adds nothing you generate with - it just makes a graph with several prompt encodings livable. The nice touch here is that it switches positive and negative together, as a matched pair, so you never end up with prompt A's positive accidentally paired with prompt B's negative.

How it works

You encode several prompts up front - say five different scene setups, each with its own positive and negative CLIP Text Encode - and route each encoded pair into a numbered slot. Then selected_pair chooses which slot flows out. Because it's operating on already-encoded conditioning, switching is instant and doesn't re-run the text encoder for the pairs you're not using.

This is the tool for keeping a small library of prepared prompts wired into one sampler and flipping between them, or for building a preset selector where each preset is a full positive+negative combination.

The inputs and outputs that matter

  • selected_pair - a dropdown, Conditions 01 through Conditions 05. This is the switch.
  • condition_positive_01 / condition_negative_01_05 - ten optional CONDITIONING inputs, paired up. Wire whichever pairs you're using and leave the rest empty.

Outputs are condition_positive and condition_negative (both CONDITIONING). Send the positive to your KSampler's positive input and the negative to its negative input - the pair stays matched to whatever selected_pair points at.

How to install it

  • ComfyUI Manager: search "Desert Pixel", install, restart. No models or heavy deps.
  • Manual: cd ComfyUI/custom_nodes && git clone https://github.com/DesertPixelAi/ComfyUI-Desert-Pixel-Nodes, pip install -r requirements.txt if present, restart.

It's under the DP category, filed with the conditioning nodes.

Common issues

The main thing to get right is pairing. Each slot has a positive and a negative input; if you only wire the positive for a slot and select it, the negative output for that slot has nothing to carry. For a slot you intend to use, connect both halves.

Also worth knowing: negative conditioning only does anything when your CFG is above 1. On guidance-distilled models that run at CFG 1 by default - Turbo, Lightning, and Hyper checkpoints, plus many 2026 base models - the sampler skips the negative pass entirely, so switching negatives has no visible effect there. That's not this node misbehaving; it's how classifier-free guidance works. If your negatives seem to do nothing, check your CFG before blaming the switch.

CategoryDP/conditioning

Inputs (11)

NameTypeDefaultDescription
selected_pairCOMBO5 options: Conditions 01, Conditions 02, Conditions 03, Conditions 04, Conditions 05
condition_positive_01optCONDITIONING
condition_negative_01optCONDITIONING
condition_positive_02optCONDITIONING
condition_negative_02optCONDITIONING
condition_positive_03optCONDITIONING
condition_negative_03optCONDITIONING
condition_positive_04optCONDITIONING
condition_negative_04optCONDITIONING
condition_positive_05optCONDITIONING
condition_negative_05optCONDITIONING

Outputs (2)

NameTypeDescription
condition_positiveCONDITIONING
condition_negativeCONDITIONING