About
A TakeData object stores the take system related data of a BaseDocument.
Access
A TakeData object is returned by the host BaseDocument:
  
  
 
  if (takeData == nullptr)
Definition: lib_takesystem.h:589
 
#define MAXON_SOURCE_LOCATION
Definition: memoryallocationbase.h:67
 
const char * doc
Definition: pyerrors.h:226
 
  
Read-Only Properties
The TakeData object allows access to its parent document and to different settings of the Take Manager.
- Note
 - The take mode can be toggled with command 431000081. See Command Utility Manual.
 
Takes
Accessing Takes
Existing takes are accessed from the TakeData object:
  
  
 
  
  if (currentTake == nullptr)
 
  
  if (currentTake->
IsMain() == 
false)
 
  {
    
  }
Definition: lib_takesystem.h:335
 
Bool SetCurrentTake(BaseTake *take)
 
BaseTake * GetCurrentTake() const
 
  
Create Takes
The TakeData object creates and deletes takes:
  
 
  if (takeData == nullptr)
 
  BaseTake* 
const newTake = takeData->
AddTake(
"This is a new take", 
nullptr, 
nullptr);
 
  if (newTake == nullptr)
 
BaseTake * AddTake(const String &name, BaseTake *parent, BaseTake *cloneFrom)
 
  
Overrides
The TakeData object also provides access to the override backup for a given override and parameter:
  
  
  
 
  if (take == nullptr)
 
  
 
  
  if (baseOverride == nullptr)
 
 
  
  if (backup == nullptr)
 
 
  
 
  
Definition: lib_takesystem.h:79
 
void UpdateSceneNode(TakeData *takeData, const DescID &descID)
 
BaseOverride * FindOverride(TakeData *takeData, BaseList2D *node)
 
Bool SetParameter(const DescID &id, const GeData &t_data, DESCFLAGS_SET flags)
 
Bool GetParameter(const DescID &id, GeData &t_data, DESCFLAGS_GET flags) const
 
Definition: lib_description.h:355
 
Definition: c4d_gedata.h:83
 
BaseOverride * FindOverrideCounterPart(BaseOverride *overrideNode, const DescID &descID, BaseTake *&resultTake)
 
PyObject PyObject * result
Definition: abstract.h:43
 
return OK
Definition: apibase.h:2735
 
@ DTYPE_COLOR
Color.
Definition: lib_description.h:57
 
#define ConstDescID(...)
Definition: lib_description.h:594
 
@ MATERIAL_COLOR_COLOR
Definition: mmaterial.h:56
 
Represents a level within a DescID.
Definition: lib_description.h:298
 
  
Undo States
Several functions of the Take system like TakeData::AddTake() or TakeData::DeleteTake() create an undo step when used. This might not be necessary in some cases, so it is possible to disable the take system's undo state.
  
  
  
 
  
  if (takeTemplateDoc == nullptr)
 
  TakeData* 
const takeData = takeTemplateDoc->GetTakeData();
 
  if (takeData == nullptr)
 
  
 
  
  takeData->
AddTake(
"Take 1", 
nullptr, 
nullptr);
 
  takeData->
AddTake(
"Take 2", 
nullptr, 
nullptr);
 
 
  
Bool SaveDocument(BaseDocument *doc, const Filename &name, SAVEDOCUMENTFLAGS saveflags, Int32 format)
 
Definition: ge_autoptr.h:37
 
void SetUndoState(Bool state)
 
#define FORMAT_C4DEXPORT
Cinema 4D export.
Definition: ge_prepass.h:3535
 
  
Convert
With TakeData::TakeToDocument() it is possible to create a BaseDocument with the state of the selected take.
  
  
  
 
  while (childTake != nullptr)
  {
    
    if (takeDoc == nullptr)
 
    
    
 
    
 
    
 
  }
PyCompilerFlags const char * filename
Definition: ast.h:15
 
Definition: c4d_basedocument.h:497
 
static void Free(BaseDocument *&bl)
 
String GetName() const
Definition: c4d_baselist.h:2544
 
BaseTake * GetNext() const
Definition: lib_takesystem.h:353
 
BaseTake * GetDown() const
Definition: lib_takesystem.h:371
 
Manages file and path names.
Definition: c4d_file.h:94
 
Definition: c4d_string.h:41
 
BaseDocument * TakeToDocument(BaseTake *take)
 
const char const char const char * file
Definition: object.h:439
 
  
Disc I/O
With TakeData::SaveTakesWithAssets() it is possible to save all takes as a separate project.
  
 
  if (takeData == nullptr)
 
Bool SaveTakesWithAssets(Bool selected)
 
  
Further Reading