| OLD | NEW |
| 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 #ifndef GrGLGpu_DEFINED | 8 #ifndef GrGLGpu_DEFINED |
| 9 #define GrGLGpu_DEFINED | 9 #define GrGLGpu_DEFINED |
| 10 | 10 |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 SkASSERT(glCaps().shaderCaps()->pathRenderingSupport()); | 53 SkASSERT(glCaps().shaderCaps()->pathRenderingSupport()); |
| 54 return static_cast<GrGLPathRendering*>(pathRendering()); | 54 return static_cast<GrGLPathRendering*>(pathRendering()); |
| 55 } | 55 } |
| 56 | 56 |
| 57 void discard(GrRenderTarget*) override; | 57 void discard(GrRenderTarget*) override; |
| 58 | 58 |
| 59 // Used by GrGLProgram to configure OpenGL state. | 59 // Used by GrGLProgram to configure OpenGL state. |
| 60 void bindTexture(int unitIdx, const GrTextureParams& params, bool allowSRGBI
nputs, | 60 void bindTexture(int unitIdx, const GrTextureParams& params, bool allowSRGBI
nputs, |
| 61 GrGLTexture* texture); | 61 GrGLTexture* texture); |
| 62 | 62 |
| 63 void bindTexelBuffer(int unitIdx, intptr_t offsetInBytes, GrPixelConfig, GrG
LBuffer*); | 63 void bindTexelBuffer(int unitIdx, GrPixelConfig, GrGLBuffer*); |
| 64 | 64 |
| 65 bool onGetReadPixelsInfo(GrSurface* srcSurface, int readWidth, int readHeigh
t, size_t rowBytes, | 65 bool onGetReadPixelsInfo(GrSurface* srcSurface, int readWidth, int readHeigh
t, size_t rowBytes, |
| 66 GrPixelConfig readConfig, DrawPreference*, | 66 GrPixelConfig readConfig, DrawPreference*, |
| 67 ReadPixelTempDrawInfo*) override; | 67 ReadPixelTempDrawInfo*) override; |
| 68 | 68 |
| 69 bool onGetWritePixelsInfo(GrSurface* dstSurface, int width, int height, | 69 bool onGetWritePixelsInfo(GrSurface* dstSurface, int width, int height, |
| 70 GrPixelConfig srcConfig, DrawPreference*, | 70 GrPixelConfig srcConfig, DrawPreference*, |
| 71 WritePixelTempDrawInfo*) override; | 71 WritePixelTempDrawInfo*) override; |
| 72 | 72 |
| 73 bool initCopySurfaceDstDesc(const GrSurface* src, GrSurfaceDesc* desc) const
override; | 73 bool initCopySurfaceDstDesc(const GrSurface* src, GrSurfaceDesc* desc) const
override; |
| (...skipping 427 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 501 TriState fHWSRGBFramebuffer; | 501 TriState fHWSRGBFramebuffer; |
| 502 SkTArray<uint32_t, true> fHWBoundTextureUniqueIDs; | 502 SkTArray<uint32_t, true> fHWBoundTextureUniqueIDs; |
| 503 | 503 |
| 504 struct BufferTexture { | 504 struct BufferTexture { |
| 505 BufferTexture() : fTextureID(0), fKnownBound(false), | 505 BufferTexture() : fTextureID(0), fKnownBound(false), |
| 506 fAttachedBufferUniqueID(SK_InvalidUniqueID), | 506 fAttachedBufferUniqueID(SK_InvalidUniqueID), |
| 507 fSwizzle(GrSwizzle::RGBA()) {} | 507 fSwizzle(GrSwizzle::RGBA()) {} |
| 508 | 508 |
| 509 GrGLuint fTextureID; | 509 GrGLuint fTextureID; |
| 510 bool fKnownBound; | 510 bool fKnownBound; |
| 511 intptr_t fOffsetInBytes; | |
| 512 GrPixelConfig fTexelConfig; | 511 GrPixelConfig fTexelConfig; |
| 513 size_t fAttachedSizeInBytes; | |
| 514 uint32_t fAttachedBufferUniqueID; | 512 uint32_t fAttachedBufferUniqueID; |
| 515 GrSwizzle fSwizzle; | 513 GrSwizzle fSwizzle; |
| 516 }; | 514 }; |
| 517 | 515 |
| 518 SkTArray<BufferTexture, true> fHWBufferTextures; | 516 SkTArray<BufferTexture, true> fHWBufferTextures; |
| 519 int fHWMaxUsedBufferTextureUnit; | 517 int fHWMaxUsedBufferTextureUnit; |
| 520 | 518 |
| 521 // EXT_raster_multisample. | 519 // EXT_raster_multisample. |
| 522 TriState fHWRasterMultisampleEnabled; | 520 TriState fHWRasterMultisampleEnabled; |
| 523 int fHWNumRasterSamples; | 521 int fHWNumRasterSamples; |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 562 bool fHWPLSEnabled; | 560 bool fHWPLSEnabled; |
| 563 bool fPLSHasBeenUsed; | 561 bool fPLSHasBeenUsed; |
| 564 | 562 |
| 565 float fHWMinSampleShading; | 563 float fHWMinSampleShading; |
| 566 | 564 |
| 567 typedef GrGpu INHERITED; | 565 typedef GrGpu INHERITED; |
| 568 friend class GrGLPathRendering; // For accessing setTextureUnit. | 566 friend class GrGLPathRendering; // For accessing setTextureUnit. |
| 569 }; | 567 }; |
| 570 | 568 |
| 571 #endif | 569 #endif |
| OLD | NEW |