A new version of Cineversity has been launched. This legacy site and its tutorials will remain accessible for a limited transition period

Visit the New Cineversity
   
 
Setting Morph strength keyframe with Python
Posted: 01 July 2021 06:02 PM   [ Ignore ]  
Total Posts:  73
Joined  2018-08-27

I’m using Python to “re-target” morphs. I’ve successfully written code to perform object position and rotation animation, but struggling with morph animation.

So far my code successfully finds the object with a morph tag and obtaining the strength value of a specific morph.

Where I’m failing, is trying to create the CTrack.

For doing this with a position value, I use code:
newtrack_y = clear_objectTrack(targetObj, c4d.DescID(c4d.DescLevel(c4d.ID_BASEOBJECT_REL_POSITION), c4d.DescLevel(c4d.VECTOR_Y)))

But for a morph, I’m using which fails:
newtrack = c4d.CTrack(targetObj, c4d.DescID(c4d.CTmorph))

targetObj is the morph tag.

I expect setting and adding a key to the CTrack will be different as well.

Does someone have an example of Setting Morph strength keyframe with Python?

Profile
 
 
Posted: 01 July 2021 07:09 PM   [ Ignore ]   [ # 1 ]  
Administrator
Avatar
Total Posts:  12043
Joined  2011-03-04

Hi brucek5,

Please have a look at Maxon’s Python Forum about this.
https://plugincafe.maxon.net/login

This should not be spread nor split across fora.

If I’m not mistaken, the Cineversity Wiki has this entry, but even here, I have no idea if it is helpful for Python 3.
https://www.cineversity.com/wiki/Python:_DescIDs_and_Animation/

All the best

 Signature 

Dr. Sassi V. Sassmannshausen Ph.D.
Cinema 4D Mentor since 2004
Maxon Master Trainer, VES, DCS

Photography For C4D Artists: 200 Free Tutorials.
https://www.youtube.com/user/DrSassiLA/playlists

NEW:

NEW: Cineversity [CV4]

Profile
 
 
Posted: 01 July 2021 08:28 PM   [ Ignore ]   [ # 2 ]  
Total Posts:  73
Joined  2018-08-27

Hi Dr. Sassi, I know this is not the place for this…
I set up an account on PluginCafe, which fails indicating the “send email” executable failed, won’t let me post a questions because I’ve not replied to the email, and I can’t find any “support” links for support for the forum! Any ideas who I can contact to fix this?

BTW- I already looked at the Cineversity Wiki link, which has examples of what I already know, and doesn’t cover Morph tracks.

Profile
 
 
Posted: 01 July 2021 08:41 PM   [ Ignore ]   [ # 3 ]  
Administrator
Avatar
Total Posts:  12043
Joined  2011-03-04

Hi brucek5,

Sorry that so many things don’t work as you like to have them.

Please open a support ticket. I hope it gets forwarded.
https://www.maxon.net/en/support-center

Perhaps try with a different email?

Fingers crossed that one or the other option will work.

Cheers

 Signature 

Dr. Sassi V. Sassmannshausen Ph.D.
Cinema 4D Mentor since 2004
Maxon Master Trainer, VES, DCS

Photography For C4D Artists: 200 Free Tutorials.
https://www.youtube.com/user/DrSassiLA/playlists

NEW:

NEW: Cineversity [CV4]

Profile