Fix compiler warnings.
parent
152cddedd3
commit
0dc2e9197a
|
@ -708,7 +708,7 @@ void AssbinImporter::InternReadFile( const std::string& pFile, aiScene* pScene,
|
||||||
|
|
||||||
unsigned char * uncompressedData = new unsigned char[ uncompressedSize ];
|
unsigned char * uncompressedData = new unsigned char[ uncompressedSize ];
|
||||||
|
|
||||||
int res = uncompress( uncompressedData, &uncompressedSize, compressedData, len );
|
int res = uncompress( uncompressedData, &uncompressedSize, compressedData, (uLong) len );
|
||||||
if(res != Z_OK)
|
if(res != Z_OK)
|
||||||
{
|
{
|
||||||
delete [] uncompressedData;
|
delete [] uncompressedData;
|
||||||
|
|
|
@ -964,7 +964,7 @@ namespace Assimp {
|
||||||
{
|
{
|
||||||
if (indices[i] < 0) epcount++;
|
if (indices[i] < 0) epcount++;
|
||||||
}
|
}
|
||||||
unsigned int pcount = indices.size();
|
unsigned int pcount = static_cast<unsigned int>( indices.size() );
|
||||||
unsigned int scount = out_mesh->mNumFaces = pcount - epcount;
|
unsigned int scount = out_mesh->mNumFaces = pcount - epcount;
|
||||||
|
|
||||||
aiFace* fac = out_mesh->mFaces = new aiFace[scount]();
|
aiFace* fac = out_mesh->mFaces = new aiFace[scount]();
|
||||||
|
|
|
@ -486,7 +486,7 @@ void SMDImporter::CreateOutputAnimations(const std::string &pFile, IOSystem* pIO
|
||||||
if (bLoadAnimationList) {
|
if (bLoadAnimationList) {
|
||||||
GetAnimationFileList(pFile, pIOHandler, animFileList);
|
GetAnimationFileList(pFile, pIOHandler, animFileList);
|
||||||
}
|
}
|
||||||
int animCount = animFileList.size() + 1;
|
int animCount = static_cast<int>( animFileList.size() + 1u );
|
||||||
pScene->mNumAnimations = 1;
|
pScene->mNumAnimations = 1;
|
||||||
pScene->mAnimations = new aiAnimation*[animCount];
|
pScene->mAnimations = new aiAnimation*[animCount];
|
||||||
memset(pScene->mAnimations, 0, sizeof(aiAnimation*)*animCount);
|
memset(pScene->mAnimations, 0, sizeof(aiAnimation*)*animCount);
|
||||||
|
@ -510,7 +510,7 @@ void SMDImporter::CreateOutputAnimation(int index, const std::string &name) {
|
||||||
anim->mName.Set(name.c_str());
|
anim->mName.Set(name.c_str());
|
||||||
}
|
}
|
||||||
anim->mDuration = dLengthOfAnim;
|
anim->mDuration = dLengthOfAnim;
|
||||||
anim->mNumChannels = asBones.size();
|
anim->mNumChannels = static_cast<unsigned int>( asBones.size() );
|
||||||
anim->mTicksPerSecond = 25.0; // FIXME: is this correct?
|
anim->mTicksPerSecond = 25.0; // FIXME: is this correct?
|
||||||
|
|
||||||
aiNodeAnim** pp = anim->mChannels = new aiNodeAnim*[anim->mNumChannels];
|
aiNodeAnim** pp = anim->mChannels = new aiNodeAnim*[anim->mNumChannels];
|
||||||
|
|
|
@ -152,10 +152,10 @@ TEST_F(utSTLImporterExporter, test_export_pointclouds) {
|
||||||
|
|
||||||
auto pMesh = scene.mMeshes[0];
|
auto pMesh = scene.mMeshes[0];
|
||||||
|
|
||||||
long numValidPoints = points.size();
|
size_t numValidPoints = points.size();
|
||||||
|
|
||||||
pMesh->mVertices = new aiVector3D[numValidPoints];
|
pMesh->mVertices = new aiVector3D[numValidPoints];
|
||||||
pMesh->mNumVertices = numValidPoints;
|
pMesh->mNumVertices = static_cast<unsigned int>( numValidPoints );
|
||||||
|
|
||||||
int i = 0;
|
int i = 0;
|
||||||
for (XYZ &p : points) {
|
for (XYZ &p : points) {
|
||||||
|
|
|
@ -90,7 +90,7 @@ void SceneAnimator::SetAnimIndex( size_t pAnimIndex) {
|
||||||
delete mAnimEvaluator; mAnimEvaluator = nullptr;
|
delete mAnimEvaluator; mAnimEvaluator = nullptr;
|
||||||
mNodesByName.clear();
|
mNodesByName.clear();
|
||||||
|
|
||||||
mCurrentAnimIndex = pAnimIndex;
|
mCurrentAnimIndex = static_cast<int>( pAnimIndex );
|
||||||
|
|
||||||
// create the internal node tree. Do this even in case of invalid animation index
|
// create the internal node tree. Do this even in case of invalid animation index
|
||||||
// so that the transformation matrices are properly set up to mimic the current scene
|
// so that the transformation matrices are properly set up to mimic the current scene
|
||||||
|
|
Loading…
Reference in New Issue