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

Side by Side Diff: src/gpu/gl/GrGpuGL.h

Issue 15331003: fix slowness of getImageData() for CanvasRenderingContext2D in linux due to un-optimized format for… (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: patch preferredReadPixelsConfig() Created 7 years, 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/gpu/GrGpu.h ('k') | src/gpu/gl/GrGpuGL.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2011 Google Inc. 2 * Copyright 2011 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 8
9 9
10 #ifndef GrGpuGL_DEFINED 10 #ifndef GrGpuGL_DEFINED
(...skipping 26 matching lines...) Expand all
37 GrGLBinding glBinding() const { return fGLContext.info().binding(); } 37 GrGLBinding glBinding() const { return fGLContext.info().binding(); }
38 GrGLVersion glVersion() const { return fGLContext.info().version(); } 38 GrGLVersion glVersion() const { return fGLContext.info().version(); }
39 GrGLSLGeneration glslGeneration() const { return fGLContext.info().glslGener ation(); } 39 GrGLSLGeneration glslGeneration() const { return fGLContext.info().glslGener ation(); }
40 40
41 // Used by GrGLProgram to bind necessary textures for GrGLEffects. 41 // Used by GrGLProgram to bind necessary textures for GrGLEffects.
42 void bindTexture(int unitIdx, const GrTextureParams& params, GrGLTexture* te xture); 42 void bindTexture(int unitIdx, const GrTextureParams& params, GrGLTexture* te xture);
43 43
44 bool programUnitTest(int maxStages); 44 bool programUnitTest(int maxStages);
45 45
46 // GrGpu overrides 46 // GrGpu overrides
47 virtual GrPixelConfig preferredReadPixelsConfig(GrPixelConfig config) const SK_OVERRIDE; 47 virtual GrPixelConfig preferredReadPixelsConfig(GrPixelConfig readConfig, Gr PixelConfig targetConfig) const SK_OVERRIDE;
48 virtual GrPixelConfig preferredWritePixelsConfig(GrPixelConfig config) const SK_OVERRIDE; 48 virtual GrPixelConfig preferredWritePixelsConfig(GrPixelConfig writeConfig, GrPixelConfig targetConfig) const SK_OVERRIDE;
49 virtual bool canWriteTexturePixels(const GrTexture*, GrPixelConfig srcConfig ) const SK_OVERRIDE; 49 virtual bool canWriteTexturePixels(const GrTexture*, GrPixelConfig srcConfig ) const SK_OVERRIDE;
50 virtual bool readPixelsWillPayForYFlip( 50 virtual bool readPixelsWillPayForYFlip(
51 GrRenderTarget* renderTarget, 51 GrRenderTarget* renderTarget,
52 int left, int top, 52 int left, int top,
53 int width, int height, 53 int width, int height,
54 GrPixelConfig config, 54 GrPixelConfig config,
55 size_t rowBytes) const SK_OVERRIDE; 55 size_t rowBytes) const SK_OVERRIDE;
56 virtual bool fullReadPixelsIsFasterThanPartial() const SK_OVERRIDE; 56 virtual bool fullReadPixelsIsFasterThanPartial() const SK_OVERRIDE;
57 57
58 virtual void initCopySurfaceDstDesc(const GrSurface* src, GrTextureDesc* des c) SK_OVERRIDE; 58 virtual void initCopySurfaceDstDesc(const GrSurface* src, GrTextureDesc* des c) SK_OVERRIDE;
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after
438 ///@} 438 ///@}
439 439
440 // we record what stencil format worked last time to hopefully exit early 440 // we record what stencil format worked last time to hopefully exit early
441 // from our loop that tries stencil formats and calls check fb status. 441 // from our loop that tries stencil formats and calls check fb status.
442 int fLastSuccessfulStencilFmtIdx; 442 int fLastSuccessfulStencilFmtIdx;
443 443
444 typedef GrGpu INHERITED; 444 typedef GrGpu INHERITED;
445 }; 445 };
446 446
447 #endif 447 #endif
OLDNEW
« no previous file with comments | « src/gpu/GrGpu.h ('k') | src/gpu/gl/GrGpuGL.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698