Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(955)

Unified Diff: src/gpu/gl/GrGpuGL.h

Issue 25846002: Use vertexless shaders when NVpr is available (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Fix mac build Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/gl/GrGLShaderBuilder.cpp ('k') | src/gpu/gl/GrGpuGL.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/gl/GrGpuGL.h
diff --git a/src/gpu/gl/GrGpuGL.h b/src/gpu/gl/GrGpuGL.h
index b0195bbaed5b04e2039088cdc986f6184ebc10b9..a59654a0f8af792798a418cf6b35f7991879fd04 100644
--- a/src/gpu/gl/GrGpuGL.h
+++ b/src/gpu/gl/GrGpuGL.h
@@ -37,8 +37,19 @@ public:
GrGLVersion glVersion() const { return fGLContext.info().version(); }
GrGLSLGeneration glslGeneration() const { return fGLContext.info().glslGeneration(); }
- // Used by GrGLProgram to bind necessary textures for GrGLEffects.
+ // Used by GrGLProgram and GrGLTexGenProgramEffects to configure OpenGL state.
void bindTexture(int unitIdx, const GrTextureParams& params, GrGLTexture* texture);
+ void setProjectionMatrix(const SkMatrix& matrix,
+ const SkISize& renderTargetSize,
+ GrSurfaceOrigin renderTargetOrigin);
+ enum TexGenComponents {
+ kS_TexGenComponents = 1,
+ kST_TexGenComponents = 2,
+ kSTR_TexGenComponents = 3
+ };
+ void enableTexGen(int unitIdx, TexGenComponents, const GrGLfloat* coefficients);
+ void enableTexGen(int unitIdx, TexGenComponents, const SkMatrix& matrix);
+ void disableUnusedTexGen(int numUsedTexCoordSets);
bool programUnitTest(int maxStages);
@@ -213,9 +224,6 @@ private:
#endif
};
- // sets the matrix for path stenciling (uses the GL fixed pipe matrices)
- void flushPathStencilMatrix();
-
// flushes dithering, color-mask, and face culling stat
void flushMiscFixedFunctionState();
@@ -432,6 +440,14 @@ private:
TriState fHWDitherEnabled;
GrRenderTarget* fHWBoundRenderTarget;
SkTArray<GrTexture*, true> fHWBoundTextures;
+
+ struct TexGenData {
+ GrGLenum fMode;
+ GrGLint fNumComponents;
+ GrGLfloat fCoefficients[3 * 3];
+ };
+ int fHWActiveTexGenSets;
+ SkTArray<TexGenData, true> fHWTexGenSettings;
///@}
// we record what stencil format worked last time to hopefully exit early
« no previous file with comments | « src/gpu/gl/GrGLShaderBuilder.cpp ('k') | src/gpu/gl/GrGpuGL.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698