About
The CAPoseMorphTag class represents a pose morph tag. Such a tag stores multiple morphs that can be applied to the host object (and it's child objects) to modify and animate it. The class is defined in the lib_ca.h
header file.
CAPoseMorphTag objects are an instance of Tposemorph.
if (cube == nullptr)
doc->InsertObject(cube,
nullptr,
nullptr);
if (poseMorphTag == nullptr)
if (baseMorph == nullptr)
if (morph == nullptr)
Definition: c4d_baseobject.h:248
static BaseObject * Alloc(Int32 type)
void InsertTag(BaseTag *tp, BaseTag *pred=nullptr)
Bool SetParameter(const DescID &id, const GeData &t_data, DESCFLAGS_SET flags)
Definition: lib_ca.h:1475
Bool Store(BaseDocument *doc, CAPoseMorphTag *tag, CAMORPH_DATA_FLAGS flags)
void SetName(const String &name)
Definition: lib_ca.h:1670
Bool ExitEdit(BaseDocument *doc, Bool noapply)
DescID GetMorphID(Int32 index) const
void UpdateMorphs(BaseDocument *doc=nullptr)
static CAPoseMorphTag * Alloc()
Definition: lib_ca.h:1683
Definition: lib_description.h:355
maxon::Vec3< maxon::Float64, 1 > Vector
Definition: ge_math.h:145
#define Ocube
Cube.
Definition: ge_prepass.h:1110
#define MAXON_SOURCE_LOCATION
Definition: memoryallocationbase.h:67
#define ConstDescID(...)
Definition: lib_description.h:594
@ PRIM_CUBE_LEN
Definition: ocube.h:6
const char * doc
Definition: pyerrors.h:226
Represents a level within a DescID.
Definition: lib_description.h:298
@ ID_CA_POSE_MODE
Definition: tcaposemorph.h:18
@ ID_CA_POSE_PARAM
Definition: tcaposemorph.h:30
@ ID_CA_POSE_MODE_ANIMATE
Definition: tcaposemorph.h:87
Access
A CAPoseMorphTag tag can be accessed like any other tag, see BaseTag and VariableTag Manual.
{
if (morph != nullptr)
{
}
}
Py_ssize_t i
Definition: abstract.h:645
Definition: c4d_basetag.h:50
Bool IsInstanceOf(Int32 id) const
Definition: c4d_baselist.h:1437
Int32 GetMorphCount() const
const CAMorph * GetMorph(Int32 index) const
maxon::Int32 Int32
Definition: ge_sys_math.h:60
#define ApplicationOutput(formatString,...)
Definition: debugdiagnostics.h:210
#define Tposemorph
Pose morph.
Definition: ge_prepass.h:1442
Allocation/Deallocation
CAPoseMorphTag instances are created with the usual tools, see Entity Creation and Destruction Manual (Classic).
if (poseMorphTag == nullptr)
polyObject->InsertTag(poseMorphTag);
After creation, the tag must be initialized.
Properties
The parameters of CAPoseMorphTag can be edited with C4DAtom::SetParameter() and C4DAtom::GetParameter(). The parameter IDs are defined in tcaposemorph.h
.
- Note
- Several settings of the active morph must be set on the morph tag using C4DAtom::SetParameter().
if (morph == nullptr)
void SetActiveMorphIndex(Int32 index)
Int32 GetMorphIndex(const CAMorph *morph) const
Py_ssize_t * index
Definition: abstract.h:374
@ ID_CA_POSE_POINTS
Definition: tcaposemorph.h:34
@ ID_CA_POSE_MIXING_DEFORMED
Definition: tcaposemorph.h:42
Morphs
Any change to the morph data must be encompassed by the following functions:
The stored morphs are accessed with:
See also CAMorph Manual.
{
if (morph == nullptr)
{
}
}
Bool GetParameter(const DescID &id, GeData &t_data, DESCFLAGS_GET flags) const
Definition: c4d_gedata.h:83
Float GetFloat() const
Definition: c4d_gedata.h:468
static String FloatToString(Float32 v, Int32 vvk=-1, Int32 nnk=-3)
Definition: c4d_string.h:529
maxon::Float Float
Definition: ge_sys_math.h:66
void RemoveMorph(Int32 index)
Int32 GetActiveMorphIndex() const
PSD
Several Pose Space Deformation related settings can be edited with these functions:
See also CAReferencePSD Manual.
if (poseMorphTag)
{
}
Bool SetPSDFeedbackColorEnabled(Bool active)
Bool SetPSDFeedbackColor(const Vector &color)
Mode
A CAPoseMorphTag can either be in "edit" or "animate" mode:
- Note
- To change the mode use C4DAtom::SetParameter() with DescID ID_CA_POSE_MODE.
Further Reading