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
    • Admin
    • Login

    Updating while dragging a handle

    Scheduled Pinned Locked Moved PYTHON Development
    3 Posts 0 Posters 330 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/05/2016 at 06:46, xxxxxxxx wrote:

      I have a Objectdata plugin (OBJECT_GENERATOR) with handles.
      I use these handles to deform an object.

      Only, when I drag the handles, the scene is not update.
      I tried to update the scene using DrawViews(), but that did not work.

      What should I do to update the scene while dragging handles?
      I did look at RoundedTube, that updates the scene during dragging, but that did not give any clues how to solve it.

      Note: In GetVirtualObjects, I create the object and insert it directly  into the scene (after first deleting the previous created one). Thus the object is not inserted using the return of GetVirtualObjects.

      -Pim

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

        On 03/05/2016 at 07:27, xxxxxxxx wrote:

        Hi Pim,

        Originally posted by xxxxxxxx

        I have a Objectdata plugin (OBJECT_GENERATOR) with handles.
        I use these handles to deform an object.

        Only, when I drag the handles, the scene is not update.
        I tried to update the scene using DrawViews(), but that did not work.

        What should I do to update the scene while dragging handles?
        I did look at RoundedTube, that updates the scene during dragging, but that did not give any clues how to solve it.

        How do you implement MoveHandle()?
        If an handle is moved successfully then this should change one of its parameters and the way it has to be generated. See SetHandle() called from MoveHandle() in DoubleCircle and RoundedTube examples.

        Originally posted by xxxxxxxx

        Note: In GetVirtualObjects, I create the object and insert it directly  into the scene (after first deleting the previous created one). Thus the object is not inserted using the return of GetVirtualObjects.

        I'm confused by what you describe here.
        GetVirtualObjects() shouldn't delete any object. It should return a new one if it's updated.
        Also the active document must not be touched in GetVirtualObjects().

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

          On 03/05/2016 at 08:19, xxxxxxxx wrote:

          Hi Yannick,

          Indeed, i do not use GetVirtualObjects correctly, I change the setup and now it is updating.

          Thanks, Pim

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