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

    Noob Questions

    Scheduled Pinned Locked Moved PYTHON Development
    3 Posts 0 Posters 986 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 05/07/2018 at 01:45, xxxxxxxx wrote:

      Hi there,

      I'd like to read data from zipped text files via a Python plugin and create rigged objects with Xpresso driven morphs. All needed data are available in this collection of text files. This will be my first plugin.

      I'm aware that this is a longtime project, but I really want to start with that. Unfortunately the information about writing Python plugins for Cinema 4D is quite cluttered and quite old, so I'd love to get some hints, where to start, as I didn't find an in-depth tutorial about what I need to start with.

      Any hints or recommendations? Any tutorials (paid or free) that can be recommended?

      Thanks a lot in advance
      V4N

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

        On 06/07/2018 at 02:51, xxxxxxxx wrote:

        Hi Vision4Next,

        Regarding your first question, the c4d SDK does not offer any way to manage zip file. But python offers it through the zipfile module. But we can't offer you support for 3rd party stuff, so if you have questions regarding zipfile module you should ask them on another forum like stackoverflow

        With that said, if I understand correctly you want a one execution thing(a user press a button/menu and it does the import). For that, you can simply make a script, or either a CommandData plugin.
        But if making a plugin afraid you, you can make a script and then convert it to a plugin using the prototype converted[URL-REMOVED].
        Then the creation of an object can be done using BaseObject. To understand the concept of BaseObject I let you read the C++ manual (don't be afraid C++ code and python is pretty similar, the most important is to understand the concept)

        About tutorials since as you can imagine C4D SDK is pretty big and cover a lot of topics, there is nothing that resumes everything, but some resources are linked in this page Public resource[URL-REMOVED]
        But in all case, the way to success is going step by step, and solve problems step by step. So please do not hesitate to come to us for any questions!

        Cheers,
        Maxime


        [URL-REMOVED] @maxon: This section contained a non-resolving link which has been removed.

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

          On 06/07/2018 at 10:58, xxxxxxxx wrote:

          Thanks a lot for your fast response. I have some character files that I analyzed in the last 2 years and really want to find a way to import them into Cinema 4D with as much features as possible. I did it manually, but I'd like to automate it, as doing it manually takes several hours. Taking the script route for a start is definitely a good hint.

          Your answer is quite helpful and I really want to share my findings, if someone is interested here. Thanks again 🙂
          V4N

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