This commit is contained in:
2026-11-13 18:31:07 +06:00
parent 3a16ac0c0e
commit bb258484df
7 changed files with 153 additions and 9 deletions
+7 -2
View File
@@ -4,7 +4,11 @@
#include <cstdint>
#include <numbers>
#include <cmath>
#include <atomic>
#include "../include/envelope.hpp"
#include "../include/spsc_queue.hpp"
#include "../include/command.hpp"
class Synth {
public:
@@ -21,8 +25,8 @@ class Synth {
void set_frequency(double value);
void set_amplitude(double value);
void note_on();
void note_off();
bool note_on();
bool note_off();
private:
/* 1. частота звука в Герцах
@@ -31,6 +35,7 @@ class Synth {
4. фаза. от 0 до 2 пи*/
Envelope envelope;
SpscQueue queue;
double frequency;
double amplitude;