Fix sub-optimal uses of is_equal_approx

This commit is contained in:
Aaron Franke 2021-06-20 03:03:06 -04:00
parent 60dcc4f39c
commit 45c24fd039
No known key found for this signature in database
GPG key ID: 40A1750B977E56BF
9 changed files with 23 additions and 23 deletions

View file

@ -3596,7 +3596,7 @@ void GLTFDocument::spec_gloss_to_rough_metal(Ref<GLTFSpecGloss> r_spec_gloss, Re
if (!Math::is_equal_approx(mr.g, 1.0f)) {
has_roughness = true;
}
if (!Math::is_equal_approx(mr.b, 0.0f)) {
if (!Math::is_zero_approx(mr.b)) {
has_metal = true;
}
mr.g *= r_spec_gloss->gloss_factor;