aboutsummaryrefslogtreecommitdiff
path: root/include/libyuv/planar_functions.h
diff options
context:
space:
mode:
authorFrank Barchard <fbarchard@google.com>2017-09-11 11:52:20 -0700
committerFrank Barchard <fbarchard@google.com>2017-09-11 21:02:04 +0000
commit1e16cb5c386b42dc831b3f897d291a764ea5f63f (patch)
treeaee2b89b14f3266de2a9535f19eb0efd2e2f3354 /include/libyuv/planar_functions.h
parent367c0d8f81a1e26b3349cf71c328518b0fa71a53 (diff)
downloadlibyuv-1e16cb5c386b42dc831b3f897d291a764ea5f63f.tar.gz
SplitRGBPlane and MergeRGBPlane functions added
Converts packed RGB to planar and back. TBR=kjellander@chromium.org BUG=libyuv:728 TEST=MergeRGBPlane_Opt and SplitRGBPlane_Opt unittests added Change-Id: Ida59af940afcb1fc4a48bbf62c714f592665c3cc Reviewed-on: https://chromium-review.googlesource.com/658069 Reviewed-by: Frank Barchard <fbarchard@google.com> Reviewed-by: Cheng Wang <wangcheng@google.com>
Diffstat (limited to 'include/libyuv/planar_functions.h')
-rw-r--r--include/libyuv/planar_functions.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/include/libyuv/planar_functions.h b/include/libyuv/planar_functions.h
index 040839c2..d97965cb 100644
--- a/include/libyuv/planar_functions.h
+++ b/include/libyuv/planar_functions.h
@@ -69,6 +69,32 @@ void MergeUVPlane(const uint8* src_u,
int width,
int height);
+// Split interleaved RGB plane into separate R, G and B planes.
+LIBYUV_API
+void SplitRGBPlane(const uint8* src_rgb,
+ int src_stride_rgb,
+ uint8* dst_r,
+ int dst_stride_r,
+ uint8* dst_g,
+ int dst_stride_g,
+ uint8* dst_b,
+ int dst_stride_b,
+ int width,
+ int height);
+
+// Merge separate R, G and B planes into one interleaved RGB plane.
+LIBYUV_API
+void MergeRGBPlane(const uint8* src_r,
+ int src_stride_r,
+ const uint8* src_g,
+ int src_stride_g,
+ const uint8* src_b,
+ int src_stride_b,
+ uint8* dst_rgb,
+ int dst_stride_rgb,
+ int width,
+ int height);
+
// Copy I400. Supports inverting.
LIBYUV_API
int I400ToI400(const uint8* src_y,