fixed OgreImporter compilation error with boost scoped_ptr

pull/294/head
EdgarsT 2014-06-10 19:58:02 +03:00
parent e09d88fa59
commit 8549e4b1b1
2 changed files with 5 additions and 5 deletions

View File

@ -108,10 +108,10 @@ void OgreImporter::InternReadFile(const std::string &pFile, aiScene *pScene, Ass
MemoryStreamReader reader(f);
// Import mesh
boost::scoped_ptr<Mesh> mesh = OgreBinarySerializer::ImportMesh(&reader);
boost::scoped_ptr<Mesh> mesh(OgreBinarySerializer::ImportMesh(&reader));
// Import skeleton
OgreBinarySerializer::ImportSkeleton(pIOHandler, mesh);
OgreBinarySerializer::ImportSkeleton(pIOHandler, mesh.get());
// Import mesh referenced materials
ReadMaterials(pFile, pIOHandler, pScene, mesh.get());
@ -128,10 +128,10 @@ void OgreImporter::InternReadFile(const std::string &pFile, aiScene *pScene, Ass
boost::scoped_ptr<XmlReader> reader(irr::io::createIrrXMLReader(xmlStream.get()));
// Import mesh
boost::scoped_ptr<MeshXml> mesh = OgreXmlSerializer::ImportMesh(reader.get());
boost::scoped_ptr<MeshXml> mesh(OgreXmlSerializer::ImportMesh(reader.get()));
// Import skeleton
OgreXmlSerializer::ImportSkeleton(pIOHandler, mesh);
OgreXmlSerializer::ImportSkeleton(pIOHandler, mesh.get());
// Import mesh referenced materials
ReadMaterials(pFile, pIOHandler, pScene, mesh.get());

View File

@ -325,7 +325,7 @@ uint32_t VertexData::VertexSize(uint16_t source) const
MemoryStream *VertexData::VertexBuffer(uint16_t source)
{
if (vertexBindings.find(source) != vertexBindings.end())
return vertexBindings[source];
return vertexBindings[source].get();
return 0;
}