DSPark 1.6.1
Header-only audio DSP framework in pure C++20 — zero dependencies
Loading...
Searching...
No Matches
dspark::harmony::DiatonicChord Struct Reference

Contains the structure and generated symbol name of a diatonic chord. More...

#include <HarmonyConstants.h>

Public Member Functions

constexpr std::string_view view () const noexcept
 Safely obtain a string_view of the internal name buffer.
 

Public Attributes

std::array< char, 24 > name
 
std::array< int, 7 > intervals
 Intervals in semitones (R-3-5-7-9-11-13). -1 = absent.
 

Detailed Description

Contains the structure and generated symbol name of a diatonic chord.

Definition at line 506 of file HarmonyConstants.h.

Member Function Documentation

◆ view()

constexpr std::string_view dspark::harmony::DiatonicChord::view ( ) const
inlineconstexprnoexcept

Safely obtain a string_view of the internal name buffer.

Returns
A std::string_view tightly bound to the null-terminated string length.

Definition at line 516 of file HarmonyConstants.h.

Member Data Documentation

◆ intervals

std::array<int, 7> dspark::harmony::DiatonicChord::intervals

Intervals in semitones (R-3-5-7-9-11-13). -1 = absent.

Definition at line 510 of file HarmonyConstants.h.

◆ name

std::array<char, 24> dspark::harmony::DiatonicChord::name

NUL-terminated buffer ("m7", "maj7"...). Zero alloc. Sized for the longest symbol "m(maj7)(9)(11)(13)" (18+NUL).

Definition at line 508 of file HarmonyConstants.h.


The documentation for this struct was generated from the following file: