diff options
author | Chris Craik <ccraik@google.com> | 2014-01-17 02:07:45 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2014-01-17 02:07:46 +0000 |
commit | ed0f7cba53be0af991fc7435549f7a798b1d377b (patch) | |
tree | ec88efeb25a565071e0272c643eb6c234737738e /libs | |
parent | ca10d38aef3a6867bdd1b5ab265ea4fd85de50eb (diff) | |
parent | cf8d9d4af3faecd804763d7c6f85b3f8741e180b (diff) | |
download | frameworks_base-ed0f7cba53be0af991fc7435549f7a798b1d377b.zip frameworks_base-ed0f7cba53be0af991fc7435549f7a798b1d377b.tar.gz frameworks_base-ed0f7cba53be0af991fc7435549f7a798b1d377b.tar.bz2 |
Merge "Fix view z translation with 3d projection disabled"
Diffstat (limited to 'libs')
-rw-r--r-- | libs/hwui/DisplayList.cpp | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/libs/hwui/DisplayList.cpp b/libs/hwui/DisplayList.cpp index d3d2613..a156341 100644 --- a/libs/hwui/DisplayList.cpp +++ b/libs/hwui/DisplayList.cpp @@ -418,11 +418,16 @@ void DisplayList::setViewProperties(OpenGLRenderer& renderer, T& handler, renderer.concatMatrix(mAnimationMatrix); } if (mMatrixFlags != 0) { - if (mMatrixFlags == TRANSLATION) { - renderer.translate(mTranslationX, mTranslationY, mTranslationZ); - } else { - if (Caches::getInstance().propertyEnable3d) { + if (Caches::getInstance().propertyEnable3d) { + if (mMatrixFlags == TRANSLATION) { + renderer.translate(mTranslationX, mTranslationY, mTranslationZ); + } else { renderer.concatMatrix(mTransform); + } + } else { + // avoid setting translationZ, use SkMatrix + if (mMatrixFlags == TRANSLATION) { + renderer.translate(mTranslationX, mTranslationY, 0); } else { renderer.concatMatrix(mTransformMatrix); } |