diff options
Diffstat (limited to 'include/core/SkTypes.h')
-rw-r--r-- | include/core/SkTypes.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/core/SkTypes.h b/include/core/SkTypes.h index a38be84d8f..72ebb093c2 100644 --- a/include/core/SkTypes.h +++ b/include/core/SkTypes.h @@ -12,6 +12,7 @@ #include "SkUserConfig.h" #include "SkPostConfig.h" #include <stdint.h> +#include <sys/types.h> /** \file SkTypes.h */ @@ -244,6 +245,7 @@ typedef uint8_t SkBool8; SK_API int SkToInt(intmax_t); SK_API unsigned SkToUInt(uintmax_t); SK_API size_t SkToSizeT(uintmax_t); + SK_API off_t SkToOffT(intmax_t x); #else #define SkToS8(x) ((int8_t)(x)) #define SkToU8(x) ((uint8_t)(x)) @@ -254,6 +256,7 @@ typedef uint8_t SkBool8; #define SkToInt(x) ((int)(x)) #define SkToUInt(x) ((unsigned)(x)) #define SkToSizeT(x) ((size_t)(x)) + #define SkToOffT(x) ((off_t)(x)) #endif /** Returns 0 or 1 based on the condition |