From d0484e7829b819b87bf05839f73be4237193985e Mon Sep 17 00:00:00 2001 From: Steven Fuller Date: Wed, 21 May 2003 03:38:50 +0000 Subject: Converted TranslatePoint to C. --- src/kshape.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'src/kshape.c') diff --git a/src/kshape.c b/src/kshape.c index 16df603..cdb49be 100644 --- a/src/kshape.c +++ b/src/kshape.c @@ -4396,7 +4396,7 @@ extern void TranslationSetup(void) } -#if 0 +#ifndef LINUX #ifndef _MSC_VER void TranslatePoint(int *source, int *dest, int *matrix); #pragma aux TranslatePoint = \ @@ -4496,6 +4496,13 @@ void TranslatePoint(int *source, int *dest, int *matrix) } #endif +#else /* LINUX */ +static void TranslatePoint(const float *source, float *dest, const float *matrix) +{ + dest[0] = matrix[ 0] * source[0] + matrix[ 1] * source[1] + matrix[ 2] * source[2] + matrix[ 3]; + dest[1] = matrix[ 4] * source[0] + matrix[ 5] * source[1] + matrix[ 6] * source[2] + matrix[ 7]; + dest[2] = matrix[ 8] * source[0] + matrix[ 9] * source[1] + matrix[10] * source[2] + matrix[11]; +} #endif void TranslatePointIntoViewspace(VECTORCH *pointPtr) -- cgit v1.3