Class AudityNodeDef
The single source of truth for one node kind: pin specs, channel behavior, param-blob defaults and validation, finiteness contribution, and the Burst exec function. Registered once via [AudityNode] reflection (see AudityNodeRegistry); the program builder, compiler, editor schema and realtime dispatch all read the registry rather than switching on a fixed kind enum.
Assembly: DarkEffekt.Audity.Runtime
Section titled “Assembly: DarkEffekt.Audity.Runtime”public abstract class AudityNodeDefProperties
Section titled “Properties”Registry-assigned identity (see DarkEffekt.Audity.AudityNodeRegistry.KindOf%60%601).
public AudityNodeKindId Kind { get; }IsVariadic
Section titled “IsVariadic”Pin count expands with a per-node count (Mixer, Split, Random Route, …).
public virtual bool IsVariadic { get; }PropagatesChannels
Section titled “PropagatesChannels”Audio output adopts the channel count of connected audio inputs (all must agree - exact match, no auto up/downmix).
public virtual bool PropagatesChannels { get; }HasFixedChannelPins
Section titled “HasFixedChannelPins”Channel-construction kind: every audio pin carries a FIXED declared channel count from the pin spec (Split’s input is Audio(N), its outputs Audio(1), …).
public virtual bool HasFixedChannelPins { get; }AdoptsAnyInputWidth
Section titled “AdoptsAnyInputWidth”Fixed-pin exception (Take Channel): the audio input adopts any incoming width even though the outputs stay fixed.
public virtual bool AdoptsAnyInputWidth { get; }AdoptsAnyValueWidth
Section titled “AdoptsAnyValueWidth”This kind’s DYNAMIC Float pins (spec width 0) adopt the incoming wire’s full
width instead of truncating it to 4. Opt in only when the exec reads and
writes through the span API (DarkEffekt.Audity.AudityExecContext.ReadValues(DarkEffekt.Audity.AudityNodeDesc%40%2cSystem.Int32%2cSystem.Span%7bSystem.Single%7d) /
DarkEffekt.Audity.AudityExecContext.ValueOut(DarkEffekt.Audity.AudityNodeDesc%40%2cSystem.Int32)) - a float4-based exec resolved to
width 8 would index past lane w. See
DarkEffekt.Audity.AudityNodeSpec.ResolveDynamicWidth(System.Int32%2cSystem.Int32).
public virtual bool AdoptsAnyValueWidth { get; }IsVoicePlayer
Section titled “IsVoicePlayer”Draws from the per-player voice pool (WavePlayer, and custom voice-players).
public virtual bool IsVoicePlayer { get; }VoiceConfig
Section titled “VoiceConfig”Pool requirements for a custom voice-player (ignored unless DarkEffekt.Audity.AudityNodeDef.IsVoicePlayer). The node’s exec drives voices through DarkEffekt.Audity.AudityExecContext’s SpawnVoice / LiveVoices / VoiceState surface. Default max-voices falls back to the engine pool size.
public virtual AudityVoiceConfig VoiceConfig { get; }LivenessFollowsVoiceStartReachability
Section titled “LivenessFollowsVoiceStartReachability”This kind’s DarkEffekt.Audity.AudityNodeDef.KeepsInstanceAlive(DarkEffekt.Audity.AudityNodeLiveness%40) claim exists only because its
trigger outputs could conjure sound from silence (an external entry, a
threshold crossing, a running clock). The builder refines such a claim by
reachability: when no path from this node’s triggers reaches a
voice-starting pin, the claim is waived and a one-shot can retire. Endless
audio sources (Oscillator, Noise, a looping player) keep the default false -
they ARE the sound, no conjuring needed.
public virtual bool LivenessFollowsVoiceStartReachability { get; }StateBytes
Section titled “StateBytes”Bytes of per-node DSP state this kind needs (phase accumulators, filter
memories, envelope stages). Allocated per node in one arena at Configure,
zero-initialized at instance start, reached in exec as a struct via
DarkEffekt.Audity.AudityExecContext.State%60%601(DarkEffekt.Audity.AudityNodeDesc%40) (or as floats via
DarkEffekt.Audity.AudityExecContext.UserState(DarkEffekt.Audity.AudityNodeDesc%40)). The default keeps the classic
16-float UserState scratch; stateless kinds should declare 0.
public virtual int StateBytes { get; }The kind’s exec function, compiled to a Burst function pointer at registration. Null for kinds the executor runs specially (the Output sink).
public virtual AudityNodeExec Exec { get; }Methods
Section titled “Methods”GetInputPins(int, List<AudityPinSpec>)
Section titled “GetInputPins(int, List<AudityPinSpec>)”Appends the kind’s input pins in executor pin order.
public abstract void GetInputPins(int variadicCount, List<AudityPinSpec> pins)Parameters
Section titled “Parameters”| Type | Name |
|---|---|
System.Int32 |
variadicCount |
System.Collections.Generic.List<DarkEffekt.Audity.AudityPinSpec> |
pins |
GetOutputPins(int, List<AudityPinSpec>)
Section titled “GetOutputPins(int, List<AudityPinSpec>)”Appends the kind’s output pins in executor pin order.
public abstract void GetOutputPins(int variadicCount, List<AudityPinSpec> pins)Parameters
Section titled “Parameters”| Type | Name |
|---|---|
System.Int32 |
variadicCount |
System.Collections.Generic.List<DarkEffekt.Audity.AudityPinSpec> |
pins |
CreateDefaultParams()
Section titled “CreateDefaultParams()”Minimum float-param blob, so the executor never reads out of range.
public virtual float[] CreateDefaultParams()Returns
Section titled “Returns”System.Single[]
Validate(in AudityNodeValidation)
Section titled “Validate(in AudityNodeValidation)”Build-time param validation (report via DarkEffekt.Audity.AudityNodeValidation.Error(System.String)).
public virtual void Validate(in AudityNodeValidation validation)Parameters
Section titled “Parameters”| Type | Name |
|---|---|
DarkEffekt.Audity.AudityNodeValidation |
validation |
KeepsInstanceAlive(in AudityNodeLiveness)
Section titled “KeepsInstanceAlive(in AudityNodeLiveness)”True when this node can keep the instance alive indefinitely (an endless source, an external trigger entry, a looping sample) - the program is then non-finite and only stops on request.
public virtual bool KeepsInstanceAlive(in AudityNodeLiveness liveness)Returns
Section titled “Returns”System.Boolean
Parameters
Section titled “Parameters”| Type | Name |
|---|---|
DarkEffekt.Audity.AudityNodeLiveness |
liveness |
LivenessReason(in AudityNodeLiveness)
Section titled “LivenessReason(in AudityNodeLiveness)”The user-facing fact behind a true DarkEffekt.Audity.AudityNodeDef.KeepsInstanceAlive(DarkEffekt.Audity.AudityNodeLiveness%40) - one
sentence, shown in the graph editor’s lifetime list so “why doesn’t my
one-shot finish?” is answerable without reading engine code.
public virtual string LivenessReason(in AudityNodeLiveness liveness)Returns
Section titled “Returns”System.String
Parameters
Section titled “Parameters”| Type | Name |
|---|---|
DarkEffekt.Audity.AudityNodeLiveness |
liveness |
TriggerInputStartsVoice(string)
Section titled “TriggerInputStartsVoice(string)”A trigger arriving on input pinId can start a voice from
silence. Drives the Trigger In liveness refinement: an external trigger entry
only holds the instance open if some reachable pin can actually conjure
sound - a stop-only entry is reactive and lets one-shots retire.
public virtual bool TriggerInputStartsVoice(string pinId)Returns
Section titled “Returns”System.Boolean
Parameters
Section titled “Parameters”| Type | Name |
|---|---|
System.String |
pinId |
TriggerInputPropagates(string)
Section titled “TriggerInputPropagates(string)”A trigger arriving on input pinId can cause this node’s
outputs to fire (now or later) - the reachability walk continues through it.
Stop-like pins that only end or suppress return false. Default is the
conservative true.
public virtual bool TriggerInputPropagates(string pinId)Returns
Section titled “Returns”System.Boolean
Parameters
Section titled “Parameters”| Type | Name |
|---|---|
System.String |
pinId |
BreaksTriggerCycles(float[])
Section titled “BreaksTriggerCycles(float[])”True when this node eventually goes quiet inside a trigger feedback cycle (a Stop-ending Sequence Step), letting an otherwise-cyclic patch count as finite.
public virtual bool BreaksTriggerCycles(float[] nodeParams)Returns
Section titled “Returns”System.Boolean
Parameters
Section titled “Parameters”| Type | Name |
|---|---|
System.Single[] |
nodeParams |
DspSecondsPerChannel(float[])
Section titled “DspSecondsPerChannel(float[])”Seconds of per-channel DSP-pool memory this node needs (delay lines, reverb tanks). 0 = none. The pool is sized at Configure time (seconds × sample rate × the node’s resolved channel count) and reached in exec via the engine’s DspRegion; per-node layout inside the region is the exec’s own business.
public virtual float DspSecondsPerChannel(float[] nodeParams)Returns
Section titled “Returns”System.Single
Parameters
Section titled “Parameters”| Type | Name |
|---|---|
System.Single[] |
nodeParams |