From f8f416cd3ce317b45c0ad2536e756192a17ea5f0 Mon Sep 17 00:00:00 2001 From: lvlong Date: Sat, 16 Aug 2014 11:12:26 +0800 Subject: [PATCH 1/2] merge bundle --- cocos/3d/CCBundle3D.cpp | 285 ++++++++++++++++++++++++++++++++++------ cocos/3d/CCBundle3D.h | 22 +++- 2 files changed, 269 insertions(+), 38 deletions(-) diff --git a/cocos/3d/CCBundle3D.cpp b/cocos/3d/CCBundle3D.cpp index ed65f00e04..0fc72fd6df 100644 --- a/cocos/3d/CCBundle3D.cpp +++ b/cocos/3d/CCBundle3D.cpp @@ -48,9 +48,6 @@ static const char* VERSION = "version"; static const char* ID = "id"; -static const char* MESHDATA_MESH = "mesh"; -static const char* MESHDATA_MESHES = "meshes"; -static const char* MESHDATA_PARTS ="parts"; static const char* MESHDATA_DEFAULTPART = "body"; static const char* MESHDATA_VERTEXSIZE = "vertexsize"; static const char* MESHDATA_VERTEX = "vertex"; @@ -64,11 +61,20 @@ static const char* MESHDATA_TYPE = "type"; static const char* MESHDATA_ATTRIBUTE = "attribute"; static const char* SKINDATA_SKIN = "skin"; -static const char* SKINDATA_BONES = "bones"; -static const char* SKINDATA_NODE = "node"; static const char* SKINDATA_BINDSHAPE = "bindshape"; -static const char* SKINDATA_CHILDREN = "children"; -static const char* SKINDATA_TRANSFORM = "tansform"; + +static const char* MESH = "mesh"; +static const char* MESHES = "meshes"; +static const char* MESHPARTID = "meshpartid"; +static const char* MATERIALID = "materialid"; +static const char* NODE = "node"; +static const char* NODES = "nodes"; +static const char* CHILDREN = "children"; +static const char* PARTS = "parts"; +static const char* BONES = "bones"; +static const char* MATERIALS = "materials"; +static const char* ANIMATIONS = "animations"; +static const char* TRANSFORM = "transform"; static const char* MATERIALDATA_MATERIAL = "material"; static const char* MATERIALDATA_MATERIALS = "materials"; @@ -78,7 +84,6 @@ static const char* MATERIALDATA_TEXTURES = "textures"; static const char* ANIMATIONDATA_ANIMATION = "animation"; static const char* ANIMATIONDATA_LENGTH = "length"; -static const char* ANIMATIONDATA_BONES = "bones"; static const char* ANIMATIONDATA_BONEID = "boneId"; static const char* ANIMATIONDATA_KEYFRAMES = "keyframes"; static const char* ANIMATIONDATA_TRANSLATION = "translation"; @@ -95,7 +100,7 @@ void getChildMap(std::map >& map, SkinData* skinData, cons // get transform matrix Mat4 transform; - const rapidjson::Value& parent_tranform = val[SKINDATA_TRANSFORM]; + const rapidjson::Value& parent_tranform = val[TRANSFORM]; for (rapidjson::SizeType j = 0; j < parent_tranform.Size(); j++) { transform.m[j] = parent_tranform[j].GetDouble(); @@ -119,10 +124,10 @@ void getChildMap(std::map >& map, SkinData* skinData, cons if(skinData->rootBoneIndex < 0) skinData->rootBoneIndex = parent_name_index; - if (!val.HasMember(SKINDATA_CHILDREN)) + if (!val.HasMember(CHILDREN)) return; - const rapidjson::Value& children = val[SKINDATA_CHILDREN]; + const rapidjson::Value& children = val[CHILDREN]; for (rapidjson::SizeType i = 0; i < children.Size(); i++) { // get child bone name @@ -291,7 +296,7 @@ bool Bundle3D::loadMeshDatasBinary(MeshDatas& meshdatas) } bool Bundle3D::loadMeshDatasJson(MeshDatas& meshdatas) { - const rapidjson::Value& mesh_data_array = _jsonReader[MESHDATA_MESHES]; + const rapidjson::Value& mesh_data_array = _jsonReader[MESHES]; for (rapidjson::SizeType index = 0; index < mesh_data_array.Size(); index++) { MeshData* meshData = new MeshData(); @@ -325,7 +330,7 @@ bool Bundle3D::loadMeshDatasJson(MeshDatas& meshdatas) } // mesh part //////////////////////////////////////////////////////////////////////////////////////////////// - const rapidjson::Value& mesh_part_array = mesh_data[MESHDATA_PARTS]; + const rapidjson::Value& mesh_part_array = mesh_data[PARTS]; for (rapidjson::SizeType i = 0; i < mesh_part_array.Size(); i++) { std::vector indexArray; @@ -341,10 +346,19 @@ bool Bundle3D::loadMeshDatasJson(MeshDatas& meshdatas) } meshdatas.meshDatas.push_back(meshData); } - return true; + return true; } bool Bundle3D::loadNodes(NodeDatas& nodedatas) { + if (_isBinary) + { + // TODO + return false; + } + else + { + return loadNodesJson(nodedatas); + } return true; } @@ -361,7 +375,7 @@ bool Bundle3D::loadMaterials(MaterialDatas& materialdatas) } return true; } -bool Bundle3D::loadMaterialsBinary(MaterialDatas& materialdatas) +bool Bundle3D::loadMaterialsBinary(MaterialDatas& materialdatas) { return true; } @@ -385,7 +399,7 @@ bool Bundle3D::loadMaterialsJson(MaterialDatas& materialdatas) // NTextureData textureData; // const rapidjson::Value& texture_val = testure_array[j]; // std::string filename = texture_val[MATERIALDATA_FILENAME].GetString(); -// textureData.filename = _modelRelativePath + filename; +// textureData.filename = _modelPath + filename; // textureData.wrapS = parseGLType(texture_val["wrapModeU"].GetString()); // textureData.wrapT = parseGLType(texture_val["wrapModeV"].GetString()); // materialData.textures.push_back(textureData); @@ -438,7 +452,7 @@ bool Bundle3D::loadMeshDataJson(MeshData* meshdata) bool Bundle3D::loadMeshDataJson_0_1(MeshData* meshdata) { - const rapidjson::Value& mesh_data_array = _jsonReader[MESHDATA_MESH]; + const rapidjson::Value& mesh_data_array = _jsonReader[MESH]; const rapidjson::Value& mesh_data_val = mesh_data_array[(rapidjson::SizeType)0]; @@ -486,7 +500,7 @@ bool Bundle3D::loadMeshDataJson_0_1(MeshData* meshdata) bool Bundle3D::loadMeshDataJson_0_2(MeshData* meshdata) { - const rapidjson::Value& mesh_array = _jsonReader[MESHDATA_MESH]; + const rapidjson::Value& mesh_array = _jsonReader[MESH]; const rapidjson::Value& mesh_array_0 = mesh_array[(rapidjson::SizeType)0]; @@ -547,14 +561,14 @@ bool Bundle3D::loadSkinDataJson(SkinData* skindata) assert(skin_data_array.IsArray()); const rapidjson::Value& skin_data_array_val_0 = skin_data_array[(rapidjson::SizeType)0]; - if (!skin_data_array_val_0.HasMember(SKINDATA_BONES)) + if (!skin_data_array_val_0.HasMember(BONES)) return false; - const rapidjson::Value& skin_data_bones = skin_data_array_val_0[SKINDATA_BONES]; + const rapidjson::Value& skin_data_bones = skin_data_array_val_0[BONES]; for (rapidjson::SizeType i = 0; i < skin_data_bones.Size(); i++) { const rapidjson::Value& skin_data_bone = skin_data_bones[i]; - std::string name = skin_data_bone[SKINDATA_NODE].GetString(); + std::string name = skin_data_bone[NODE].GetString(); skindata->addSkinBoneNames(name); Mat4 mat_bind_pos; @@ -607,7 +621,7 @@ bool Bundle3D::loadMaterialDataJson_0_1(MaterialData* materialdata) const rapidjson::Value& material_data_base_array_0 = material_data_base_array[(rapidjson::SizeType)0]; // set texture - materialdata->texturePaths[0] =_modelRelativePath + material_data_base_array_0[MATERIALDATA_FILENAME].GetString(); + materialdata->texturePaths[0] = _modelPath + material_data_base_array_0[MATERIALDATA_FILENAME].GetString(); return true; } @@ -625,7 +639,7 @@ bool Bundle3D::loadMaterialDataJson_0_2(MaterialData* materialdata) //std::string id = material_val[ID].GetString(); // set texture - materialdata->texturePaths[i] = _modelRelativePath + material_val[MATERIALDATA_TEXTURES].GetString(); + materialdata->texturePaths[i] = _modelPath + material_val[MATERIALDATA_TEXTURES].GetString(); } return true; @@ -642,7 +656,7 @@ bool Bundle3D::loadAnimationDataJson(Animation3DData* animationdata) animationdata->_totalTime = animation_data_array_val_0[ANIMATIONDATA_LENGTH].GetDouble(); - const rapidjson::Value& bones = animation_data_array_val_0[ANIMATIONDATA_BONES]; + const rapidjson::Value& bones = animation_data_array_val_0[BONES]; for (rapidjson::SizeType i = 0; i < bones.Size(); i++) { const rapidjson::Value& bone = bones[i]; @@ -1034,7 +1048,7 @@ bool Bundle3D::loadMaterialDataBinary(MaterialData* materialdata) return false; } - std::string path = _modelRelativePath + texturePath; + std::string path = _modelPath + texturePath; materialdata->texturePaths[i] = path; } @@ -1108,6 +1122,213 @@ bool Bundle3D::loadAnimationDataBinary(Animation3DData* animationdata) return true; } +bool Bundle3D::loadNodesJson(NodeDatas& nodedatas) +{ + if (!_jsonReader.HasMember(NODES)) return false; + const rapidjson::Value& nodes = _jsonReader[NODES]; + if(!nodes.IsArray()) return false; + + loadBoneNamesJson(nodes); + + for (rapidjson::SizeType i = 0; i < nodes.Size(); i++) + { + const rapidjson::Value& jnode = nodes[i]; + std::string id = jnode[ID].GetString(); + NodeData* nodedata = parseNodesRecursivelyJson(jnode); + + bool isSkeleton; + isSkeleton = checkIsSkeletonJson(jnode); + + if (isSkeleton) + nodedatas.skeleton.push_back(nodedata); + else + nodedatas.nodes.push_back(nodedata); + } + + return true; +} + +void Bundle3D::loadBoneNamesJson(const rapidjson::Value& jnodes) +{ + for (rapidjson::SizeType i = 0; i < jnodes.Size(); i++) + { + parseBoneNameRecursivelyJson(jnodes[i]); + } +} + +void Bundle3D::parseBoneNameRecursivelyJson(const rapidjson::Value& jnode) +{ + std::string id = jnode[ID].GetString(); + if (jnode.HasMember(PARTS)) + { + const rapidjson::Value& parts = jnode[PARTS]; + + for (rapidjson::SizeType i = 0; i < parts.Size(); i++) + { + const rapidjson::Value& part = parts[i]; + + if (part.HasMember(BONES)) + { + const rapidjson::Value& bones = part[BONES]; + + for (rapidjson::SizeType j = 0; j < bones.Size(); j++) + { + const rapidjson::Value& bone = bones[j]; + std::string bonename = bone[NODE].GetString(); + + if (!checkIsBone(bonename)) + { + _bonenames.push_back(bonename); + } + } + } + } + } + + if (jnode.HasMember(CHILDREN)) + { + const rapidjson::Value& children = jnode[CHILDREN]; + + for (rapidjson::SizeType i = 0; i < children.Size(); i++) + { + parseBoneNameRecursivelyJson(children[i]); + } + } +} + +bool Bundle3D::checkIsBone(const std::string& name) +{ + std::list::iterator iter = std::find(_bonenames.begin(), _bonenames.end(), name); + bool ret = (iter != _bonenames.end()) ? true : false; + return ret; +} + +bool Bundle3D::checkIsSkeletonJson(const rapidjson::Value& jnode) +{ + bool ret = false; + if (jnode.HasMember(CHILDREN)) + { + const rapidjson::Value& children = jnode[CHILDREN]; + for (rapidjson::SizeType i = 0; i < children.Size(); i++) + { + ret = checkIsSkeletonRecursivelyJson(children[i]); + if (ret) break; + } + } + else + { + ret = checkIsSkeletonRecursivelyJson(jnode); + } + + return ret; +} + +bool Bundle3D::checkIsSkeletonRecursivelyJson(const rapidjson::Value& jnode) +{ + std::string id = jnode[ID].GetString(); + if (checkIsBone(id)) + return true; + + if (jnode.HasMember(CHILDREN)) + { + const rapidjson::Value& children = jnode[CHILDREN]; + + for (rapidjson::SizeType i = 0; i < children.Size(); i++) + { + checkIsSkeletonRecursivelyJson(children[i]); + } + } + + return false; +} + +NodeData* Bundle3D::parseNodesRecursivelyJson(const rapidjson::Value& jvalue) +{ + NodeData* nodedata; + if (jvalue.HasMember(PARTS)) + nodedata = new ModelNodeData(); + else + nodedata = new NodeData(); + + // id + nodedata->id = jvalue[ID].GetString(); + + // transform + Mat4 tranform; + const rapidjson::Value& jtransform = jvalue[TRANSFORM]; + + for (rapidjson::SizeType j = 0; j < jtransform.Size(); j++) + { + tranform.m[j] = jtransform[j].GetDouble(); + } + + nodedata->transform = tranform; + + // parts + if (jvalue.HasMember(PARTS)) + { + const rapidjson::Value& parts = jvalue[PARTS]; + ModelNodeData* modelnodedata = dynamic_cast(nodedata); + + for (rapidjson::SizeType i = 0; i < parts.Size(); i++) + { + const rapidjson::Value& part = parts[i]; + std::string meshPartId = part[MESHPARTID].GetString(); + std::string materialId = part[MATERIALID].GetString(); + + if (meshPartId == "" || materialId == "") + { + std::string err = "Node " + nodedata->id + " part is missing meshPartId or materialId"; + CCASSERT(false, err.c_str()); + return nullptr; + } + + if (part.HasMember(BONES)) + { + const rapidjson::Value& bones = part[BONES]; + + for (rapidjson::SizeType j = 0; j < bones.Size(); j++) + { + const rapidjson::Value& bone = bones[i]; + + // node + if (!bone.HasMember(NODE)) + { + CCASSERT(false, "Bone node ID missing"); + return nullptr; + } + + modelnodedata->bones.push_back(bone[NODE].GetString()); + + Mat4 invbindpos; + const rapidjson::Value& jtransform = jvalue[TRANSFORM]; + + for (rapidjson::SizeType j = 0; j < jtransform.Size(); j++) + { + invbindpos.m[j] = jtransform[j].GetDouble(); + } + + modelnodedata->invBindPose.push_back(invbindpos); + } + } + } + } + + if (jvalue.HasMember(CHILDREN)) + { + const rapidjson::Value& children = jvalue[CHILDREN]; + for (rapidjson::SizeType i = 0; i < children.Size(); i++) + { + const rapidjson::Value& child = children[i]; + + NodeData* tempdata = parseNodesRecursivelyJson(child); + nodedata->children.push_back(tempdata); + } + } + + return nodedata; +} + GLenum Bundle3D::parseGLType(const std::string& str) { if (str == "GL_BYTE") @@ -1182,17 +1403,7 @@ void Bundle3D::getModelRelativePath(const std::string& path) { ssize_t index = path.find_last_of('/'); std::string fullModelPath; - fullModelPath = path.substr(0, index + 1); - - auto list = FileUtils::getInstance()->getSearchPaths(); - for( const auto &item : list ) - { - if ( fullModelPath.find(item) != std::string::npos ) - { - _modelRelativePath = fullModelPath.substr(item.length(), fullModelPath.length() + 1); - break; - } - } + _modelPath = path.substr(0, index + 1); } Reference* Bundle3D::seekToFirstType(unsigned int type) @@ -1217,7 +1428,7 @@ Reference* Bundle3D::seekToFirstType(unsigned int type) Bundle3D::Bundle3D() :_isBinary(false), -_modelRelativePath(""), +_modelPath(""), _path(""), _version(""), _jsonBuffer(nullptr), diff --git a/cocos/3d/CCBundle3D.h b/cocos/3d/CCBundle3D.h index c89a37e925..3e0fc00913 100644 --- a/cocos/3d/CCBundle3D.h +++ b/cocos/3d/CCBundle3D.h @@ -26,6 +26,7 @@ #define __CCBUNDLE3D_H__ #include +#include #include "3d/CCBundle3DData.h" @@ -153,6 +154,23 @@ protected: */ bool loadAnimationDataBinary(Animation3DData* animationdata); + bool checkIsBone(const std::string& name); + + /** + * load nodes of json + */ + bool loadNodesJson(NodeDatas& nodedatas); + void loadBoneNamesJson(const rapidjson::Value& jnodes); + void parseBoneNameRecursivelyJson(const rapidjson::Value& jnode); + bool checkIsSkeletonJson(const rapidjson::Value& jnode); + bool checkIsSkeletonRecursivelyJson(const rapidjson::Value& jnode); + NodeData* parseNodesRecursivelyJson(const rapidjson::Value& jvalue); + + /** + * load nodes of Binary + */ + + /** * get define data type * @param str The type in string @@ -186,7 +204,7 @@ protected: static Bundle3D* _instance; - std::string _modelRelativePath; + std::string _modelPath; std::string _path; std::string _version;// the c3b or c3t version @@ -202,6 +220,8 @@ protected: Reference* _references; bool _isBinary; + + std::list _bonenames; }; NS_CC_END From d60a7734b164dffdf5b10bd2cd37cc584681e9ae Mon Sep 17 00:00:00 2001 From: lvlong Date: Sat, 16 Aug 2014 14:28:15 +0800 Subject: [PATCH 2/2] merge bundle. --- cocos/3d/CCBundle3D.cpp | 168 ++++++++++++++++++++++++++++++---------- cocos/3d/CCBundle3D.h | 10 ++- 2 files changed, 131 insertions(+), 47 deletions(-) diff --git a/cocos/3d/CCBundle3D.cpp b/cocos/3d/CCBundle3D.cpp index 0fc72fd6df..05b241c9ce 100644 --- a/cocos/3d/CCBundle3D.cpp +++ b/cocos/3d/CCBundle3D.cpp @@ -1130,16 +1130,18 @@ bool Bundle3D::loadNodesJson(NodeDatas& nodedatas) loadBoneNamesJson(nodes); + // traverse the nodes again for (rapidjson::SizeType i = 0; i < nodes.Size(); i++) { + _skeleton = false; const rapidjson::Value& jnode = nodes[i]; std::string id = jnode[ID].GetString(); NodeData* nodedata = parseNodesRecursivelyJson(jnode); - bool isSkeleton; - isSkeleton = checkIsSkeletonJson(jnode); + //bool isSkeleton; + //isSkeleton = checkIsSkeletonJson(jnode); - if (isSkeleton) + if (_skeleton) nodedatas.skeleton.push_back(nodedata); else nodedatas.nodes.push_back(nodedata); @@ -1203,45 +1205,6 @@ bool Bundle3D::checkIsBone(const std::string& name) return ret; } -bool Bundle3D::checkIsSkeletonJson(const rapidjson::Value& jnode) -{ - bool ret = false; - if (jnode.HasMember(CHILDREN)) - { - const rapidjson::Value& children = jnode[CHILDREN]; - for (rapidjson::SizeType i = 0; i < children.Size(); i++) - { - ret = checkIsSkeletonRecursivelyJson(children[i]); - if (ret) break; - } - } - else - { - ret = checkIsSkeletonRecursivelyJson(jnode); - } - - return ret; -} - -bool Bundle3D::checkIsSkeletonRecursivelyJson(const rapidjson::Value& jnode) -{ - std::string id = jnode[ID].GetString(); - if (checkIsBone(id)) - return true; - - if (jnode.HasMember(CHILDREN)) - { - const rapidjson::Value& children = jnode[CHILDREN]; - - for (rapidjson::SizeType i = 0; i < children.Size(); i++) - { - checkIsSkeletonRecursivelyJson(children[i]); - } - } - - return false; -} - NodeData* Bundle3D::parseNodesRecursivelyJson(const rapidjson::Value& jvalue) { NodeData* nodedata; @@ -1253,6 +1216,10 @@ NodeData* Bundle3D::parseNodesRecursivelyJson(const rapidjson::Value& jvalue) // id nodedata->id = jvalue[ID].GetString(); + // check is skeleton + if (checkIsBone(nodedata->id)) + _skeleton = true; + // transform Mat4 tranform; const rapidjson::Value& jtransform = jvalue[TRANSFORM]; @@ -1329,6 +1296,120 @@ NodeData* Bundle3D::parseNodesRecursivelyJson(const rapidjson::Value& jvalue) return nodedata; } +bool Bundle3D::loadNodesBinary(NodeDatas& nodedatas) +{ + if (!seekToFirstType(BUNDLE_TYPE_NODE)) + return false; + + loadBoneNamesBinary(); + + if (!seekToFirstType(BUNDLE_TYPE_NODE)) + return false; + + unsigned int nodeSize = 0; + if (_binaryReader.read(&nodeSize, 4, 1) != 1) + { + CCLOGINFO("Failed to read nodes: size '%s'.", _path.c_str()); + return false; + } + + // traverse the nodes again + for (rapidjson::SizeType i = 0; i < nodeSize; i++) + { + std::string id = _binaryReader.readString(); + NodeData* nodedata = parseNodesRecursivelyBinary(); + + if (_skeleton) + nodedatas.skeleton.push_back(nodedata); + else + nodedatas.nodes.push_back(nodedata); + } + return true; +} + +void Bundle3D::loadBoneNamesBinary() +{ + unsigned int nodeSize=0; + if (_binaryReader.read(&nodeSize, 4, 1) != 1) + { + CCLOGINFO("Failed to read nodes: size '%s'.", _path.c_str()); + return; + } + + for (unsigned int i = 0; i < nodeSize; i++) + { + parseBoneNameRecursivelyBinary(); + } +} + +void Bundle3D::parseBoneNameRecursivelyBinary() +{ + std::string id = _binaryReader.readString(); + + Mat4 nodeMat; + if (!_binaryReader.readMatrix(nodeMat.m)) + return; + + // read pass + unsigned int partsSize=0; + if (_binaryReader.read(&partsSize, 4, 1) != 1) + { + CCASSERT("Failed to read part size: '%s'.", _path.c_str()); + return; + } + + if (partsSize > 0) + { + for (unsigned i = 0; i < partsSize; i++) + { + unsigned int boneSize=0; + if (_binaryReader.read(&boneSize, 4, 1) != 1) + { + CCASSERT("Failed to read bone: size '%s'.", _path.c_str()); + return; + } + + if (boneSize > 0) + { + for (unsigned j = 0; j < boneSize; j++) + { + std::string bonename = _binaryReader.readString(); + + Mat4 boneMat; + if (!_binaryReader.readMatrix(boneMat.m)) + return; + + if (!checkIsBone(bonename)) + { + _bonenames.push_back(bonename); + } + } + } + } + } + + // read children + unsigned int childrenSize = 0; + if (_binaryReader.read(&childrenSize, 4, 1) != 1) + { + CCASSERT("Failed to read children size: '%s'.", _path.c_str()); + return; + } + + if (childrenSize > 0) + { + for (rapidjson::SizeType i = 0; i < childrenSize; i++) + { + parseBoneNameRecursivelyBinary(); + } + } +} + +NodeData* Bundle3D::parseNodesRecursivelyBinary() +{ + return nullptr; +} + GLenum Bundle3D::parseGLType(const std::string& str) { if (str == "GL_BYTE") @@ -1434,7 +1515,8 @@ _version(""), _jsonBuffer(nullptr), _binaryBuffer(nullptr), _referenceCount(0), -_references(nullptr) +_references(nullptr), +_skeleton(false) { } diff --git a/cocos/3d/CCBundle3D.h b/cocos/3d/CCBundle3D.h index 3e0fc00913..58906a6a94 100644 --- a/cocos/3d/CCBundle3D.h +++ b/cocos/3d/CCBundle3D.h @@ -162,14 +162,15 @@ protected: bool loadNodesJson(NodeDatas& nodedatas); void loadBoneNamesJson(const rapidjson::Value& jnodes); void parseBoneNameRecursivelyJson(const rapidjson::Value& jnode); - bool checkIsSkeletonJson(const rapidjson::Value& jnode); - bool checkIsSkeletonRecursivelyJson(const rapidjson::Value& jnode); NodeData* parseNodesRecursivelyJson(const rapidjson::Value& jvalue); /** - * load nodes of Binary + * load nodes of binary */ - + bool loadNodesBinary(NodeDatas& nodedatas); + void loadBoneNamesBinary(); + void parseBoneNameRecursivelyBinary(); + NodeData* parseNodesRecursivelyBinary(); /** * get define data type @@ -222,6 +223,7 @@ protected: bool _isBinary; std::list _bonenames; + bool _skeleton; }; NS_CC_END