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

    Hide Instance Master [SOLVED]

    SDK Help
    0
    5
    664
    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
      Helper
      last edited by

      On 11/03/2015 at 14:45, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   14,15,16 
      Platform:      
      Language(s) :     C++  ;

      ---------
      Hi,

      Is there a way to hide the instance master in the render?

      I want to get a behavior similar to the cloner object, where the children of the cloner object no longer appear in the viewport, and only render as clones.
      I am generating my own instance clones, and not using the cloner object in any way.

      Using this

      child->SetParameter(DescID(ID_BASEOBJECT_VISIBILITY_EDITOR), OBJECT_OFF, DESCFLAGS_SET_0);
      

      does not seem to work since the master will still appear in the render. In my case I want only the generated clones to render without rendering the master.

      Thanks

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

        On 12/03/2015 at 08:03, xxxxxxxx wrote:

        Hello,

        can you give us some more information on what kind of plugin you work on? Are you working on a ObjectData generator? Is the "instance master" a child object of your object?

        In this case you can set the OBJECT_INPUT flag when registering your object plugin. Then you can use GetAndCheckHierarchyClone() to hide the child objects in GetVirtualObjects(). You find some code in the Atom Object examle.

        Also, ID_BASEOBJECT_VISIBILITY_EDITOR does, as the name suggest, only define the visibility of an object in the editor (viewport). The visibility of an object while rendering is defined with ID_BASEOBJECT_VISIBILITY_RENDER.

        Best wishes,
        Sebastian

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

          On 12/03/2015 at 14:20, xxxxxxxx wrote:

          Thanks Sebastian. I already came up with another solution, but I'll keep yours in mind for the future.

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

            On 13/03/2015 at 07:38, xxxxxxxx wrote:

            Hello,

            great that you found a solution. Maybe you want to share that solution with us so other users with the same problem may benefit from it? Also it would be nice if you would inform the forum when you already solved your own issue.

            Thanks & best wishes,
            Sebastian

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

              On 13/03/2015 at 14:45, xxxxxxxx wrote:

              Hi,

              The reason I waited was because I wanted to get an "official" solution to the problem from support.

              I ended up manipulating the transform matrix of the master object at render time, thus making it disappear only on render.

              Thanks again.

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