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 tmorphcam

tmorphcam

Attributes

  • ENGLISH NAME :
  • NAME : tmorphcam
  • INCLUDE : Texpression
  • PATH : motioncam/description/tmorphcam.res
  • PLUGIN : motioncam
  • MAXON online help (may not exist): TMORPHCAM

Elements

ID UI Name Type Parameters Cycle
TMORPHCAM_VISUALIZATION_POS ShowPosition BOOL  
TMORPHCAM_VISUALIZATION_ALIGN ShowAlignment BOOL  
TMORPHCAM_VISUALIZATION_NAMES ShowNames BOOL  
TMORPHCAM_VISUALIZATION_CAM_ENABLED UseCustomCameraColor BOOL  
TMORPHCAM_VISUALIZATION_CAM_COLOR CameraColor COLOR  
TMORPHCAM_BLEND Blend REAL
PARENTCOLLAPSE
UNIT PERCENT
STEP 0.1
MIN 0.0
MAX 100.0
CUSTOMGUI REALSLIDER
TMORPHCAM_BLEND_CURVE BlendCurve SPLINE PARENTCOLLAPSE
TMORPHCAM_INTERPOLATION MorphInterpolation LONG  
TMORPHCAM_INTERPOLATION_LINEAR Linear
TMORPHCAM_INTERPOLATION_CUBIC Soft1
TMORPHCAM_INTERPOLATION_AKIMA Soft2
TMORPHCAM_STEADY Stabilize BOOL  
TMORPHCAM_STEADY_LINK StabilizingObject LINK  
TMORPHCAM_LIST_MODE SourceMode LONG  
TMORPHCAM_LIST_MODE_SIMPLE SimpleMorph
TMORPHCAM_LIST_MODE_MULTI MultiMorph
TMORPHCAM_LIST_LINK_A SimpleMorph:Camera1 LINK  
TMORPHCAM_LIST_LINK_B SimpleMorph:Camera2 LINK  
TMORPHCAM_LIST_LINKS MultiMorph:List IN_EXCLUDE
OPEN
NUM_FLAGS 0
TMORPHCAM_TRACK_FOCALLENGTH MorphFocalLength BOOL  
TMORPHCAM_TRACK_APERTURE MorphSensorSize BOOL  
TMORPHCAM_TRACK_TARGETDIST MorphFocusDistance BOOL  
TMORPHCAM_TRACK_DOF MorphDepthofField BOOL  
TMORPHCAM_TRACK_WB MorphWhiteBalance BOOL  
TMORPHCAM_TRACK_STEREO MorphStereoParameters BOOL  
TMORPHCAM_TRACK_PHY_FNUMBER MorphF-Stop BOOL  
TMORPHCAM_TRACK_PHY_ISOGAIN MorphISO/Gain BOOL  
TMORPHCAM_TRACK_PHY_SHUTTER MorphShutter BOOL  
TMORPHCAM_TRACK_PHY_LENSDIST MorphLensDistortion BOOL  
TMORPHCAM_TRACK_PHY_VIGNETTE MorphVignetting BOOL  
TMORPHCAM_TRACK_PHY_ABERRATION MorphChromaticAberration BOOL  

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.tmorphcam)
    doc.InsertObject(obj)
    c4d.EventAdd(c4d.EVENT_FORCEREDRAW)
    
    #You can set parameters two different ways. 
    #First way              
    tag[c4d.TMORPHCAM_VISUALIZATION_POS] = True
    tag[c4d.TMORPHCAM_VISUALIZATION_ALIGN] = True
    tag[c4d.TMORPHCAM_VISUALIZATION_NAMES] = True
    tag[c4d.TMORPHCAM_VISUALIZATION_CAM_ENABLED] = True
    tag[c4d.TMORPHCAM_BLEND] = 0.1
    tag[c4d.TMORPHCAM_INTERPOLATION] = c4d.TMORPHCAM_INTERPOLATION_LINEAR
    tag[c4d.TMORPHCAM_STEADY] = True
    tag[c4d.TMORPHCAM_LIST_MODE] = c4d.TMORPHCAM_LIST_MODE_SIMPLE
    tag[c4d.TMORPHCAM_TRACK_FOCALLENGTH] = True
    tag[c4d.TMORPHCAM_TRACK_APERTURE] = True
    tag[c4d.TMORPHCAM_TRACK_TARGETDIST] = True
    tag[c4d.TMORPHCAM_TRACK_DOF] = True
    tag[c4d.TMORPHCAM_TRACK_WB] = True
    tag[c4d.TMORPHCAM_TRACK_STEREO] = True
    tag[c4d.TMORPHCAM_TRACK_PHY_FNUMBER] = True
    tag[c4d.TMORPHCAM_TRACK_PHY_ISOGAIN] = True
    tag[c4d.TMORPHCAM_TRACK_PHY_SHUTTER] = True
    tag[c4d.TMORPHCAM_TRACK_PHY_LENSDIST] = True
    tag[c4d.TMORPHCAM_TRACK_PHY_VIGNETTE] = True
    tag[c4d.TMORPHCAM_TRACK_PHY_ABERRATION] = True
    
    #Second way, using the base container.
    bc = tag.GetDataInstance()
    bc.SetBool(c4d.TMORPHCAM_VISUALIZATION_POS,True)
    bc.SetBool(c4d.TMORPHCAM_VISUALIZATION_ALIGN,True)
    bc.SetBool(c4d.TMORPHCAM_VISUALIZATION_NAMES,True)
    bc.SetBool(c4d.TMORPHCAM_VISUALIZATION_CAM_ENABLED,True)
    bc.SetFloat(c4d.TMORPHCAM_BLEND,0.1)
    bc.SetInt32(c4d.TMORPHCAM_INTERPOLATION,c4d.TMORPHCAM_INTERPOLATION_LINEAR)
    bc.SetBool(c4d.TMORPHCAM_STEADY,True)
    bc.SetInt32(c4d.TMORPHCAM_LIST_MODE,c4d.TMORPHCAM_LIST_MODE_SIMPLE)
    bc.SetBool(c4d.TMORPHCAM_TRACK_FOCALLENGTH,True)
    bc.SetBool(c4d.TMORPHCAM_TRACK_APERTURE,True)
    bc.SetBool(c4d.TMORPHCAM_TRACK_TARGETDIST,True)
    bc.SetBool(c4d.TMORPHCAM_TRACK_DOF,True)
    bc.SetBool(c4d.TMORPHCAM_TRACK_WB,True)
    bc.SetBool(c4d.TMORPHCAM_TRACK_STEREO,True)
    bc.SetBool(c4d.TMORPHCAM_TRACK_PHY_FNUMBER,True)
    bc.SetBool(c4d.TMORPHCAM_TRACK_PHY_ISOGAIN,True)
    bc.SetBool(c4d.TMORPHCAM_TRACK_PHY_SHUTTER,True)
    bc.SetBool(c4d.TMORPHCAM_TRACK_PHY_LENSDIST,True)
    bc.SetBool(c4d.TMORPHCAM_TRACK_PHY_VIGNETTE,True)
    bc.SetBool(c4d.TMORPHCAM_TRACK_PHY_ABERRATION,True)

if __name__=='__main__':
    main()
             

C++

#include "c4d.h"
#include "../motioncam/description/tmorphcam.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(tmorphcam);
    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(TMORPHCAM_VISUALIZATION_POS),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_VISUALIZATION_ALIGN),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_VISUALIZATION_NAMES),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_VISUALIZATION_CAM_ENABLED),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_BLEND),GeData(0.1),flags);
    pTag->SetParameter(DescID(TMORPHCAM_INTERPOLATION),GeData(TMORPHCAM_INTERPOLATION_LINEAR),flags);
    pTag->SetParameter(DescID(TMORPHCAM_STEADY),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_LIST_MODE),GeData(TMORPHCAM_LIST_MODE_SIMPLE),flags);
    pTag->SetParameter(DescID(TMORPHCAM_TRACK_FOCALLENGTH),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_TRACK_APERTURE),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_TRACK_TARGETDIST),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_TRACK_DOF),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_TRACK_WB),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_TRACK_STEREO),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_TRACK_PHY_FNUMBER),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_TRACK_PHY_ISOGAIN),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_TRACK_PHY_SHUTTER),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_TRACK_PHY_LENSDIST),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_TRACK_PHY_VIGNETTE),GeData(true),flags);
    pTag->SetParameter(DescID(TMORPHCAM_TRACK_PHY_ABERRATION),GeData(true),flags);
    pTag->Message(MSG_UPDATE);            

    //Second way, using the base container.
    BaseContainer *bc =     pTag->GetDataInstance();
    bc->SetBool(TMORPHCAM_VISUALIZATION_POS,true);
    bc->SetBool(TMORPHCAM_VISUALIZATION_ALIGN,true);
    bc->SetBool(TMORPHCAM_VISUALIZATION_NAMES,true);
    bc->SetBool(TMORPHCAM_VISUALIZATION_CAM_ENABLED,true);
    bc->SetFloat(TMORPHCAM_BLEND,0.1);
    bc->SetInt32(TMORPHCAM_INTERPOLATION,TMORPHCAM_INTERPOLATION_LINEAR);
    bc->SetBool(TMORPHCAM_STEADY,true);
    bc->SetInt32(TMORPHCAM_LIST_MODE,TMORPHCAM_LIST_MODE_SIMPLE);
    bc->SetBool(TMORPHCAM_TRACK_FOCALLENGTH,true);
    bc->SetBool(TMORPHCAM_TRACK_APERTURE,true);
    bc->SetBool(TMORPHCAM_TRACK_TARGETDIST,true);
    bc->SetBool(TMORPHCAM_TRACK_DOF,true);
    bc->SetBool(TMORPHCAM_TRACK_WB,true);
    bc->SetBool(TMORPHCAM_TRACK_STEREO,true);
    bc->SetBool(TMORPHCAM_TRACK_PHY_FNUMBER,true);
    bc->SetBool(TMORPHCAM_TRACK_PHY_ISOGAIN,true);
    bc->SetBool(TMORPHCAM_TRACK_PHY_SHUTTER,true);
    bc->SetBool(TMORPHCAM_TRACK_PHY_LENSDIST,true);
    bc->SetBool(TMORPHCAM_TRACK_PHY_VIGNETTE,true);
    bc->SetBool(TMORPHCAM_TRACK_PHY_ABERRATION,true);
    pTag->Message(MSG_UPDATE);                                                      
}