fix 'warning: implicit conversion from ‘rw::float32’ {aka ‘float’} to ‘double’ to match other operand of binary expression [-Wdouble-promotion]'

This commit is contained in:
Anonymous Maarten
2018-07-13 01:33:18 +02:00
parent b38cbc7961
commit add55f08c5
2 changed files with 16 additions and 16 deletions

View File

@@ -502,8 +502,8 @@ Camera::setFOV(float32 hfov, float32 ratio)
float ar1 = 4.0/3.0;
float ar2 = w/h;
float vfov = atan(tan(hfov/2) / ar1) *2;
hfov = atan(tan(vfov/2) * ar2) *2;
float vfov = atanf(tanf(hfov/2) / ar1) *2;
hfov = atanf(tanf(vfov/2) * ar2) *2;
float32 a = tan(hfov);
v.set(a, a/ratio);