JUCE-7.0.12-0-g4f43011b96 JUCE-7.0.12-0-g4f43011b96
JUCE — C++ application framework with suport for VST, VST3, LV2 audio plug-ins

« « « Anklang Documentation
Loading...
Searching...
No Matches
ivstaudioprocessor.h
Go to the documentation of this file.
1 //------------------------------------------------------------------------
2// Project : VST SDK
3//
4// Category : Interfaces
5// Filename : pluginterfaces/vst/ivstaudioprocessor.h
6// Created by : Steinberg, 10/2005
7// Description : VST Audio Processing Interfaces
8//
9//-----------------------------------------------------------------------------
10// This file is part of a Steinberg SDK. It is subject to the license terms
11// in the LICENSE file found in the top-level directory of this distribution
12// and at www.steinberg.net/sdklicenses.
13// No part of the SDK, including this file, may be copied, modified, propagated,
14// or distributed except according to the terms contained in the LICENSE file.
15//-----------------------------------------------------------------------------
16
17#pragma once
18
19#include "ivstcomponent.h"
20#include "vstspeaker.h"
21
22//------------------------------------------------------------------------
24//------------------------------------------------------------------------
25
26//------------------------------------------------------------------------
28//------------------------------------------------------------------------
29#ifndef kVstAudioEffectClass
30#define kVstAudioEffectClass "Audio Module Class"
31#endif
32
33//------------------------------------------------------------------------
34namespace Steinberg {
35namespace Vst {
36
37class IEventList;
38class IParameterChanges;
39struct ProcessContext;
40
41//------------------------------------------------------------------------
43namespace PlugType
44{
48//------------------------------------------------------------------------
49SMTG_CONSTEXPR const CString kFx = "Fx";
50SMTG_CONSTEXPR const CString kFxAnalyzer = "Fx|Analyzer";
51SMTG_CONSTEXPR const CString kFxDelay = "Fx|Delay";
52SMTG_CONSTEXPR const CString kFxDistortion = "Fx|Distortion";
53SMTG_CONSTEXPR const CString kFxDynamics = "Fx|Dynamics";
54SMTG_CONSTEXPR const CString kFxEQ = "Fx|EQ";
55SMTG_CONSTEXPR const CString kFxFilter = "Fx|Filter";
56SMTG_CONSTEXPR const CString kFxGenerator = "Fx|Generator";
57SMTG_CONSTEXPR const CString kFxInstrument = "Fx|Instrument";
58SMTG_CONSTEXPR const CString kFxInstrumentExternal = "Fx|Instrument|External";
59SMTG_CONSTEXPR const CString kFxMastering = "Fx|Mastering";
60SMTG_CONSTEXPR const CString kFxModulation = "Fx|Modulation";
61SMTG_CONSTEXPR const CString kFxNetwork = "Fx|Network";
62SMTG_CONSTEXPR const CString kFxPitchShift = "Fx|Pitch Shift";
63SMTG_CONSTEXPR const CString kFxRestoration = "Fx|Restoration";
64SMTG_CONSTEXPR const CString kFxReverb = "Fx|Reverb";
65SMTG_CONSTEXPR const CString kFxSpatial = "Fx|Spatial";
66SMTG_CONSTEXPR const CString kFxSurround = "Fx|Surround";
67SMTG_CONSTEXPR const CString kFxTools = "Fx|Tools";
68SMTG_CONSTEXPR const CString kFxVocals = "Fx|Vocals";
69
70SMTG_CONSTEXPR const CString kInstrument = "Instrument";
71SMTG_CONSTEXPR const CString kInstrumentDrum = "Instrument|Drum";
72SMTG_CONSTEXPR const CString kInstrumentExternal = "Instrument|External";
73SMTG_CONSTEXPR const CString kInstrumentPiano = "Instrument|Piano";
74SMTG_CONSTEXPR const CString kInstrumentSampler = "Instrument|Sampler";
75SMTG_CONSTEXPR const CString kInstrumentSynth = "Instrument|Synth";
76SMTG_CONSTEXPR const CString kInstrumentSynthSampler = "Instrument|Synth|Sampler";
77
78SMTG_CONSTEXPR const CString kAmbisonics = "Ambisonics";
79SMTG_CONSTEXPR const CString kAnalyzer = "Analyzer";
80SMTG_CONSTEXPR const CString kNoOfflineProcess = "NoOfflineProcess";
81SMTG_CONSTEXPR const CString kOnlyARA = "OnlyARA";
82SMTG_CONSTEXPR const CString kOnlyOfflineProcess = "OnlyOfflineProcess";
83SMTG_CONSTEXPR const CString kOnlyRealTime = "OnlyRT";
84SMTG_CONSTEXPR const CString kSpatial = "Spatial";
85SMTG_CONSTEXPR const CString kSpatialFx = "Spatial|Fx";
86SMTG_CONSTEXPR const CString kUpDownMix = "Up-Downmix";
87
88SMTG_CONSTEXPR const CString kMono = "Mono";
89SMTG_CONSTEXPR const CString kStereo = "Stereo";
90SMTG_CONSTEXPR const CString kSurround = "Surround";
91
92//------------------------------------------------------------------------
94}
95
96//------------------------------------------------------------------------
99{
100//------------------------------------------------------------------------
101 kDistributable = 1 << 0,
102 kSimpleModeSupported = 1 << 1
103//------------------------------------------------------------------------
105
106//------------------------------------------------------------------------
115
116//------------------------------------------------------------------------
144
145//------------------------------------------------------------------------
151static const uint32 kNoTail = 0;
152
153//------------------------------------------------------------------------
159static const uint32 kInfiniteTail = kMaxInt32u;
160
161//------------------------------------------------------------------------
166{
167//------------------------------------------------------------------------
172//------------------------------------------------------------------------
173};
174
175//------------------------------------------------------------------------
192{
193 AudioBusBuffers () : numChannels (0), silenceFlags (0), channelBuffers64 (nullptr) {}
194
195//------------------------------------------------------------------------
198 union
199 {
200 Sample32** channelBuffers32;
201 Sample64** channelBuffers64;
202 };
203//------------------------------------------------------------------------
204};
205
206//------------------------------------------------------------------------
214{
215 ProcessData ()
216 : processMode (0)
218 , numSamples (0)
219 , numInputs (0)
220 , numOutputs (0)
221 , inputs (nullptr)
222 , outputs (nullptr)
223 , inputParameterChanges (nullptr)
224 , outputParameterChanges (nullptr)
225 , inputEvents (nullptr)
226 , outputEvents (nullptr)
227 , processContext (nullptr)
228 {
229 }
230
231//------------------------------------------------------------------------
235 int32 numInputs;
239
245//------------------------------------------------------------------------
246};
247
248//------------------------------------------------------------------------
259{
260public:
261//------------------------------------------------------------------------
282 virtual tresult PLUGIN_API setBusArrangements (SpeakerArrangement* inputs, int32 numIns,
283 SpeakerArrangement* outputs, int32 numOuts) = 0;
284
288 virtual tresult PLUGIN_API getBusArrangement (BusDirection dir, int32 index, SpeakerArrangement& arr) = 0;
289
291 virtual tresult PLUGIN_API canProcessSampleSize (int32 symbolicSampleSize) = 0;
292
300 virtual uint32 PLUGIN_API getLatencySamples () = 0;
301
303 virtual tresult PLUGIN_API setupProcessing (ProcessSetup& setup) = 0;
304
314 virtual tresult PLUGIN_API setProcessing (TBool state) = 0;
315
317 virtual tresult PLUGIN_API process (ProcessData& data) = 0;
318
328 virtual uint32 PLUGIN_API getTailSamples () = 0;
329
330//------------------------------------------------------------------------
331 static const FUID iid;
332};
333
334DECLARE_CLASS_IID (IAudioProcessor, 0x42043F99, 0xB7DA453C, 0xA569E79D, 0x9AAEC33D)
335
336//------------------------------------------------------------------------
367{
368public:
369 //------------------------------------------------------------------------
371 virtual tresult PLUGIN_API setAudioPresentationLatencySamples (BusDirection dir, int32 busIndex, uint32 latencyInSamples) = 0;
372
373 //------------------------------------------------------------------------
374 static const FUID iid;
375};
376
377DECLARE_CLASS_IID (IAudioPresentationLatency, 0x309ECE78, 0xEB7D4fae, 0x8B2225D9, 0x09FD08B6)
378
379//------------------------------------------------------------------------
400{
401public:
402 enum Flags
403 {
404 kNeedSystemTime = 1 << 0, // kSystemTimeValid
405 kNeedContinousTimeSamples = 1 << 1, // kContTimeValid
406 kNeedProjectTimeMusic = 1 << 2, // kProjectTimeMusicValid
407 kNeedBarPositionMusic = 1 << 3, // kBarPositionValid
408 kNeedCycleMusic = 1 << 4, // kCycleValid
409 kNeedSamplesToNextClock = 1 << 5, // kClockValid
410 kNeedTempo = 1 << 6, // kTempoValid
411 kNeedTimeSignature = 1 << 7, // kTimeSigValid
412 kNeedChord = 1 << 8, // kChordValid
413 kNeedFrameRate = 1 << 9, // kSmpteValid
414 kNeedTransportState = 1 << 10, // kPlaying, kCycleActive, kRecording
415 };
416 virtual uint32 PLUGIN_API getProcessContextRequirements () = 0;
417//------------------------------------------------------------------------
418 static const FUID iid;
419};
420
421DECLARE_CLASS_IID (IProcessContextRequirements, 0x2A654303, 0xEF764E3D, 0x95B5FE83, 0x730EF6D0)
422
423//------------------------------------------------------------------------
424} // namespace Vst
425} // namespace Steinberg
426
427//------------------------------------------------------------------------
429//------------------------------------------------------------------------
Handling 16 Byte Globally Unique Identifiers.
Definition funknown.h:241
The basic interface of all interfaces.
Definition funknown.h:375
Extended IAudioProcessor interface for a component: Vst::IAudioPresentationLatency.
virtual tresult PLUGIN_API setAudioPresentationLatencySamples(BusDirection dir, int32 busIndex, uint32 latencyInSamples)=0
Informs the plug-in about the Audio Presentation Latency in samples for a given direction (kInput/kOu...
Audio processing interface: Vst::IAudioProcessor.
virtual tresult PLUGIN_API setProcessing(TBool state)=0
Informs the plug-in about the processing state.
virtual tresult PLUGIN_API setupProcessing(ProcessSetup &setup)=0
Called in disable state (setActive not called with true) before setProcessing is called and processin...
virtual tresult PLUGIN_API process(ProcessData &data)=0
The Process call, where all information (parameter changes, event, audio buffer) are passed.
virtual tresult PLUGIN_API getBusArrangement(BusDirection dir, int32 index, SpeakerArrangement &arr)=0
Gets the bus arrangement for a given direction (input/output) and index.
virtual uint32 PLUGIN_API getTailSamples()=0
Gets tail size in samples.
virtual tresult PLUGIN_API setBusArrangements(SpeakerArrangement *inputs, int32 numIns, SpeakerArrangement *outputs, int32 numOuts)=0
Try to set (host => plug-in) a wanted arrangement for inputs and outputs.
virtual uint32 PLUGIN_API getLatencySamples()=0
Gets the current Latency in samples.
virtual tresult PLUGIN_API canProcessSampleSize(int32 symbolicSampleSize)=0
Asks if a given sample size is supported see SymbolicSampleSizes.
List of events to process: Vst::IEventList.
Definition ivstevents.h:197
All parameter changes of a processing block: Vst::IParameterChanges.
Extended IAudioProcessor interface for a component: Vst::IProcessContextRequirements.
SMTG_CONSTEXPR const CString kInstrumentExternal
External Instrument (wrapped Hardware)
SMTG_CONSTEXPR const CString kFxReverb
Reverberation, Room Simulation, Convolution Reverb...
SMTG_CONSTEXPR const CString kFxEQ
Equalization, Graphical EQ...
SMTG_CONSTEXPR const CString kFxTools
Volume, Mixer, Tuner...
SMTG_CONSTEXPR const CString kFxInstrumentExternal
Fx which could be loaded as Instrument too and is external (wrapped Hardware)
SMTG_CONSTEXPR const CString kFxVocals
Tools dedicated to vocals.
SMTG_CONSTEXPR const CString kInstrumentDrum
Instrument for Drum sounds.
SMTG_CONSTEXPR const CString kSpatial
used for SurroundPanner
SMTG_CONSTEXPR const CString kFx
others type (not categorized)
SMTG_CONSTEXPR const CString kMono
used for Mono only plug-in [optional]
SMTG_CONSTEXPR const CString kFxNetwork
using Network
SMTG_CONSTEXPR const CString kSpatialFx
used for SurroundPanner and as insert effect
SMTG_CONSTEXPR const CString kInstrumentPiano
Instrument for Piano sounds.
SMTG_CONSTEXPR const CString kFxModulation
Phaser, Flanger, Chorus, Tremolo, Vibrato, AutoPan, Rotary, Cloner...
SMTG_CONSTEXPR const CString kFxMastering
Dither, Noise Shaping,...
SMTG_CONSTEXPR const CString kInstrumentSynthSampler
Instrument based on Synthesis and Samples.
SMTG_CONSTEXPR const CString kInstrumentSynth
Instrument based on Synthesis.
SMTG_CONSTEXPR const CString kAnalyzer
Meter, Scope, FFT-Display, not selectable as insert plug-in.
SMTG_CONSTEXPR const CString kNoOfflineProcess
will be NOT used for plug-in offline processing (will work as normal insert plug-in)
SMTG_CONSTEXPR const CString kFxRestoration
Denoiser, Declicker,...
SMTG_CONSTEXPR const CString kFxSurround
dedicated to surround processing: LFE Splitter, Bass Manager...
SMTG_CONSTEXPR const CString kFxDynamics
Compressor, Expander, Gate, Limiter, Maximizer, Tape Simulator, EnvelopeShaper...
SMTG_CONSTEXPR const CString kFxFilter
WahWah, ToneBooster, Specific Filter,...
SMTG_CONSTEXPR const CString kFxGenerator
Tone Generator, Noise Generator...
SMTG_CONSTEXPR const CString kOnlyARA
used for plug-ins that require ARA to operate (will not work as normal insert plug-in)
SMTG_CONSTEXPR const CString kFxDelay
Delay, Multi-tap Delay, Ping-Pong Delay...
SMTG_CONSTEXPR const CString kSurround
used for Surround only plug-in [optional]
SMTG_CONSTEXPR const CString kInstrumentSampler
Instrument based on Samples.
SMTG_CONSTEXPR const CString kAmbisonics
used for Ambisonics channel (FX or Panner/Mixconverter/Up-Mixer/Down-Mixer when combined with other c...
SMTG_CONSTEXPR const CString kUpDownMix
used for Mixconverter/Up-Mixer/Down-Mixer
SMTG_CONSTEXPR const CString kOnlyOfflineProcess
used for plug-in offline processing (will not work as normal insert plug-in)
SMTG_CONSTEXPR const CString kFxPitchShift
Pitch Processing, Pitch Correction, Vocal Tuning...
SMTG_CONSTEXPR const CString kFxInstrument
Fx which could be loaded as Instrument too.
SMTG_CONSTEXPR const CString kStereo
used for Stereo only plug-in [optional]
SMTG_CONSTEXPR const CString kFxDistortion
Amp Simulator, Sub-Harmonic, SoftClipper...
SMTG_CONSTEXPR const CString kOnlyRealTime
indicates that it supports only realtime process call, no processing faster than realtime
SMTG_CONSTEXPR const CString kInstrument
Effect used as instrument (sound generator), not as insert.
SMTG_CONSTEXPR const CString kFxAnalyzer
Scope, FFT-Display, Loudness Processing...
SMTG_CONSTEXPR const CString kFxSpatial
MonoToStereo, StereoEnhancer,...
double Sample64
64-bit precision audio sample
Definition vsttypes.h:98
ComponentFlags
Component Flags used as classFlags in PClassInfo2.
@ kDistributable
Component can be run on remote computer.
@ kSimpleModeSupported
Component supports simple IO mode (or works in simple mode anyway) see vst3IoMode.
int32 symbolicSampleSize
SymbolicSampleSizes
ProcessModes
Processing mode informs the plug-in about the context and at which frequency the process call is call...
@ kRealtime
realtime processing
@ kOffline
offline processing
@ kPrefetch
prefetch processing
float Sample32
32-bit precision audio sample
Definition vsttypes.h:97
int32 maxSamplesPerBlock
maximum number of samples per audio block
double SampleRate
sample rate
Definition vsttypes.h:99
int32 BusDirection
bus direction (in/out)
Definition vsttypes.h:76
SampleRate sampleRate
sample rate
uint64 SpeakerArrangement
Bitset of speakers.
Definition vsttypes.h:104
const char8 * CString
C-String.
Definition vsttypes.h:70
SymbolicSampleSizes
Symbolic sample size.
@ kSample32
32-bit precision
@ kSample64
64-bit precision
Processing buffers of an audio bus.
int32 numChannels
number of audio channels in bus
uint64 silenceFlags
Bitset of silence state per channel.
Audio processing context.
Any data needed in audio processing.
IEventList * inputEvents
incoming events for this block (optional)
int32 symbolicSampleSize
sample size - value of SymbolicSampleSizes
AudioBusBuffers * inputs
buffers of input busses
AudioBusBuffers * outputs
buffers of output busses
int32 numInputs
number of audio input busses
ProcessContext * processContext
processing context (optional, but most welcome)
int32 processMode
processing mode - value of ProcessModes
IEventList * outputEvents
outgoing events for this block (optional)
IParameterChanges * outputParameterChanges
outgoing parameter changes for this block (optional)
int32 numOutputs
number of audio output busses
int32 numSamples
number of samples to process
IParameterChanges * inputParameterChanges
incoming parameter changes for this block