Use FT_INT64 instead of FT_LONG64.
* include/freetype/config/integer-types.h: Remove synonymous FT_LONG64. * include/freetype/internal/ftcalc.h: s/FT_LONG64/FT_INT64/. * src/base/ftcalc.c: Ditto. * src/base/fttrigon.c: Ditto. * src/smooth/ftgrays.c: Ditto.
This commit is contained in:
parent
e2cceed857
commit
857038399a
@ -178,8 +178,6 @@
|
||||
/* Autoconf */
|
||||
#if FT_SIZEOF_LONG == ( 64 / FT_CHAR_BIT )
|
||||
|
||||
/* `FT_LONG64` must be defined if a 64-bit type is available */
|
||||
#define FT_LONG64
|
||||
#define FT_INT64 long
|
||||
#define FT_UINT64 unsigned long
|
||||
|
||||
@ -194,14 +192,12 @@
|
||||
|
||||
#if defined( __STDC_VERSION__ ) && __STDC_VERSION__ >= 199901L
|
||||
|
||||
#define FT_LONG64
|
||||
#define FT_INT64 long long int
|
||||
#define FT_UINT64 unsigned long long int
|
||||
|
||||
#elif defined( _MSC_VER ) && _MSC_VER >= 900 /* Visual C++ (and Intel C++) */
|
||||
|
||||
/* this compiler provides the `__int64` type */
|
||||
#define FT_LONG64
|
||||
#define FT_INT64 __int64
|
||||
#define FT_UINT64 unsigned __int64
|
||||
|
||||
@ -211,7 +207,6 @@
|
||||
/* to test the compiler version. */
|
||||
|
||||
/* this compiler provides the `__int64` type */
|
||||
#define FT_LONG64
|
||||
#define FT_INT64 __int64
|
||||
#define FT_UINT64 unsigned __int64
|
||||
|
||||
@ -221,14 +216,12 @@
|
||||
|
||||
#elif defined( __MWERKS__ ) /* Metrowerks CodeWarrior */
|
||||
|
||||
#define FT_LONG64
|
||||
#define FT_INT64 long long int
|
||||
#define FT_UINT64 unsigned long long int
|
||||
|
||||
#elif defined( __GNUC__ )
|
||||
|
||||
/* GCC provides the `long long` type */
|
||||
#define FT_LONG64
|
||||
#define FT_INT64 long long int
|
||||
#define FT_UINT64 unsigned long long int
|
||||
|
||||
@ -236,7 +229,7 @@
|
||||
|
||||
#endif /* FT_SIZEOF_LONG == (64 / FT_CHAR_BIT) */
|
||||
|
||||
#ifdef FT_LONG64
|
||||
#ifdef FT_INT64
|
||||
typedef FT_INT64 FT_Int64;
|
||||
typedef FT_UINT64 FT_UInt64;
|
||||
#endif
|
||||
|
@ -487,7 +487,7 @@ FT_BEGIN_HEADER
|
||||
#define NEG_INT32( a ) \
|
||||
(FT_Int32)( (FT_UInt32)0 - (FT_UInt32)(a) )
|
||||
|
||||
#ifdef FT_LONG64
|
||||
#ifdef FT_INT64
|
||||
|
||||
#define ADD_INT64( a, b ) \
|
||||
(FT_Int64)( (FT_UInt64)(a) + (FT_UInt64)(b) )
|
||||
@ -498,7 +498,7 @@ FT_BEGIN_HEADER
|
||||
#define NEG_INT64( a ) \
|
||||
(FT_Int64)( (FT_UInt64)0 - (FT_UInt64)(a) )
|
||||
|
||||
#endif /* FT_LONG64 */
|
||||
#endif /* FT_INT64 */
|
||||
|
||||
|
||||
FT_END_HEADER
|
||||
|
@ -45,7 +45,7 @@
|
||||
|
||||
/* we need to emulate a 64-bit data type if a real one isn't available */
|
||||
|
||||
#ifndef FT_LONG64
|
||||
#ifndef FT_INT64
|
||||
|
||||
typedef struct FT_Int64_
|
||||
{
|
||||
@ -54,7 +54,7 @@
|
||||
|
||||
} FT_Int64;
|
||||
|
||||
#endif /* !FT_LONG64 */
|
||||
#endif /* !FT_INT64 */
|
||||
|
||||
|
||||
/**************************************************************************
|
||||
@ -79,7 +79,7 @@
|
||||
FT_END_STMNT
|
||||
|
||||
/* The following three functions are available regardless of whether */
|
||||
/* FT_LONG64 is defined. */
|
||||
/* FT_INT64 is defined. */
|
||||
|
||||
/* documentation is in freetype.h */
|
||||
|
||||
@ -164,7 +164,7 @@
|
||||
}
|
||||
|
||||
|
||||
#ifdef FT_LONG64
|
||||
#ifdef FT_INT64
|
||||
|
||||
|
||||
/* documentation is in freetype.h */
|
||||
@ -272,7 +272,7 @@
|
||||
}
|
||||
|
||||
|
||||
#else /* !FT_LONG64 */
|
||||
#else /* !FT_INT64 */
|
||||
|
||||
|
||||
static void
|
||||
@ -651,7 +651,7 @@
|
||||
}
|
||||
|
||||
|
||||
#endif /* !FT_LONG64 */
|
||||
#endif /* !FT_INT64 */
|
||||
|
||||
|
||||
/* documentation is in ftglyph.h */
|
||||
@ -985,7 +985,7 @@
|
||||
/* we silently ignore overflow errors since such large values */
|
||||
/* lead to even more (harmless) rendering errors later on */
|
||||
|
||||
#ifdef FT_LONG64
|
||||
#ifdef FT_INT64
|
||||
|
||||
FT_Int64 delta = SUB_INT64( MUL_INT64( in_x, out_y ),
|
||||
MUL_INT64( in_y, out_x ) );
|
||||
|
@ -53,7 +53,7 @@
|
||||
};
|
||||
|
||||
|
||||
#ifdef FT_LONG64
|
||||
#ifdef FT_INT64
|
||||
|
||||
/* multiply a given value by the CORDIC shrink factor */
|
||||
static FT_Fixed
|
||||
@ -76,7 +76,7 @@
|
||||
return s < 0 ? -val : val;
|
||||
}
|
||||
|
||||
#else /* !FT_LONG64 */
|
||||
#else /* !FT_INT64 */
|
||||
|
||||
/* multiply a given value by the CORDIC shrink factor */
|
||||
static FT_Fixed
|
||||
@ -125,7 +125,7 @@
|
||||
return s < 0 ? -val : val;
|
||||
}
|
||||
|
||||
#endif /* !FT_LONG64 */
|
||||
#endif /* !FT_INT64 */
|
||||
|
||||
|
||||
/* undefined and never called for zero vector */
|
||||
|
@ -625,7 +625,7 @@ typedef ptrdiff_t FT_PtrDist;
|
||||
}
|
||||
|
||||
|
||||
#ifndef FT_LONG64
|
||||
#ifndef FT_INT64
|
||||
|
||||
/**************************************************************************
|
||||
*
|
||||
@ -1015,11 +1015,11 @@ typedef ptrdiff_t FT_PtrDist;
|
||||
|
||||
/*
|
||||
* For now, the code that depends on `BEZIER_USE_DDA` requires `FT_Int64`
|
||||
* to be defined. If `FT_LONG64` is not defined, meaning there is no
|
||||
* to be defined. If `FT_INT64` is not defined, meaning there is no
|
||||
* 64-bit type available, disable it to avoid compilation errors. See for
|
||||
* example https://gitlab.freedesktop.org/freetype/freetype/-/issues/1071.
|
||||
*/
|
||||
#if !defined( FT_LONG64 )
|
||||
#if !defined( FT_INT64 )
|
||||
# undef BEZIER_USE_DDA
|
||||
# define BEZIER_USE_DDA 0
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user