Fix crash on uvunwrapping #18
parent
90b0388ff0
commit
f0334c3eec
|
@ -4,10 +4,10 @@ DEFINES += NDEBUG
|
|||
RESOURCES += resources.qrc
|
||||
|
||||
isEmpty(HUMAN_VERSION) {
|
||||
HUMAN_VERSION = "1.0.0-beta.3"
|
||||
HUMAN_VERSION = "1.0.0-beta.4"
|
||||
}
|
||||
isEmpty(VERSION) {
|
||||
VERSION = 1.0.0.3
|
||||
VERSION = 1.0.0.4
|
||||
}
|
||||
|
||||
REPOSITORY_URL = "https://github.com/huxingyi/dust3d"
|
||||
|
|
|
@ -55,6 +55,10 @@ bool extractResult(const std::vector<Vertex> &verticies, const Eigen::MatrixXd &
|
|||
return false;
|
||||
return true;
|
||||
};
|
||||
if ((decltype(verticies.size()))V_uv.size() < verticies.size() * 2) {
|
||||
qDebug() << "Invalid V_uv.size:" << V_uv.size() << "Expected:" << verticies.size() * 2;
|
||||
return false;
|
||||
}
|
||||
for (decltype(verticies.size()) i = 0; i < verticies.size(); i++) {
|
||||
TextureCoord coord;
|
||||
coord.uv[0] = V_uv.row(i)[0];
|
||||
|
|
Loading…
Reference in New Issue