SDK: Set Parameter value during paramSetup
Hi
I need my effects to have a unique ID. So I have created an AEGP and a custom suite. The custom suite have a function which returns an unique effect ID.
In the very end of the ParamSetup function I want to do this:
Call GetUniqueEffectID function
Use AEGP_GetNewEffectForEffect to get effect
Use AEGP_GetNewEffectStreamByIndex to get parameter stream
Use AEGP_SetStreamValue to set value of a hidden ID parameter to the uniqueID
The problem is I don't get far. If I call this line at the end of paramSetup I get a runtime error:
ERR(suites.PFInterfaceSuite1()->AEGP_GetNewEffectForEffect(globP->my_id, in_data->effect_ref, &effectRef));What would be the correct way to do this? Is there a better time to set the parameter value?
Thanks,
Jakob
