Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware 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

    SetDocumentData options for exporting

    Cinema 4D SDK
    r20 python
    2
    4
    1.2k
    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.
    • R
      Rage
      last edited by

      Hi everyone,

      I'm struggling to find the options (like the ones visible in the gui, export materials/flip z axis and so on) in the python documentation.

      SaveDocument takes a base document as parameter and I set its settings using SetDocumentData that points to this list of settings:

      [https://developers.maxon.net/docs/Cinema4DPythonSDK/html/consts/DOCUMENTSETTINGS.html](link url)

      I don't see all the options I can see in the gui. How do I set them?

      1 Reply Last reply Reply Quote 0
      • M
        m_adam
        last edited by m_adam

        Hi @Rage,

        I'm not sure to understand your current context. Are you doing a script, or a SceneSaver plugin?

        Moreover, do you want to export the file in a different format than c4d?
        And about "export materials/flip Z axis" parameter can you tell me where you find them within Cinema 4D?

        Cheers,
        Maxime.

        MAXON SDK Specialist

        Development Blog, MAXON Registered Developer

        1 Reply Last reply Reply Quote 0
        • R
          Rage
          last edited by

          Hi @m_adam ,

          Let me give you more details.
          I'm writing a plugin that processes the geometry of each object in a scene. After processing the geometry I want to export the file as obj and mtl. I followed the documentation to do this last part (linked in the first post) but the mtl is not exporting. On the other hand, on another machine, the mtl gets exported.

          If you go to file->export->obj , after selecting the path to export to, you will see that a list of parameters pops up. In one of these parameters you can set to export or to don't export the materials. For some reasons, when I run the plugin, on my computer the material is not exported. How can I set this property and all the others that pop up in this dialog?

          1 Reply Last reply Reply Quote 0
          • M
            m_adam
            last edited by m_adam

            Hi @Rage

            I guess export_OBJ example on our Github repository is what you are looking for.
            Note for the moment values of the BaseContainer are not available in the Python Documentation.
            But you could find them in the C++ documentation about fobjexport2.h.

            If you have any question please let me know.
            Cheers,
            Maxime.

            MAXON SDK Specialist

            Development Blog, MAXON Registered Developer

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