Merge pull request #3501 from Nodrev/issue_3500
Fixing issue 3500, invalid outer cone angle readed from gltf2 file on machines which defines M_PI as a double valuepull/3484/head^2
commit
749a4963a2
|
@ -1282,7 +1282,7 @@ inline void Light::Read(Value &obj, Asset & /*r*/) {
|
|||
Value *spot = FindObject(obj, "spot");
|
||||
if (!spot) throw DeadlyImportError("GLTF: Light missing its spot parameters");
|
||||
innerConeAngle = MemberOrDefault(*spot, "innerConeAngle", 0.0f);
|
||||
outerConeAngle = MemberOrDefault(*spot, "outerConeAngle", M_PI / 4.0f);
|
||||
outerConeAngle = MemberOrDefault(*spot, "outerConeAngle", static_cast<float>(M_PI / 4.0f));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue