mirror of
https://github.com/webmproject/libwebp.git
synced 2024-12-27 06:08:21 +01:00
dsp/alpha*.c: rework WEBP_USE_<arch> ifdef
add a dummy init rather than repeating the '#ifdef WEBP_USE_...' pattern. Change-Id: I9e7f187daffe1a3b1bc92953dce980c38d1a6269
This commit is contained in:
parent
e9570dd987
commit
80ff38130e
@ -124,16 +124,19 @@ static void MultARGBRow(uint32_t* const ptr, int width, int inverse) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // WEBP_USE_MIPS_DSP_R2
|
|
||||||
|
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
// Init function
|
// Entry point
|
||||||
|
|
||||||
extern void WebPInitAlphaProcessingMIPSdspR2(void);
|
extern void WebPInitAlphaProcessingMIPSdspR2(void);
|
||||||
|
|
||||||
WEBP_TSAN_IGNORE_FUNCTION void WebPInitAlphaProcessingMIPSdspR2(void) {
|
WEBP_TSAN_IGNORE_FUNCTION void WebPInitAlphaProcessingMIPSdspR2(void) {
|
||||||
#if defined(WEBP_USE_MIPS_DSP_R2)
|
|
||||||
WebPDispatchAlpha = DispatchAlpha;
|
WebPDispatchAlpha = DispatchAlpha;
|
||||||
WebPMultARGBRow = MultARGBRow;
|
WebPMultARGBRow = MultARGBRow;
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#else // !WEBP_USE_MIPS_DSP_R2
|
||||||
|
|
||||||
|
extern void WebPInitAlphaProcessingMIPSdspR2(void);
|
||||||
|
WEBP_TSAN_IGNORE_FUNCTION void WebPInitAlphaProcessingMIPSdspR2(void) {}
|
||||||
|
|
||||||
|
#endif // WEBP_USE_MIPS_DSP_R2
|
||||||
|
@ -277,20 +277,23 @@ static void MultRow(uint8_t* const ptr, const uint8_t* const alpha,
|
|||||||
if (width > 0) WebPMultRowC(ptr + x, alpha + x, width, inverse);
|
if (width > 0) WebPMultRowC(ptr + x, alpha + x, width, inverse);
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // WEBP_USE_SSE2
|
|
||||||
|
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
// Init function
|
// Entry point
|
||||||
|
|
||||||
extern void WebPInitAlphaProcessingSSE2(void);
|
extern void WebPInitAlphaProcessingSSE2(void);
|
||||||
|
|
||||||
WEBP_TSAN_IGNORE_FUNCTION void WebPInitAlphaProcessingSSE2(void) {
|
WEBP_TSAN_IGNORE_FUNCTION void WebPInitAlphaProcessingSSE2(void) {
|
||||||
#if defined(WEBP_USE_SSE2)
|
|
||||||
WebPMultARGBRow = MultARGBRow;
|
WebPMultARGBRow = MultARGBRow;
|
||||||
WebPMultRow = MultRow;
|
WebPMultRow = MultRow;
|
||||||
WebPApplyAlphaMultiply = ApplyAlphaMultiply;
|
WebPApplyAlphaMultiply = ApplyAlphaMultiply;
|
||||||
WebPDispatchAlpha = DispatchAlpha;
|
WebPDispatchAlpha = DispatchAlpha;
|
||||||
WebPDispatchAlphaToGreen = DispatchAlphaToGreen;
|
WebPDispatchAlphaToGreen = DispatchAlphaToGreen;
|
||||||
WebPExtractAlpha = ExtractAlpha;
|
WebPExtractAlpha = ExtractAlpha;
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#else // !WEBP_USE_SSE2
|
||||||
|
|
||||||
|
extern void WebPInitAlphaProcessingSSE2(void);
|
||||||
|
WEBP_TSAN_IGNORE_FUNCTION void WebPInitAlphaProcessingSSE2(void) {}
|
||||||
|
|
||||||
|
#endif // WEBP_USE_SSE2
|
||||||
|
Loading…
Reference in New Issue
Block a user