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

    Python generator after making editable

    Scheduled Pinned Locked Moved PYTHON Development
    3 Posts 0 Posters 540 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 09/01/2018 at 02:58, xxxxxxxx wrote:

      I noticed that some of the C4D generators can return another object when making it editable.
      for example, subdivision surface has 2 subdivision types. When this generator is 'alive' it returns geometry with a value set to subdivision editor, but after making it editable, we are getting another object with a value of subdivision renderer...
      I wonder if it is possible to execute some other code when turning object generator plugin or python generator, into an editable object.

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

        On 09/01/2018 at 03:02, xxxxxxxx wrote:

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

          On 10/01/2018 at 04:13, xxxxxxxx wrote:

          Hi,

          A generator checks the BUILDFLAGS in GetVirtualObjects() to return the correct geometry.
          When an object is made editable the flag is set to BUILDFLAGS_EXTERNALRENDERER. Then the generator should return the render geometry representation.

          The BUILDFLAGS have to be retrieved from a HierarchyHelp object.
          Unfortunately this class is not available in the Python API, so hh variable in a Python generator is an opaque object ( PyCObject ). This is also the case for the hh parameter of ObjectData.GetVirtualObjects().
          So this is a limitation and there is no way to obtain the current BUILDFLAGS with the Python API.

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