Here you will find documentation on all the descriptions that Cinema 4D currently has. You can list them Alphabetically, by Type or Plugin . The sample Python and C++ code is automatically generated and in some cases may not be 100% correct. If something doesn't work then please refer to the official Cinema 4D SDK documentation for more information.

IDs and information for COMPOSITING3DTAG

COMPOSITING3DTAG

Attributes

  • ENGLISH NAME : ExternalCompositingTag
  • NAME : COMPOSITING3DTAG
  • INCLUDE : Tbase
  • PATH : compositing/description/compositing3dtag.res
  • PLUGIN : compositing
  • MAXON online help (may not exist): COMPOSITING3DTAG

Elements

ID UI Name Type Parameters Cycle
COMP3DTAG_CHILDREN Children BOOL ANIM
COMP3DTAG_CACHE Cache BOOL ANIM
COMP3DTAG_MIDPOINT AnchorPoint LONG
ANIM OFF
FIT_H
COMP3DTAG_MIDTL Topleft
COMP3DTAG_MIDTR Topright
COMP3DTAG_MIDCTR Center
COMP3DTAG_MIDBL Bottomleft
COMP3DTAG_MIDBR Bottomright
COMP3DTAG_SOLID Solid BOOL ANIM
COMP3DTAG_SIZEX SizeX LONG
ANIM OFF
MIN 1
MAX 50000
COMP3DTAG_SIZEY SizeY LONG
ANIM OFF
MIN 1
MAX 50000
COMP3DTAG_COLOR Color COLOR ANIM

Example Code

The following code does not use the correct values when setting the data. You should check directly in C4D for the correct values that you should use in place of the ones that are shown. This code is just to show you how to access the values for getting and setting the parameters.

Python

import c4d
from c4d import gui
def main():
    obj = c4d.BaseObject(c4d.Osphere)
    tag = obj.MakeTag(c4d.COMPOSITING3DTAG)
    doc.InsertObject(obj)
    c4d.EventAdd(c4d.EVENT_FORCEREDRAW)
    
    #You can set parameters two different ways. 
    #First way              
    tag[c4d.COMP3DTAG_CHILDREN] = True
    tag[c4d.COMP3DTAG_CACHE] = True
    tag[c4d.COMP3DTAG_MIDPOINT] = c4d.COMP3DTAG_MIDTL
    tag[c4d.COMP3DTAG_SOLID] = True
    tag[c4d.COMP3DTAG_SIZEX] = 1
    tag[c4d.COMP3DTAG_SIZEY] = 1
    
    #Second way, using the base container.
    bc = tag.GetDataInstance()
    bc.SetBool(c4d.COMP3DTAG_CHILDREN,True)
    bc.SetBool(c4d.COMP3DTAG_CACHE,True)
    bc.SetInt32(c4d.COMP3DTAG_MIDPOINT,c4d.COMP3DTAG_MIDTL)
    bc.SetBool(c4d.COMP3DTAG_SOLID,True)
    bc.SetInt32(c4d.COMP3DTAG_SIZEX,1)
    bc.SetInt32(c4d.COMP3DTAG_SIZEY,1)

if __name__=='__main__':
    main()
             

C++

#include "c4d.h"
#include "../compositing/description/compositing3dtag.h"
void SampleFunction()
{
    BaseDocument *pDoc = GetActiveDocument();
    BaseObject *pObject = BaseObject::Alloc(Osphere);
    pDoc->InsertObject(pObject);
    pDoc->StartUndo();
    pDoc->AddUndo(UNDOTYPE_NEW,pObject);
    pDoc->EndUndo();
    pDoc->StartUndo();
    BaseTag *pTag = pObject->MakeTag(COMPOSITING3DTAG);
    pDoc->AddUndo(UNDOTYPE_NEW,pTag);
    pDoc->EndUndo();
    pObject->Message(MSG_UPDATE);
    
    //You can set parameters two different ways. 

    //First way              
    //Some objects do not store all their data in the container. You need to use GetParameter()/SetParameter() instead. 

    DESCFLAGS_SET flags = DESCFLAGS_SET_PARAM_SET;
    pTag->SetParameter(DescID(COMP3DTAG_CHILDREN),GeData(true),flags);
    pTag->SetParameter(DescID(COMP3DTAG_CACHE),GeData(true),flags);
    pTag->SetParameter(DescID(COMP3DTAG_MIDPOINT),GeData(COMP3DTAG_MIDTL),flags);
    pTag->SetParameter(DescID(COMP3DTAG_SOLID),GeData(true),flags);
    pTag->SetParameter(DescID(COMP3DTAG_SIZEX),GeData(1),flags);
    pTag->SetParameter(DescID(COMP3DTAG_SIZEY),GeData(1),flags);
    pTag->Message(MSG_UPDATE);            

    //Second way, using the base container.
    BaseContainer *bc =     pTag->GetDataInstance();
    bc->SetBool(COMP3DTAG_CHILDREN,true);
    bc->SetBool(COMP3DTAG_CACHE,true);
    bc->SetInt32(COMP3DTAG_MIDPOINT,COMP3DTAG_MIDTL);
    bc->SetBool(COMP3DTAG_SOLID,true);
    bc->SetInt32(COMP3DTAG_SIZEX,1);
    bc->SetInt32(COMP3DTAG_SIZEY,1);
    pTag->Message(MSG_UPDATE);                                                      
}