--- deliantra/Deliantra-Client/Client.xs 2006/05/14 22:24:14 1.79 +++ deliantra/Deliantra-Client/Client.xs 2006/05/15 00:25:14 1.83 @@ -9,6 +9,7 @@ #include "perl.h" #include "XSUB.h" +#include #include #include @@ -85,7 +86,11 @@ substitute_func (FcPattern *pattern, gpointer data) { FcPatternAddBool (pattern, FC_HINTING , 1); +#ifdef _WIN32 FcPatternAddBool (pattern, FC_AUTOHINT, 1); +#else + FcPatternAddBool (pattern, FC_AUTOHINT, 0); +#endif } static void @@ -1591,8 +1596,10 @@ void glColor (float r, float g, float b, float a = 1.0) PROTOTYPE: @ CODE: - // 255.999 is close enough to correctness (256 and clamp) - glColor4ub (r * 255.999, g * 255.999, b * 255.999, a * 255.999); + glColor4ub (MIN ((int)(r * 255.f), 255), + MIN ((int)(g * 255.f), 255), + MIN ((int)(b * 255.f), 255), + MIN ((int)(a * 255.f), 255)); void glVertex (float x, float y, float z = 0.) CODE: