Hi,
I just downloaded IPlug2 from GitHub recently and tried to compile it with MSVS 19 under Win10.
The included example for IPlugInstrument does not compile for VST2 and produces following errors:
1>C:\iPlug2\IPlug\IPlug_include_in_plug_src.h(76,36): error C2672: ‘std::max’: no matching overloaded function found
1>C:\iPlug2\IPlug\IPlug_include_in_plug_src.h(76,62): error C2780: ‘_Ty std::max(std::initializer_list<_Elem>)’: expects 1 arguments - 2 provided
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Preview\VC\Tools\MSVC\14.27.28919\include\utility(52): message : see declaration of ‘std::max’
1>C:\iPlug2\IPlug\IPlug_include_in_plug_src.h(76,62): error C2784: ‘_Ty std::max(std::initializer_list<_Elem>,_Pr)’: could not deduce template argument for ‘std::initializer_list<_Elem>’ from ‘VstInt32’
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Preview\VC\Tools\MSVC\14.27.28919\include\utility(49): message : see declaration of ‘std::max’
1>C:\iPlug2\IPlug\IPlug_include_in_plug_src.h(76,62): error C2782: ‘const _Ty &std::max(const _Ty &,const _Ty &) noexcept()’: template parameter ‘_Ty’ is ambiguous
What I did wrong?
For VST3 it can not find included files (too many to list).
New tutorial is great. It builds VST3 plugin. But if I go to VST2 project then I got the same errors in compilation
1>C:\iPlug2\IPlug\IPlug_include_in_plug_src.h(76,36): error C2672: ‘std::max’: no matching overloaded function found
1>C:\iPlug2\IPlug\IPlug_include_in_plug_src.h(76,62): error C2780: ‘_Ty std::max(std::initializer_list<_Elem>)’: expects 1 arguments - 2 provided
pointing me out to this line in IPlug_include_in_plug_src.h
aEffect.numPrograms = std::max(aEffect.numPrograms, 1); // some hosts don’t like 0 presets
Ok, thanks… Otherwise, it is great !
I will check the compilation on MAC tonight.
Now it seems that anyone can do his own synth - a dream comes true)
A good thing and is not only.