summaryrefslogtreecommitdiff
path: root/src/resources/dye/dyepalette_replaceaoglcolor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/resources/dye/dyepalette_replaceaoglcolor.cpp')
-rw-r--r--src/resources/dye/dyepalette_replaceaoglcolor.cpp126
1 files changed, 0 insertions, 126 deletions
diff --git a/src/resources/dye/dyepalette_replaceaoglcolor.cpp b/src/resources/dye/dyepalette_replaceaoglcolor.cpp
index 938d648eb..ec999812a 100644
--- a/src/resources/dye/dyepalette_replaceaoglcolor.cpp
+++ b/src/resources/dye/dyepalette_replaceaoglcolor.cpp
@@ -48,47 +48,6 @@ void DyePalette::replaceAOGLColorDefault(uint32_t *restrict pixels,
if ((sz % 2) != 0u)
-- it_end;
-#ifdef ENABLE_CILKPLUS
- cilk_for (int ptr = 0; ptr < bufSize; ptr ++)
- {
- uint8_t *const p = reinterpret_cast<uint8_t *>(&pixels[ptr]);
- const unsigned int data = pixels[ptr];
-
- STD_VECTOR<DyeColor>::const_iterator it = mColors.begin();
- while (it != it_end)
- {
- const DyeColor &col = *it;
- ++ it;
- const DyeColor &col2 = *it;
-
-#if SDL_BYTEORDER == SDL_BIG_ENDIAN
- const unsigned int coldata = (col.value[0] << 24U)
- | (col.value[1] << 16U)
- | (col.value[2] << 8U)
- | col.value[3];
-#else // SDL_BYTEORDER == SDL_BIG_ENDIAN
-
- const unsigned int coldata = (col.value[0])
- | (col.value[1] << 8U)
- | (col.value[2] << 16U)
- | (col.value[3] << 24U);
-#endif // SDL_BYTEORDER == SDL_BIG_ENDIAN
-
- if (data == coldata)
- {
- p[0] = col2.value[0];
- p[1] = col2.value[1];
- p[2] = col2.value[2];
- p[3] = col2.value[3];
- break;
- }
-
- ++ it;
- }
- }
-
-#else // ENABLE_CILKPLUS
-
for (const uint32_t *const p_end = pixels + CAST_SIZE(bufSize);
pixels != p_end;
++pixels)
@@ -128,7 +87,6 @@ void DyePalette::replaceAOGLColorDefault(uint32_t *restrict pixels,
++ it;
}
}
-#endif // ENABLE_CILKPLUS
}
#ifdef SIMD_SUPPORTED
@@ -182,47 +140,6 @@ void DyePalette::replaceAOGLColorSse2(uint32_t *restrict pixels,
}
else
{
-#ifdef ENABLE_CILKPLUS
- cilk_for (int ptr = 0; ptr < bufSize; ptr ++)
- {
- uint8_t *const p = reinterpret_cast<uint8_t *>(&pixels[ptr]);
- const unsigned int data = pixels[ptr];
-
- STD_VECTOR<DyeColor>::const_iterator it = mColors.begin();
- while (it != it_end)
- {
- const DyeColor &col = *it;
- ++ it;
- const DyeColor &col2 = *it;
-
-#if SDL_BYTEORDER == SDL_BIG_ENDIAN
- const unsigned int coldata = (col.value[0] << 24U)
- | (col.value[1] << 16U)
- | (col.value[2] << 8U)
- | col.value[3];
-#else // SDL_BYTEORDER == SDL_BIG_ENDIAN
-
- const unsigned int coldata = (col.value[0])
- | (col.value[1] << 8U)
- | (col.value[2] << 16U)
- | (col.value[3] << 24U);
-#endif // SDL_BYTEORDER == SDL_BIG_ENDIAN
-
- if (data == coldata)
- {
- p[0] = col2.value[0];
- p[1] = col2.value[1];
- p[2] = col2.value[2];
- p[3] = col2.value[3];
- break;
- }
-
- ++ it;
- }
- }
-
-#else // ENABLE_CILKPLUS
-
for (const uint32_t *const p_end = pixels + CAST_SIZE(bufSize);
pixels != p_end;
++pixels)
@@ -262,7 +179,6 @@ void DyePalette::replaceAOGLColorSse2(uint32_t *restrict pixels,
++ it;
}
}
-#endif // ENABLE_CILKPLUS
}
}
@@ -310,47 +226,6 @@ void DyePalette::replaceAOGLColorAvx2(uint32_t *restrict pixels,
}
else
{
-#ifdef ENABLE_CILKPLUS
- cilk_for (int ptr = 0; ptr < bufSize; ptr ++)
- {
- uint8_t *const p = reinterpret_cast<uint8_t *>(&pixels[ptr]);
- const unsigned int data = pixels[ptr];
-
- STD_VECTOR<DyeColor>::const_iterator it = mColors.begin();
- while (it != it_end)
- {
- const DyeColor &col = *it;
- ++ it;
- const DyeColor &col2 = *it;
-
-#if SDL_BYTEORDER == SDL_BIG_ENDIAN
- const unsigned int coldata = (col.value[0] << 24U)
- | (col.value[1] << 16U)
- | (col.value[2] << 8U)
- | col.value[3];
-#else // SDL_BYTEORDER == SDL_BIG_ENDIAN
-
- const unsigned int coldata = (col.value[0])
- | (col.value[1] << 8U)
- | (col.value[2] << 16U)
- | (col.value[3] << 24U);
-#endif // SDL_BYTEORDER == SDL_BIG_ENDIAN
-
- if (data == coldata)
- {
- p[0] = col2.value[0];
- p[1] = col2.value[1];
- p[2] = col2.value[2];
- p[3] = col2.value[3];
- break;
- }
-
- ++ it;
- }
- }
-
-#else // ENABLE_CILKPLUS
-
for (const uint32_t *const p_end = pixels + CAST_SIZE(bufSize);
pixels != p_end;
++pixels)
@@ -390,7 +265,6 @@ void DyePalette::replaceAOGLColorAvx2(uint32_t *restrict pixels,
++ it;
}
}
-#endif // ENABLE_CILKPLUS
}
}