From f9e11dabeb4f34552fc7f65ebed34c2d55c21f98 Mon Sep 17 00:00:00 2001 From: Dane Springmeyer Date: Sat, 30 Aug 2014 15:39:52 -0700 Subject: [PATCH] simplify agg_basics.h - remove unused/obsolete asm - visual studio since 2010 supports long long and we target 2014 now --- deps/agg/include/agg_basics.h | 53 ----------------------------------- 1 file changed, 53 deletions(-) diff --git a/deps/agg/include/agg_basics.h b/deps/agg/include/agg_basics.h index 6b34a3fb7..a617cf253 100644 --- a/deps/agg/include/agg_basics.h +++ b/deps/agg/include/agg_basics.h @@ -89,20 +89,12 @@ namespace agg #endif #ifndef AGG_INT64 -#if defined(_MSC_VER) || defined(__BORLANDC__) -#define AGG_INT64 signed __int64 -#else #define AGG_INT64 signed long long #endif -#endif #ifndef AGG_INT64U -#if defined(_MSC_VER) || defined(__BORLANDC__) -#define AGG_INT64U unsigned __int64 -#else #define AGG_INT64U unsigned long long #endif -#endif //------------------------------------------------ Some fixes for MS Visual C++ #if defined(_MSC_VER) @@ -127,50 +119,6 @@ namespace agg typedef AGG_INT64 int64; //----int64 typedef AGG_INT64U int64u; //----int64u -#if defined(AGG_FISTP) -#pragma warning(push) -#pragma warning(disable : 4035) //Disable warning "no return value" - AGG_INLINE int iround(double v) //-------iround - { - int t; - __asm fld qword ptr [v] - __asm fistp dword ptr [t] - __asm mov eax, dword ptr [t] - } - AGG_INLINE unsigned uround(double v) //-------uround - { - unsigned t; - __asm fld qword ptr [v] - __asm fistp dword ptr [t] - __asm mov eax, dword ptr [t] - } -#pragma warning(pop) - AGG_INLINE unsigned ufloor(double v) //-------ufloor - { - return unsigned(std::floor(v)); - } - AGG_INLINE unsigned uceil(double v) //--------uceil - { - return unsigned(std::ceil(v)); - } -#elif defined(AGG_QIFIST) - AGG_INLINE int iround(double v) - { - return int(v); - } - AGG_INLINE int uround(double v) - { - return unsigned(v); - } - AGG_INLINE unsigned ufloor(double v) - { - return unsigned(std::floor(v)); - } - AGG_INLINE unsigned uceil(double v) - { - return unsigned(std::ceil(v)); - } -#else AGG_INLINE int iround(double v) { return int((v < 0.0) ? v - 0.5 : v + 0.5); @@ -187,7 +135,6 @@ namespace agg { return unsigned(std::ceil(v)); } -#endif //---------------------------------------------------------------saturation template struct saturation