Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush Python API
      • ZBrush GoZ API
      • Code Examples on Github
    • Forum
    • Downloads
    • Support
      • Support Procedures
      • Registered Developer Program
      • Plugin IDs
      • Contact Us
    • Categories
      • Overview
      • News & Information
      • Cinema 4D SDK Support
      • Cineware SDK Support
      • ZBrush 4D SDK Support
      • Bugs
      • General Talk
    • Recent
    • Tags
    • Users
    • Login

    Getting the x,y values of a spline

    Scheduled Pinned Locked Moved PYTHON Development
    3 Posts 0 Posters 258 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • H Offline
      Helper
      last edited by

      On 03/04/2014 at 15:08, xxxxxxxx wrote:

      Hey Everyone,
      I am trying to map the current frame to the x value of a spline, how would I get the y value?  I know how to get the value if it is a knot but what if it's not a knot, It'd be similar to an animation curve in the animation timeline.

      If this is confusing I can give some clarification.
      Jimmy

      1 Reply Last reply Reply Quote 0
      • H Offline
        Helper
        last edited by

        On 04/04/2014 at 02:18, xxxxxxxx wrote:

        Work out the frame as a fraction of the document length (e.g. in a 90 frame scene, frame 9 = 9/90 = 0.1).

        Plug that into the SplineData::GetPoint function. It returns a vector; the value you want is the y component of that vector.

        Steve

        1 Reply Last reply Reply Quote 0
        • H Offline
          Helper
          last edited by

          On 04/04/2014 at 12:45, xxxxxxxx wrote:

          Awesome, That totally Worked!  Thank you!

          1 Reply Last reply Reply Quote 0
          • First post
            Last post