summaryrefslogtreecommitdiff
path: root/libs/ui/GraphicBufferMapper.cpp
diff options
context:
space:
mode:
author Chih-Hung Hsieh <chh@google.com> 2017-10-05 13:51:32 -0700
committer Chih-Hung Hsieh <chh@google.com> 2017-10-13 16:12:08 -0700
commitd66be0ae6929fee064a229d6c6bac3a871aba137 (patch)
treeedf6df30381838963d504cc4e0e68a7ec8f515b9 /libs/ui/GraphicBufferMapper.cpp
parentafee092bee459332c8d577163794581c3128df4f (diff)
Use -Werror in frameworks/native/libs/gui and ui
* Remove unused variable and function. * Suppress warning of unused return results. Bug: 66996870 Test: build with WITH_TIDY=1 Change-Id: If6f445be1e7677a37bf780844a79b84d6d7e1c1e
Diffstat (limited to 'libs/ui/GraphicBufferMapper.cpp')
-rw-r--r--libs/ui/GraphicBufferMapper.cpp23
1 files changed, 0 insertions, 23 deletions
diff --git a/libs/ui/GraphicBufferMapper.cpp b/libs/ui/GraphicBufferMapper.cpp
index 5b0e7f6020..d5a30d7023 100644
--- a/libs/ui/GraphicBufferMapper.cpp
+++ b/libs/ui/GraphicBufferMapper.cpp
@@ -125,29 +125,6 @@ status_t GraphicBufferMapper::lockAsync(buffer_handle_t handle,
return static_cast<status_t>(error);
}
-static inline bool isValidYCbCrPlane(const android_flex_plane_t& plane) {
- if (plane.bits_per_component != 8) {
- ALOGV("Invalid number of bits per component: %d",
- plane.bits_per_component);
- return false;
- }
- if (plane.bits_used != 8) {
- ALOGV("Invalid number of bits used: %d", plane.bits_used);
- return false;
- }
-
- bool hasValidIncrement = plane.h_increment == 1 ||
- (plane.component != FLEX_COMPONENT_Y && plane.h_increment == 2);
- hasValidIncrement = hasValidIncrement && plane.v_increment > 0;
- if (!hasValidIncrement) {
- ALOGV("Invalid increment: h %d v %d", plane.h_increment,
- plane.v_increment);
- return false;
- }
-
- return true;
-}
-
status_t GraphicBufferMapper::lockAsyncYCbCr(buffer_handle_t handle,
uint32_t usage, const Rect& bounds, android_ycbcr *ycbcr, int fenceFd)
{