rt-vamp-plugin-sdk
0.3.1
Real-time Vamp plugin SDK for C++20
|
Go to the documentation of this file.
16 explicit Plugin(
float inputSampleRate) : inputSampleRate_(inputSampleRate) {}
53 using InputBuffer = std::variant<TimeDomainBuffer, FrequencyDomainBuffer>;
62 virtual std::string_view
getName() const noexcept = 0;
64 virtual std::string_view
getMaker() const noexcept = 0;
65 virtual std::string_view
getCopyright() const noexcept = 0;
70 virtual std::optional<
float>
getParameter(std::string_view
id) const = 0;
71 virtual
bool setParameter(std::string_view
id,
float value) = 0;
83 virtual
bool initialise(uint32_t stepSize, uint32_t blockSize) = 0;
84 virtual
void reset() = 0;
90 const float inputSampleRate_;
std::optional< std::string_view > CurrentProgram
Current program (if programs avaiable)
Definition: Plugin.hpp:49
std::string_view name
Definition: Plugin.hpp:24
std::vector< float > Feature
Feature with one or more values (defined by OutputDescriptor::binCount)
Definition: Plugin.hpp:54
std::string identifier
Definition: Plugin.hpp:35
virtual uint32_t getPreferredStepSize() const =0
uint32_t binCount
Definition: Plugin.hpp:39
float maxValue
Definition: Plugin.hpp:43
std::string_view description
Definition: Plugin.hpp:25
Plugin(float inputSampleRate)
Definition: Plugin.hpp:16
std::string unit
Definition: Plugin.hpp:38
Definition: Plugin.hpp:34
Definition: Plugin.hpp:22
std::string name
Definition: Plugin.hpp:36
std::optional< float > quantizeStep
Definition: Plugin.hpp:44
virtual bool initialise(uint32_t stepSize, uint32_t blockSize)=0
virtual uint32_t getPreferredBlockSize() const =0
std::vector< std::string > binNames
Definition: Plugin.hpp:40
virtual std::string_view getMaker() const noexcept=0
float defaultValue
Definition: Plugin.hpp:27
virtual FeatureSet process(InputBuffer buffer, uint64_t nsec)=0
std::span< const std::string_view > ProgramList
List of programs.
Definition: Plugin.hpp:48
virtual std::optional< float > getParameter(std::string_view id) const =0
virtual std::filesystem::path getLibraryPath() const noexcept=0
std::variant< TimeDomainBuffer, FrequencyDomainBuffer > InputBuffer
Input buffer variant.
Definition: Plugin.hpp:53
virtual std::string_view getName() const noexcept=0
virtual ParameterList getParameterDescriptors() const noexcept=0
Definition: Plugin.hpp:12
std::string description
Definition: Plugin.hpp:37
virtual ProgramList getPrograms() const noexcept=0
virtual uint32_t getVampApiVersion() const noexcept=0
virtual CurrentProgram getCurrentProgram() const =0
Definition: Plugin.hpp:14
virtual int getPluginVersion() const noexcept=0
bool hasKnownExtents
Definition: Plugin.hpp:41
float maxValue
Definition: Plugin.hpp:29
std::span< const float > TimeDomainBuffer
Time domain buffer.
Definition: Plugin.hpp:51
std::string_view identifier
Definition: Plugin.hpp:23
virtual std::string_view getDescription() const noexcept=0
virtual ~Plugin()=default
InputDomain
Input domain of the plugin.
Definition: Plugin.hpp:20
std::vector< OutputDescriptor > OutputList
List of output descriptors.
Definition: Plugin.hpp:50
std::string_view unit
Definition: Plugin.hpp:26
virtual std::string_view getCopyright() const noexcept=0
virtual std::string_view getIdentifier() const noexcept=0
virtual InputDomain getInputDomain() const noexcept=0
std::span< const std::complex< float > > FrequencyDomainBuffer
Frequency domain buffer (FFT)
Definition: Plugin.hpp:52
virtual bool selectProgram(std::string_view name)=0
float minValue
Definition: Plugin.hpp:28
virtual OutputList getOutputDescriptors() const =0
std::optional< float > quantizeStep
Definition: Plugin.hpp:30
virtual uint32_t getOutputCount() const =0
float getInputSampleRate() const noexcept
Definition: Plugin.hpp:87
float minValue
Definition: Plugin.hpp:42
std::span< const Feature > FeatureSet
Computed features for each output.
Definition: Plugin.hpp:55
virtual bool setParameter(std::string_view id, float value)=0
std::vector< std::string_view > valueNames
Definition: Plugin.hpp:31
std::span< const ParameterDescriptor > ParameterList
List of parameter descriptors.
Definition: Plugin.hpp:47