About
A CAMorphNode object stores the actual morph data for a corresponding BaseList2D object. It is stored in a CAPoseMorphTag, see CAPoseMorphTag Manual. The class is defined in the lib_ca.h
header file.
Access
A CAMorphNode object is obtained from the host CAMorph. See CAMorph Manual.
poseMorphTag->ExitEdit(doc, false);
const Int32 activeIndex = poseMorphTag->GetActiveMorphIndex();
CAMorph*
const morph = poseMorphTag->GetMorph(activeIndex);
if (morph == nullptr)
if (mnode == nullptr)
{
for (
Int32 i = 0; i < pointCount; ++i)
{
}
}
poseMorphTag->UpdateMorphs();
Navigation
A CAMorphNode stores the data of the corresponding BaseList2D object. In "Hierarchy" mode of the host CAPoseMorphTag a CAMorph stores multiple CAMorphNode objects for all corresponding objects in the object tree.
{
while (mnode != nullptr)
{
if (link != nullptr)
{
}
CheckMorphNode(mnode->
GetDown(), tag, morph, doc);
}
}
Data
Info
A CAMorphNode stores morph data of a corresponding BaseList2D object.
PSR
A CAMorphNode object can store PSR data:
Points
A CAMorphNode object can store point data:
{
for (
Int32 i = 0; i < pointCount; ++i)
{
point.
x += random.
Get01() * 10.0;
point.
y += random.
Get01() * 10.0;
point.
z += random.
Get01() * 10.0;
}
}
For point mode additional Pose Space Deformation data is stored:
See CAReferencePSD Manual.
{
if (psd)
{
for (
Int32 controllerIndex = 0; controllerIndex < controllerCount; ++controllerIndex)
{
if (controller == nullptr)
}
}
}
Tangents
A CAMorphNode object can store tangent data for spline points:
- Note
- For each spline point two tangent vectors are stored.
{
for (
Int32 i = 0; i < tangentCount; ++i)
{
}
}
Vertex Map
A CAMorphNode object can store vertex map data for all vertex map tags of the host object.
{
for (
Int32 tagIndex = 0; tagIndex < vertexMapCount; ++tagIndex)
{
for (
Int32 vertexIndex = 0; vertexIndex < vertexCount; ++vertexIndex)
{
}
}
}
Parameters
A CAMorphNode object can store data for various object parameters.
UV Sets
A CAMorphNode object can store UVW data for all UVW tags of the host object. See also UVWTag Manual.
{
for (
Int32 tagIndex = 0; tagIndex < uvTagCount; ++tagIndex)
{
for (
Int32 uvIndex = 0; uvIndex < uvCount; ++uvIndex)
{
mnode->
GetUV(tagIndex, uvIndex, uvw);
}
}
}
Weight Maps
A CAMorphNode object can store weight data for all weight tags of the host object. See also CAWeightTag Manual.
{
for (
Int32 tagIndex = 0; tagIndex < weightTagCount; ++tagIndex)
{
for (
Int32 jointIndex = 0; jointIndex < jointCount; ++jointIndex)
{
for (
Int32 weightIndex = 0; weightIndex < weightCount; ++weightIndex)
{
}
}
}
}
Further Reading