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
    • Unread
    • Recent
    • Tags
    • Users
    • Login

    Rotation handle

    Scheduled Pinned Locked Moved PYTHON Development
    3 Posts 0 Posters 353 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 02/05/2016 at 09:45, xxxxxxxx wrote:

      What is the best way to add a rotation handle to my object?
      Sizing and moving is ok, but how to add a rotation handle?

      -Pim

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

        On 03/05/2016 at 03:53, xxxxxxxx wrote:

        Hi Pim,

        Objects are usually rotated with the Rotate tool.
        Do you want to rotate the object or rotate a component/parameter of the object?

        Spherical handles can be declared with the HandleInfo type.
        Look at the DoubleCircle SDK example for a way to implement handles with HandleInfo/GetHandleInfo()/GetHandle()/SetHandle() and DetectHandle()/MoveHandle().

        DetectHandle()/MoveHandle() shouldn't be implemented in objects but the Python API doesn't use the automatic Handle interface currently for ObjectData plugins. It is supported for FalloffData plugins only.

        In GetHandle() an HandleInfo can be initialized with info.type = HANDLECONSTRAINTTYPE_SPHERICAL
        Then in MoveHandle() the info.CalculateNewPosition() for the handle will return a position calculated with a spherical constraint.

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

          On 03/05/2016 at 05:48, xxxxxxxx wrote:

          Hi Yannick,

          I agree with you. Stick to using the Rotate Tool is the best thing.

          Thanks, Pim

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