MSVC crash workaround
I do not know why, but the following line causes crash if assimp was compiled using MSVC with RelWithDebInfo configuration: `std::transform(shading.begin(), shading.end(), shading.begin(), Assimp::ToLower<char>);` replacing `shading.begin()` with `shading.data()` fixes this issue.pull/3471/head
parent
f13a69a817
commit
7781fe5781
|
@ -86,7 +86,7 @@ Material::Material(uint64_t id, const Element& element, const Document& doc, con
|
|||
std::string templateName;
|
||||
|
||||
// lower-case shading because Blender (for example) writes "Phong"
|
||||
std::transform(shading.begin(), shading.end(), shading.begin(), Assimp::ToLower<char>);
|
||||
std::transform(shading.data(), shading.data() + shading.size(), shading.data(), Assimp::ToLower<char>);
|
||||
if(shading == "phong") {
|
||||
templateName = "Material.FbxSurfacePhong";
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue