aboutsummaryrefslogtreecommitdiff
path: root/source/row_common.cc
diff options
context:
space:
mode:
authorJustin Green <greenjustin@google.com>2022-02-03 11:46:44 -0500
committerlibyuv LUCI CQ <libyuv-scoped@luci-project-accounts.iam.gserviceaccount.com>2022-02-03 17:01:49 +0000
commitb4ddbaf549a1bf5572bf703fd2862d1eb7380c6a (patch)
tree9e0a90646de7b1c50f40e3aeb452f749d297561b /source/row_common.cc
parent804980bbab748fd0e180cd6e7d9292ff49baf704 (diff)
downloadlibyuv-b4ddbaf549a1bf5572bf703fd2862d1eb7380c6a.tar.gz
Add support for MM21.
Add support for MM21 to NV12 and I420 conversion, and add SIMD optimizations for arm, aarch64, SSE2, and SSSE3 machines. Bug: libyuv:915, b/215425056 Change-Id: Iecb0c33287f35766a6169d4adf3b7397f1ba8b5d Reviewed-on: https://chromium-review.googlesource.com/c/libyuv/libyuv/+/3433269 Reviewed-by: Frank Barchard <fbarchard@chromium.org> Commit-Queue: Justin Green <greenjustin@google.com>
Diffstat (limited to 'source/row_common.cc')
-rw-r--r--source/row_common.cc24
1 files changed, 24 insertions, 0 deletions
diff --git a/source/row_common.cc b/source/row_common.cc
index 84b395b6..3e5f419d 100644
--- a/source/row_common.cc
+++ b/source/row_common.cc
@@ -2674,6 +2674,30 @@ void DetileRow_C(const uint8_t* src,
}
}
+void DetileSplitUVRow_C(const uint8_t* src_uv,
+ ptrdiff_t src_tile_stride,
+ uint8_t* dst_u,
+ uint8_t* dst_v,
+ int width) {
+ int tile;
+ for (tile = 0; tile < width / 16; tile++) {
+ for (int x = 0; x < 8; x++) {
+ *dst_u++ = src_uv[0];
+ *dst_v++ = src_uv[1];
+ src_uv += 2;
+ }
+ src_uv += src_tile_stride - 16;
+ }
+ for (int x = 0; x < (width & 0xF) / 2; ++x) {
+ *dst_u = *src_uv;
+ dst_u++;
+ src_uv++;
+ *dst_v = *src_uv;
+ dst_v++;
+ src_uv++;
+ }
+}
+
void SplitUVRow_C(const uint8_t* src_uv,
uint8_t* dst_u,
uint8_t* dst_v,