You need to sign in or sign up before continuing.
Commit cd6632de authored by hybrid's avatar hybrid

Fixed minor mem leak in 3ds loader. Fixed texture translation in q3 shaders.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@1334 dfc29bdd-3216-0410-991c-e03cc46cb475
parent 22ffe908
......@@ -179,9 +179,13 @@ IAnimatedMesh* C3DSMeshFileLoader::createMesh(io::IReadFile* file)
{
SMesh tmp;
tmp.addMeshBuffer(mb);
IMesh* tangentMesh = SceneManager->getMeshManipulator()->createMeshWithTangents(&tmp);
mb->drop();
IMesh* tangentMesh = SceneManager->getMeshManipulator()->createMeshWithTangents(&tmp);
Mesh->MeshBuffers[i]=tangentMesh->getMeshBuffer(0);
// we need to grab because we replace the buffer manually.
Mesh->MeshBuffers[i]->grab();
// clean up intermediate mesh struct
tangentMesh->drop();
}
Mesh->MeshBuffers[i]->recalculateBoundingBox();
}
......
......@@ -636,7 +636,7 @@ void CQuake3ShaderSceneNode::animate( u32 stage,core::matrix4 &texture )
// scroll
f0 = quake3::getAsFloat ( v.content, pos ) * TimeAbs;
f1 = quake3::getAsFloat ( v.content, pos ) * TimeAbs;
m2.setTextureTranslate ( -f0, f1 );
m2.setTextureTranslate ( f0, f1 );
break;
case 1:
// scale
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment