Sound Byte Libs 0.5.1-121-g3358a44
C++ firmware library for audio applications on 32-bit ARM Cortex-M processors
Loading...
Searching...
No Matches
sbl::dsp::diagram Namespace Reference

A model's wiring as data, for pictures. More...

Detailed Description

A model's wiring as data, for pictures.

Namespaces

namespace  detail
 

Classes

struct  Edge
 
class  Graph
 
struct  Group
 
struct  Node
 
struct  Ports
 The ports a component exposes after describing itself, so an owner can wire them. More...
 

Enumerations

enum class  Kind : uint8_t {
  DelayLine , Loss , Allpass , DcBlock ,
  Reflection , Junction , Source , Load ,
  Resonator , Bandpass , Gain , Sum ,
  Tap , Component
}
 What a node is, in the paper's vocabulary. More...
 
enum class  Wave : uint8_t { Velocity , Force , Signal }
 What travels along an edge. More...
 
enum class  Depth : uint8_t { Full , Components }
 

Functions

size_t render_mermaid (const Graph &g, char *buf, size_t cap, Depth depth=Depth::Full)
 Render the graph as a Mermaid flowchart into a buffer.
 

Variables

constexpr uint8_t NO_GROUP = 0xFF
 
constexpr uint8_t NO_NODE = 0xFF
 

Enumeration Type Documentation

◆ Kind

enum class sbl::dsp::diagram::Kind : uint8_t
strong

What a node is, in the paper's vocabulary.

Enumerator
DelayLine 

value: length in samples

Loss 

value: cutoff in Hz

Allpass 

value: delay in samples

DcBlock 

value: corner in Hz

Reflection 

value: coefficient (−1 wall, +1 free end)

Junction 

where waves scatter or a source meets the string

Source 

a driving signal (bow velocity, pluck)

Load 

a lumped body; value: Hz, value2: Q

Resonator 

a modal source; value: Hz, value2: Q

Bandpass 

a banded-waveguide band; value: Hz, value2: Q

Gain 

value: the factor

Sum 

where signals add

Tap 

an output

Component 

a folded group, made by the renderer

Definition at line 26 of file graph.hpp.

◆ Wave

enum class sbl::dsp::diagram::Wave : uint8_t
strong

What travels along an edge.

Enumerator
Velocity 
Force 
Signal 

Definition at line 44 of file graph.hpp.

◆ Depth

enum class sbl::dsp::diagram::Depth : uint8_t
strong
Enumerator
Full 

every node, as the components described them

Components 

nested groups folded to one box each

Definition at line 22 of file mermaid.hpp.

Function Documentation

◆ render_mermaid()

Variable Documentation

◆ NO_GROUP

constexpr uint8_t sbl::dsp::diagram::NO_GROUP = 0xFF
constexpr

◆ NO_NODE