Vital
Loading...
Searching...
No Matches
line_map.h
Go to the documentation of this file.
1#pragma once
2
3#include "processor.h"
4
5class LineGenerator;
6
7namespace vital {
8
16 class LineMap : public Processor {
17 public:
19 static constexpr mono_float kMaxPower = 20.0f;
20
32
38 LineMap(LineGenerator* source);
39
45 virtual Processor* clone() const override { return new LineMap(*this); }
46
55 void process(int num_samples) override;
56
62 void process(poly_float phase);
63
64 protected:
67
68 JUCE_LEAK_DETECTOR(LineMap)
69 };
70} // namespace vital
A class for generating and storing a line shape, defined by a series of points and associated powers.
Definition line_generator.h:20
A processor that maps a phase input through a line generator, producing a value and phase output.
Definition line_map.h:16
void process(int num_samples) override
Processes a given number of samples at the current rate (audio or control).
Definition line_map.cpp:10
LineMap(LineGenerator *source)
Constructs a LineMap processor.
Definition line_map.cpp:8
virtual Processor * clone() const override
Creates a duplicate of this LineMap processor.
Definition line_map.h:45
MapOutput
Indices of the outputs produced by LineMap.
Definition line_map.h:27
@ kNumOutputs
Definition line_map.h:30
@ kValue
Definition line_map.h:28
@ kPhase
Definition line_map.h:29
static constexpr mono_float kMaxPower
The maximum allowable curvature/power for certain operations within the line mapping.
Definition line_map.h:19
poly_float offset_
An offset that could be applied to the output (not currently set in this code).
Definition line_map.h:65
LineGenerator * source_
The associated LineGenerator used for generating the values.
Definition line_map.h:66
Base class for all signal-processing units in Vital.
Definition processor.h:212
Contains classes and functions used within the Vital synthesizer framework.
float mono_float
Definition common.h:33
Declares the Processor class and related structures for handling audio processing in a polyphonic con...
Represents a vector of floating-point values using SIMD instructions.
Definition poly_values.h:600