A newer version of Max is available. Click here to access the latest documentation.

plugmorph

Generate parameter values created by morphing between other presets

Description

Note: plug-in building for hosts other than Ableton Live is no longer supported. For more information to help you make the transition to creating plug-ins in Max for Live, see Max for Live for Pluggo Developers.

plugmorph allows a plug-in to modify the parameter values of another plug-in by creating a weighted average of two or more of its effect programs. Such an average is often known as a "morph" since it can often (but not always) create a continuous perceptual space between one effect program and another. plugmorph generates a pop-up menu listing all currently loaded plug-ins. The output of this menu is fed back to the input of the object, allowing the user to specify which plug-in should be modified according to the input plugmorph receives. An additional inlet and outlet interface with a pp object saves the object's connection to a particular plug-in. This allows plugmorph to reconnect to its target plug-in when a sequencer document is reloaded.

Arguments

None.

Messages

bang Reloads menu information.
int plug-in-target-code [int]
Converted to float.
float plug-in-target-code [float]
In right inlet: The value is interpreted as a code to assign a new plug-in as a target. The outlet of a pp object is normally connected to this inlet.
list program-number and weighting-fraction [list]
In left inlet: Causes plugmorph to calculate new values for the connected plug-in's parameters. The format of the list is an effect program number followed by a weighting fraction. A maximum of 128 program numbers can be specified. If the fractions do not add up to 1, they are normalized to do so. As an example, the list 1 0.5 2 0.5 would set the target plug-in's parameters to values that were a simple average of effect programs 1 and 2. A list of 1 0.6 2 0.6 3 0.6 4 0.6 would perform a weighted averaging of the first four effect programs where the parameter values of each program were represented equally. In other words, each program's parameter value contributes 25% to the morphed value. If the target plug-in's current effect program is among those being morphed, an attempt is made not to store the parameter values so the user can perform more than one morph. The generated parameter values can be stored later using the store message to plugmorph. However, some multislider-based plug-ins defer parameter changes in such a way that this storage prevention mechanism doesn't work, requiring that the user set the current effect program to a number that isn't involved in the morph.
anything name [list]
In left inlet: A plug-in name sets what the plugmorph object will modify with its input. This plug-in is referred to as the object's target.
morphfixed fixed-include-flag (0 or non-zero) [int]
In left inlet: The word morphfixed, followed by a number, determines whether parameters marked as fixed are included in the morph. If the number is 0, fixed parameters are not included and their values are left unchanged. If the number not zero, fixed parameters are included. The default behavior of plugmorph is to include fixed parameters.
morphhidden hidden-include-flag (0 or non-zero) [int]
In left inlet: The word morphhidden, followed by a number, determines whether parameters marked as hidden are included in the morph. If the number is 0, hidden parameters are not included and their values are left unchanged. If the number not zero, hidden parameters are included. The default behavior of plugmorph is to include hidden parameters.
store In left inlet: The word store copies the current values of the target plug-in's parameters to its effect program.

Information for box attributes common to all objects

Output

anything: Out left outlet: Output from this outlet of the plugmorph object occurs when a new plug-in is either inserted or deleted. The messages update an attached umenu object with a new list of plug-ins that are potential targets.
float: Out 2nd outlet: When a new plug-in is selected as a target, plugmorph outputs the number of effect programs it contains out this outlet.
Out right outlet: The current parameter code is output when the object's plug-in target changes via a message from the attached pop-up menu object sent to the object's left inlet, or when a new parameter code is received in the right inlet.

Examples

See Also

Name Description
umenu Pop-up menu, to display and send commands
plugconfig Configure the behavior of a plug-in
plugmidiin Receive MIDI events from a plug-in host
plugmidiout Send MIDI messages to a plug-in host
plugmod Modify plug-in parameter values in other plug-ins
plugmultiparam Define an array of plug-in parameters
plugstore Store multiple plug-in parameter values
pp Define a plug-in parameter
pptempo Define plug-in tempo and sync parameters
pptime Define time-based plug-in parameter
plugin~ Define a Max for Live device's audio inputs
plugout~ Define a plug-in's audio outputs