From d2055064395b72ef674fdfea0ca4553818a5e655 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Duval?= Date: Sun, 17 Jun 2007 12:15:30 +0000 Subject: [PATCH] we use C for the ppc build git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21433 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/add-ons/translators/wonderbrush/support/support.h | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/add-ons/translators/wonderbrush/support/support.h b/src/add-ons/translators/wonderbrush/support/support.h index 0a27bfb398..0d67a7efb4 100644 --- a/src/add-ons/translators/wonderbrush/support/support.h +++ b/src/add-ons/translators/wonderbrush/support/support.h @@ -21,6 +21,8 @@ constrain(float& value, float min, float max) value = max; } +#ifdef __INTEL__ + // constrain_int32_0_255_asm inline int32 constrain_int32_0_255_asm(int32 value) { @@ -36,13 +38,19 @@ constrain_int32_0_255_asm(int32 value) { return value; } +#define constrain_int32_0_255 constrain_int32_0_255_asm + +#else + inline int32 constrain_int32_0_255_c(int32 value) { return max_c(0, min_c(255, value)); } -#define constrain_int32_0_255 constrain_int32_0_255_asm +#define constrain_int32_0_255 constrain_int32_0_255_c + +#endif // rect_to_int inline void