Class CodecDeclarationAttribute
The codec of a replicated field, named rather than defaulted from its type; the numeric properties parameterize it.
public abstract class CodecDeclarationAttribute : Attribute
- Inheritance
-
CodecDeclarationAttribute
- Derived
- Inherited Members
Constructors
CodecDeclarationAttribute(CodecKind)
A codec named by kind alone, or Unknown to default it from the field's type.
protected CodecDeclarationAttribute(CodecKind kind)
Parameters
kindCodecKind
Properties
Bits
Bits, for Quant, Unorm, Snorm, Angle, Bits, Vec2/3, an enum or a position; 0 for the codec's default.
public int Bits { get; set; }
Property Value
Kind
The codec's kind; Unknown defaults it from the field's CLR type.
public CodecKind Kind { get; }
Property Value
Max
The upper bound of a Quant codec.
public double Max { get; set; }
Property Value
MaxBytes
The cap of a Str or Blob, or the length of Bytes.
public int MaxBytes { get; set; }
Property Value
Min
The lower bound of a Quant codec.
public double Min { get; set; }
Property Value
Name
The field's wire name; the builder's default (its own name) when unset.
public string Name { get; set; }
Property Value
Saturate
Whether a value past the codec's range is clamped to it rather than refused (Codec.Saturate()).
public bool Saturate { get; set; }
Property Value
Scale
The step of a Vec2/3 codec.
public double Scale { get; set; }