EasyUse/Logicgenerated

A or B(ab)

The A or B node is a logic switch from EasyUse/Logic. It takes any value through in and routes it to one of its two outputs, selected by the A or B boolean.

ab

in
A
B
A or B
Easy Use

Description

The A or B node is a logic switch from EasyUse/Logic. It takes any value through in and routes it to one of its two outputs, selected by the A or B boolean. Despite the name, this is not a boolean OR gate; it sends a value to either the first output or the second output.

Inputs

  • A or B (BOOLEAN, default true): Output selector. When true, the input value is sent to the first output. When false, the input value is sent to the second output.
  • in (ANYTYPE): The value to route. This can be any ComfyUI data type, including images, latents, masks, conditioning, or primitive values.

Outputs

  • First output (ANYTYPE): Receives in when A or B is true; otherwise it is None.
  • Second output (ANYTYPE): Receives in when A or B is false; otherwise it is None.

Usage Notes

  • The selected output preserves the type of in, so it can be connected directly to downstream nodes expecting that same data type.
  • The unselected output returns None. Downstream nodes connected to the inactive output will receive None and may fail if they do not handle missing values.
  • Use this node when a workflow needs to switch a value between two paths at runtime without manually rewiring the graph.

Comments

Sign in with GitHub to join the discussion.

Loading comments…