Struct Generator
- Namespace
- SpessaSharp.SoundBank
- Assembly
- SpessaSharp.dll
public readonly struct Generator
- Inherited Members
Constructors
Generator(Type, int, bool)
Constructs a new generator
public Generator(Generator.Type type, int value, bool validate = true)
Parameters
typeGenerator.TypeGenerator type
valueintGenerator value
validateboolIf the limits should be validated and clamped.
Fields
Amount
public static readonly int Amount
Field Value
ByteSize
public const int ByteSize = 4
Field Value
GType
The generator's SF2 type.
public readonly Generator.Type GType
Field Value
Limits
public static readonly FrozenDictionary<Generator.Type, (short Min, int Max, short Def, int NRPN)> Limits
Field Value
List
public static readonly Generator.Type[] List
Field Value
- Type[]
Max
public static readonly short Max
Field Value
Value
The generator's 16-bit value.
public readonly short Value
Field Value
Methods
Copy(List<Generator>, List<Generator>)
public static List<Generator> Copy(List<Generator> target, List<Generator> source)
Parameters
Returns
HasDefaultValue(Generator)
public static bool HasDefaultValue(Generator g)
Parameters
Returns
IsDefaultValue(Type, int)
public static bool IsDefaultValue(Generator.Type type, int value)
Parameters
Returns
Write(ref Span<byte>)
public void Write(ref Span<byte> genData)