Index: include/core/SkPostConfig.h |
diff --git a/include/core/SkPostConfig.h b/include/core/SkPostConfig.h |
index c34397cde64c13c64e3d3839c616f82b98501611..1b1cb3e751e7273d984ef48212ce266159b85136 100644 |
--- a/include/core/SkPostConfig.h |
+++ b/include/core/SkPostConfig.h |
@@ -75,6 +75,15 @@ |
# else |
# define SK_ATTRIBUTE(attr) |
# endif |
+#endif |
+ |
+// As usual, there are two ways to increase alignment... the MSVC way and the everyone-else way. |
+#ifndef SK_STRUCT_ALIGN |
+ #ifdef _MSC_VER |
+ #define SK_STRUCT_ALIGN(N) __declspec(align(N)) |
+ #else |
+ #define SK_STRUCT_ALIGN(N) __attribute__((aligned(N))) |
+ #endif |
#endif |
#if defined(_MSC_VER) && SK_CPU_SSE_LEVEL >= SK_CPU_SSE_LEVEL_SSE2 |