Skip to content

Commit

Permalink
Pull request #86: Main => deploy
Browse files Browse the repository at this point in the history
Merge in VSTSDK/vst3_dev_portal from main to deploy

* commit '0b097255362f6cf90ccf1c862d6ee2166c7ac809':
  [fix] doc review
  [fix] doc review
  • Loading branch information
ygrabit committed Oct 11, 2023
2 parents ace5350 + 0b09725 commit b6ea131
Show file tree
Hide file tree
Showing 16 changed files with 55 additions and 55 deletions.
22 changes: 11 additions & 11 deletions src/.vst3_tutorials/advanced-techniques-tutorial/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,15 @@

## Tutorial - Advanced Techniques

In this tutorial you will learn:
In this tutorial, you will learn:

- How to add nearly sample accurate parameter changes to an audio effect
- Using C++ templates to write one algorithm supporting 32 bit and 64 bit audio processing
- Setting the state of the audio effect in a thread safe manner
- How to add nearly sample-accurate parameter changes to an audio effect
- How to use C++ templates to write one algorithm supporting 32 bit and 64 bit audio processing
- How to set the state of the audio effect in a thread safe manner

---

## Part 1: Sample accurate parameter handling
## Part 1: Sample-accurate parameter handling

We will start by looking at this process function:

Expand Down Expand Up @@ -156,7 +156,7 @@ void MyEffect::handleParameterChanges (IParameterChanges*inputParameterChanges)
in order to delegate the handling of the parameter changes to the *gainParameter* object.
Now we just need another small change in the process lambda to use the nearly sample accurate *gain* value. We have to call the *gainParameter* object to *advance* the parameter value:
Now we just need another small change in the process lambda to use the nearly sample-accurate *gain* value. We have to call the *gainParameter* object to *advance* the parameter value:
``` c++
auto doProcessing = [this] (ProcessData& data) {
Expand Down Expand Up @@ -209,9 +209,9 @@ void MyEffect::process (ProcessData& data)
}
```
Now we have nearly sample accurate parameter changes support in this example. Every 8 samples the *gain* parameter will be updated to the correct value.
Now we have nearly sample-accurate parameter changes support in this example. Every 8 samples the *gain* parameter will be updated to the correct value.
It's very simple to make this 100% sample accurate, check out the **AGain sample accurate** example in the SDK.
It's very simple to make this 100% sample-accurate, check out the **AGain Sample Accurate** example in the SDK.
---
Expand All @@ -221,7 +221,7 @@ The example currently only supports 32 bit processing. Now we will add 64 bit pr
As you may have noticed above the *ProcessDataSlicer* uses a template parameter for its process function. This template parameter *SampleSize* defines the bit depth of the audio buffers in the *ProcessData* structure. This is currently hard-coded to be *SymbolicSampleSizes::kSample32*.
In order to support *SymbolicSampleSizes::kSample64* we only have to make a few changes to the code. First we adopt the algorithm part by introducing a new templated method to our effect:
In order to support *SymbolicSampleSizes::kSample64* we only have to make a few changes to the code. First, we adopt the algorithm part by introducing a new templated method to our effect:
``` c++
template <SymbolicSampleSizes SampleSize>
Expand Down Expand Up @@ -340,7 +340,7 @@ tresult PLUGIN_API MyEffect::canProcessSampleSize (int32symbolicSampleSize)
}
```
Now we have sample accurate parameter changes and 32 and 64 bit audio processing.
Now we have sample-accurate parameter changes and 32 and 64 bit audio processing.
---
Expand Down Expand Up @@ -421,7 +421,7 @@ tresult PLUGIN_API MyEffect::terminate ()
}
```

If the model data uses more memory and you want to get rid of it earlier you have to use a timer or similar to call the clear_ui method a little bit after the setState method was called. But this is not the scope of this tutorial.
If the model data uses more memory and you want to get rid of it in advance, use a timer or something similar to call the clear_ui method a little bit after the setState method was called. But this is not the scope of this tutorial.

If you want to use the utility classes, you will find them in the sdk at:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,25 +36,25 @@ BEGIN_FACTORY_DEF ("Steinberg Media Technologies",
// its kVstAudioEffectClass component
DEF_CLASS2 (INLINE_UID_FROM_FUID(ProcessorUID),
PClassInfo::kManyInstances, // cardinality
kVstAudioEffectClass, // the component category (do not changed this)
kVstAudioEffectClass, // the component category (do not change this)
stringPluginName, // here the Plug-in name (to be changed)
Vst::kDistributable, // means that component and controller could be distributed on different computers
DataExchangeVST3Category, // Subcategory for this Plug-in (to be changed)
DataExchangeVST3Category, // Subcategory for this plug-in (to be changed)
FULL_VERSION_STR, // Plug-in version (to be changed)
kVstVersionString, // the VST 3 SDK version (do not changed this, use always this define)
kVstVersionString, // the VST 3 SDK version (do not change this, always use this define)
createProcessorInstance)// function pointer called when this component should be instantiated

// its kVstComponentControllerClass component
DEF_CLASS2 (INLINE_UID_FROM_FUID (ControllerUID),
PClassInfo::kManyInstances, // cardinality
kVstComponentControllerClass,// the Controller category (do not changed this)
stringPluginName "Controller", // controller name (could be the same than component name)
kVstComponentControllerClass,// the Controller category (do not change this)
stringPluginName "Controller", // controller name (can be the same as the component name)
0, // not used here
"", // not used here
FULL_VERSION_STR, // Plug-in version (to be changed)
kVstVersionString, // the VST 3 SDK version (do not changed this, use always this define)
kVstVersionString, // the VST 3 SDK version (do not change this, always use this define)
createControllerInstance)// function pointer called when this component should be instantiated

//----for others Plug-ins contained in this factory, put like for the first Plug-in different DEF_CLASS2---
//----for others plug-ins contained in this factory, same as for the first Plug-in different DEF_CLASS2---

END_FACTORY
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@

#define stringOriginalFilename "advanced-techniques-tutorial.vst3"
#if SMTG_PLATFORM_64
#define stringFileDescription "advanced-techniques-tutorial VST3 (64Bit)"
#define stringFileDescription "advanced-techniques-tutorial VST 3 (64Bit)"
#else
#define stringFileDescription "advanced-techniques-tutorial VST3"
#define stringFileDescription "advanced-techniques-tutorial VST 3"
#endif
#define stringCompanyName "Steinberg Media Technologies\0"
#define stringLegalCopyright "Copyright(c) 2023 Steinberg Media Technologies."
Expand Down
22 changes: 11 additions & 11 deletions src/.vst3_tutorials/dataexchange-tutorial/README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Data Exchange Tutorial Plug-in

This tutorial shows how to use the Data Exchange API via the backwards compatible wrapper class which either uses the API directly if available or uses an alternative IMessage based method to provide the same functionality for hosts not implementing the API.
This tutorial explains how to use the Data Exchange API via the backwards-compatible wrapper class, which either uses the API directly, if available, or an alternative IMessage based method to provide the same functionality for hosts not implementing the API.

In this example the audio processor sends the samples it processes to the controller in 1 second big chunks.
In this example, the audio processor sends the samples it processes to the controller in chunks, each with a duration of one second.

---

Expand Down Expand Up @@ -30,21 +30,21 @@ In this example the audio processor sends the samples it processes to the contro

## Tutorial - How to use the Data Exchange API

In this tutorial you learn how to use the Data Exchange API to send data from the realtime audio
In this tutorial, you learn how to use the Data Exchange API to send data from the realtime audio
process method to the edit controller of your plug-in.

### Sending data from the audio processor

Let's send data from the processor to the controller.

First we need to add the required include so that we can use the wrapper class. Add the following
First, we need to add the required include so that we can use the wrapper class. Add the following
include before you define your audio processor:

```c++
#include "public.sdk/source/vst/utility/dataexchange.h"
```

To prepare the AudioEffect class you need to overwrite the following methods:
To prepare the AudioEffect class, you need to overwrite the following methods:

```c++
tresult PLUGIN_API initialize (FUnknown* context) override;
Expand Down Expand Up @@ -90,10 +90,10 @@ tresult PLUGIN_API DataExchangeProcessor::connect (Vst::IConnectionPoint* other)
}
```
The configration is done via the `configCallback`. In this example we configure the queue to have
The configration is done via the `configCallback`. In this example, we configure the queue to have
a block size to store exactly 1 second of audio data of all the channels of the configured speaker
arrangement of the input bus. We choose two for `numBlocks` because we send one block per second
and in this case two blocks should be enough. If the frequency you need to send the block is higher
arrangement of the input bus. We choose two for `numBlocks` because we send one block per second,
and in this case, two blocks should be enough. If the frequency you need to send the block is higher,
you need to increase this value to prevent data drop outs.
The `configCallback` is called when the audio processor is activated.
Expand Down Expand Up @@ -125,8 +125,8 @@ tresult PLUGIN_API DataExchangeProcessor::setActive (TBool state)
}
```
Now we prepare the data that we want to send to the controller. To make this a little bit easier we
define a struct how this data should look like and move this into its own header "dataexchange.h":
Now we prepare the data that we want to send to the controller. To make this a little bit easier, we
define a struct that specifies what should look like and move this into its own header "dataexchange.h":
```c++
// dataexchange.h
Expand Down Expand Up @@ -352,7 +352,7 @@ private:
}
```
First we need to forward messages to the `DataExchangeReceiverHandler` so that it can process the
First, we need to forward messages to the `DataExchangeReceiverHandler` so that it can process the
data exchange messages when the host does not support the native API:
```c++
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class DataExchangeController : public Vst::EditControllerEx1, public Vst::IDataE
bool onBackgroundThread) override;
//---Interface---------
DEFINE_INTERFACES
// Here you can add more supported VST3 interfaces
// Here you can add more supported VST 3 interfaces
DEF_INTERFACE (Vst::IDataExchangeReceiver)
END_DEFINE_INTERFACES (EditController)
DELEGATE_REFCOUNT (EditController)
Expand Down
14 changes: 7 additions & 7 deletions src/.vst3_tutorials/dataexchange-tutorial/source/entry.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,25 +29,25 @@ BEGIN_FACTORY_DEF ("Steinberg Media Technologies",
// its kVstAudioEffectClass component
DEF_CLASS2 (INLINE_UID_FROM_FUID(kDataExchangeProcessorUID),
PClassInfo::kManyInstances, // cardinality
kVstAudioEffectClass, // the component category (do not changed this)
kVstAudioEffectClass, // the component category (do not change this)
stringPluginName, // here the Plug-in name (to be changed)
Vst::kDistributable, // means that component and controller could be distributed on different computers
DataExchangeVST3Category, // Subcategory for this Plug-in (to be changed)
DataExchangeVST3Category, // Subcategory for this plug-in (to be changed)
FULL_VERSION_STR, // Plug-in version (to be changed)
kVstVersionString, // the VST 3 SDK version (do not changed this, use always this define)
kVstVersionString, // the VST 3 SDK version (do not change this, always use this define)
DataExchangeProcessor::createInstance) // function pointer called when this component should be instantiated

// its kVstComponentControllerClass component
DEF_CLASS2 (INLINE_UID_FROM_FUID (kDataExchangeControllerUID),
PClassInfo::kManyInstances, // cardinality
kVstComponentControllerClass,// the Controller category (do not changed this)
stringPluginName "Controller", // controller name (could be the same than component name)
kVstComponentControllerClass,// the Controller category (do not change this)
stringPluginName "Controller", // controller name (can be the same as the component name)
0, // not used here
"", // not used here
FULL_VERSION_STR, // Plug-in version (to be changed)
kVstVersionString, // the VST 3 SDK version (do not changed this, use always this define)
kVstVersionString, // the VST 3 SDK version (do not change this, always use this define)
DataExchangeController::createInstance)// function pointer called when this component should be instantiated

//----for others Plug-ins contained in this factory, put like for the first Plug-in different DEF_CLASS2---
//----for others plug-ins contained in this factory, same as for the first Plug-in different DEF_CLASS2---

END_FACTORY
2 changes: 1 addition & 1 deletion src/pages/FAQ/Communication.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ IAudioProcessor::process (processData)
}
```
Automation data is transmitted as a list of parameter changes. This list always contains enough information to transmit the original automation curve from the host in a sample accurate way. Check the [AGain](../What+is+the+VST+3+SDK/Plug-in+Examples.md#again) example to see how it can be implemented.
Automation data is transmitted as a list of parameter changes. This list always contains enough information to transmit the original automation curve from the host in a sample-accurate way. Check the [AGain](../What+is+the+VST+3+SDK/Plug-in+Examples.md#again) example to see how it can be implemented.
See also [Parameters and Automation](../Technical+Documentation/Parameters+Automation/Index.md)
Expand Down
2 changes: 1 addition & 1 deletion src/pages/FAQ/Processing.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ The implementation of the bypass feature is entirely the responsibility of the p

The [IIAudioProcessor::process](https://steinbergmedia.github.io/vst3_doc/vstinterfaces/classSteinberg_1_1Vst_1_1IAudioProcessor.html#a6b98eb31cf38ba96a28b303c13c64e13) method will continue to be called. The plug-in must take care of artifact-free switching (ramping/fade-in/fade-out, parallel processing or algorithm changes) and must also provide a delayed action if the plug-in has a latency and be sure that the output buffers are providing a copy of the input buffers (eventually delayed). No need to copy the input buffers to the output buffers when the pointers are the same and the plug-in has no latency!

This is the choice of the plug-in to handle/process the bypass (like any other parameters) sample accurate (by using the sampleOffset of the parameter change) or audio block based (not recommended when the audio block length is too large > 1024).
This is the choice of the plug-in to handle/process the bypass (like any other parameters) sample-accurate (by using the sampleOffset of the parameter change) or audio block based (not recommended when the audio block length is too large > 1024).

During bypass the process is still called, but if not, for some reason, the host may call a flush (using process call with null audio buffer).

Expand Down
4 changes: 2 additions & 2 deletions src/pages/Technical+Documentation/Data+Exchange/Index.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ Version 3.7.9 of the SDK contains the new *Data Exchange* API to send data from
processing function to the controller in a safe and efficient way.

As this API needs support from the host and not all hosts will provide this API in the beginning
the SDK contains a backwards compatibility layer that either uses the API directly if available or
uses an alternative method based on the IMessage API to emulate the API. See the
the SDK contains a backwards compatibility layer that either uses the API directly, if available, or
an alternative method based on the IMessage API to emulate the API. See the
[tutorial](../../Tutorials/Data+Exchange.md) on how to use it.

## The Data Exchange API
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ For reporting the results of a text input value change for a continuous or a dis

In **VST 3**, automation playback is the task of the plug-in and it is the host's task to provide the automation data. The only way for a parameter change to arrive in the processor is the processing call. Receiving parameter changes from the edit controller and playing back automation data is one and the same thing.

The need to perform all transformations, from the normalized GUI representation to the DSP representation, produces some overhead. Performing sample accurate automation requires even more overhead, because the DSP value must be calculated for each single sample. While this cannot be avoided entirely, it is the choice of the plug-in implementation how much processing time to spend on automation accuracy. The host always transmits value changes in a way that allows a sample accurate reconstruction of the underlying automation curve. The plug-in is responsible for the realization.
The need to perform all transformations, from the normalized GUI representation to the DSP representation, produces some overhead. Performing sample-accurate automation requires even more overhead, because the DSP value must be calculated for each single sample. While this cannot be avoided entirely, it is the choice of the plug-in implementation how much processing time to spend on automation accuracy. The host always transmits value changes in a way that allows a sample-accurate reconstruction of the underlying automation curve. The plug-in is responsible for the realization.

![Tech_doc_12](../../../resources/tech_doc_12.jpg)

Expand Down
6 changes: 3 additions & 3 deletions src/pages/Tutorials/Code+your+first+plug-in.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ tresult PLUGIN_API PlugProcessor::process (Vst::ProcessData&data)
for (int32 index = 0; index < numParamsChanged; index++)
{
// for this parameter we could iterate the list of value changes (could 1 per audio block or more!)
// in this example we get only the last value (getPointCount - 1)
// in this example, we get only the last value (getPointCount - 1)
Vst::IParamValueQueue* paramQueue = data.inputParameterChanges->getParameterData (index);
if (paramQueue)
{
Expand Down Expand Up @@ -310,7 +310,7 @@ tresult PLUGIN_API PlugProcessor::initialize (FUnknown* context)
```

>**Note**\
>In this example we add 1 input event bus, receiving only on 1 channel. If you need to receive differentiated events, for example, from different channels, just change it like this:
>In this example, we add 1 input event bus, receiving only on 1 channel. If you need to receive differentiated events, for example, from different channels, just change it like this:
>
>addEventInput (STR16 ("Event In"), 4); // here 4 channels
Expand Down Expand Up @@ -409,7 +409,7 @@ tresult PLUGIN_API PlugProcessor::process (Vst::ProcessData&data)
In our example we want to modulate our main audio input with a [Side-chain](../Technical+Documentation/Change+History/3.0.0/Multiple+Dynamic+IO.html#what-is-a-side-chain) audio input.
1. First add a new side-chain audio input (busType: ***kAux***) in the **initialize** call of our processor:
1. First, add a new side-chain audio input (busType: ***kAux***) in the **initialize** call of our processor:
**plugprocessor.cpp**
Expand Down
8 changes: 4 additions & 4 deletions src/pages/Tutorials/Index.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,11 +67,11 @@ This tutorial explains how to send data from the realtime process to the edit co

[Link](Advanced+VST+3+techniques.md)

In this tutorial you will learn:
In this tutorial, you will learn:

- How to add nearly sample accurate parameter changes to an audio effect
- Using C++ templates to write one algorithm supporting 32 bit and 64 bit audio processing
- Setting the state of the audio effect in a thread safe manner
- How to add nearly sample-accurate parameter changes to an audio effect
- How to use C++ templates to write one algorithm supporting 32 bit and 64 bit audio processing
- How to set the state of the audio effect in a thread safe manner

## How to use the silence flags

Expand Down
2 changes: 1 addition & 1 deletion src/pages/Versions/Version+3.7.3.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
- Add restartComponent (kKeyswitchChanged) / restartComponent (kNoteExpressionChanged) / restartComponent (kParamValuesChanged)
- Add support of ivstparameterfunctionname in Panner sample
- New VST 3 plug-ins example:
- New "AGain Sample Accurate" showing sample accurate parameter changes processing
- New "AGain Sample Accurate" showing sample-accurate parameter changes processing
- Fix editorHost when launch without arguments
- Fix crash in VST3Inspector when no VST 3 plug-ins available
- Fix warnings for mda plug-ins
Expand Down
Loading

0 comments on commit b6ea131

Please sign in to comment.