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

    How to set options for SendModelingCommand?

    Scheduled Pinned Locked Moved PYTHON Development
    3 Posts 0 Posters 287 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 25/07/2015 at 05:08, xxxxxxxx wrote:

      How can I send options for SendModellingCommand?
      As far as I can understand from the documentation I need to send the options through a bc, but I'm not sure how.

      c4d.utils.SendModelingCommand(c4d.MCOMMAND_SUBDIVIDE,[polyobj],c4d.MODIFY_ALL,c4d.BaseContainer)

      #errors
      ?

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

        On 25/07/2015 at 12:28, xxxxxxxx wrote:

        Just create a BaseContainer and set the options that are provided in the SDK. Some options are not documented in the SDK but the SDK points out the header file (some_name.h) that contains the relevant parameters.
        So, here is an example of how to use the Untriangulate command:

        bc=c4d.BaseContainer()
        bc.SetBool(c4d.MDATA_UNTRIANGULATE_ANGLE,True)
        bc.SetReal(c4d.MDATA_UNTRIANGULATE_ANGLE_RAD,angle);
        bc.SetBool(c4d.MDATA_UNTRIANGULATE_NGONS,False)

        result=utils.SendModelingCommand(command=c4d.MCOMMAND_UNTRIANGULATE,list=[op],mode=c4d.MODELINGCOMMANDMODE_POLYGONSELECTION,bc=bc,doc=doc)

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

          On 31/07/2015 at 10:30, xxxxxxxx wrote:

          Hello utisz,

          was your question answered?

          Best wishes,
          Sebastian

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