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

    Render Options [SOLVED]

    Scheduled Pinned Locked Moved PYTHON Development
    5 Posts 0 Posters 455 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 22/01/2015 at 07:52, xxxxxxxx wrote:

      I would like to create automatic setup render, with Effect (Ambient Occlusion, GI, Sketch and Toon) by Python

      I have not found in the SDK documentation
      Could you help me?
      Thank You

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

        On 22/01/2015 at 14:28, xxxxxxxx wrote:

        Example: 
        How do I create a new "My Render Setting" with Sketch and Toon?  🙂

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

          On 22/01/2015 at 15:41, xxxxxxxx wrote:

          You are going to want to look at pvp and RenderData, this should help you out[URL-REMOVED].


          [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 23/01/2015 at 06:20, xxxxxxxx wrote:

            Hello,

            as Shawn pointed out, render settings are stored with RenderData[URL-REMOVED] objects. You can create such an object and add it to your document. The RenderData object stores also a list of post effects; to add a post effect you have to create such an object and add it to the RenderData:

              
            # create new render settings  
            renderData = c4d.documents.RenderData()  
              
            if renderData is None:  
             return  
              
            renderData.SetName("My New Render Settings")  
              
            # create S&T post effect  
            stVideoPost = c4d.BaseList2D(1011015)   
              
            if stVideoPost is not None:  
               
              # setup the video post  
              stVideoPost[c4d.OUTLINEMAT_LINE_OUTLINE] = True  
                
              # add video post to render data  
              renderData.InsertVideoPost(stVideoPost)  
                
              # add render data to document  
              doc.InsertRenderData(renderData)  
                
              # make active  
              doc.SetActiveRenderData(renderData)  
              
            c4d.EventAdd()  
            

            The ID's of the post effects can be found in the ge_prepass.h and c4d_videopostdata.h header files; if such an ID cannot be found there you may have to create the post effect in question yourself and use above infrastructure to get the type via GetType()[URL-REMOVED].

            best wishes,
            Sebastian


            [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 23/01/2015 at 14:02, xxxxxxxx wrote:

              thanks to all!!! 🙂

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