diff --git a/apps/navmeshtool/worldspacedata.cpp b/apps/navmeshtool/worldspacedata.cpp index 1e44e65b8b..ec44d33e6c 100644 --- a/apps/navmeshtool/worldspacedata.cpp +++ b/apps/navmeshtool/worldspacedata.cpp @@ -131,8 +131,7 @@ namespace NavMeshTool osg::ref_ptr shape = [&] { try { - return bulletShapeManager.getShape( - VFS::Path::toNormalized(Misc::ResourceHelpers::correctMeshPath(model))); + return bulletShapeManager.getShape(Misc::ResourceHelpers::correctMeshPath(model)); } catch (const std::exception& e) { diff --git a/apps/openmw/mwphysics/physicssystem.cpp b/apps/openmw/mwphysics/physicssystem.cpp index 77ea0fe7da..e236db4633 100644 --- a/apps/openmw/mwphysics/physicssystem.cpp +++ b/apps/openmw/mwphysics/physicssystem.cpp @@ -571,7 +571,7 @@ namespace MWPhysics { if (animationMesh != mesh) { - shape = mShapeManager->getShape(VFS::Path::toNormalized(mesh)); + shape = mShapeManager->getShape(mesh); } } @@ -591,8 +591,7 @@ namespace MWPhysics int PhysicsSystem::addProjectile( const MWWorld::Ptr& caster, const osg::Vec3f& position, VFS::Path::NormalizedView mesh, bool computeRadius) { - osg::ref_ptr shapeInstance - = mShapeManager->getInstance(VFS::Path::toNormalized(mesh)); + osg::ref_ptr shapeInstance = mShapeManager->getInstance(mesh); assert(shapeInstance); float radius = computeRadius ? shapeInstance->mCollisionBox.mExtents.length() / 2.f : 1.f; diff --git a/components/vfs/pathutil.hpp b/components/vfs/pathutil.hpp index 4492be3967..f5393617d7 100644 --- a/components/vfs/pathutil.hpp +++ b/components/vfs/pathutil.hpp @@ -297,6 +297,10 @@ namespace VFS::Path { return Normalized(std::forward(value)); } + + Normalized toNormalized(NormalizedView value) = delete; + + Normalized toNormalized(Normalized value) = delete; } #endif