Allow plug-ins to output values for expressions to reference
For example, take the 2d positions of 2 nulls and output in the plug-in UI :
A slider showing distance between them
2d Point showing the midpoint between the positions
Angle showing the angle between the points
Stretch % based on the distance between the points relative to their original distance.
This is a very simple example, but if you're calculating Inverse Kinematics you end up duplicating a lot of code, because expressions can only share one output value.
I read this in the 2018 SDK updates :
A new entry point has been defined, to allow effects to register basic information with the host at runtime, without relying on legacy PiPL resources. An effect can register multiple entry points in a single binary this way. Premiere Pro is the first host to support this entry point, and After Effects will support this in a future release.
Is this what i'm referring to and if so, can we expect it any time soon for After Effects?
Another option would be the support of an array effect control, so multiple values can be output by a single expression at the moment we're limited to a 3d point outputting an array of length 3.
Would really appreciate any advice or info.
> Are you saying with the help of an AEGP an effect plug-in can be applied...
No, I was completely setting aside effect plug-ins; AEGPs can control streams directly.
For the example you provide, an AEGP could display as a panel, offering two layer picking pop-ups (the AEGP would likely want to update available layers, based on the currently active Comp), and computing a value for that point control.
Where is that point control coming from, by the way; one of the layers? Some other property?
James Smith commented
Hi Bruce, thanks for your comment, i'm very excited because I've been told it can't be done.
Are you saying with the help of an AEGP an effect plugin can be applied to a layer, with the following controls :
1) Layer Control A
2) Layer Control B
3) Point Control
Layer control A and B allow the user to select layers. With the help of AEGP, the midpoint of Layer A and B position is calculated and the value output in Point Control 3.
Point Control 3 is read-only and can be accessed by expressions, for example to make a null follow the midpoint.
This would all need to work regardless of whether the layer is selected and also calculated at render-time.
I appreciate this very simple example can be done easily with expressions, but my goal is to create an IK plugin that doesn't rely on multiple expressions, on different layers.
The IK calculation would all be contained in one effect and able to share calculated bone data.
If you're confident this is possible, please can you explain in more detail how I can achieve the simple midpoint example.
I'm very good at writing scripts and created a few basic effect plugins, but can't figure out how to achieve this.
Really appreciate any help/advice.
The new entry point definition has nothing to do with offering stream access to effect plug-ins.
Happily, AEGPs have had access to parameter streams for years! See the 'Streamie' and 'Panelator' AEGP samples in the plug-in SDK, and feel free to ask us questions.