Improve performance of non-SIMD color conversion routines and use global constants to define colorspace extension parameters


git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@698 632fc199-4ca6-4c93-a231-07263d6284db
diff --git a/simd/jdcolss2-64.asm b/simd/jdcolss2-64.asm
index d14a28a..01b3dce 100644
--- a/simd/jdcolss2-64.asm
+++ b/simd/jdcolss2-64.asm
@@ -57,10 +57,10 @@
 %undef RGB_GREEN
 %undef RGB_BLUE
 %undef RGB_PIXELSIZE
-%define RGB_RED 0
-%define RGB_GREEN 1
-%define RGB_BLUE 2
-%define RGB_PIXELSIZE 3
+%define RGB_RED EXT_RGB_RED
+%define RGB_GREEN EXT_RGB_GREEN
+%define RGB_BLUE EXT_RGB_BLUE
+%define RGB_PIXELSIZE EXT_RGB_PIXELSIZE
 %define jsimd_ycc_rgb_convert_sse2 jsimd_ycc_extrgb_convert_sse2
 %include "jdclrss2-64.asm"
 
@@ -68,10 +68,10 @@
 %undef RGB_GREEN
 %undef RGB_BLUE
 %undef RGB_PIXELSIZE
-%define RGB_RED 0
-%define RGB_GREEN 1
-%define RGB_BLUE 2
-%define RGB_PIXELSIZE 4
+%define RGB_RED EXT_RGBX_RED
+%define RGB_GREEN EXT_RGBX_GREEN
+%define RGB_BLUE EXT_RGBX_BLUE
+%define RGB_PIXELSIZE EXT_RGBX_PIXELSIZE
 %define jsimd_ycc_rgb_convert_sse2 jsimd_ycc_extrgbx_convert_sse2
 %include "jdclrss2-64.asm"
 
@@ -79,10 +79,10 @@
 %undef RGB_GREEN
 %undef RGB_BLUE
 %undef RGB_PIXELSIZE
-%define RGB_RED 2
-%define RGB_GREEN 1
-%define RGB_BLUE 0
-%define RGB_PIXELSIZE 3
+%define RGB_RED EXT_BGR_RED
+%define RGB_GREEN EXT_BGR_GREEN
+%define RGB_BLUE EXT_BGR_BLUE
+%define RGB_PIXELSIZE EXT_BGR_PIXELSIZE
 %define jsimd_ycc_rgb_convert_sse2 jsimd_ycc_extbgr_convert_sse2
 %include "jdclrss2-64.asm"
 
@@ -90,10 +90,10 @@
 %undef RGB_GREEN
 %undef RGB_BLUE
 %undef RGB_PIXELSIZE
-%define RGB_RED 2
-%define RGB_GREEN 1
-%define RGB_BLUE 0
-%define RGB_PIXELSIZE 4
+%define RGB_RED EXT_BGRX_RED
+%define RGB_GREEN EXT_BGRX_GREEN
+%define RGB_BLUE EXT_BGRX_BLUE
+%define RGB_PIXELSIZE EXT_BGRX_PIXELSIZE
 %define jsimd_ycc_rgb_convert_sse2 jsimd_ycc_extbgrx_convert_sse2
 %include "jdclrss2-64.asm"
 
@@ -101,10 +101,10 @@
 %undef RGB_GREEN
 %undef RGB_BLUE
 %undef RGB_PIXELSIZE
-%define RGB_RED 3
-%define RGB_GREEN 2
-%define RGB_BLUE 1
-%define RGB_PIXELSIZE 4
+%define RGB_RED EXT_XBGR_RED
+%define RGB_GREEN EXT_XBGR_GREEN
+%define RGB_BLUE EXT_XBGR_BLUE
+%define RGB_PIXELSIZE EXT_XBGR_PIXELSIZE
 %define jsimd_ycc_rgb_convert_sse2 jsimd_ycc_extxbgr_convert_sse2
 %include "jdclrss2-64.asm"
 
@@ -112,9 +112,9 @@
 %undef RGB_GREEN
 %undef RGB_BLUE
 %undef RGB_PIXELSIZE
-%define RGB_RED 1
-%define RGB_GREEN 2
-%define RGB_BLUE 3
-%define RGB_PIXELSIZE 4
+%define RGB_RED EXT_XRGB_RED
+%define RGB_GREEN EXT_XRGB_GREEN
+%define RGB_BLUE EXT_XRGB_BLUE
+%define RGB_PIXELSIZE EXT_XRGB_PIXELSIZE
 %define jsimd_ycc_rgb_convert_sse2 jsimd_ycc_extxrgb_convert_sse2
 %include "jdclrss2-64.asm"