Index: src/gpu/gl/GrGLGpu.h |
diff --git a/src/gpu/gl/GrGLGpu.h b/src/gpu/gl/GrGLGpu.h |
index d802f08b75b236ce6a8820a82e50b7a565fbd97d..409aae8f43da64a3d11f35f7af5002b344ea43ca 100644 |
--- a/src/gpu/gl/GrGLGpu.h |
+++ b/src/gpu/gl/GrGLGpu.h |
@@ -283,6 +283,7 @@ private: |
void flushStencil(const GrStencilSettings&); |
void flushHWAAState(GrRenderTarget* rt, bool useHWAA); |
+ void generateConfigTable(); |
bool configToGLFormats(GrPixelConfig config, |
bool getSizedInternal, |
GrGLenum* internalFormat, |
@@ -500,6 +501,19 @@ private: |
} |
} fHWBlendState; |
+ TriState fMSAAEnabled; |
+ |
+ GrStencilSettings fHWStencilSettings; |
+ TriState fHWStencilTestEnabled; |
+ |
+ |
+ GrPipelineBuilder::DrawFace fHWDrawFace; |
+ TriState fHWWriteToColor; |
+ uint32_t fHWBoundRenderTargetUniqueID; |
+ TriState fHWSRGBFramebuffer; |
+ SkTArray<uint32_t, true> fHWBoundTextureUniqueIDs; |
bsalomon
2015/12/16 19:10:45
just moved this stuff to be within the ///@} below
|
+ ///@} |
+ |
/** IDs for copy surface program. */ |
struct { |
GrGLuint fProgram; |
@@ -525,19 +539,16 @@ private: |
} |
} |
- TriState fMSAAEnabled; |
- |
- GrStencilSettings fHWStencilSettings; |
- TriState fHWStencilTestEnabled; |
- |
- |
- GrPipelineBuilder::DrawFace fHWDrawFace; |
- TriState fHWWriteToColor; |
- uint32_t fHWBoundRenderTargetUniqueID; |
- TriState fHWSRGBFramebuffer; |
- SkTArray<uint32_t, true> fHWBoundTextureUniqueIDs; |
+ struct ConfigEntry { |
+ // Default constructor inits to known bad GL enum values. |
+ ConfigEntry() { memset(this, 0xAB, sizeof(ConfigEntry)); } |
+ GrGLenum fBaseInternalFormat; |
+ GrGLenum fSizedInternalFormat; |
+ GrGLenum fExternalFormat; |
+ GrGLenum fExternalType; |
+ }; |
- ///@} |
+ ConfigEntry fConfigTable[kLast_GrPixelConfig + 1]; |
egdaniel
2015/12/16 19:19:08
Why not have this configTable live on the caps ins
bsalomon
2015/12/16 19:21:20
Yes, as noted in description, this is the first st
|
// Mapping of pixel configs to known supported stencil formats to be used |
// when adding a stencil buffer to a framebuffer. |