加载遮挡路径还原
This commit is contained in:
1 parent
4a8e6dedee
commit
8d428ab5a8
1 file changed
+4
-2
@@ -9605,20 +9605,22 @@ bool Scene::TextureMesh(unsigned nResolutionLevel, unsigned nMinResolution, unsi
|
|||||||
printf("id=%s\n", id.c_str());
|
printf("id=%s\n", id.c_str());
|
||||||
|
|
||||||
#ifdef MASK_FACE_OCCLUSION
|
#ifdef MASK_FACE_OCCLUSION
|
||||||
/*
|
//*
|
||||||
fs::path p(baseFileName.c_str());
|
fs::path p(baseFileName.c_str());
|
||||||
// 2. 获取父路径 (e.g., /path/to/data/scene)
|
// 2. 获取父路径 (e.g., /path/to/data/scene)
|
||||||
fs::path parent = p.parent_path();
|
fs::path parent = p.parent_path();
|
||||||
// 4. 转换为字符串,并附加一个路径分隔符
|
// 4. 转换为字符串,并附加一个路径分隔符
|
||||||
// ( / "" 会自动处理,确保 /path/to/data 变为 /path/to/data/ )
|
// ( / "" 会自动处理,确保 /path/to/data 变为 /path/to/data/ )
|
||||||
std::string basePath = (parent / "").string();
|
std::string basePath = (parent / "").string();
|
||||||
*/
|
//*/
|
||||||
|
/*
|
||||||
std::string basePath = "";
|
std::string basePath = "";
|
||||||
size_t lastSlash = baseFileName.find_last_of('/');
|
size_t lastSlash = baseFileName.find_last_of('/');
|
||||||
size_t secondLastSlash = baseFileName.find_last_of('/', lastSlash - 1);
|
size_t secondLastSlash = baseFileName.find_last_of('/', lastSlash - 1);
|
||||||
if (secondLastSlash == std::string::npos)
|
if (secondLastSlash == std::string::npos)
|
||||||
basePath = baseFileName;
|
basePath = baseFileName;
|
||||||
basePath = baseFileName.substr(0, secondLastSlash + 1);
|
basePath = baseFileName.substr(0, secondLastSlash + 1);
|
||||||
|
/*/
|
||||||
|
|
||||||
// printf("basePath=%s\n", basePath.c_str());
|
// printf("basePath=%s\n", basePath.c_str());
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user