#pragma once #include "config/ConfigService.hpp" #include "config/AudioConfig.hpp" #include "LoggerService.hpp" #include "Instruments/Instrument.hpp" #include "WavetableLoader.hpp" class InstrumentFactory { public: InstrumentFactory(ConfigService* config, LoggerService* logger); ~InstrumentFactory() = default; int32_t createInstruments(std::vector* instruments, size_t voiceCount, float sampleRate, AudioParams* params); enum class InstrumentType { Default, PianoString, WavetableOscillator }; private: Instrument* createInstrument(InstrumentType type, float sampleRate, AudioParams* params); ConfigService* config_; LoggerService* logger_; // optional creators WavetableLoader* wavetableLoader_ = nullptr; };