Jump to content

Sign in to follow this  
Michael Goldshteyn

Issues resetting the HPB coords of a rotated spline

Recommended Posts

Updated: Crossed out the editable portion and changed it to non-editable, since with an editable spline, Axis modification makes this trivial.

I start by creating a planar spline shape (let's pretend it's a circle). The spline lies along the XY plane - you could say it is vertical if Y points up (its Z size is therefore zero). The spline is editable not editable, but that probably doesn't matter, except to say that any re-orienting will be done via the rotation tool (or by modifying its HPB Values via the Coords attributes panel).

OK, so the goal is this:

I want the spline to lie on the XZ plane - making it horizontal.

"OK, no problem, " you say. Just do a 90 degree rotation in Pitch (i.e., around the X axis).

Now, after said rotation, the spline lies along the XZ plane, as desired and its Y size is now zero.

But, the kicker, I want to reset its HPB rotation values of the spline in this new orientation to zero - my goal is as simple as that!

Resetting the PSR at this point, to accomplish the goal, will just make the circle spline vertical again. I guess this is expected functionality, since resetting the PSR also changes the position, scale, and rotation of the object being reset as part of said reset.

Playing tricks such as creating a counter-rotated Null object, placing the spline inside of it, and trying to reset the PSR of the spline and/or the Null, and pulling the spline back out, also gets us nowhere - either the circle becomes vertical again with a zero Pitch angle, or horizontal, but with the dreaded -90/90 degree pitch angle.

I finally came up with a solution which went along the lines of placing the horizontal spline in a counter-rotated Null, putting a protection tag on the Null, clearing the PSR on the circle (or maybe I rotated it by hand), and then pulling it out, and this finally got the result I wanted - a horizontal circle spline with zeros for all of its rotation Coords in its new horizontal orientation. I should also note here that doing the opposite, that is putting the spline inside a counter-rotated Null, so that the spline's HPB values once inside the Null get zeroed out, then putting a protection tag on the spline in the hopes that one can then do whatever one wants with its parent Null without modifying the Spline's HPB values or its orientation, does not work!

There has to be an easier way to do this for an arbitrary spline! That is, to rotate it into some orientation and then reset its rotation Coords back to zero in this new orientation.

I would love any tips on an easy way to accomplish this, without having to go through the Null/Protection tag method I used above, which seems overly onerous for something this simple.

 

Share this post


Link to post
13 minutes ago, Michael Goldshteyn said:

There has to be an easier way to do this for an arbitrary spline!

Er... unless I am missing something, or have misunderstood you, yes there is a totally easier way - Axis Mode, although I hesitate to mention it because if you have been using Cinema for a couple of years I can't quite believe you haven't discovered it already !

If a spline is editable you have full control of its axis, so just rotate your spline as you wish, then enter Axis Mode, rotate that back again so the rotation becomes 0, and exit Axis Mode. Done right ?

 

CBR

Share this post


Link to post

When your spline lie on XZ and spline Y axis is pointed to world Z, just simply press "L" and set in coordinate manager rotation to zero...

Share this post


Link to post
  • Topic Author
  • Thanks guys, I am aware of this for editable splines and although I explicitly said that the spline is editable in my original question (definitely a mistake!), my intention was to be able to do this with a parametric spline object, such as a circle or rectangle for example, where using Axis Mode to modify values is not an option, since Axis mode does not work for parametric objects.

     

    Sorry for the confusion.

     

     

    Share this post


    Link to post

    If you want change axis in parametric spline, just use plane projection option for every parametric spline and then rotate object where needed...

    Share this post


    Link to post
  • Topic Author
  • 6 minutes ago, bezo said:

    If you want change axis in parametric spline, just use plane projection option for every parametric spline and then rotate object where needed...

    I guess for a parametric spline, there really is no way to zero out those angles until it is first made editable.

    Share this post


    Link to post
    38 minutes ago, Michael Goldshteyn said:

    I guess for a parametric spline, there really is no way to zero out those angles until it is first made editable.

    Correct. Hence why a null setup is sometimes needed...

     

    CBR

    Share this post


    Link to post

    Do you want to animate by some way or why needs to zero out axis?

    For example like in this case are axis aligned in all three axis, looks the same and still are parametric splines

    para_spline_axis.thumb.png.0b063c972b44dbbb373d01563eaa1740.png

    Share this post


    Link to post

    Join the conversation

    You can post now and register later. If you have an account, sign in now to post with your account.

    Guest
    Reply to this topic...

    ×   Pasted as rich text.   Paste as plain text instead

      Only 75 emoji are allowed.

    ×   Your link has been automatically embedded.   Display as a link instead

    ×   Your previous content has been restored.   Clear editor

    ×   You cannot paste images directly. Upload or insert images from URL.

    Sign in to follow this  

    • Recently Browsing   0 members

      No registered users viewing this page.

    ×
    ×
    • Create New...