THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 24/04/2006 at 04:12, xxxxxxxx wrote:
User Information:
Cinema 4D Version: 9.102
Platform: Windows ; Mac ; Mac OSX ;
Language(s) : C++ ;
---------
This is going to be difficult to describe succinctly. I'll try to do it.
In order to accomodate Poser paradigms, the construction for Poser figures is thus:
Polygon Object
Plugin Deformer Bone: plugin tags representing 'dials'/sliders for translation, rotation, scale, morph.
Plugin Deformer Bone: similar
... (for an entire rigged hierarchy)
All of the plugin tags are collected on the Plugin Deformer as a list of sliders (using dynamic descriptions with GetDDescription()). When the sliders are changed, the values are converted within the plugin tags and make the appropriate translations into Cinema 4D for the action they represent.
Now enter master-slave control. 'Dials'/sliders can be master or slave to any other 'Dials'/sliders (on the figure or betwixt figures or props even). I've decided that the best implementation is by way of XPresso tags with nodes that take the master setting and affect the slave setting (on the plugin tag - dial). Poser doesn't directly affect the dial/slider, but instead uses its value as input to a calculation of the resulting slave value (not on the slider directly). In other words, you can set the slider value, but the master uses that to set the resultant value independently.
Now, I've set up a means to do this with XPresso tags: the slave dial setting is fed into the calculation along with the master dial setting to arrive at a result into a 'slave' setting that is not the same as the slave dial setting. The problem is that when I go to resolve the slave settings of the master, there is no way to force the XPresso tags to calculate their results.
What I mean is this: When the master slider value is changed by the user, SetDParameter() of the Plugin deformer is used to find and set the appropriate plugin tag on that deformer. This, in turn, checks to see if the slider is a master and calculates the slave values. But it appears that the XPresso nodes are not being evaluated so that the current settings are applied to the slave dials. This keeps the settings out of synch by one step, something that must be avoided.
I've tried everything (EventAdd(), AnimateObjet(), Message(), ...) but a change on the master dial does not immediately reflect in its slaves because the XPresso nodes are not being forced to reevaluate. If source code is required, I will be glad to profer it to the required party (as complex as it is) to be analyzed for solutions.
Thank you very much,
Robert