diff --git a/src/wavetable.cpp b/src/wavetable.cpp new file mode 100644 index 0000000..a52393d --- /dev/null +++ b/src/wavetable.cpp @@ -0,0 +1,8 @@ +#include "wavetable.h" + +std::string Wavetable::name() { + std::string id_str = std::to_string(m_id); + id_str.append(": "); + id_str.append(m_name); + return id_str; +} diff --git a/src/wavetable.h b/src/wavetable.h index d3490f6..2e75ba9 100644 --- a/src/wavetable.h +++ b/src/wavetable.h @@ -9,18 +9,13 @@ /* Table of single cycle wave lookup tables */ class Wavetable { -private: + private: uint16_t m_id{}; // Unique ID number of wavetable std::string m_name{}; // String name of wavetable std::array m_table; // table data public: - std::string name() { - std::string id_str = std::to_string(m_id); - id_str.append(": "); - id_str.append(m_name); - return id_str; - } + std::string name(); void set_table(std::array table) { m_table = table; } };