Table of Contents

Struct ChordInfo

Namespace
Celeritas.Core
Assembly
Celeritas.dll

Compact chord info (8 bytes instead of 24+ for class)

public readonly record struct ChordInfo : IEquatable<ChordInfo>
Implements
Inherited Members

Constructors

ChordInfo(byte, ChordQuality)

Compact chord info (8 bytes instead of 24+ for class)

public ChordInfo(byte RootPitchClass, ChordQuality Quality)

Parameters

RootPitchClass byte

Root pitch class of the chord (0=C .. 11=B).

Quality ChordQuality

The chord's quality.

Properties

Quality

The chord's quality.

public ChordQuality Quality { get; init; }

Property Value

ChordQuality

Root

Root note name (e.g. "C", "F#") for RootPitchClass.

public string Root { get; }

Property Value

string

Remarks

Meaningless when Quality is Unknown: the library pairs that with pitch class 0, so this reads "C" for a chord it did not recognize at all.

RootPitchClass

Root pitch class of the chord (0=C .. 11=B).

public byte RootPitchClass { get; init; }

Property Value

byte

Methods

ToString()

Returns the root name followed by the quality (e.g. "C Major").

public override string ToString()

Returns

string

Remarks

The two fields are rendered as given, so an unrecognized chord reads "C Unknown" whatever notes it was — see Unknown.