diff options
| author | 2015-07-10 12:58:53 +0000 | |
|---|---|---|
| committer | 2015-07-10 12:58:53 +0000 | |
| commit | 434b577fa7c42115d24c1cc9b13c698bc3b0860c (patch) | |
| tree | b9cfd06294aa460ad4c089338d67ac7a35c275d6 /libs/hwui/OpenGLRenderer.h | |
| parent | 7478bc13084c1d3ab798116c7194c142aab2b4e2 (diff) | |
| parent | 8ac76504feb4837ea524b2e62a0bd04c1e266d9a (diff) | |
am 8ac76504: am 9613e9b7: Merge "New setLocalMatrix() operation for HWUI" into mnc-dev
* commit '8ac76504feb4837ea524b2e62a0bd04c1e266d9a':
New setLocalMatrix() operation for HWUI
Diffstat (limited to 'libs/hwui/OpenGLRenderer.h')
| -rwxr-xr-x | libs/hwui/OpenGLRenderer.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/libs/hwui/OpenGLRenderer.h b/libs/hwui/OpenGLRenderer.h index 800a9f9cf18f..402f6edd475d 100755 --- a/libs/hwui/OpenGLRenderer.h +++ b/libs/hwui/OpenGLRenderer.h @@ -368,6 +368,7 @@ public: void getMatrix(SkMatrix* outMatrix) const { mState.getMatrix(outMatrix); } void setMatrix(const SkMatrix& matrix) { mState.setMatrix(matrix); } + void setLocalMatrix(const SkMatrix& matrix); void concatMatrix(const SkMatrix& matrix) { mState.concatMatrix(matrix); } void translate(float dx, float dy, float dz = 0.0f); @@ -418,6 +419,8 @@ public: return returnPath; } + void setBaseTransform(const Matrix4& matrix) { mBaseTransform = matrix; } + protected: /** * Perform the setup specific to a frame. This method does not @@ -877,6 +880,16 @@ private: // Paths kept alive for the duration of the frame std::vector<std::unique_ptr<SkPath>> mTempPaths; + /** + * Initial transform for a rendering pass; transform from global device + * coordinates to the current RenderNode's drawing content coordinates, + * with the RenderNode's RenderProperty transforms already applied. + * Calling setMatrix(mBaseTransform) will result in drawing at the origin + * of the DisplayList's recorded surface prior to any Canvas + * transformation. + */ + Matrix4 mBaseTransform; + friend class Layer; friend class TextDrawFunctor; friend class DrawBitmapOp; |