Fix more integer conversion warnings

This commit is contained in:
sabrina-shanman 2019-09-16 09:55:25 -07:00
parent 5837053f50
commit 46616b4efd
4 changed files with 5 additions and 5 deletions

View file

@ -80,7 +80,7 @@ QVariantHash ModelPropertiesDialog::getMapping() const {
// update the joint indices
QVariantHash jointIndices;
for (int i = 0; i < _hfmModel.joints.size(); i++) {
for (size_t i = 0; i < _hfmModel.joints.size(); i++) {
jointIndices.insert(_hfmModel.joints.at(i).name, QString::number(i));
}
mapping.insert(JOINT_INDEX_FIELD, jointIndices);

View file

@ -77,7 +77,7 @@ FST* FST::createFSTFromModel(const QString& fstPath, const QString& modelFilePat
mapping.insert(JOINT_FIELD, joints);
QVariantHash jointIndices;
for (int i = 0; i < hfmModel.joints.size(); i++) {
for (size_t i = 0; i < (size_t)hfmModel.joints.size(); i++) {
jointIndices.insert(hfmModel.joints.at(i).name, QString::number(i));
}
mapping.insert(JOINT_INDEX_FIELD, jointIndices);

View file

@ -166,11 +166,11 @@ void HFMModel::computeKdops() {
glm::vec3(INV_SQRT_3, INV_SQRT_3, -INV_SQRT_3),
glm::vec3(INV_SQRT_3, -INV_SQRT_3, -INV_SQRT_3)
};
if (joints.size() != (int)shapeVertices.size()) {
if (joints.size() != shapeVertices.size()) {
return;
}
// now that all joints have been scanned compute a k-Dop bounding volume of mesh
for (int i = 0; i < joints.size(); ++i) {
for (size_t i = 0; i < joints.size(); ++i) {
HFMJoint& joint = joints[i];
// NOTE: points are in joint-frame

View file

@ -37,7 +37,7 @@ namespace baker {
output.edit2() = hfmModelIn->meshIndicesToModelNames;
auto& blendshapesPerMesh = output.edit3();
blendshapesPerMesh.reserve(hfmModelIn->meshes.size());
for (int i = 0; i < hfmModelIn->meshes.size(); i++) {
for (size_t i = 0; i < hfmModelIn->meshes.size(); i++) {
blendshapesPerMesh.push_back(hfmModelIn->meshes[i].blendshapes.toStdVector());
}
output.edit4() = hfmModelIn->joints;