summaryrefslogtreecommitdiff
path: root/src/resources/dye/dyepalette.h
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-12-23 01:41:05 +0300
committerAndrei Karas <akaras@inbox.ru>2016-12-23 01:56:21 +0300
commitf3729240770f5a18b22fe1992e3775161246d60d (patch)
treea75ce2bc2cb79437d6e9580e239b9bbe7307eec1 /src/resources/dye/dyepalette.h
parentf3ebfff841aafc0aac6186243606e1b2ea381e71 (diff)
downloadplus-f3729240770f5a18b22fe1992e3775161246d60d.tar.gz
plus-f3729240770f5a18b22fe1992e3775161246d60d.tar.bz2
plus-f3729240770f5a18b22fe1992e3775161246d60d.tar.xz
plus-f3729240770f5a18b22fe1992e3775161246d60d.zip
Add a color dye function for sse2 (OpenGL).
Diffstat (limited to 'src/resources/dye/dyepalette.h')
-rw-r--r--src/resources/dye/dyepalette.h32
1 files changed, 32 insertions, 0 deletions
diff --git a/src/resources/dye/dyepalette.h b/src/resources/dye/dyepalette.h
index 19a406097..79bc03443 100644
--- a/src/resources/dye/dyepalette.h
+++ b/src/resources/dye/dyepalette.h
@@ -197,13 +197,45 @@ class DyePalette final
void replaceAOGLColorSimd(uint32_t *restrict pixels,
const int bufSize) const restrict2;
+ /**
+ * replace colors for OpenGL for A dye.
+ */
+ FUNCTION_SIMD_DEFAULT
+ void replaceAOGLColorSse2(uint32_t *restrict pixels,
+ const int bufSize) const restrict2;
+
+ /**
+ * replace colors for OpenGL for A dye.
+ */
+ FUNCTION_SIMD_DEFAULT
+ void replaceAOGLColorAvx2(uint32_t *restrict pixels,
+ const int bufSize) const restrict2;
+
#ifdef SIMD_SUPPORTED
/**
* replace colors for OpenGL for A dye.
*/
+ __attribute__ ((target ("sse2")))
+ void replaceAOGLColorSimd(uint32_t *restrict pixels,
+ const int bufSize) const restrict2;
+ /**
+ * replace colors for OpenGL for A dye.
+ */
__attribute__ ((target ("avx2")))
void replaceAOGLColorSimd(uint32_t *restrict pixels,
const int bufSize) const restrict2;
+ /**
+ * replace colors for OpenGL for A dye.
+ */
+ __attribute__ ((target ("sse2")))
+ void replaceAOGLColorSse2(uint32_t *restrict pixels,
+ const int bufSize) const restrict2;
+ /**
+ * replace colors for OpenGL for A dye.
+ */
+ __attribute__ ((target ("avx2")))
+ void replaceAOGLColorAvx2(uint32_t *restrict pixels,
+ const int bufSize) const restrict2;
#endif // SIMD_SUPPORTED
#endif // USE_OPENGL