ColorTriggerMetaData

@Serializable
data class ColorTriggerMetaData(val name: String = "Color Trigger", val rMin: Int = 0, val rMax: Int = 255, val gMin: Int = 0, val gMax: Int = 255, val bMin: Int = 0, val bMax: Int = 255, val nodeAction: NodeAction = NodeAction.EXECUTE, val error: String = "", val sources: List<NodeIdentity> = emptyList(), val snapshot: Snapshot = Snapshot(), val invocationTriggers: List<InvocationTrigger> = emptyList(), val inputs: List<NodeIdentity> = emptyList()) : SourceMetaData(source)

Payload for a Color trigger.

Constructors

Link copied to clipboard
constructor(name: String = "Color Trigger", rMin: Int = 0, rMax: Int = 255, gMin: Int = 0, gMax: Int = 255, bMin: Int = 0, bMax: Int = 255, nodeAction: NodeAction = NodeAction.EXECUTE, error: String = "", sources: List<NodeIdentity> = emptyList(), snapshot: Snapshot = Snapshot(), invocationTriggers: List<InvocationTrigger> = emptyList(), inputs: List<NodeIdentity> = emptyList())

Properties

Link copied to clipboard
val bMax: Int

Upper bound for the blue channel [0, 255].

Link copied to clipboard
val bMin: Int

Lower bound for the blue channel [0, 255].

Link copied to clipboard
open override val error: String

Last known error message for this node, or empty string when healthy.

Link copied to clipboard
val gMax: Int

Upper bound for the green channel [0, 255].

Link copied to clipboard
val gMin: Int

Lower bound for the green channel [0, 255].

Link copied to clipboard
open override val inputs: List<NodeIdentity>

sets the nodes this node reads from to complete its work when invoked

Link copied to clipboard

The set of InvocationTriggers configured to wake this node. The node processor checks the incoming event against this list before doing any work. An empty list means "never auto-fire" — only manual execution.

Link copied to clipboard

Display name shown on the node chip.

Link copied to clipboard
open override val nodeAction: NodeAction

The action this node performs when it fires. Defaults to NodeAction.EXECUTE on every concrete implementation so that deserialising a payload that predates this field yields the original behaviour unchanged.

Link copied to clipboard
val rMax: Int

Upper bound for the red channel [0, 255].

Link copied to clipboard
val rMin: Int

Lower bound for the red channel [0, 255].

Link copied to clipboard
open override val snapshot: Snapshot

Stores the last result of when this node was invoked and is a source of data

Link copied to clipboard
open override val sources: List<NodeIdentity>

Upstream nodes whose values feed this one. For a filter or executor this is the data being read; for a trigger it is the value being watched.

Functions

Link copied to clipboard

Returns the centre of the configured RGB bounding box as a packed ARGB Long (0xFFRRGGBB) suitable for use as a Compose colour. Used by the editor to render a one-glance swatch of "what colour does this trigger approximately match".