Plush

SoundZone#

PlushEngine · Type index

Namespace: PlushEngine

One keyzone of a Sound: a sample (another Sound) played over a range of notes and velocities. With PitchFollowsNote the sample plays at the note's pitch relative to RootKey (the sample Sound's own root when null); without it every note plays the sample as recorded (a drum kit's hits). Overlapping zones layer; zones sharing a nonzero Group are alternatives, one picked per play. A zone with its own Modulation plays through it instead of the Sound's (a SoundFont's per-key envelopes).

public sealed record SoundZone(SoundAsset Sample, int KeyLow = 0, int KeyHigh = 119, int VelocityLow = 1, int VelocityHigh = 127, int? RootKey = null, bool PitchFollowsNote = true, float TuneCents = 0, float VolumeDb = 0, int Group = 0, ModulationChain? Modulation = null)

Record properties#

PropertyTypeAccessConstructor default
SampleSoundAssetget; init;required
KeyLowintget; init;0
KeyHighintget; init;119
VelocityLowintget; init;1
VelocityHighintget; init;127
RootKeyint?get; init;null
PitchFollowsNoteboolget; init;true
TuneCentsfloatget; init;0
VolumeDbfloatget; init;0
Groupintget; init;0
ModulationModulationChain?get; init;null

Members: Covers

Covers#

public bool Covers(int key, int velocity);

ModulationChain · SoundAsset

Source#