Hide Instance Master [SOLVED]
On 11/03/2015 at 14:45, xxxxxxxx wrote:
Cinema 4D Version: 14,15,16
Language(s) : C++ ;
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.
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.
On 12/03/2015 at 08:03, xxxxxxxx wrote:
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.
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.
On 13/03/2015 at 07:38, xxxxxxxx wrote:
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,
On 13/03/2015 at 14:45, xxxxxxxx wrote:
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.