When importing FBX meshes with some unmapped UV's, they are now substituted with (0,0) rather than asserting false and cancelling the import.
--HG-- branch : nfb
This commit is contained in:
@@ -1420,8 +1420,9 @@ void LoadMesh(KRContext &context, FbxScene* pFbxScene, FbxGeometryConverter *pGe
|
|||||||
FbxVector2 uv;
|
FbxVector2 uv;
|
||||||
bool unmapped = false;
|
bool unmapped = false;
|
||||||
if(pMesh->GetPolygonVertexUV(iPolygon, iVertex, setName, uv, unmapped)) {
|
if(pMesh->GetPolygonVertexUV(iPolygon, iVertex, setName, uv, unmapped)) {
|
||||||
assert(!unmapped);
|
if(!unmapped) {
|
||||||
new_uva = KRVector2(uv[0], uv[1]);
|
new_uva = KRVector2(uv[0], uv[1]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
mi.uva.push_back(new_uva);
|
mi.uva.push_back(new_uva);
|
||||||
}
|
}
|
||||||
@@ -1431,8 +1432,9 @@ void LoadMesh(KRContext &context, FbxScene* pFbxScene, FbxGeometryConverter *pGe
|
|||||||
FbxVector2 uv;
|
FbxVector2 uv;
|
||||||
bool unmapped = false;
|
bool unmapped = false;
|
||||||
if(pMesh->GetPolygonVertexUV(iPolygon, iVertex, setName, uv, unmapped)) {
|
if(pMesh->GetPolygonVertexUV(iPolygon, iVertex, setName, uv, unmapped)) {
|
||||||
assert(!unmapped);
|
if(!unmapped) {
|
||||||
new_uvb = KRVector2(uv[0], uv[1]);
|
new_uvb = KRVector2(uv[0], uv[1]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
mi.uvb.push_back(new_uvb);
|
mi.uvb.push_back(new_uvb);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user