X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fambientocclusion.cpp;h=444b18b8354cd620fe900ece6ef1c873e6450995;hb=e079d5a878e83dc0baffcec66a57659c885cd593;hp=cf530dc3ce389fcd6650fd60f82966df055ef354;hpb=b8ddfb1f874bc18fa9b6ea27d08b009c8264a577;p=libs%2Fgl.git diff --git a/source/ambientocclusion.cpp b/source/ambientocclusion.cpp index cf530dc3..444b18b8 100644 --- a/source/ambientocclusion.cpp +++ b/source/ambientocclusion.cpp @@ -1,3 +1,4 @@ +#define _USE_MATH_DEFINES #include #include "ambientocclusion.h" #include "blend.h" @@ -107,12 +108,12 @@ AmbientOcclusion::AmbientOcclusion(unsigned w, unsigned h, float depth_ratio): occlude_shdata.uniform("depth", 0); occlude_shdata.uniform("rotate", 1); - occlude_shdata.uniform("screen_size", w, h); + occlude_shdata.uniform("screen_size", static_cast(w), static_cast(h)); combine_shdata.uniform("color", 1); combine_shdata.uniform("depth", 0); combine_shdata.uniform("occlusion", 2); - combine_shdata.uniform("screen_size", w, h); + combine_shdata.uniform("screen_size", static_cast(w), static_cast(h)); set_depth_ratio(depth_ratio); set_darkness(1.5);