gpu_tonemapper: Tonemap unaligned width and height of source
GPU tonemapper should tonemap only the source pixels within unaligned
width and height. The aligned width and height of the source buffer
can have padding due to alignment requirements, hence GPU tonemapper
should not tonemap on the aligned width and height of the source.
CRs-Fixed: 2048764
Change-Id: I71e9dcca6da2be9663053adc744f9958cc5c1148
diff --git a/gpu_tonemapper/EGLImageWrapper.cpp b/gpu_tonemapper/EGLImageWrapper.cpp
index 84f4343..dfc16d8 100644
--- a/gpu_tonemapper/EGLImageWrapper.cpp
+++ b/gpu_tonemapper/EGLImageWrapper.cpp
@@ -121,7 +121,7 @@
}
android::sp<android::GraphicBuffer> graphicBuffer =
- new android::GraphicBuffer(src->width, src->height, src->format,
+ new android::GraphicBuffer(src->unaligned_width, src->unaligned_height, src->format,
#ifndef __NOUGAT__
1, // Layer count
#endif