Jump to content
[[Template core/front/profile/profileHeader is throwing an error. This theme may be out of date. Run the support tool in the AdminCP to restore the default theme.]]

Community Reputation

0 Neutral

About lou_untitled

  • Rank
    Peon

Personal Information

  • Name
    Louis Taddei
  • Location
    France
  1. Hello, I wrote a little python snippet which load a preset of an HDA when conditions are met. The only thing I haven't succeed is to get the HDA path without writing it exactly (if I copy paste the HDA the path need to change automatically or if I change the name of the HDA). My python node is inside the HDA so maybe there's an expression for something like this. Thank you ! EDIT : a very simple work around is just to use the opfullpath in vex and read the path back in Python.
  2. Matrix and quaternion to degrees problem

    This is indeed much simpler and effective, thank you so much !
  3. Hello, I'm trying to automate cogs rotation using vex and a formula I've found online. The basic scenario is the following : one cog 'parent' and one cog 'child'. The cog 'parent' is animated (simple animation on Y axis) and will drive the cog 'child' by the following formula : (cog 'parent') * (-cog 'parent' teeth / cog 'child' teeth) this is quite easy. In the example I provided I 'hardcoded' the teeth count but it is calculated procedurally in a larger setup. All my cogs are packed primitive so I used matrices to modify their rotation. The main problem is when I extract the rotation of the cog 'parent' to modify it, converting the matrix4 into a matrix3 then into a quaternion then into Euler then into degree, it looks like the angle in degree can't go beyond 360°. The rotation in degrees takes weird values. At the frame 87 the extracted rotation Y of the cog 'parent' is 89.5836 degrees but at the frame 88 it's -269.375 which is the same value of angle (90° = 270°) but since the cog 'child' is not symmetrical I can see 'jumping' and If I calculate velocity on top of that the vector between these two frames will be wrong. The value at the frame 88 should be 90.625 not -269.375. I feel like the conversion doesn't allow for value bigger than 360°. I feel like I'm missing on a small thing that can be easily fixed. Is there a solution ? I've tried putting a modulo 360 somewhere but that didn't change anything I've tried dealing only with matrices without converting them but that's out of my knowledge (multiplying the rotation matrices by the ratio driven/driving so (cog 'child' teeth / cog 'parent' teeth) . Thank you for your time, Stay safe. cogs_automation_problem.hiplc
×