|
|
|
Tell us what you think of the site.
|
Autodesk Media & Entertainment User Community
|
Autodesk® 3ds Max®
|
|
Autodesk® Maya®
|
|
Autodesk® Softimage®
|
|
Autodesk® MotionBuilder®
|
|
Autodesk® Mudbox™
|
|
Autodesk® ImageModeler™
|
|
Autodesk® Sketchbook® Pro
|
|
Autodesk® Smoke on Mac®
|
|
Hi!
I am trying to read layers data from fbx file (imported from .max), that are in Tools -> Manage Layers window (in 3ds max design 2012). Unfortunately, non KFbxNodes, KFbxMeshes doesn’t have any methods, that contains needed information. And I can’t find any global objects, that contains needed info. Where can i find global list of layers, and link from mesh to layer?
|
|
|
|
Hi, Ultrablox, I am not 100% sure about your question.
But I think you are looking for where layer info is stored in FBX.
It is called DisplayLayer in FBX, and the link from mesh to the layer is described by connections between the KFbxMesh and the KFbxDisplayLayer.
I attached an ascii FBX file exported from 3ds Max, it has two layers,and each layer contain some mesh.
Jiayang Xu
Maya Data Platform
Autodesk
|
|
|
|
Thank you for reply, i discovered 2 ways:
1.
Get layer with
for(int i = 0; i < pScene->GetMemberCount(KFbxCriteria::ObjectType(KFbxDisplayLayer::ClassId)); i++)
{
KFbxDisplayLayer * l = (KFbxDisplayLayer*)pScene->GetMember(KFbxCriteria::ObjectType(KFbxDisplayLayer::ClassId), i);
for(int j = 0; j < l->GetMemberCount(); j++)
{
KFbxObject * node = l->GetMember(j);
}
}
and node is attached to layer.
2. Really throughout the connection:
KFbxDisplayLayer * fbxLayer = (KFbxDisplayLayer*)(node->GetDstObject(KFbxCriteria::ObjectType(KFbxDisplayLayer::ClassId), 0));
|
|
|
|
|
|