diff --git a/modules/juce_audio_plugin_client/juce_audio_plugin_client_VST3.cpp b/modules/juce_audio_plugin_client/juce_audio_plugin_client_VST3.cpp index 39dc1c50b9..c6976780df 100644 --- a/modules/juce_audio_plugin_client/juce_audio_plugin_client_VST3.cpp +++ b/modules/juce_audio_plugin_client/juce_audio_plugin_client_VST3.cpp @@ -1748,6 +1748,8 @@ private: #endif } + ~JuceVST3Editor() override = default; // NOLINT + tresult PLUGIN_API queryInterface (const TUID targetIID, void** obj) override { const auto result = testFor (*this, targetIID, UniqueBase{}); @@ -1758,7 +1760,9 @@ private: return Vst::EditorView::queryInterface (targetIID, obj); } + // NOLINTBEGIN REFCOUNT_METHODS (Vst::EditorView) + // NOLINTEND //============================================================================== tresult PLUGIN_API isPlatformTypeSupported (FIDString type) override diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/LICENSE.txt b/modules/juce_audio_processors/format_types/VST3_SDK/LICENSE.txt index 6daa072e68..f5df1de438 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/LICENSE.txt +++ b/modules/juce_audio_processors/format_types/VST3_SDK/LICENSE.txt @@ -1,6 +1,6 @@ //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- This license applies only to files referencing this license, for other files of the Software Development Kit the respective embedded license text diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/README.md b/modules/juce_audio_processors/format_types/VST3_SDK/README.md index 191fe79948..3befbc0642 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/README.md +++ b/modules/juce_audio_processors/format_types/VST3_SDK/README.md @@ -19,10 +19,10 @@ - VST 3 API - VST 3 Implementation Helper Classes -- AAX, AU, AUv3 and VST 2 wrappers +- AAX, AUv3 and AU Wrappers - VST 3 plug-ins Examples -The full VST 3 SDK is available [here!](https://www.steinberg.net/en/company/developers.html). It contains : +The full VST 3 SDK is available [here!](https://www.steinberg.net/en/company/developers.html). It contains: - VST 3 plug-in Test Host Application/Validator, - the **Steinberg VST 3 Plug-In SDK Licensing Agreement** that you have to sign if you want to develop or host **VST 3** plug-ins. @@ -146,25 +146,6 @@ Some more features implemented specifically for developers include: git clone --recursive https://github.com/steinbergmedia/vst3sdk.git ``` -### Adding VST2 version - -The **VST 2 SDK** is not part anymore of the **VST 3 SDK**, you have to use an older version of the SDK and copy the vst2sdk folder into the VST_SDK folder. -In order to build a VST2 version of the plug-in and a VST3 at the same time, you need to copy the VST2 folder into the VST3 folder, simply run the following commands: - -- for macOS: - -```c -cd TheFolderWhereYouDownloadTheSDK -./copy_vst2_to_vst3_sdk.sh -``` - -- for Windows: - -```c -cd TheFolderWhereYouDownloadTheSDK -copy_vst2_to_vst3_sdk.bat -``` - ### Build the examples on Windows - Create a folder for the build and move to this folder (using cd): @@ -192,6 +173,7 @@ msbuild.exe vstsdk.sln // (or alternatively for example for release) cmake --build . --config Release ``` +Note: If you have any issue with symbolic links, check [Preparation on Windows](https://steinbergmedia.github.io/vst3_dev_portal/pages/Getting+Started/Preparation+on+Windows.html) for potential solutions. ### Build the examples on macOS diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/VST3_License_Agreement.pdf b/modules/juce_audio_processors/format_types/VST3_SDK/VST3_License_Agreement.pdf index ad8c399b48..ec7da49827 100644 Binary files a/modules/juce_audio_processors/format_types/VST3_SDK/VST3_License_Agreement.pdf and b/modules/juce_audio_processors/format_types/VST3_SDK/VST3_License_Agreement.pdf differ diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/LICENSE.txt b/modules/juce_audio_processors/format_types/VST3_SDK/base/LICENSE.txt index f9c531e745..ec797c8bd3 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/LICENSE.txt +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/LICENSE.txt @@ -1,6 +1,6 @@ //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/baseiids.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/baseiids.cpp index 7d12c713a4..0169c2ec20 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/baseiids.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/baseiids.cpp @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/classfactoryhelpers.h b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/classfactoryhelpers.h index 5a531e93d3..e4231358b3 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/classfactoryhelpers.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/classfactoryhelpers.h @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fbuffer.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fbuffer.cpp index 83866ea9bb..45dd41940a 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fbuffer.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fbuffer.cpp @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fbuffer.h b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fbuffer.h index 0a8c1ff6b5..e1efd2c5c2 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fbuffer.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fbuffer.h @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fcommandline.h b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fcommandline.h index 653fb7c629..dfbe364bda 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fcommandline.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fcommandline.h @@ -9,36 +9,36 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: -// -// * Redistributions of source code must retain the above copyright notice, +// +// * Redistributions of source code must retain the above copyright notice, // this list of conditions and the following disclaimer. // * Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation +// this list of conditions and the following disclaimer in the documentation // and/or other materials provided with the distribution. // * Neither the name of the Steinberg Media Technologies nor the names of its -// contributors may be used to endorse or promote products derived from this +// contributors may be used to endorse or promote products derived from this // software without specific prior written permission. -// +// // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. -// IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, -// INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -// LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE +// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +// IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, +// INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +// LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE // OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED // OF THE POSSIBILITY OF SUCH DAMAGE. //----------------------------------------------------------------------------- //------------------------------------------------------------------------ /** @file base/source/fcommandline.h - Very simple command-line parser. - @see Steinberg::CommandLine */ + Very simple command-line parser. + @see Steinberg::CommandLine */ //------------------------------------------------------------------------ #pragma once @@ -57,310 +57,336 @@ namespace Steinberg { Parses the command-line into a CommandLine::VariablesMap.\n The command-line parser uses CommandLine::Descriptions to define the available options. -@b Example: +@b Example: \code #include "base/source/fcommandline.h" #include int main (int argc, char* argv[]) { - using namespace std; + using namespace std; - CommandLine::Descriptions desc; - CommandLine::VariablesMap valueMap; + CommandLine::Descriptions desc; + CommandLine::VariablesMap valueMap; - desc.addOptions ("myTool") - ("help", "produce help message") - ("opt1", string(), "option 1") - ("opt2", string(), "option 2") - ; - CommandLine::parse (argc, argv, desc, valueMap); + desc.addOptions ("myTool") + ("help", "produce help message") + ("opt1", string(), "option 1") + ("opt2", string(), "option 2") + ; + CommandLine::parse (argc, argv, desc, valueMap); - if (valueMap.hasError () || valueMap.count ("help")) - { - cout << desc << "\n"; - return 1; - } - if (valueMap.count ("opt1")) - { - cout << "Value of option 1 " << valueMap["opt1"] << "\n"; - } - if (valueMap.count ("opt2")) - { - cout << "Value of option 2 " << valueMap["opt2"] << "\n"; - } - return 0; + if (valueMap.hasError () || valueMap.count ("help")) + { + cout << desc << "\n"; + return 1; + } + if (valueMap.count ("opt1")) + { + cout << "Value of option 1 " << valueMap["opt1"] << "\n"; + } + if (valueMap.count ("opt2")) + { + cout << "Value of option 2 " << valueMap["opt2"] << "\n"; + } + return 0; } \endcode @note This is a "header only" implementation.\n -If you need the declarations in more than one cpp file, you have to define +If you need the declarations in more than one cpp file, you have to define @c SMTG_NO_IMPLEMENTATION in all but one file. */ //------------------------------------------------------------------------ namespace CommandLine { - - //------------------------------------------------------------------------ - /** Command-line parsing result. - - This is the result of the parser.\n - - Use hasError() to check for errors.\n - - To test if a option was specified on the command-line use: count()\n - - To retrieve the value of an options, use operator [](const VariablesMapContainer::key_type k)\n - */ - //------------------------------------------------------------------------ - class VariablesMap - { - bool mParaError; - using VariablesMapContainer = std::map; - VariablesMapContainer mVariablesMapContainer; - public: - VariablesMap () : mParaError (false) {} ///< Constructor. Creates a empty VariablesMap. - bool hasError () const { return mParaError; } ///< Returns @c true when an error has occurred. - void setError () { mParaError = true; } ///< Sets the error state to @c true. - std::string& operator [](const VariablesMapContainer::key_type k); ///< Retrieve the value of option @c k. - const std::string& operator [](const VariablesMapContainer::key_type k) const; ///< Retrieve the value of option @c k. - VariablesMapContainer::size_type count (const VariablesMapContainer::key_type k) const; ///< Returns @c != @c 0 if command-line contains option @c k. - }; - //! type of the list of elements on the command line that are not handled by options parsing - using FilesVector = std::vector; +//------------------------------------------------------------------------ +/** Command-line parsing result. + This is the result of the parser.\n + - Use hasError() to check for errors.\n + - To test if a option was specified on the command-line use: count()\n + - To retrieve the value of an options, use operator [](const VariablesMapContainer::key_type + k)\n +*/ +//------------------------------------------------------------------------ +class VariablesMap +{ + bool mParaError; + using VariablesMapContainer = std::map; + VariablesMapContainer mVariablesMapContainer; - //------------------------------------------------------------------------ - /** The description of one single command-line option. - - Normally you rarely use a Description directly.\n - In most cases you will use the Descriptions::addOptions (const std::string&) method to create and add descriptions. - */ - //------------------------------------------------------------------------ - class Description : public std::string - { - public: - Description (const std::string& name, const std::string& help, const std::string& valueType ); ///< Construct a Description - std::string mHelp; ///< The help string for this option. - std::string mType; ///< The type of this option (kBool, kString). - static const std::string kBool; - static const std::string kString; - }; - //------------------------------------------------------------------------ - /** List of command-line option descriptions. +public: + VariablesMap () : mParaError (false) {} ///< Constructor. Creates a empty VariablesMap. + bool hasError () const { return mParaError; } ///< Returns @c true when an error has occurred. + void setError () { mParaError = true; } ///< Sets the error state to @c true. - Use addOptions(const std::string&) to add Descriptions. - */ - //------------------------------------------------------------------------ - class Descriptions - { - using DescriptionsList = std::deque; - DescriptionsList mDescriptions; - std::string mCaption; - public: - /** Sets the command-line tool caption and starts adding Descriptions. */ - Descriptions& addOptions (const std::string& caption = "", - std::initializer_list&& options = {}); - /** Parse the command-line. */ - bool parse (int ac, char* av[], VariablesMap& result, FilesVector* files = nullptr) const; - /** Print a brief description for the command-line tool into the stream @c os. */ - void print (std::ostream& os) const; - /** Add a new switch. Only */ - Descriptions& operator() (const std::string& name, const std::string& help); - /** Add a new option of type @c inType. Currently only std::string is supported. */ - template - Descriptions& operator () (const std::string& name, const Type& inType, std::string help); - }; + /** Retrieve the value of option @c k.*/ + std::string& operator[] (const VariablesMapContainer::key_type k); + /** Retrieve the value of option @c k. */ + const std::string& operator[] (const VariablesMapContainer::key_type k) const; + + /** Returns @c != @c 0 if command-line contains option @c k. */ + VariablesMapContainer::size_type count (const VariablesMapContainer::key_type k) const; +}; + +//! type of the list of elements on the command line that are not handled by options parsing +using FilesVector = std::vector; + +//------------------------------------------------------------------------ +/** The description of one single command-line option. + Normally you rarely use a Description directly.\n + In most cases you will use the Descriptions::addOptions (const std::string&) method to create + and add descriptions. +*/ +//------------------------------------------------------------------------ +class Description : public std::string +{ +public: + /** Construct a Description */ + Description (const std::string& name, const std::string& help, + const std::string& valueType); + std::string mHelp; ///< The help string for this option. + std::string mType; ///< The type of this option (kBool, kString). + static const std::string kBool; + static const std::string kString; +}; +//------------------------------------------------------------------------ +/** List of command-line option descriptions. + + Use addOptions (const std::string&) to add Descriptions. +*/ +//------------------------------------------------------------------------ +class Descriptions +{ + using DescriptionsList = std::deque; + DescriptionsList mDescriptions; + std::string mCaption; + +public: + /** Sets the command-line tool caption and starts adding Descriptions. */ + Descriptions& addOptions (const std::string& caption = "", + std::initializer_list&& options = {}); + + /** Parse the command-line. */ + bool parse (int ac, char* av[], VariablesMap& result, FilesVector* files = nullptr) const; + + /** Print a brief description for the command-line tool into the stream @c os. */ + void print (std::ostream& os) const; + + /** Add a new switch. Only */ + Descriptions& operator () (const std::string& name, const std::string& help); + + /** Add a new option of type @c inType. Currently only std::string is supported. */ + template + Descriptions& operator () (const std::string& name, const Type& inType, std::string help); +}; + //------------------------------------------------------------------------ // If you need the declarations in more than one cpp file you have to define // SMTG_NO_IMPLEMENTATION in all but one file. //------------------------------------------------------------------------ #ifndef SMTG_NO_IMPLEMENTATION - //------------------------------------------------------------------------ - /*! If command-line contains option @c k more than once, only the last value will survive. */ - //------------------------------------------------------------------------ - std::string& VariablesMap::operator [](const VariablesMapContainer::key_type k) - { - return mVariablesMapContainer[k]; - } - - //------------------------------------------------------------------------ - /*! If command-line contains option @c k more than once, only the last value will survive. */ - //------------------------------------------------------------------------ - const std::string& VariablesMap::operator [](const VariablesMapContainer::key_type k) const - { - return (*const_cast(this))[k]; - } - - //------------------------------------------------------------------------ - VariablesMap::VariablesMapContainer::size_type VariablesMap::count (const VariablesMapContainer::key_type k) const - { - return mVariablesMapContainer.count (k); - } - - //------------------------------------------------------------------------ - /** Add a new option with a string as parameter. */ - //------------------------------------------------------------------------ - template <> Descriptions& Descriptions::operator() (const std::string& name, const std::string& inType, std::string help) - { - mDescriptions.emplace_back (name, help, inType); - return *this; - } - bool parse (int ac, char* av[], const Descriptions& desc, VariablesMap& result, FilesVector* files = nullptr); ///< Parse the command-line. - std::ostream& operator<< (std::ostream& os, const Descriptions& desc); ///< Make Descriptions stream able. - - const std::string Description::kBool = "bool"; - const std::string Description::kString = "string"; - - //------------------------------------------------------------------------ - /*! In most cases you will use the Descriptions::addOptions (const std::string&) method to create and add descriptions. - - @param[in] name of the option. - @param[in] help a help description for this option. - @param[out] valueType Description::kBool or Description::kString. - */ - Description::Description (const std::string& name, const std::string& help, const std::string& valueType) - : std::string (name) - , mHelp (help) - , mType (valueType) - { - } +//------------------------------------------------------------------------ +/*! If command-line contains option @c k more than once, only the last value will survive. */ +//------------------------------------------------------------------------ +std::string& VariablesMap::operator[] (const VariablesMapContainer::key_type k) +{ + return mVariablesMapContainer[k]; +} //------------------------------------------------------------------------ - /*! Returning a reference to *this, enables chaining of calls to operator()(const std::string&, - const std::string&). - @param[in] name of the added option. - @param[in] help a help description for this option. - @return a reference to *this. - */ - Descriptions& Descriptions::operator () (const std::string& name, const std::string& help) - { - mDescriptions.emplace_back (name, help, Description::kBool); - return *this; - } +/*! If command-line contains option @c k more than once, only the last value will survive. */ +//------------------------------------------------------------------------ +const std::string& VariablesMap::operator[] (const VariablesMapContainer::key_type k) const +{ + return (*const_cast (this))[k]; +} //------------------------------------------------------------------------ - /*! Usage example: - @code - CommandLine::Descriptions desc; - desc.addOptions ("myTool") // Set caption to "myTool" - ("help", "produce help message") // add switch -help - ("opt1", string(), "option 1") // add string option -opt1 - ("opt2", string(), "option 2") // add string option -opt2 - ; - @endcode - @note - The operator() is used for every additional option. - - Or with initializer list : - @code - CommandLine::Descriptions desc; - desc.addOptions ("myTool", // Set caption to "myTool" - {{"help", "produce help message", Description::kBool}, // add switch -help - {"opt1", "option 1", Description::kString}, // add string option -opt1 - {"opt2", "option 2", Description::kString}} // add string option -opt2 - ); - @endcode - @param[in] caption the caption of the command-line tool. - @param[in] options initializer list with options - @return a reverense to *this. - */ - Descriptions& Descriptions::addOptions (const std::string& caption, - std::initializer_list&& options) - { - mCaption = caption; - std::move (options.begin (), options.end (), std::back_inserter (mDescriptions)); - return *this; - } - - //------------------------------------------------------------------------ - /*! @param[in] ac count of command-line parameters - @param[in] av command-line as array of strings - @param[out] result the parsing result - @param[out] files optional list of elements on the command line that are not handled by options parsing - */ - bool Descriptions::parse (int ac, char* av[], VariablesMap& result, FilesVector* files) const - { - using namespace std; - - for (int i = 1; i < ac; i++) - { - string current = av[i]; - if (current[0] == '-') - { - int pos = current[1] == '-' ? 2 : 1; - current = current.substr (pos, string::npos); - - DescriptionsList::const_iterator found = - find (mDescriptions.begin (), mDescriptions.end (), current); - if (found != mDescriptions.end ()) - { - result[*found] = "true"; - if (found->mType != Description::kBool) - { - if (((i + 1) < ac) && *av[i + 1] != '-') - { - result[*found] = av[++i]; - } - else - { - result[*found] = "error!"; - result.setError (); - return false; - } - } - } - else - { - result.setError (); - return false; - } - } - else if (files) - files->push_back (av[i]); - } - return true; - } +VariablesMap::VariablesMapContainer::size_type VariablesMap::count ( + const VariablesMapContainer::key_type k) const +{ + return mVariablesMapContainer.count (k); +} //------------------------------------------------------------------------ - /*! The description includes the help strings for all options. */ - //------------------------------------------------------------------------ - void Descriptions::print (std::ostream& os) const - { - if (!mCaption.empty ()) - os << mCaption << ":\n"; +/** Add a new option with a string as parameter. */ +//------------------------------------------------------------------------ +template <> +Descriptions& Descriptions::operator () (const std::string& name, const std::string& inType, + std::string help) +{ + mDescriptions.emplace_back (name, help, inType); + return *this; +} - size_t maxLength = 0u; - std::for_each (mDescriptions.begin (), mDescriptions.end (), - [&] (const Description& d) { maxLength = std::max (maxLength, d.size ()); }); +/** Parse the command - line. */ +bool parse (int ac, char* av[], const Descriptions& desc, VariablesMap& result, + FilesVector* files = nullptr); - for (const Description& opt : mDescriptions) - { - os << "-" << opt; - for (auto s = opt.size (); s < maxLength; ++s) - os << " "; - os << " | " << opt.mHelp << "\n"; - } - } +/** Make Descriptions stream able. */ +std::ostream& operator<< (std::ostream& os, const Descriptions& desc); + +const std::string Description::kBool = "bool"; +const std::string Description::kString = "string"; //------------------------------------------------------------------------ - std::ostream& operator<< (std::ostream& os, const Descriptions& desc) +/*! In most cases you will use the Descriptions::addOptions (const std::string&) method to create + and add descriptions. + + @param[in] name of the option. + @param[in] help a help description for this option. + @param[out] valueType Description::kBool or Description::kString. +*/ +Description::Description (const std::string& name, const std::string& help, + const std::string& valueType) +: std::string (name), mHelp (help), mType (valueType) +{ +} + +//------------------------------------------------------------------------ +/*! Returning a reference to *this, enables chaining of calls to operator()(const std::string&, + const std::string&). + + @param[in] name of the added option. + @param[in] help a help description for this option. + @return a reference to *this. +*/ +Descriptions& Descriptions::operator () (const std::string& name, const std::string& help) +{ + mDescriptions.emplace_back (name, help, Description::kBool); + return *this; +} + +//------------------------------------------------------------------------ +/*! Usage example: + @code +CommandLine::Descriptions desc; +desc.addOptions ("myTool") // Set caption to "myTool" + ("help", "produce help message") // add switch -help + ("opt1", string(), "option 1") // add string option -opt1 + ("opt2", string(), "option 2") // add string option -opt2 +; + @endcode +@note + The operator() is used for every additional option. + +Or with initializer list : + @code +CommandLine::Descriptions desc; +desc.addOptions ("myTool", // Set caption to "myTool" + {{"help", "produce help message", Description::kBool}, // add switch -help + {"opt1", "option 1", Description::kString}, // add string option -opt1 + {"opt2", "option 2", Description::kString}} // add string option -opt2 +); + @endcode +@param[in] caption the caption of the command-line tool. +@param[in] options initializer list with options +@return a reverense to *this. +*/ +Descriptions& Descriptions::addOptions (const std::string& caption, + std::initializer_list&& options) +{ + mCaption = caption; + std::move (options.begin (), options.end (), std::back_inserter (mDescriptions)); + return *this; +} + +//------------------------------------------------------------------------ +/*! @param[in] ac count of command-line parameters + @param[in] av command-line as array of strings + @param[out] result the parsing result + @param[out] files optional list of elements on the command line that are not handled by options + parsing +*/ +bool Descriptions::parse (int ac, char* av[], VariablesMap& result, FilesVector* files) const +{ + using namespace std; + + for (int i = 1; i < ac; i++) { - desc.print (os); - return os; - } + string current = av[i]; + if (current[0] == '-') + { + int pos = current[1] == '-' ? 2 : 1; + current = current.substr (pos, string::npos); - //------------------------------------------------------------------------ - /*! @param[in] ac count of command-line parameters - @param[in] av command-line as array of strings - @param[in] desc Descriptions including all allowed options - @param[out] result the parsing result - @param[out] files optional list of elements on the command line that are not handled by options parsing - */ - bool parse (int ac, char* av[], const Descriptions& desc, VariablesMap& result, FilesVector* files) - { - return desc.parse (ac, av, result, files); + DescriptionsList::const_iterator found = + find (mDescriptions.begin (), mDescriptions.end (), current); + if (found != mDescriptions.end ()) + { + result[*found] = "true"; + if (found->mType != Description::kBool) + { + if (((i + 1) < ac) && *av[i + 1] != '-') + { + result[*found] = av[++i]; + } + else + { + result[*found] = "error!"; + result.setError (); + return false; + } + } + } + else + { + result.setError (); + return false; + } + } + else if (files) + files->push_back (av[i]); } + return true; +} + +//------------------------------------------------------------------------ +/*! The description includes the help strings for all options. */ +//------------------------------------------------------------------------ +void Descriptions::print (std::ostream& os) const +{ + if (!mCaption.empty ()) + os << mCaption << ":\n"; + + size_t maxLength = 0u; + std::for_each (mDescriptions.begin (), mDescriptions.end (), + [&] (const Description& d) { maxLength = std::max (maxLength, d.size ()); }); + + for (const Description& opt : mDescriptions) + { + os << "-" << opt; + for (auto s = opt.size (); s < maxLength; ++s) + os << " "; + os << " | " << opt.mHelp << "\n"; + } +} + +//------------------------------------------------------------------------ +std::ostream& operator<< (std::ostream& os, const Descriptions& desc) +{ + desc.print (os); + return os; +} + +//------------------------------------------------------------------------ +/*! @param[in] ac count of command-line parameters + @param[in] av command-line as array of strings + @param[in] desc Descriptions including all allowed options + @param[out] result the parsing result + @param[out] files optional list of elements on the command line that are not handled by options + parsing +*/ +bool parse (int ac, char* av[], const Descriptions& desc, VariablesMap& result, FilesVector* files) +{ + return desc.parse (ac, av, result, files); +} #endif -} //namespace CommandLine -} //namespace Steinberg +//------------------------------------------------------------------------ +} // namespace CommandLine +} // namespace Steinberg diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fdebug.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fdebug.cpp index 9fe27d85aa..18fa1c9b44 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fdebug.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fdebug.cpp @@ -11,7 +11,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fdebug.h b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fdebug.h index 3b376ae642..ecfb82fcb7 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fdebug.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fdebug.h @@ -11,7 +11,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fobject.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fobject.cpp index a061556b92..239afb5617 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fobject.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fobject.cpp @@ -10,7 +10,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fobject.h b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fobject.h index 4165a7b400..080c05599c 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fobject.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fobject.h @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -125,6 +125,9 @@ public: // static helper functions static inline bool classIDsEqual (FClassID ci1, FClassID ci2); ///< compares (evaluates) 2 class IDs static inline FObject* unknownToObject (FUnknown* unknown); ///< pointer conversion from FUnknown to FObject + /** convert from FUnknown to FObject */ + template + static inline IPtr fromUnknown (FUnknown* unknown); /** Special UID that is used to cast an FUnknown pointer to a FObject */ static const FUID iid; @@ -140,7 +143,24 @@ protected: //------------------------------------------------------------------------ -// conversion from FUnknown to FObject +// conversion from FUnknown to FObject subclass +//------------------------------------------------------------------------ +template +inline IPtr FObject::fromUnknown (FUnknown* unknown) +{ + if (unknown) + { + FObject* object = nullptr; + if (unknown->queryInterface (FObject::iid, (void**)&object) == kResultTrue && object) + { + if (object->isTypeOf (C::getFClassID (), true)) + return IPtr (static_cast (object), false); + object->release (); + } + } + return {}; +} + //------------------------------------------------------------------------ inline FObject* FObject::unknownToObject (FUnknown* unknown) { @@ -149,7 +169,10 @@ inline FObject* FObject::unknownToObject (FUnknown* unknown) { unknown->queryInterface (FObject::iid, (void**)&object); if (object) - object->release (); // queryInterface has added ref + { + if (object->release () == 0) + object = nullptr; + } } return object; } @@ -168,7 +191,7 @@ inline C* FCast (const FObject* object) { if (object && object->isTypeOf (C::getFClassID (), true)) return (C*) object; - return 0; + return nullptr; } //----------------------------------------------------------------------- @@ -182,19 +205,48 @@ inline C* FCast (FUnknown* unknown) } //----------------------------------------------------------------------- -/** FUCast - casting from FUnknown to Interface */ +/** ICast - casting from FObject to FUnknown Interface */ +//----------------------------------------------------------------------- +template +inline IPtr ICast (FObject* object) +{ + return FUnknownPtr (object ? object->unknownCast () : nullptr); +} + +//----------------------------------------------------------------------- +/** ICast - casting from FUnknown to another FUnknown Interface */ +//----------------------------------------------------------------------- +template +inline IPtr ICast (FUnknown* object) +{ + return FUnknownPtr (object); +} + +//------------------------------------------------------------------------ +template +inline C* FCastIsA (const FObject* object) +{ + if (object && object->isA (C::getFClassID ())) + return (C*)object; + return nullptr; +} + +#ifndef SMTG_HIDE_DEPRECATED_INLINE_FUNCTIONS +//----------------------------------------------------------------------- +/** \deprecated FUCast - casting from FUnknown to Interface */ //----------------------------------------------------------------------- template -inline C* FUCast (FObject* object) +SMTG_DEPRECATED_MSG("use ICast<>") inline C* FUCast (FObject* object) { return FUnknownPtr (object ? object->unknownCast () : nullptr); } template -inline C* FUCast (FUnknown* object) +SMTG_DEPRECATED_MSG("use ICast<>") inline C* FUCast (FUnknown* object) { return FUnknownPtr (object); } +#endif // SMTG_HIDE_DEPRECATED_FUNCTIONS //------------------------------------------------------------------------ /** @name Convenience methods that call release or delete respectively diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstreamer.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstreamer.cpp index 524956b9ef..3a1a2a5aad 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstreamer.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstreamer.cpp @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -607,8 +607,10 @@ TSize FStreamer::readString8 (char8* ptr, TSize size) if (i > 0 && ptr[i - 1] == '\r') i--; } + if (i >= size) + i = size - 1; ptr[i] = 0; - + return i; } diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstreamer.h b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstreamer.h index 8b97bb6cd1..dbec4054bc 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstreamer.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstreamer.h @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstring.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstring.cpp index 907baa7338..77024c248e 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstring.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstring.cpp @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -2245,7 +2245,8 @@ bool String::toMultiByte (uint32 destCodePage) //----------------------------------------------------------------------------- void String::fromUTF8 (const char8* utf8String) { - resize (0, false); + if (buffer8 != utf8String) + resize (0, false); _toWideString (utf8String, static_cast (strlen (utf8String)), kCP_Utf8); } diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstring.h b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstring.h index 7fc758aa77..b8676d6d86 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstring.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstring.h @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/updatehandler.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/updatehandler.cpp index f4ac80cc57..e722d45ed7 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/updatehandler.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/updatehandler.cpp @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -299,10 +299,7 @@ tresult PLUGIN_API UpdateHandler::removeDependent (FUnknown* u, IDependent* depe listIsEmpty = true; break; } - else - { - iterList = list.erase (iterList); - } + iterList = list.erase (iterList); } else { diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/updatehandler.h b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/updatehandler.h index e85a9bbcc3..084105e5f1 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/source/updatehandler.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/source/updatehandler.h @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/thread/include/flock.h b/modules/juce_audio_processors/format_types/VST3_SDK/base/thread/include/flock.h index 2ef35ba8d8..14ffee4158 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/thread/include/flock.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/thread/include/flock.h @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -178,6 +178,7 @@ private: FLock* lock; ///< guarded lock }; -} // Thread -} // Base -} // Steinberg +//------------------------------------------------------------------------ +} // namespace Thread +} // namespace Base +} // namespace Steinberg diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/base/thread/source/flock.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/base/thread/source/flock.cpp index e7c154bad7..ac9d7d5729 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/base/thread/source/flock.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/base/thread/source/flock.cpp @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -140,7 +140,7 @@ bool FLock::trylock () #endif } -} // Thread -} // Base -} // Steinberg - +//------------------------------------------------------------------------ +} // namespace Thread +} // namespace Base +} // namespace Steinberg diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/LICENSE.txt b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/LICENSE.txt index 6daa072e68..f5df1de438 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/LICENSE.txt +++ b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/LICENSE.txt @@ -1,6 +1,6 @@ //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- This license applies only to files referencing this license, for other files of the Software Development Kit the respective embedded license text diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/coreiids.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/coreiids.cpp index d5935044d4..95d59aed49 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/coreiids.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/coreiids.cpp @@ -37,4 +37,4 @@ DEF_CLASS_IID (IBStream) DEF_CLASS_IID (ISizeableStream) //------------------------------------------------------------------------ -} // Steinberg +} // namespace Steinberg diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/fplatform.h b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/fplatform.h index 7b4a78d27a..fea5e8d629 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/fplatform.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/fplatform.h @@ -322,8 +322,12 @@ // Deprecation setting //----------------------------------------------------------------------------- #ifndef SMTG_DEPRECATED_ATTRIBUTE +#if SMTG_CPP17 +#define SMTG_DEPRECATED_ATTRIBUTE(msg) [[deprecated(msg)]] +#else #define SMTG_DEPRECATED_ATTRIBUTE(msg) #endif +#endif #define SMTG_DEPRECATED_MSG(msg) SMTG_DEPRECATED_ATTRIBUTE(msg) //----------------------------------------------------------------------------- diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/fstrdefs.h b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/fstrdefs.h index fea4522c56..a365b69594 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/fstrdefs.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/fstrdefs.h @@ -246,7 +246,7 @@ inline SMTG_CONSTEXPR14 void str8ToStr16 (char16* dst, const char8* src, int32 n int32 i = 0; for (;;) { - if (i == n) + if (i == (n - 1)) { dst[i] = 0; return; diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/ftypes.h b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/ftypes.h index 133dbba38d..e1bf9388cb 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/ftypes.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/ftypes.h @@ -117,7 +117,7 @@ namespace Steinberg typedef int32 UCoord; static const UCoord kMaxCoord = ((UCoord)0x7FFFFFFF); static const UCoord kMinCoord = ((UCoord)-0x7FFFFFFF); -} // namespace Steinberg +} // namespace Steinberg //---------------------------------------------------------------------------- diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/smartpointer.h b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/smartpointer.h index 99dd037303..ca64ae8f62 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/smartpointer.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/smartpointer.h @@ -381,4 +381,6 @@ Used toUsed (T* obj) { return Detail::Adopt::toOwnerType (obj); } //------------------------------------------------------------------------ } // SKI #endif -} // Steinberg + +//------------------------------------------------------------------------ +} // namespace Steinberg diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/gui/iplugview.h b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/gui/iplugview.h index 797650198d..b4a00efd25 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/gui/iplugview.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/gui/iplugview.h @@ -253,7 +253,11 @@ DECLARE_CLASS_IID (ITimerHandler, 0x10BDD94F, 0x41424774, 0x821FAD8F, 0xECA72CA9 - [released: 3.6.8] On Linux the host has to provide this interface to the plug-in as there's no global event run loop -defined as on other platforms. +defined as on other platforms. + +This can be done by IPlugFrame and the context which is passed to the plug-in as an argument +in the method IPlugFactory3::setHostContext. This way the plug-in can get a runloop even if +it does not have an editor. A plug-in can register an event handler for a file descriptor. The host has to call the event handler when the file descriptor is marked readable. diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstaudioprocessor.h b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstaudioprocessor.h index 82d550e327..03e76b4640 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstaudioprocessor.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstaudioprocessor.h @@ -48,15 +48,20 @@ namespace PlugType //------------------------------------------------------------------------ SMTG_CONSTEXPR const CString kFx = "Fx"; ///< others type (not categorized) SMTG_CONSTEXPR const CString kFxAnalyzer = "Fx|Analyzer"; ///< Scope, FFT-Display, Loudness Processing... +SMTG_CONSTEXPR const CString kFxBass = "Fx|Bass"; ///< Tools dedicated to Bass Guitar +SMTG_CONSTEXPR const CString kFxChannelStrip = "Fx|Channel Strip"; ///< Tools dedicated to Channel Strip SMTG_CONSTEXPR const CString kFxDelay = "Fx|Delay"; ///< Delay, Multi-tap Delay, Ping-Pong Delay... SMTG_CONSTEXPR const CString kFxDistortion = "Fx|Distortion"; ///< Amp Simulator, Sub-Harmonic, SoftClipper... +SMTG_CONSTEXPR const CString kFxDrums = "Fx|Drums"; ///< Tools dedicated to Drums... SMTG_CONSTEXPR const CString kFxDynamics = "Fx|Dynamics"; ///< Compressor, Expander, Gate, Limiter, Maximizer, Tape Simulator, EnvelopeShaper... SMTG_CONSTEXPR const CString kFxEQ = "Fx|EQ"; ///< Equalization, Graphical EQ... SMTG_CONSTEXPR const CString kFxFilter = "Fx|Filter"; ///< WahWah, ToneBooster, Specific Filter,... SMTG_CONSTEXPR const CString kFxGenerator = "Fx|Generator"; ///< Tone Generator, Noise Generator... +SMTG_CONSTEXPR const CString kFxGuitar = "Fx|Guitar"; ///< Tools dedicated to Guitar SMTG_CONSTEXPR const CString kFxInstrument = "Fx|Instrument"; ///< Fx which could be loaded as Instrument too SMTG_CONSTEXPR const CString kFxInstrumentExternal = "Fx|Instrument|External"; ///< Fx which could be loaded as Instrument too and is external (wrapped Hardware) SMTG_CONSTEXPR const CString kFxMastering = "Fx|Mastering"; ///< Dither, Noise Shaping,... +SMTG_CONSTEXPR const CString kFxMicrophone = "Fx|Microphone"; ///< Tools dedicated to Microphone SMTG_CONSTEXPR const CString kFxModulation = "Fx|Modulation"; ///< Phaser, Flanger, Chorus, Tremolo, Vibrato, AutoPan, Rotary, Cloner... SMTG_CONSTEXPR const CString kFxNetwork = "Fx|Network"; ///< using Network SMTG_CONSTEXPR const CString kFxPitchShift = "Fx|Pitch Shift"; ///< Pitch Processing, Pitch Correction, Vocal Tuning... @@ -65,7 +70,7 @@ SMTG_CONSTEXPR const CString kFxReverb = "Fx|Reverb"; ///< Reverberation, Ro SMTG_CONSTEXPR const CString kFxSpatial = "Fx|Spatial"; ///< MonoToStereo, StereoEnhancer,... SMTG_CONSTEXPR const CString kFxSurround = "Fx|Surround"; ///< dedicated to surround processing: LFE Splitter, Bass Manager... SMTG_CONSTEXPR const CString kFxTools = "Fx|Tools"; ///< Volume, Mixer, Tuner... -SMTG_CONSTEXPR const CString kFxVocals = "Fx|Vocals"; ///< Tools dedicated to vocals +SMTG_CONSTEXPR const CString kFxVocals = "Fx|Vocals"; ///< Tools dedicated to Vocals SMTG_CONSTEXPR const CString kInstrument = "Instrument"; ///< Effect used as instrument (sound generator), not as insert SMTG_CONSTEXPR const CString kInstrumentDrum = "Instrument|Drum"; ///< Instrument for Drum sounds diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstdataexchange.h b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstdataexchange.h new file mode 100644 index 0000000000..9919c17759 --- /dev/null +++ b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstdataexchange.h @@ -0,0 +1,221 @@ +//------------------------------------------------------------------------ +// Project : VST SDK +// +// Category : Interfaces +// Filename : pluginterfaces/vst/ivstdataexchange.h +// Created by : Steinberg, 06/2022 +// Description : VST Data Exchange Interface +// +//----------------------------------------------------------------------------- +// This file is part of a Steinberg SDK. It is subject to the license terms +// in the LICENSE file found in the top-level directory of this distribution +// and at www.steinberg.net/sdklicenses. +// No part of the SDK, including this file, may be copied, modified, propagated, +// or distributed except according to the terms contained in the LICENSE file. +//----------------------------------------------------------------------------- + +#pragma once + +#include "pluginterfaces/base/funknown.h" + +//------------------------------------------------------------------------ +#include "pluginterfaces/base/falignpush.h" +//------------------------------------------------------------------------ + +//------------------------------------------------------------------------ +namespace Steinberg { +namespace Vst { + +//------------------------------------------------------------------------ +class IAudioProcessor; + +//------------------------------------------------------------------------ +typedef uint32 DataExchangeQueueID; +typedef uint32 DataExchangeBlockID; +typedef uint32 DataExchangeUserContextID; + +//------------------------------------------------------------------------ +static SMTG_CONSTEXPR DataExchangeQueueID InvalidDataExchangeQueueID = kMaxInt32; +static SMTG_CONSTEXPR DataExchangeBlockID InvalidDataExchangeBlockID = kMaxInt32; + +//------------------------------------------------------------------------ +struct DataExchangeBlock +{ + /** pointer to the memory buffer */ + void* data; + /** size of the memory buffer */ + uint32 size; + /** block identifier */ + DataExchangeBlockID blockID; +}; + +//------------------------------------------------------------------------ +/** Host Data Exchange handler interface: Vst::IDataExchangeHandler +\ingroup vstHost vst379 +- [host imp] +- [context interface] +- [released: 3.7.9] +- [optional] + +The IDataExchangeHandler implements a direct and thread-safe connection from the realtime +audio context of the audio processor to the non-realtime audio context of the edit controller. +This should be used when the edit controller needs continuous data from the audio process for +visualization or other use-cases. To circumvent the bottleneck on the main thread it is possible +to configure the connection in a way that the calls to the edit controller will happen on a +background thread. + +Opening a queue: +The main operation for a plug-in is to open a queue via the handler before the plug-in is activated +(but it must be connected to the edit controller via the IConnectionPoint when the plug-in is using +the recommended separation of edit controller and audio processor). The best place to do this is in +the IAudioProcessor::setupProcessing method as this is also the place where the plug-in knows the +sample rate and maximum block size which the plug-in may need to calculate the queue block size. +When a queue is opened the edit controller gets a notification about it and the controller can +decide if it wishes to receive the data on the main thread or the background thread. + +Sending data: +In the IAudioProcessor::process call the plug-in can now lock a block from the handler, fill it and +when done free the block via the handler which then sends the block to the edit controller. The edit +controller then receives the block either on the main thread or on a background thread depending on +the setup of the queue. +The host guarantees that all blocks are send before the plug-in is deactivated. + +Closing a queue: +The audio processor must close an opened queue and this has to be done after the processor was +deactivated and before it is disconnected from the edit controller (see IConnectionPoint). + +What to do when the queue is full and no block can be locked? +The plug-in needs to be prepared for this situation as constraints in the overall system may cause +the queue to get full. If you need to get this information to the controller you can declare a +hidden parameter which you set to a special value and send this parameter change in your audio +process method. +*/ +class IDataExchangeHandler : public FUnknown +{ +public: + /** open a new queue + * + * only allowed to be called from the main thread when the component is not active but + * initialized and connected (see IConnectionPoint) + * + * @param processor the processor who wants to open the queue + * @param blockSize size of one block + * @param numBlocks number of blocks in the queue + * @param alignment data alignment, if zero will use the platform default alignment if any + * @param userContextID an identifier internal to the processor + * @param outID on return the ID of the queue + * @return kResultTrue on success + */ + virtual tresult PLUGIN_API openQueue (IAudioProcessor* processor, uint32 blockSize, + uint32 numBlocks, uint32 alignment, + DataExchangeUserContextID userContextID, + DataExchangeQueueID* outID) = 0; + /** close a queue + * + * closes and frees all memory of a previously opened queue + * if there are locked blocks in the queue, they are freed and made invalid + * + * only allowed to be called from the main thread when the component is not active but + * initialized and connected + * + * @param queueID the ID of the queue to close + * @return kResultTrue on success + */ + virtual tresult PLUGIN_API closeQueue (DataExchangeQueueID queueID) = 0; + + /** lock a block if available + * + * only allowed to be called from within the IAudioProcessor::process call + * + * @param queueID the ID of the queue + * @param block on return will contain the data pointer and size of the block + * @return kResultTrue if a free block was found and kOutOfMemory if all blocks are locked + */ + virtual tresult PLUGIN_API lockBlock (DataExchangeQueueID queueId, + DataExchangeBlock* block) = 0; + + /** free a previously locked block + * + * only allowed to be called from within the IAudioProcessor::process call + * + * @param queueID the ID of the queue + * @param blockID the ID of the block + * @param sendToController if true the block data will be send to the IEditController otherwise + * it will be discarded + * @return kResultTrue on success + */ + virtual tresult PLUGIN_API freeBlock (DataExchangeQueueID queueId, DataExchangeBlockID blockID, + TBool sendToController) = 0; + +//------------------------------------------------------------------------ + static const FUID iid; +}; + +DECLARE_CLASS_IID (IDataExchangeHandler, 0x36D551BD, 0x6FF54F08, 0xB48E830D, 0x8BD5A03B) + +//------------------------------------------------------------------------ +/** Data Exchange Receiver interface: Vst::IDataExchangeReceiver +\ingroup vstPlug vst379 +- [plug imp] +- [released: 3.7.9 +- [optional] + +The receiver interface is required to receive data from the realtime audio process via the +IDataExchangeHandler. + +\see \ref IDataExchangeHandler +*/ +class IDataExchangeReceiver : public FUnknown +{ +public: + /** queue opened notification + * + * called on the main thread when the processor has opened a queue + * + * @param userContextID the user context ID of the queue + * @param blockSize the size of one block of the queue + * @param dispatchedOnBackgroundThread if true on output the blocks are dispatched on a + * background thread [defaults to false in which case the + * blocks are dispatched on the main thread] + */ + virtual void PLUGIN_API queueOpened (DataExchangeUserContextID userContextID, uint32 blockSize, + TBool& dispatchOnBackgroundThread) = 0; + /** queue closed notification + * + * called on the main thread when the processor has closed a queue + * + * @param userContextID the user context ID of the queue + */ + virtual void PLUGIN_API queueClosed (DataExchangeUserContextID userContextID) = 0; + + /** one or more blocks were received + * + * called either on the main thread or a background thread depending on the + * dispatchOnBackgroundThread value in the queueOpened call. + * + * the data of the blocks are only valid inside this call and the blocks only become available + * to the queue afterwards. + * + * @param userContextID the user context ID of the queue + * @param numBlocks number of blocks + * @param blocks the blocks + * @param onBackgroundThread true if the call is done on a background thread + */ + virtual void PLUGIN_API onDataExchangeBlocksReceived (DataExchangeUserContextID userContextID, + uint32 numBlocks, + DataExchangeBlock* blocks, + TBool onBackgroundThread) = 0; + +//------------------------------------------------------------------------ + static const FUID iid; +}; + +DECLARE_CLASS_IID (IDataExchangeReceiver, 0x45A759DC, 0x84FA4907, 0xABCB6175, 0x2FC786B6) + +//------------------------------------------------------------------------ +} // namespace Vst +} // namespace Steinberg + +//------------------------------------------------------------------------ +#include "pluginterfaces/base/falignpop.h" +//------------------------------------------------------------------------ diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivsteditcontroller.h b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivsteditcontroller.h index d7c8925c13..48128fbe90 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivsteditcontroller.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivsteditcontroller.h @@ -86,7 +86,7 @@ const CString kEditor = "editor"; enum RestartFlags { /** The Component should be reloaded - * The host has to unload completely the plug-in (controller/processor) and reload it. + * The host has to unload completely the plug-in (controller/processor) and reload it. * [SDK 3.0.0] */ kReloadComponent = 1 << 0, @@ -105,7 +105,7 @@ enum RestartFlags /** Latency has changed * The plug informs the host that its latency has changed, getLatencySamples should return the new latency after setActive (true) was called * The host has to deactivate and reactivate the plug-in, then afterwards the host could ask for the current latency (getLatencySamples) - * see IAudioProcessor::getLatencySamples + * See IAudioProcessor::getLatencySamples * [SDK 3.0.0] */ kLatencyChanged = 1 << 3, @@ -121,39 +121,53 @@ enum RestartFlags * and reread program changes parameters (stepCount and associated unitID) * [SDK 3.0.1] */ kMidiCCAssignmentChanged = 1 << 5, - + /** Note Expression has changed (info, count, PhysicalUIMapping, ...) * Either the note expression type info, the count of note expressions or the physical UI mapping has changed. * The host invalidates all caches of note expression infos and asks the edit controller for the current ones. * See INoteExpressionController, NoteExpressionTypeInfo and INoteExpressionPhysicalUIMapping * [SDK 3.5.0] */ kNoteExpressionChanged = 1 << 6, - + /** Input / Output bus titles have changed * The host invalidates all caches of bus titles and asks the edit controller for the current titles. * [SDK 3.5.0] */ kIoTitlesChanged = 1 << 7, - + /** Prefetch support has changed * The plug-in informs the host that its PrefetchSupport has changed - * The host has to deactivate the plug-in, calls IPrefetchableSupport::getPrefetchableSupport and reactivate the plug-in - * see IPrefetchableSupport + * The host has to deactivate the plug-in, calls IPrefetchableSupport::getPrefetchableSupport + * and reactivate the plug-in. + * See IPrefetchableSupport * [SDK 3.6.1] */ - kPrefetchableSupportChanged = 1 << 8, + kPrefetchableSupportChanged = 1 << 8, /** RoutingInfo has changed - * The plug-in informs the host that its internal routing (relation of an event-input-channel to an audio-output-bus) has changed - * The host ask the plug-in for the new routing with IComponent::getRoutingInfo, \ref vst3Routing - * see IComponent + * The plug-in informs the host that its internal routing (relation of an event-input-channel to + * an audio-output-bus) has changed. The host asks the plug-in for the new routing with + * IComponent::getRoutingInfo, \ref vst3Routing + * See IComponent * [SDK 3.6.6] */ kRoutingInfoChanged = 1 << 9, /** Key switches has changed (info, count) * Either the Key switches info, the count of Key switches has changed. - * The host invalidates all caches of Key switches infos and asks the edit controller (IKeyswitchController) for the current ones. + * The host invalidates all caches of Key switches infos and asks the edit controller + * (IKeyswitchController) for the current ones. * See IKeyswitchController * [SDK 3.7.3] */ - kKeyswitchChanged = 1 << 10 + kKeyswitchChanged = 1 << 10, + + /** Mapping of ParamID has changed + * The Plug-in informs the host that its parameters ID has changed. This has to be called by the + * edit controller in the method setComponentState or setState (during projects loading) when the + * plug-in detects that the given state was associated to an older version of the plug-in, or to a + * plug-in to replace (for ex. migrating VST2 => VST3), with a different set of parameter IDs, then + * the host could remap any used parameters like automation by asking the IRemapParamID interface + * (which extends IEditController). + * See IRemapParamID + * [SDK 3.7.11] */ + kParamIDMappingChanged = 1 << 11 }; //------------------------------------------------------------------------ @@ -613,6 +627,27 @@ public: DECLARE_CLASS_IID (IEditControllerHostEditing, 0xC1271208, 0x70594098, 0xB9DD34B3, 0x6BB0195E) +//------------------------------------------------------------------------ +/** Extended plug-in interface IComponentHandler for an edit controller +\ingroup vstIHost vst379 +- [host imp] +- [extends IComponentHandler] +- [released: 3.7.9] +- [optional] +*/ +//------------------------------------------------------------------------ +class IComponentHandlerSystemTime : public FUnknown +{ +public: +//------------------------------------------------------------------------ + /** get the current systemTime (the same as the one used in ProcessContext::systemTime). */ + virtual tresult PLUGIN_API getSystemTime (int64& systemTime) = 0; +//------------------------------------------------------------------------ + static const FUID iid; +}; + +DECLARE_CLASS_IID (IComponentHandlerSystemTime, 0xF9E53056, 0xD1554CD5, 0xB7695E1B, 0x7B0F7745) + //------------------------------------------------------------------------ } // namespace Vst } // namespace Steinberg diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstremapparamid.h b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstremapparamid.h new file mode 100644 index 0000000000..bf655d4e31 --- /dev/null +++ b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstremapparamid.h @@ -0,0 +1,75 @@ +//------------------------------------------------------------------------ +// Project : VST SDK +// +// Category : Interfaces +// Filename : pluginterfaces/vst/ivstremapparamid.h +// Created by : Steinberg, 02/2024 +// Description : VST Edit Controller Interfaces +// +//----------------------------------------------------------------------------- +// This file is part of a Steinberg SDK. It is subject to the license terms +// in the LICENSE file found in the top-level directory of this distribution +// and at www.steinberg.net/sdklicenses. +// No part of the SDK, including this file, may be copied, modified, propagated, +// or distributed except according to the terms contained in the LICENSE file. +//----------------------------------------------------------------------------- + +#pragma once + +#include "pluginterfaces/base/funknown.h" +#include "pluginterfaces/vst/vsttypes.h" + +//------------------------------------------------------------------------ +#include "pluginterfaces/base/falignpush.h" +//------------------------------------------------------------------------ + +//------------------------------------------------------------------------ +namespace Steinberg { +namespace Vst { + +//------------------------------------------------------------------------ +/** Extended IEditController interface for a component. +\ingroup vstIPlug vst3711 +- [plug imp] +- [extends IEditController] +- [released: 3.7.11] +- [optional] + +When replacing one plug-in with another, the host can ask the new plug-in for remapping paramIDs to +new ones. + +\n +\see Moduleinfo +\see \ref IPluginCompatibility +\see IEditController +*/ +class IRemapParamID : public FUnknown +{ +public: +//------------------------------------------------------------------------ + /** Retrieve the appropriate paramID for a specific plug-in UID and paramID (or index for VST 2 + * plug-ins). + * The retrieved paramID should match the one it replaces, maintaining the same + * behavior during automation playback. Called in UI-Thread context. + * @param[in] pluginToReplaceUID - TUID of plug-in (processor) that will be replaced + * @param[in] oldParamID - paramID (or index for VST 2 plug-ins) to be replaced + * @param[out] newParamID - contains the associated paramID to be used + * Return kResultTrue means that a compatible parameter is available + * Return kResultFalse means that NO compatible parameter is available + */ + virtual tresult PLUGIN_API getCompatibleParamID (const TUID pluginToReplaceUID /*in*/, + ParamID oldParamID /*in*/, + ParamID& newParamID /*out*/) = 0; +//------------------------------------------------------------------------ + static const FUID iid; +}; + +DECLARE_CLASS_IID (IRemapParamID, 0x2B88021E, 0x6286B646, 0xB49DF76A, 0x5663061C) + +//------------------------------------------------------------------------ +} // namespace Vst +} // namespace Steinberg + +//------------------------------------------------------------------------ +#include "pluginterfaces/base/falignpop.h" +//------------------------------------------------------------------------ diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/vstspeaker.h b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/vstspeaker.h index 0d21684fc1..ad70211d1a 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/vstspeaker.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/vstspeaker.h @@ -103,6 +103,9 @@ const Speaker kSpeakerBsr = (Speaker)1 << 34; ///< Bottom Side Right (Bsr) const Speaker kSpeakerBrl = (Speaker)1 << 35; ///< Bottom Rear Left (Brl) const Speaker kSpeakerBrc = (Speaker)1 << 36; ///< Bottom Rear Center (Brc) const Speaker kSpeakerBrr = (Speaker)1 << 37; ///< Bottom Rear Right (Brr) + +const Speaker kSpeakerLw = (Speaker)1 << 59; ///< Left Wide (Lw) +const Speaker kSpeakerRw = (Speaker)1 << 60; ///< Right Wide (Rw) //------------------------------------------------------------------------ /** @}*/ @@ -118,6 +121,7 @@ namespace SpeakerArr const SpeakerArrangement kEmpty = 0; ///< empty arrangement const SpeakerArrangement kMono = kSpeakerM; ///< M const SpeakerArrangement kStereo = kSpeakerL | kSpeakerR; ///< L R +const SpeakerArrangement kStereoWide = kSpeakerLw | kSpeakerRw; ///< Lw Rw const SpeakerArrangement kStereoSurround = kSpeakerLs | kSpeakerRs; ///< Ls Rs const SpeakerArrangement kStereoCenter = kSpeakerLc | kSpeakerRc; ///< Lc Rc const SpeakerArrangement kStereoSide = kSpeakerSl | kSpeakerSr; ///< Sl Sr @@ -306,6 +310,22 @@ const SpeakerArrangement k90_6 = kSpeakerL | kSpeakerR | kSpeakerC | /** L R C Lfe Ls Rs Lc Rc Sl Sr Tfl Tfr Trl Trr Tsl Tsr */ // 9.1.6 const SpeakerArrangement k91_6 = k90_6 | kSpeakerLfe; +/** L R C Ls Rs Sl Sr Tfl Tfr Trl Trr Lw Rw */ // 9.0.4 (Dolby) +const SpeakerArrangement k90_4_W = kSpeakerL | kSpeakerR | kSpeakerC | + kSpeakerLs | kSpeakerRs | kSpeakerLw | kSpeakerRw | kSpeakerSl | kSpeakerSr | + kSpeakerTfl | kSpeakerTfr | kSpeakerTrl | kSpeakerTrr; + +/** L R C Lfe Ls Rs Sl Sr Tfl Tfr Trl Trr Lw Rw */ // 9.1.4 (Dolby) +const SpeakerArrangement k91_4_W = k90_4_W | kSpeakerLfe; + +/** L R C Ls Rs Sl Sr Tfl Tfr Trl Trr Tsl Tsr Lw Rw */ // 9.0.6 (Dolby) +const SpeakerArrangement k90_6_W = kSpeakerL | kSpeakerR | kSpeakerC | + kSpeakerLs | kSpeakerRs | kSpeakerLw | kSpeakerRw | kSpeakerSl | kSpeakerSr | + kSpeakerTfl | kSpeakerTfr | kSpeakerTrl | kSpeakerTrr | kSpeakerTsl | kSpeakerTsr; + +/** L R C Lfe Ls Rs Sl Sr Tfl Tfr Trl Trr Tsl Tsr Lw Rw */ // 9.1.6 (Dolby) +const SpeakerArrangement k91_6_W = k90_6_W | kSpeakerLfe; + /** L R C Ls Rs Tc Tfl Tfr Trl Trr */ // 5.0.5 (10.0 Auro-3D) const SpeakerArrangement k100 = kSpeakerL | kSpeakerR | kSpeakerC | kSpeakerLs | kSpeakerRs | kSpeakerTc | kSpeakerTfl | kSpeakerTfr | kSpeakerTrl | kSpeakerTrr; @@ -424,6 +444,7 @@ const SpeakerArrangement k50_4_4 = kSpeakerL | kSpeakerR | kSpeakerC | kSpeakerL const CString kStringEmpty = ""; const CString kStringMono = "Mono"; const CString kStringStereo = "Stereo"; +const CString kStringStereoWide = "Stereo (Lw Rw)"; const CString kStringStereoR = "Stereo (Ls Rs)"; const CString kStringStereoC = "Stereo (Lc Rc)"; const CString kStringStereoSide = "Stereo (Sl Sr)"; @@ -487,10 +508,14 @@ const CString kString70_4 = "7.0.4"; const CString kString71_4 = "7.1.4"; const CString kString70_6 = "7.0.6"; const CString kString71_6 = "7.1.6"; -const CString kString90_4 = "9.0.4"; -const CString kString91_4 = "9.1.4"; -const CString kString90_6 = "9.0.6"; -const CString kString91_6 = "9.1.6"; +const CString kString90_4 = "9.0.4 ITU"; +const CString kString91_4 = "9.1.4 ITU"; +const CString kString90_6 = "9.0.6 ITU"; +const CString kString91_6 = "9.1.6 ITU"; +const CString kString90_4_W = "9.0.4"; +const CString kString91_4_W = "9.1.4"; +const CString kString90_6_W = "9.0.6"; +const CString kString91_6_W = "9.1.6"; const CString kString50_5 = "10.0 Auro-3D"; const CString kString51_5 = "10.1 Auro-3D"; const CString kString50_6 = "11.0 Auro-3D"; @@ -514,13 +539,13 @@ const CString kString30_5_2 = "3.0.5.2"; const CString kString40_4_4 = "4.0.4.4"; const CString kString50_4_4 = "5.0.4.4"; -const CString kStringAmbi1stOrder = "1st Order Ambisonics"; -const CString kStringAmbi2cdOrder = "2nd Order Ambisonics"; -const CString kStringAmbi3rdOrder = "3rd Order Ambisonics"; -const CString kStringAmbi4thOrder = "4th Order Ambisonics"; -const CString kStringAmbi5thOrder = "5th Order Ambisonics"; -const CString kStringAmbi6thOrder = "6th Order Ambisonics"; -const CString kStringAmbi7thOrder = "7th Order Ambisonics"; +const CString kStringAmbi1stOrder = "1OA"; +const CString kStringAmbi2cdOrder = "2OA"; +const CString kStringAmbi3rdOrder = "3OA"; +const CString kStringAmbi4thOrder = "4OA"; +const CString kStringAmbi5thOrder = "5OA"; +const CString kStringAmbi6thOrder = "6OA"; +const CString kStringAmbi7thOrder = "7OA"; /*@}*/ //------------------------------------------------------------------------ @@ -529,6 +554,7 @@ const CString kStringAmbi7thOrder = "7th Order Ambisonics"; /*@{*/ const CString kStringMonoS = "M"; const CString kStringStereoS = "L R"; +const CString kStringStereoWideS = "Lw Rw"; const CString kStringStereoRS = "Ls Rs"; const CString kStringStereoCS = "Lc Rc"; const CString kStringStereoSS = "Sl Sr"; @@ -589,6 +615,10 @@ const CString kString90_4S = "L R C Ls Rs Lc Rc Sl Sr Tfl Tfr Trl Trr"; const CString kString91_4S = "L R C LFE Ls Rs Lc Rc Sl Sr Tfl Tfr Trl Trr"; const CString kString90_6S = "L R C Ls Rs Lc Rc Sl Sr Tfl Tfr Trl Trr Tsl Tsr"; const CString kString91_6S = "L R C LFE Ls Rs Lc Rc Sl Sr Tfl Tfr Trl Trr Tsl Tsr"; +const CString kString90_4_WS = "L R C Ls Rs Sl Sr Tfl Tfr Trl Trr Lw Rw"; +const CString kString91_4_WS = "L R C LFE Ls Rs Sl Sr Tfl Tfr Trl Trr Lw Rw"; +const CString kString90_6_WS = "L R C Ls Rs Sl Sr Tfl Tfr Trl Trr Tsl Tsr Lw Rw"; +const CString kString91_6_WS = "L R C LFE Ls Rs Sl Sr Tfl Tfr Trl Trr Tsl Tsr Lw Rw"; const CString kString50_5S = "L R C Ls Rs Tc Tfl Tfr Trl Trr"; const CString kString51_5S = "L R C LFE Ls Rs Tc Tfl Tfr Trl Trr"; const CString kString50_5_SonyS = "L R C Ls Rs Tfl Tfc Tfr Trl Trr"; @@ -730,7 +760,8 @@ inline bool hasMiddleSpeakers (const SpeakerArrangement& arr) if (arr & kSpeakerL || arr & kSpeakerR || arr & kSpeakerC || arr & kSpeakerLs || arr & kSpeakerRs || arr & kSpeakerLc || arr & kSpeakerRc || arr & kSpeakerCs || arr & kSpeakerSl || arr & kSpeakerSr || arr & kSpeakerM || arr & kSpeakerPl || - arr & kSpeakerPr || arr & kSpeakerLcs || arr & kSpeakerRcs) + arr & kSpeakerPr || arr & kSpeakerLcs || arr & kSpeakerRcs || arr & kSpeakerLw || + arr & kSpeakerRw) return true; return false; } @@ -802,6 +833,8 @@ inline SpeakerArrangement getSpeakerArrangementFromString (CString arrStr) return kStereo; if (!strcmp8 (arrStr, kStringStereoR)) return kStereoSurround; + if (!strcmp8 (arrStr, kStringStereoWide)) + return kStereoWide; if (!strcmp8 (arrStr, kStringStereoC)) return kStereoCenter; if (!strcmp8 (arrStr, kStringStereoSide)) @@ -926,6 +959,14 @@ inline SpeakerArrangement getSpeakerArrangementFromString (CString arrStr) return k90_6; if (!strcmp8 (arrStr, kString91_6)) return k91_6; + if (!strcmp8 (arrStr, kString90_4_W)) + return k90_4_W; + if (!strcmp8 (arrStr, kString91_4_W)) + return k91_4_W; + if (!strcmp8 (arrStr, kString90_6_W)) + return k90_6_W; + if (!strcmp8 (arrStr, kString91_6_W)) + return k91_6_W; if (!strcmp8 (arrStr, kString50_5)) return k50_5; if (!strcmp8 (arrStr, kString51_5)) @@ -998,6 +1039,7 @@ inline CString getSpeakerArrangementString (SpeakerArrangement arr, bool withSpe //--- Stereo pairs--- case kStereo: return withSpeakersName ? kStringStereoS : kStringStereo; case kStereoSurround: return withSpeakersName ? kStringStereoRS : kStringStereoR; + case kStereoWide: return withSpeakersName ? kStringStereoWideS : kStringStereoWide; case kStereoCenter: return withSpeakersName ? kStringStereoCS : kStringStereoC; case kStereoSide: return withSpeakersName ? kStringStereoSS : kStringStereoSide; case kStereoCLfe: return withSpeakersName ? kStringStereoCLfeS: kStringStereoCLfe; @@ -1066,6 +1108,10 @@ inline CString getSpeakerArrangementString (SpeakerArrangement arr, bool withSpe case k91_4: return withSpeakersName ? kString91_4S : kString91_4; case k90_6: return withSpeakersName ? kString90_6S : kString90_6; case k91_6: return withSpeakersName ? kString91_6S : kString91_6; + case k90_4_W: return withSpeakersName ? kString90_4_WS : kString90_4_W; + case k91_4_W: return withSpeakersName ? kString91_4_WS : kString91_4_W; + case k90_6_W: return withSpeakersName ? kString90_6_WS : kString90_6_W; + case k91_6_W: return withSpeakersName ? kString91_6_WS : kString91_6_W; case k130: return withSpeakersName ? kString130S : kString130; case k131: return withSpeakersName ? kString131S : kString131; @@ -1257,6 +1303,10 @@ inline CString getSpeakerShortName (const SpeakerArrangement& arr, int32 index) if (speaker == kSpeakerBrr) return "Brr"; + if (speaker == kSpeakerLw) + return "Lw"; + if (speaker == kSpeakerRw) + return "Rw"; return ""; } diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/vsttypes.h b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/vsttypes.h index 081177fa68..243f02aa72 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/vsttypes.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/vsttypes.h @@ -24,17 +24,20 @@ namespace Vst { //------------------------------------------------------------------------ /** VST 3 SDK Version */ #ifndef kVstVersionString -#define kVstVersionString "VST 3.7.8" ///< SDK version for PClassInfo2 +#define kVstVersionString "VST 3.7.11" ///< SDK version for PClassInfo2 #endif #define kVstVersionMajor 3 #define kVstVersionMinor 7 -#define kVstVersionSub 8 +#define kVstVersionSub 11 #define VST_VERSION ((kVstVersionMajor << 16) | (kVstVersionMinor << 8) | kVstVersionSub) // Versions History which allows to write such code: // #if VST_VERSION >= VST_3_6_5_VERSION +#define VST_3_7_11_VERSION 0x03070B +#define VST_3_7_10_VERSION 0x03070A +#define VST_3_7_9_VERSION 0x030709 #define VST_3_7_8_VERSION 0x030708 #define VST_3_7_7_VERSION 0x030707 #define VST_3_7_6_VERSION 0x030706 @@ -77,8 +80,11 @@ typedef int32 BusDirection; ///< bus direction (in/out) typedef int32 BusType; ///< bus type (main/aux) typedef int32 IoMode; ///< I/O mode (see \ref vst3IoMode) typedef int32 UnitID; ///< unit identifier -typedef double ParamValue; ///< parameter value type -typedef uint32 ParamID; ///< parameter identifier + +typedef double ParamValue; ///< parameter value type: normalized value => [0.0, 1.0] +typedef uint32 ParamID; ///< parameter identifier: value in range [0, 0x7FFFFFFF]. + /// The range [0x80000000, 0xFFFFFFFF], is reserved for host application. + typedef int32 ProgramListID; ///< program list identifier typedef int16 CtrlNumber; ///< MIDI controller number (see \ref ControllerNumbers for allowed values) @@ -88,8 +94,9 @@ typedef int64 TSamples; ///< time expressed in audio samples typedef uint32 ColorSpec; ///< color defining by 4 component ARGB value (Alpha/Red/Green/Blue) //------------------------------------------------------------------------ -static const ParamID kNoParamId = 0xffffffff; ///< default for uninitialized parameter ID -// static const ParamID kNoParamId = std::numeric_limits::max (); +static const ParamID kNoParamId = 0xFFFFFFFF; ///< default for uninitialized parameter ID +static const ParamID kMinParamId = 0; ///< value min for a parameter ID +static const ParamID kMaxParamId = 0x7FFFFFFF; ///< value max for a parameter ID //------------------------------------------------------------------------ // Audio Types @@ -117,6 +124,10 @@ static SMTG_CONSTEXPR const uint32 SDKVersion = // Versions History which allows to write such code: // if constexpr (SDKVersion >= SDKVersion_3_6_5) { ... } +static SMTG_CONSTEXPR const uint32 SDKVersion_3_7_11 = VST_3_7_11_VERSION; +static SMTG_CONSTEXPR const uint32 SDKVersion_3_7_10 = VST_3_7_10_VERSION; +static SMTG_CONSTEXPR const uint32 SDKVersion_3_7_9 = VST_3_7_9_VERSION; +static SMTG_CONSTEXPR const uint32 SDKVersion_3_7_8 = VST_3_7_8_VERSION; static SMTG_CONSTEXPR const uint32 SDKVersion_3_7_7 = VST_3_7_7_VERSION; static SMTG_CONSTEXPR const uint32 SDKVersion_3_7_6 = VST_3_7_6_VERSION; static SMTG_CONSTEXPR const uint32 SDKVersion_3_7_5 = VST_3_7_5_VERSION; diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/LICENSE.txt b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/LICENSE.txt index f9c531e745..ec797c8bd3 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/LICENSE.txt +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/LICENSE.txt @@ -1,6 +1,6 @@ //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/README.md b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/README.md index e7c8a93748..b06fef1ac7 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/README.md +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/README.md @@ -7,7 +7,6 @@ Here are located: - **AAX** Wrapper - **AU** Wrapper - **AUv3** Wrapper -- **VST 2** Wrapper - InterAppAudio ## License & Usage guidelines diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/samples/vst-utilities/moduleinfotool/source/main.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/samples/vst-utilities/moduleinfotool/source/main.cpp index 2d568ae831..fccecf518d 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/samples/vst-utilities/moduleinfotool/source/main.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/samples/vst-utilities/moduleinfotool/source/main.cpp @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -35,16 +35,14 @@ // OF THE POSSIBILITY OF SUCH DAMAGE. //----------------------------------------------------------------------------- -#include "base/source/fcommandline.h" -#include "pluginterfaces/base/fplatform.h" -#include "pluginterfaces/base/iplugincompatibility.h" -#include "pluginterfaces/vst/vsttypes.h" -#include "public.sdk/source/common/memorystream.h" #include "public.sdk/source/common/readfile.h" #include "public.sdk/source/vst/hosting/module.h" #include "public.sdk/source/vst/moduleinfo/moduleinfocreator.h" #include "public.sdk/source/vst/moduleinfo/moduleinfoparser.h" #include "public.sdk/source/vst/utility/stringconvert.h" +#include "base/source/fcommandline.h" +#include "pluginterfaces/base/fplatform.h" +#include "pluginterfaces/vst/vsttypes.h" #include #include #include @@ -98,35 +96,6 @@ std::optional openAndParseCompatJSON (const std:: return result; } -//------------------------------------------------------------------------ -std::optional loadCompatibilityFromModule (const VST3::Hosting::Module& module) -{ - const auto& factory = module.getFactory(); - const auto& infos = factory.classInfos(); - - const auto iter = std::find_if (infos.begin(), infos.end(), [&] (const auto& info) - { - return info.category() == kPluginCompatibilityClass; - }); - - if (iter == infos.end()) - return {}; - - const auto compatibility = factory.createInstance (iter->ID()); - - if (compatibility == nullptr) - return {}; - - Steinberg::MemoryStream stream; - - if (compatibility->getCompatibilityJSON (&stream) != kResultOk) - return {}; - - const std::string_view streamView (stream.getData(), stream.getSize()); - - return ModuleInfoLib::parseCompatibilityJson (streamView, nullptr); -} - //------------------------------------------------------------------------ int createJSON (const std::optional& compat, const std::string& modulePath, const std::string& moduleVersion, @@ -142,9 +111,6 @@ int createJSON (const std::optional& compat, auto moduleInfo = ModuleInfoLib::createModuleInfo (*module, false); if (compat) moduleInfo.compatibility = *compat; - else if (auto loaded = loadCompatibilityFromModule (*module)) - moduleInfo.compatibility = *loaded; - moduleInfo.version = moduleVersion; std::stringstream output; @@ -358,7 +324,7 @@ int run (int argc, char* argv[]) auto outputFile = valueMap[optOutputPath]; #endif auto ostream = new std::ofstream (outputFile); - + if (ostream->is_open ()) outputStream = ostream; else @@ -388,10 +354,6 @@ int run (int argc, char* argv[]) //------------------------------------------------------------------------ #if SMTG_OS_WINDOWS -//------------------------------------------------------------------------ -#include -#include - //------------------------------------------------------------------------ using Utf8String = std::string; @@ -402,7 +364,7 @@ Utf8Args toUtf8Args (int argc, wchar_t* wargv[]) Utf8Args utf8Args; for (int i = 0; i < argc; i++) { - auto str = reinterpret_cast(wargv[i]); + auto str = reinterpret_cast (wargv[i]); utf8Args.push_back (VST3::StringConvert::convert (str)); } @@ -431,9 +393,14 @@ int wmain (int argc, wchar_t* wargv[]) char** argv = &(utf8ArgPtrs.at (0)); return Steinberg::ModuleInfoTool::run (argc, argv); } + #else + +//------------------------------------------------------------------------ int main (int argc, char* argv[]) { return Steinberg::ModuleInfoTool::run (argc, argv); } -#endif + +//------------------------------------------------------------------------ +#endif // SMTG_OS_WINDOWS diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/memorystream.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/memorystream.cpp index 5b6c245e00..91bd01478b 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/memorystream.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/memorystream.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/memorystream.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/memorystream.h index 489ace5fff..b942f0b196 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/memorystream.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/memorystream.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/pluginview.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/pluginview.cpp index 0b42b5eefb..24c18869ff 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/pluginview.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/pluginview.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -51,7 +51,6 @@ CPluginView::CPluginView (const ViewRect* _rect) //------------------------------------------------------------------------ CPluginView::~CPluginView () { - // NOLINTNEXTLINE(clang-analyzer-optin.cplusplus.VirtualCall) setFrame (nullptr); } diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/pluginview.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/pluginview.h index ce131b94cb..6799fb594e 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/pluginview.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/pluginview.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -112,4 +112,5 @@ protected: IPtr plugFrame; }; -} // namespace +//------------------------------------------------------------------------ +} // namespace Steinberg diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/readfile.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/readfile.cpp index 5f6045770a..f1f0216ed4 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/readfile.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/readfile.cpp @@ -36,8 +36,13 @@ //----------------------------------------------------------------------------- #include "readfile.h" -#include "public.sdk/source/vst/utility/stringconvert.h" + #include "pluginterfaces/base/fplatform.h" + +#if SMTG_OS_WINDOWS +#include "public.sdk/source/vst/utility/stringconvert.h" +#endif + #include #include diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/readfile.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/readfile.h index fdc7105eac..8fe2ab925e 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/readfile.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/readfile.h @@ -51,5 +51,4 @@ Returns entire file content at the given path std::string readFile (const std::string& path); //------------------------------------------------------------------------ - } // namespace Steinberg diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/hostclasses.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/hostclasses.cpp index e04987e16e..266c08c3b3 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/hostclasses.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/hostclasses.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/hostclasses.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/hostclasses.h index 4a254cac16..bd51f30c26 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/hostclasses.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/hostclasses.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module.cpp index 9ce5b57522..88d910f6ff 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module.h index 36b3afad2e..adeb1c2876 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_linux.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_linux.cpp index 404054c828..96b87979ac 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_linux.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_linux.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_mac.mm b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_mac.mm index 49a7155543..8532906728 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_mac.mm +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_mac.mm @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -180,7 +180,12 @@ public: { std::string wd (workDir); wd += "/"; - return loadInternal (wd + path, errorDescription); + if (loadInternal (wd + path, errorDescription)) + { + name = path; + return true; + } + return false; } } return loadInternal (path, errorDescription); diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_win32.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_win32.cpp index 77990fdcca..ae1d03a7da 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_win32.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_win32.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/pluginterfacesupport.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/pluginterfacesupport.cpp index adabdb9028..3e9f8f85ab 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/pluginterfacesupport.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/pluginterfacesupport.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/pluginterfacesupport.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/pluginterfacesupport.h index a88cbf6815..ef769bb21b 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/pluginterfacesupport.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/pluginterfacesupport.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/jsoncxx.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/jsoncxx.h index 979c2f8527..79687789a9 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/jsoncxx.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/jsoncxx.h @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfo.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfo.h index 81b93f74be..1a0001a39d 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfo.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfo.h @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfocreator.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfocreator.cpp index 8f12829c7d..cd554e411e 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfocreator.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfocreator.cpp @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfocreator.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfocreator.h index f28716ae2a..2fad32fa18 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfocreator.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfocreator.h @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfoparser.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfoparser.cpp index 0d09d2bb0c..eb738822a5 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfoparser.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfoparser.cpp @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfoparser.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfoparser.h index 9b426da3c9..54d5705e25 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfoparser.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfoparser.h @@ -9,7 +9,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/optional.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/optional.h index 7ea6a3c373..1f2244a61e 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/optional.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/optional.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -92,7 +92,7 @@ struct Optional T&& value () noexcept { checkValid (); - return move (_value); + return std::move (_value); } const T& value () const noexcept diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/stringconvert.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/stringconvert.cpp index 6bc7f3aa7c..75cf08c0a7 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/stringconvert.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/stringconvert.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/stringconvert.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/stringconvert.h index d2d4678a74..b3bc1ac65a 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/stringconvert.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/stringconvert.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -130,7 +130,7 @@ inline const Steinberg::Vst::TChar* toTChar (const std::u16string& str) //------------------------------------------------------------------------ /** - * convert an number to an UTF-16 string + * convert a number to an UTF-16 string * * @param value number * diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/uid.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/uid.h index 2f8ed8b335..56674afa29 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/uid.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/uid.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -172,10 +172,7 @@ inline UID& UID::operator= (const UID& uid) noexcept //------------------------------------------------------------------------ inline UID& UID::operator= (const TUID& uid) noexcept { - uint64_t* p1 = reinterpret_cast (_data); - const uint64_t* p2 = reinterpret_cast (uid); - p1[0] = p2[0]; - p1[1] = p2[1]; + memcpy (_data, reinterpret_cast(uid), 16); return *this; } @@ -281,12 +278,7 @@ inline Optional UID::fromString (const StringT& str, bool comFormat) noexce inline UID UID::fromTUID (const TUID _uid) noexcept { UID result; - - uint64_t* p1 = reinterpret_cast (result._data); - const uint64_t* p2 = reinterpret_cast (_uid); - p1[0] = p2[0]; - p1[1] = p2[1]; - + memcpy (result._data, reinterpret_cast(_uid), 16); return result; } diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstbus.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstbus.cpp index 8f6ff44fc8..70722fa8d5 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstbus.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstbus.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstbus.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstbus.h index f1e7ad4b06..4820e7701f 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstbus.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstbus.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponent.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponent.cpp index 57e03d0815..6e999b2e23 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponent.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponent.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponent.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponent.h index a1009d4871..e5942690fa 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponent.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponent.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponentbase.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponentbase.cpp index c82ac39cde..d2e5ffb1d9 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponentbase.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponentbase.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponentbase.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponentbase.h index e71b857be9..4b149bd0f2 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponentbase.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponentbase.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vsteditcontroller.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vsteditcontroller.cpp index 4342c7b21c..be32db509d 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vsteditcontroller.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vsteditcontroller.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vsteditcontroller.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vsteditcontroller.h index 9fcb0e6922..446914b7d9 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vsteditcontroller.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vsteditcontroller.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstinitiids.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstinitiids.cpp index c5ad8b08fd..d61803776f 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstinitiids.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstinitiids.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -41,6 +41,7 @@ #include "pluginterfaces/vst/ivstautomationstate.h" #include "pluginterfaces/vst/ivstchannelcontextinfo.h" #include "pluginterfaces/vst/ivstcontextmenu.h" +#include "pluginterfaces/vst/ivstdataexchange.h" #include "pluginterfaces/vst/ivsteditcontroller.h" #include "pluginterfaces/vst/ivstevents.h" #include "pluginterfaces/vst/ivsthostapplication.h" @@ -53,6 +54,7 @@ #include "pluginterfaces/vst/ivstpluginterfacesupport.h" #include "pluginterfaces/vst/ivstplugview.h" #include "pluginterfaces/vst/ivstprefetchablesupport.h" +#include "pluginterfaces/vst/ivstremapparamid.h" #include "pluginterfaces/vst/ivstrepresentation.h" #include "pluginterfaces/vst/ivsttestplugprovider.h" #include "pluginterfaces/vst/ivstunits.h" @@ -138,8 +140,15 @@ DEF_CLASS_IID (Vst::IProcessContextRequirements) DEF_CLASS_IID (Vst::IProgress) DEF_CLASS_IID (Vst::ITestPlugProvider2) - //----VST 3.7.5--------------------------------- DEF_CLASS_IID (IPluginCompatibility) +//----VST 3.7.9--------------------------------- +DEF_CLASS_IID (Vst::IComponentHandlerSystemTime) +DEF_CLASS_IID (Vst::IDataExchangeHandler) +DEF_CLASS_IID (Vst::IDataExchangeReceiver) + +//----VST 3.7.11--------------------------------- +DEF_CLASS_IID (Vst::IRemapParamID) + } // Steinberg diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstparameters.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstparameters.cpp index dd0835167d..213a73e8b6 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstparameters.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstparameters.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -228,6 +228,8 @@ ParamValue RangeParameter::toNormalized (ParamValue plainValue) const { if (info.stepCount > 1) return ToNormalized (plainValue - getMin (), info.stepCount); + + SMTG_ASSERT (getMax () - getMin () != 0); return (plainValue - getMin ()) / (getMax () - getMin ()); } diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstparameters.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstparameters.h index 88742e20ce..42d3e92f42 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstparameters.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstparameters.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: @@ -98,7 +98,7 @@ public: OBJ_METHODS (Parameter, FObject) //------------------------------------------------------------------------ protected: - ParameterInfo info {0}; + ParameterInfo info {}; ParamValue valueNormalized {0.}; int32 precision {4}; }; diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstpresetfile.cpp b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstpresetfile.cpp index 3a47c175c1..4d1fb35c12 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstpresetfile.cpp +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstpresetfile.cpp @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: diff --git a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstpresetfile.h b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstpresetfile.h index 2a9f83fce5..47d23f1e96 100644 --- a/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstpresetfile.h +++ b/modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstpresetfile.h @@ -8,7 +8,7 @@ // //----------------------------------------------------------------------------- // LICENSE -// (c) 2023, Steinberg Media Technologies GmbH, All Rights Reserved +// (c) 2024, Steinberg Media Technologies GmbH, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: