summaryrefslogtreecommitdiffstats
path: root/Source/WebCore/platform/graphics/android/rendering/ShaderProgram.h
diff options
context:
space:
mode:
authorTeng-Hui Zhu <ztenghui@google.com>2012-04-16 10:07:31 -0700
committerTeng-Hui Zhu <ztenghui@google.com>2012-04-16 11:23:54 -0700
commit8fef2be984d1ec0e21a2efb0228702ea44993ed4 (patch)
tree40b034148cf2083f2676e5d0603e7dd5181911bc /Source/WebCore/platform/graphics/android/rendering/ShaderProgram.h
parent868c42d56aae84ed4cd33f9de0d93132e1483ddc (diff)
downloadexternal_webkit-8fef2be984d1ec0e21a2efb0228702ea44993ed4.zip
external_webkit-8fef2be984d1ec0e21a2efb0228702ea44993ed4.tar.gz
external_webkit-8fef2be984d1ec0e21a2efb0228702ea44993ed4.tar.bz2
Move the common matrix computation to higher level
Now we don't need to compute the same thing for each tile any more. bug:6338456 Change-Id: I68e744ab7af2bb55a67047bc16aeb8659b26daf2
Diffstat (limited to 'Source/WebCore/platform/graphics/android/rendering/ShaderProgram.h')
-rw-r--r--Source/WebCore/platform/graphics/android/rendering/ShaderProgram.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/WebCore/platform/graphics/android/rendering/ShaderProgram.h b/Source/WebCore/platform/graphics/android/rendering/ShaderProgram.h
index 41f5e70..b44c563 100644
--- a/Source/WebCore/platform/graphics/android/rendering/ShaderProgram.h
+++ b/Source/WebCore/platform/graphics/android/rendering/ShaderProgram.h
@@ -159,7 +159,7 @@ public:
private:
GLuint loadShader(GLenum shaderType, const char* pSource);
GLint createProgram(const char* vertexSource, const char* fragmentSource);
- GLfloat* getProjectionMatrix(const DrawQuadData* data);
+ GLfloat* getTileProjectionMatrix(const DrawQuadData* data);
void setBlendingState(bool enableBlending);
void drawQuadInternal(ShaderType type, const GLfloat* matrix, int textureId,
float opacity, GLenum textureTarget, GLenum filter,
@@ -167,7 +167,7 @@ private:
Color shaderColor(Color pureColor, float opacity);
ShaderType getTextureShaderType(GLenum textureTarget);
void resetBlending();
-
+ void setupSurfaceProjectionMatrix();
#if DEBUG_MATRIX
FloatRect debugMatrixTransform(const TransformationMatrix& matrix, const char* matrixName);
void debugMatrixInfo(float currentScale,
@@ -179,6 +179,7 @@ private:
bool m_blendingEnabled;
+ TransformationMatrix m_surfaceProjectionMatrix;
TransformationMatrix m_clipProjectionMatrix;
TransformationMatrix m_visibleRectProjectionMatrix;
GLuint m_textureBuffer[1];