[Migration Guide] v0.2.x -> v0.3.x #4
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This is a migration guide for anyone that uses this SDK recreation. A lot has changed thanks to scanning thousands of available VST 1.x and 2.x plug-ins automatically instead of going through them manually.
Generic Changes
typedefandstructshould now have the proper_tsuffix attached.enums that incorrectly had a plural name now have a singular name, i.e.FLAGS->FLAG.char[]buffer sizes are now in their ownenuminstead of#defineand have been split by what they're for and their stated size is now correct.Effect Changes
VST_EFFECT_CATEGORY_CONTAINERfor more information. Note that hosts may not actually support container plug-ins so it is not a safe option to use.VST_EFFECT_FLAGVST_STATUS_TRUEfrom theVST_EFFECT_OPCODE_SUPPORTSquery forbypass. This alternative mode requires the plug-in to handle the whole bypass code instead of having the host handle it. Could be useful for effects that require a constant feed of data or they regain their initial delay. See documentation forvst_effect_supports.bypassfor more information.VST_EFFECT_OPCODE_IDLEand have optional support forVST_EFFECT_PROCESS_BEGINandVST_EFFECT_PROCESS_END. You can query the host for support usingstartStopProcess, seevst_host_supports.startStopProcess. I recommend an additional host version check when the plug-in is loaded to ensure that you are in a 2.4 or later host.#defines for the actual default values that VST 1.x and 2.x expects your plug-in to default to asVST_DEFAULT_SAMPLE_RATEandVST_DEFUALT_BLOCK_SIZE. Hosts are not required to change the sample rate of your plug-in to match these defaults, but many of them do as a safety precaution.Custom Editor Changes
vst_rect_tis now in the correct counter-clockwise order as defined by Steinberg instead of the same order asRECTfrom WinAPI. Adjust your code accordingly.VST_HOST_OPCODE_AUTOMATEop-code. This expects the parameter index as well as a float representation of the value - even for integer parameters.VST_HOST_OPCODE_PARAM_START_EDITandVST_HOST_OPCODE_PARAM_STOP_EDIT.VST_HOST_OPCODE_EDITOR_UPDATE. Doesn't appear to be supported by all hosts as many just ignore it.Parameter Changes
VST_PARAMETER_FLAG_RAMPING. It allows the host to gradually increase/decrease the value of a parameter if it is automated instead of snapping to the target value immediately.VST_EFFECT_OPCODE_PARAM_VALUE_FROM_STRINGis added that allows the host to set a parameter from a string. This complementsVST_EFFECT_OPCODE_PARAM_GET_VALUEwhich is used to do the opposite. The functionsset_parameterandget_parameterappear to be only used for parameters that are automatable but not all hosts respect this and usually the functions have priority.Program/Bank Changes
VST_EFFECT_FLAG_CHUNKSflag to indicate support for saving and loading of banks and programs. Take a look atVST_EFFECT_OPCODE_SET_CHUNK_DATAandVST_EFFECT_OPCODE_GET_CHUNK_DATAfor further information. A bank appears to be a collection of program data.VST_EFFECT_OPCODE_PROGRAM_SET_BEGINandVST_EFFECT_OPCODE_PROGRAM_SET_ENDwhich are called by the host to notify the plug-in that the host is now loading a program. These have no parameters so it's likely for the currently selected program.VST_EFFECT_OPCODE_PROGRAM_LOADwhich is sent prior to the op-codes in (2), but it uses a yet unknown structured format.Input/Output Changes
VST_HOST_OPCODE_SUPPORTSquery foracceptIOChanges. If it returns true from this we can emitVST_HOST_OPCODE_IO_MODIFIEDafter we adjust thenum_inputs,num_outputs,num_programsand/ordelayvalues in our effect. This behavior is only valid while we are currently idle so it can't be tied to anything that would be automatable. Depending on the host an idle plug-in is either receivingVST_EFFECT_OPCODE_IDLEor currently between theVST_EFFECT_OPCODE_PROCESS_ENDandVST_EFFECT_OPCODE_PROCESS_STARTgroup. Seevst_host_supports.acceptIOChangesfor more information.VST_EFFECT_OPCODE_INPUT_GETCHANNELNAMEandVST_EFFECT_OPCODE_OUTPUT_GETCHANNELNAMEactually point to a structure describing each input/output stream. Therefore a new structure was created calledvst_stream_properties_tthat should be used to describe each input/output stream that you support. Seems to be used by the host fornum_inputsandnum_outputs. The new op-codes areVST_EFFECT_OPCODE_INPUT_GET_PROPERTIESandVST_EFFECT_OPCODE_OUTPUT_GET_PROPERTIES.Migration Guide v0.3.0 to v0.3.1
Generic Changes/Updates
floatParameters to be normalized within 0.0 and 1.0, even when a custom editor is provided.Effect Changes/Updates
VST_EFFECT_FLAG.Parameter Changes/Updates
VST_EFFECT_OPCODE_PARAM_PROPERTIESbeing set to the wrong number. Don't code while sleepy.Host Changes/Updates
VST_HOST_OPCODE_PARAM_UPDATEto stick with the same naming scheme.vst_host_callback_tnow also has the properVST_FUNCTION_INTERFACEdeclaration.Input/Output Changes
Migration Guide v0.3.1 to v0.3.2
vst.hpp. Somehow clang++ was happy with it despite the type not existing.Migration Guide v0.3.2 to v0.3.3
Migration Guide v0.3.3 to v0.3.4