summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEmilian Peev <epeev@mm-sol.com>2011-10-06 16:06:30 +0300
committerDaniel Levin <dendy@ti.com>2012-07-25 08:55:35 -0500
commit99709df225531801a91561a0134fa79ced48c78f (patch)
tree5173bac43fd723ba7a06c12e24a1fbaf02c460f9
parent7f96fdfc375c32162273473e8272c64ba690b714 (diff)
downloadhardware_ti_omap4-99709df225531801a91561a0134fa79ced48c78f.zip
hardware_ti_omap4-99709df225531801a91561a0134fa79ced48c78f.tar.gz
hardware_ti_omap4-99709df225531801a91561a0134fa79ced48c78f.tar.bz2
CameraHAL: Fixes a small crop issue
- The offset variables 'mXOff' and 'mYOff' in ANativeDisplayAdapter are always initialized to zero. If the offset of the incoming preview buffer is zero and the viewable preview resolution is smaller than the actual preview buffer resolution, then the crop will not get configured properly. Signed-off-by: Emilian Peev <epeev@mm-sol.com> Signed-off-by: Vicky Martinez-DeFrain <a0869710@ti.com> Change-Id: Ib321f17566d253dd65dc4c6d20bf748a9a4c614b
-rw-r--r--camera/ANativeWindowDisplayAdapter.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/camera/ANativeWindowDisplayAdapter.cpp b/camera/ANativeWindowDisplayAdapter.cpp
index 4db5a8f..fa4e1d1 100644
--- a/camera/ANativeWindowDisplayAdapter.cpp
+++ b/camera/ANativeWindowDisplayAdapter.cpp
@@ -177,8 +177,8 @@ ANativeWindowDisplayAdapter::ANativeWindowDisplayAdapter():mDisplayThread(NULL),
mFailedDQs = 0;
mPaused = false;
- mXOff = 0;
- mYOff = 0;
+ mXOff = -1;
+ mYOff = -1;
mFirstInit = false;
mFD = -1;
@@ -454,8 +454,8 @@ int ANativeWindowDisplayAdapter::disableDisplay(bool cancel_buffer)
mDisplayEnabled = false;
///Reset the offset values
- mXOff = 0;
- mYOff = 0;
+ mXOff = -1;
+ mYOff = -1;
///Reset the frame width and height values
mFrameWidth =0;