Merge branch 'master' into fix-file-detection

This commit is contained in:
Kim Kulling
2021-05-02 19:41:33 +02:00
committed by GitHub
54 changed files with 1330 additions and 462 deletions
+1 -1
View File
@@ -212,7 +212,7 @@ void Discreet3DSImporter::ConvertMaterial(D3DS::Material &oldMat,
mat.AddProperty(&tex, AI_MATKEY_GLOBAL_BACKGROUND_IMAGE);
// Be sure this is only done for the first material
mBackgroundImage = std::string("");
mBackgroundImage = std::string();
}
// At first add the base ambient color of the scene to the material
+3 -13
View File
@@ -61,20 +61,10 @@ namespace D3DS {
#include <assimp/Compiler/pushpack1.h>
// ---------------------------------------------------------------------------
/** Discreet3DS class: Helper class for loading 3ds files. Defines chunks
* and data structures.
/** Defines chunks and data structures.
*/
class Discreet3DS {
private:
Discreet3DS() AI_NO_EXCEPT {
// empty
}
namespace Discreet3DS {
~Discreet3DS() {
// empty
}
public:
//! data structure for a single chunk in a .3ds file
struct Chunk {
uint16_t Flag;
@@ -314,7 +304,7 @@ public:
// camera sub-chunks
CHUNK_CAM_RANGES = 0x4720
};
};
}
// ---------------------------------------------------------------------------
/** Helper structure representing a 3ds mesh face */
+4 -4
View File
@@ -164,7 +164,7 @@ void Discreet3DSImporter::InternReadFile(const std::string &pFile,
mRootNode->mHierarchyIndex = -1;
mRootNode->mParent = nullptr;
mMasterScale = 1.0f;
mBackgroundImage = "";
mBackgroundImage = std::string();
bHasBG = false;
bIsPrj = false;
@@ -981,9 +981,9 @@ void Discreet3DSImporter::ParseMeshChunk() {
mMesh.mMat.a3 = stream->GetF4();
mMesh.mMat.b3 = stream->GetF4();
mMesh.mMat.c3 = stream->GetF4();
mMesh.mMat.d1 = stream->GetF4();
mMesh.mMat.d2 = stream->GetF4();
mMesh.mMat.d3 = stream->GetF4();
mMesh.mMat.a4 = stream->GetF4();
mMesh.mMat.b4 = stream->GetF4();
mMesh.mMat.c4 = stream->GetF4();
} break;
case Discreet3DS::CHUNK_MAPLIST: {
+1 -1
View File
@@ -188,7 +188,7 @@ bool D3MFOpcPackage::validate() {
std::string D3MFOpcPackage::ReadPackageRootRelationship(IOStream *stream) {
XmlParser xmlParser;
if (!xmlParser.parse(stream)) {
return "";
return std::string();
}
OpcPackageRelationshipReader reader(xmlParser);
+2 -2
View File
@@ -123,9 +123,9 @@ public:
struct Object {
Object() :
type(World),
name(""),
name(),
children(),
texture(""),
texture(),
texRepeat(1.f, 1.f),
texOffset(0.0f, 0.0f),
rotation(),
+1 -1
View File
@@ -685,7 +685,7 @@ void Parser::ParseLV3MapBlock(Texture &map) {
// Files with 'None' as map name are produced by
// an Maja to ASE exporter which name I forgot ..
ASSIMP_LOG_WARN("ASE: Skipping invalid map entry");
map.mMapName = "";
map.mMapName = std::string();
}
continue;
+1 -1
View File
@@ -88,7 +88,7 @@ using namespace Assimp::Blender;
using namespace Assimp::Formatter;
static const aiImporterDesc blenderDesc = {
"Blender 3D Importer \nhttp://www.blender3d.org",
"Blender 3D Importer (http://www.blender3d.org)",
"",
"",
"No animation support yet",
+1 -1
View File
@@ -1241,7 +1241,7 @@ void ColladaLoader::CreateAnimation(aiScene *pScene, const ColladaParser &pParse
continue;
}
entry.mTargetId = entry.mTransformId;
entry.mTransformId = "";
entry.mTransformId = std::string();
}
entry.mChannel = &(*cit);
+1 -1
View File
@@ -330,7 +330,7 @@ void MeshGeometry::ReadVertexData(const std::string& type, int index, const Scop
}
const Element* Name = source["Name"];
m_uvNames[index] = "";
m_uvNames[index] = std::string();
if(Name) {
m_uvNames[index] = ParseTokenAsString(GetRequiredToken(*Name,0));
}
+4 -4
View File
@@ -462,7 +462,7 @@ std::string ParseTokenAsString(const Token& t, const char*& err_out)
if (t.Type() != TokenType_DATA) {
err_out = "expected TOK_DATA token";
return "";
return std::string();
}
if(t.IsBinary())
@@ -470,7 +470,7 @@ std::string ParseTokenAsString(const Token& t, const char*& err_out)
const char* data = t.begin();
if (data[0] != 'S') {
err_out = "failed to parse S(tring), unexpected data type (binary)";
return "";
return std::string();
}
// read string length
@@ -484,13 +484,13 @@ std::string ParseTokenAsString(const Token& t, const char*& err_out)
const size_t length = static_cast<size_t>(t.end() - t.begin());
if(length < 2) {
err_out = "token is too short to hold a string";
return "";
return std::string();
}
const char* s = t.begin(), *e = t.end() - 1;
if (*s != '\"' || *e != '\"') {
err_out = "expected double quoted string";
return "";
return std::string();
}
return std::string(s+1,length-2);
+1 -1
View File
@@ -155,7 +155,7 @@ std::string PeekPropertyName(const Element& element)
ai_assert(element.KeyToken().StringContents() == "P");
const TokenList& tok = element.Tokens();
if(tok.size() < 4) {
return "";
return std::string();
}
return ParseTokenAsString(*tok[0]);
+2 -2
View File
@@ -567,7 +567,7 @@ typedef std::map<std::string, std::string> Metadata;
// ------------------------------------------------------------------------------------------------
void ProcessMetadata(const Schema_2x3::ListOf<Schema_2x3::Lazy<Schema_2x3::IfcProperty>, 1, 0> &set, ConversionData &conv, Metadata &properties,
const std::string &prefix = "",
const std::string &prefix = std::string(),
unsigned int nest = 0) {
for (const Schema_2x3::IfcProperty &property : set) {
const std::string &key = prefix.length() > 0 ? (prefix + "." + property.Name) : property.Name;
@@ -618,7 +618,7 @@ void ProcessMetadata(const Schema_2x3::ListOf<Schema_2x3::Lazy<Schema_2x3::IfcPr
ProcessMetadata(complexProp->HasProperties, conv, properties, key, nest + 1);
}
} else {
properties[key] = "";
properties[key] = std::string();
}
}
}
+1 -1
View File
@@ -859,7 +859,7 @@ void IRRImporter::InternReadFile(const std::string &pFile, aiScene *pScene, IOSy
// Check whether we can read from the file
if (file.get() == nullptr) {
throw DeadlyImportError("Failed to open IRR file " + pFile + "");
throw DeadlyImportError("Failed to open IRR file " + pFile);
}
// Construct the irrXML parser
+1 -1
View File
@@ -135,7 +135,7 @@ void IRRMeshImporter::InternReadFile(const std::string &pFile,
// Check whether we can read from the file
if (file.get() == NULL)
throw DeadlyImportError("Failed to open IRRMESH file " + pFile + "");
throw DeadlyImportError("Failed to open IRRMESH file " + pFile);
// Construct the irrXML parser
XmlParser parser;
+1 -1
View File
@@ -502,7 +502,7 @@ struct Surface {
Surface() :
mColor(0.78431f, 0.78431f, 0.78431f), bDoubleSided(false), mDiffuseValue(1.f), mSpecularValue(0.f), mTransparency(0.f), mGlossiness(0.4f), mLuminosity(0.f), mColorHighlights(0.f), mMaximumSmoothAngle(0.f) // 0 == not specified, no smoothing
,
mVCMap(""),
mVCMap(),
mVCMapType(AI_LWO_RGBA),
mIOR(1.f) // vakuum
,
+1 -1
View File
@@ -88,7 +88,7 @@ struct NodeDesc {
id(),
number(0),
parent(0),
name(""),
name(),
isPivotSet(false),
lightColor(1.f, 1.f, 1.f),
lightIntensity(1.f),
+1 -1
View File
@@ -51,7 +51,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#define AI_MDL_NORMALTABLE_H_INC
float g_avNormals[162][3] = {
const float g_avNormals[162][3] = {
{ -0.525731f, 0.000000f, 0.850651f },
{ -0.442863f, 0.238856f, 0.864188f },
{ -0.295242f, 0.000000f, 0.955423f },
+1 -1
View File
@@ -36,7 +36,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#define MDC_NORMAL_TABLE_INCLUDED
/* mdc decoding normal table */
float mdcNormals[ 256 ][ 3 ] =
const float mdcNormals[ 256 ][ 3 ] =
{
{ 1.000000f, 0.000000f, 0.000000f },
{ 0.980785f, 0.195090f, 0.000000f },
@@ -95,7 +95,7 @@ void UniqueNameGenerator::make_unique(std::vector<std::string> &names) {
auto generate_unique_name = [&](const std::string &base_name) -> std::string {
auto *duplicate_info = &names_to_duplicates[base_name];
std::string new_name = "";
std::string new_name;
bool found_identical_name;
bool tried_with_base_name_only = false;
+1 -1
View File
@@ -75,7 +75,7 @@ using namespace std;
// Default constructor
MMDImporter::MMDImporter() :
m_Buffer(),
m_strAbsPath("") {
m_strAbsPath() {
DefaultIOSystem io;
m_strAbsPath = io.getOsSeparator();
}
+1 -1
View File
@@ -91,7 +91,7 @@ namespace pmx
std::vector<char> buffer;
if (size == 0)
{
return std::string("");
return std::string();
}
buffer.reserve(size);
stream->read((char*) buffer.data(), size);
+1 -1
View File
@@ -206,7 +206,7 @@ USE_ODDLPARSER_NS
//------------------------------------------------------------------------------------------------
static void propId2StdString(Property *prop, std::string &name, std::string &key) {
name = key = "";
name = key = std::string();
if (nullptr == prop) {
return;
}
+1 -1
View File
@@ -79,7 +79,7 @@ struct MetricInfo {
int m_intValue;
MetricInfo()
: m_stringValue( "" )
: m_stringValue( )
, m_floatValue( 0.0f )
, m_intValue( -1 ) {
// empty
+1 -1
View File
@@ -178,7 +178,7 @@ struct Q3BSPModel {
m_Textures(),
m_Lightmaps(),
m_EntityData(),
m_ModelName( "" )
m_ModelName()
{
// empty
}
+8 -8
View File
@@ -113,7 +113,7 @@ static void extractIds(const std::string &key, int &id1, int &id2) {
// ------------------------------------------------------------------------------------------------
// Local helper function to normalize filenames.
static void normalizePathName(const std::string &rPath, std::string &normalizedPath) {
normalizedPath = "";
normalizedPath = std::string();
if (rPath.empty()) {
return;
}
@@ -183,7 +183,7 @@ void Q3BSPFileImporter::InternReadFile(const std::string &rFile, aiScene *scene,
throw DeadlyImportError("Failed to open file ", rFile, ".");
}
std::string archiveName(""), mapName("");
std::string archiveName, mapName;
separateMapName(rFile, archiveName, mapName);
if (mapName.empty()) {
@@ -202,8 +202,8 @@ void Q3BSPFileImporter::InternReadFile(const std::string &rFile, aiScene *scene,
// ------------------------------------------------------------------------------------------------
// Separates the map name from the import name.
void Q3BSPFileImporter::separateMapName(const std::string &importName, std::string &archiveName, std::string &mapName) {
archiveName = "";
mapName = "";
archiveName = std::string();
mapName = std::string();
if (importName.empty()) {
return;
}
@@ -221,7 +221,7 @@ void Q3BSPFileImporter::separateMapName(const std::string &importName, std::stri
// ------------------------------------------------------------------------------------------------
// Returns the first map in the map archive.
bool Q3BSPFileImporter::findFirstMapInArchive(ZipArchiveIOSystem &bspArchive, std::string &mapName) {
mapName = "";
mapName = std::string();
std::vector<std::string> fileList;
bspArchive.getFileListExtension(fileList, "bsp");
if (fileList.empty()) {
@@ -440,7 +440,7 @@ void Q3BSPFileImporter::createMaterials(const Q3BSP::Q3BSPModel *pModel, aiScene
if (-1 != textureId) {
sQ3BSPTexture *pTexture = pModel->m_Textures[textureId];
if (nullptr != pTexture) {
std::string tmp("*"), texName("");
std::string tmp("*"), texName;
tmp += pTexture->strName;
tmp += ".jpg";
normalizePathName(tmp, texName);
@@ -512,7 +512,7 @@ size_t Q3BSPFileImporter::countTriangles(const std::vector<Q3BSP::sQ3BSPFace *>
// ------------------------------------------------------------------------------------------------
// Creates the faces-to-material map.
void Q3BSPFileImporter::createMaterialMap(const Q3BSP::Q3BSPModel *pModel) {
std::string key("");
std::string key;
std::vector<sQ3BSPFace *> *pCurFaceArray = nullptr;
for (size_t idx = 0; idx < pModel->m_Faces.size(); idx++) {
Q3BSP::sQ3BSPFace *pQ3BSPFace = pModel->m_Faces[idx];
@@ -660,7 +660,7 @@ bool Q3BSPFileImporter::expandFile(ZipArchiveIOSystem *pArchive, const std::stri
if (rExtList.empty()) {
rFile = rFilename;
rExt = "";
rExt = std::string();
return true;
}
+1 -1
View File
@@ -130,7 +130,7 @@ struct Mesh {
std::vector<Bone> mBones;
explicit Mesh(const std::string &pName = "") AI_NO_EXCEPT
explicit Mesh(const std::string &pName = std::string()) AI_NO_EXCEPT
: mName( pName )
, mPositions()
, mPosFaces()
+1 -1
View File
@@ -142,7 +142,7 @@ void XGLImporter::InternReadFile(const std::string &pFile, aiScene *pScene, IOSy
// check whether we can read from the file
if (stream.get() == NULL) {
throw DeadlyImportError("Failed to open XGL/ZGL file " + pFile + "");
throw DeadlyImportError("Failed to open XGL/ZGL file " + pFile);
}
// see if its compressed, if so uncompress it
+1 -1
View File
@@ -1033,7 +1033,7 @@ namespace glTF
AssetMetadata()
: premultipliedAlpha(false)
, version("")
, version()
{
}
};
+1 -1
View File
@@ -1071,7 +1071,7 @@ struct AssetMetadata {
void Read(Document &doc);
AssetMetadata() :
version("") {}
version() {}
};
//
+25 -2
View File
@@ -162,6 +162,9 @@ inline static bool ReadValue(Value &val, T &out) {
template <class T>
inline static bool ReadMember(Value &obj, const char *id, T &out) {
if (!obj.IsObject()) {
return false;
}
Value::MemberIterator it = obj.FindMember(id);
if (it != obj.MemberEnd()) {
return ReadHelper<T>::Read(it->value, out);
@@ -176,6 +179,9 @@ inline static T MemberOrDefault(Value &obj, const char *id, T defaultValue) {
}
inline Value *FindMember(Value &val, const char *id) {
if (!val.IsObject()) {
return nullptr;
}
Value::MemberIterator it = val.FindMember(id);
return (it != val.MemberEnd()) ? &it->value : nullptr;
}
@@ -193,6 +199,9 @@ inline void throwUnexpectedTypeError(const char (&expectedTypeName)[N], const ch
// Look-up functions with type checks. Context and extra context help the user identify the problem if there's an error.
inline Value *FindStringInContext(Value &val, const char *memberId, const char* context, const char* extraContext = nullptr) {
if (!val.IsObject()) {
return nullptr;
}
Value::MemberIterator it = val.FindMember(memberId);
if (it == val.MemberEnd()) {
return nullptr;
@@ -204,6 +213,9 @@ inline Value *FindStringInContext(Value &val, const char *memberId, const char*
}
inline Value *FindNumberInContext(Value &val, const char *memberId, const char* context, const char* extraContext = nullptr) {
if (!val.IsObject()) {
return nullptr;
}
Value::MemberIterator it = val.FindMember(memberId);
if (it == val.MemberEnd()) {
return nullptr;
@@ -215,6 +227,9 @@ inline Value *FindNumberInContext(Value &val, const char *memberId, const char*
}
inline Value *FindUIntInContext(Value &val, const char *memberId, const char* context, const char* extraContext = nullptr) {
if (!val.IsObject()) {
return nullptr;
}
Value::MemberIterator it = val.FindMember(memberId);
if (it == val.MemberEnd()) {
return nullptr;
@@ -226,6 +241,9 @@ inline Value *FindUIntInContext(Value &val, const char *memberId, const char* co
}
inline Value *FindArrayInContext(Value &val, const char *memberId, const char* context, const char* extraContext = nullptr) {
if (!val.IsObject()) {
return nullptr;
}
Value::MemberIterator it = val.FindMember(memberId);
if (it == val.MemberEnd()) {
return nullptr;
@@ -237,6 +255,9 @@ inline Value *FindArrayInContext(Value &val, const char *memberId, const char* c
}
inline Value *FindObjectInContext(Value &val, const char *memberId, const char* context, const char* extraContext = nullptr) {
if (!val.IsObject()) {
return nullptr;
}
Value::MemberIterator it = val.FindMember(memberId);
if (it == val.MemberEnd()) {
return nullptr;
@@ -886,7 +907,7 @@ inline void Accessor::Read(Value &obj, Asset &r) {
componentType = MemberOrDefault(obj, "componentType", ComponentType_BYTE);
{
const Value* countValue = FindUInt(obj, "count");
if (!countValue || countValue->GetInt() < 1)
if (!countValue || countValue->GetUint() < 1)
{
throw DeadlyImportError("A strictly positive count value is required, when reading ", id.c_str(), name.empty() ? "" : " (" + name + ")");
}
@@ -1105,7 +1126,9 @@ inline Accessor::Indexer::Indexer(Accessor &acc) :
template <class T>
T Accessor::Indexer::GetValue(int i) {
ai_assert(data);
ai_assert(i * stride < accessor.GetMaxByteSize());
if (i * stride >= accessor.GetMaxByteSize()) {
throw DeadlyImportError("GLTF: Invalid index ", i, ", count out of range for buffer with stride ", stride, " and size ", accessor.GetMaxByteSize(), ".");
}
// Ensure that the memcpy doesn't overwrite the local.
const size_t sizeToCopy = std::min(elemSize, sizeof(T));
T value = T();
+3 -3
View File
@@ -1172,7 +1172,7 @@ aiNodeAnim *CreateNodeAnim(glTF2::Asset&, Node &node, AnimationSamplers &sampler
static const float kMillisecondsFromSeconds = 1000.f;
if (samplers.translation) {
if (samplers.translation && samplers.translation->input && samplers.translation->output) {
float *times = nullptr;
samplers.translation->input->ExtractData(times);
aiVector3D *values = nullptr;
@@ -1196,7 +1196,7 @@ aiNodeAnim *CreateNodeAnim(glTF2::Asset&, Node &node, AnimationSamplers &sampler
anim->mPositionKeys->mValue.z = node.translation.value[2];
}
if (samplers.rotation) {
if (samplers.rotation && samplers.rotation->input && samplers.rotation->output) {
float *times = nullptr;
samplers.rotation->input->ExtractData(times);
aiQuaternion *values = nullptr;
@@ -1224,7 +1224,7 @@ aiNodeAnim *CreateNodeAnim(glTF2::Asset&, Node &node, AnimationSamplers &sampler
anim->mRotationKeys->mValue.w = node.rotation.value[3];
}
if (samplers.scale) {
if (samplers.scale && samplers.scale->input && samplers.scale->output) {
float *times = nullptr;
samplers.scale->input->ExtractData(times);
aiVector3D *values = nullptr;
+1 -1
View File
@@ -271,7 +271,7 @@ std::string BaseImporter::GetExtension(const std::string &file) {
// no file extension at all
if (pos == std::string::npos) {
return "";
return std::string();
}
// thanks to Andy Maloney for the hint
+4 -2
View File
@@ -90,10 +90,12 @@ DefaultIOStream::~DefaultIOStream() {
size_t DefaultIOStream::Read(void *pvBuffer,
size_t pSize,
size_t pCount) {
if (0 == pCount) {
return 0;
}
ai_assert(nullptr != pvBuffer);
ai_assert(0 != pSize);
ai_assert(0 != pCount);
return (mFile ? ::fread(pvBuffer, pSize, pCount, mFile) : 0);
}
+1 -1
View File
@@ -76,7 +76,7 @@ public:
if (std::string::npos != (ss2 = mBase.find_last_of("\\/"))) {
mBase.erase(ss2,mBase.length()-ss2);
} else {
mBase = "";
mBase = std::string();
}
// make sure the directory is terminated properly
+3 -3
View File
@@ -149,7 +149,7 @@ void AllocateFromAssimpHeap::operator delete[] ( void* data) {
Importer::Importer()
: pimpl( new ImporterPimpl ) {
pimpl->mScene = nullptr;
pimpl->mErrorString = "";
pimpl->mErrorString = std::string();
// Allocate a default IO handler
pimpl->mIOHandler = new DefaultIOSystem;
@@ -387,7 +387,7 @@ void Importer::FreeScene( ) {
delete pimpl->mScene;
pimpl->mScene = nullptr;
pimpl->mErrorString = "";
pimpl->mErrorString = std::string();
pimpl->mException = std::exception_ptr();
ASSIMP_END_EXCEPTION_REGION(void);
}
@@ -434,7 +434,7 @@ aiScene* Importer::GetOrphanedScene() {
ASSIMP_BEGIN_EXCEPTION_REGION();
pimpl->mScene = nullptr;
pimpl->mErrorString = ""; // reset error string
pimpl->mErrorString = std::string();
pimpl->mException = std::exception_ptr();
ASSIMP_END_EXCEPTION_REGION(aiScene*);
+4 -2
View File
@@ -45,7 +45,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
// possible as new fields are added to assimp structures.
// ----------------------------------------------------------------------------
/**
/**
* @file Implements Assimp::SceneCombiner. This is a smart utility
* class that combines multiple scenes, meshes, ... into one. Currently
* these utilities are used by the IRR and LWS loaders and the
@@ -359,7 +359,7 @@ void SceneCombiner::MergeScenes(aiScene **_dest, aiScene *master, std::vector<At
// generate the output texture list + an offset table for all texture indices
if (dest->mNumTextures) {
aiTexture **pip = dest->mTextures = new aiTexture *[dest->mNumMaterials];
aiTexture **pip = dest->mTextures = new aiTexture *[dest->mNumTextures];
cnt = 0;
for (unsigned int n = 0; n < src.size(); ++n) {
SceneHelper *cur = &src[n];
@@ -638,6 +638,8 @@ void SceneCombiner::MergeScenes(aiScene **_dest, aiScene *master, std::vector<At
deleteMe->mMaterials = nullptr;
delete[] deleteMe->mAnimations;
deleteMe->mAnimations = nullptr;
delete[] deleteMe->mTextures;
deleteMe->mTextures = nullptr;
deleteMe->mRootNode = nullptr;
+1 -1
View File
@@ -43,7 +43,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <assimp/scene.h>
aiNode::aiNode()
: mName("")
: mName()
, mParent(nullptr)
, mNumChildren(0)
, mChildren(nullptr)
@@ -81,7 +81,7 @@ public:
/** @brief Set list of fixed (inmutable) materials
* @param fixed See #AI_CONFIG_PP_RRM_EXCLUDE_LIST
*/
void SetFixedMaterialsString(const std::string& fixed = "") {
void SetFixedMaterialsString(const std::string& fixed = std::string()) {
mConfigFixedMaterials = fixed;
}
+3 -1
View File
@@ -135,7 +135,9 @@ void SortByPTypeProcess::Execute(aiScene *pScene) {
std::vector<unsigned int>::iterator meshIdx = replaceMeshIndex.begin();
for (unsigned int i = 0; i < pScene->mNumMeshes; ++i) {
aiMesh *const mesh = pScene->mMeshes[i];
ai_assert(0 != mesh->mPrimitiveTypes);
if (mesh->mPrimitiveTypes == 0) {
throw DeadlyImportError("Mesh with invalid primitive type: ", mesh->mName.C_Str());
}
// if there's just one primitive type in the mesh there's nothing to do for us
unsigned int num = 0;