Commit 1ffb04b4 authored by fbarchard@google.com's avatar fbarchard@google.com

Allow ScaleRowDown any functions to accept non-power of 2 for destination SIMD multiple.

BUG=none
TESTED=local unittests pass
R=bcornell@google.com

Review URL: https://webrtc-codereview.appspot.com/45129004

git-svn-id: http://libyuv.googlecode.com/svn/trunk@1379 16f28f9a-4ce2-e073-06de-1de4eb20be90
parent c8a2c236
......@@ -46,12 +46,13 @@ CANY(ScaleARGBFilterCols_Any_NEON, ScaleARGBFilterCols_NEON,
#define SDANY(NAMEANY, SCALEROWDOWN_SIMD, SCALEROWDOWN_C, FACTOR, BPP, MASK) \
void NAMEANY(const uint8* src_ptr, ptrdiff_t src_stride, \
uint8* dst_ptr, int dst_width) { \
int n = dst_width & ~MASK; \
int r = (int)((unsigned int)dst_width % (MASK + 1)); \
int n = dst_width - r; \
if (n > 0) { \
SCALEROWDOWN_SIMD(src_ptr, src_stride, dst_ptr, n); \
} \
SCALEROWDOWN_C(src_ptr + (n * FACTOR) * BPP, src_stride, \
dst_ptr + n * BPP, dst_width & MASK); \
dst_ptr + n * BPP, r); \
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment