OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 #ifndef GrGLCaps_DEFINED | 9 #ifndef GrGLCaps_DEFINED |
10 #define GrGLCaps_DEFINED | 10 #define GrGLCaps_DEFINED |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
58 * Instead the texture is multisampled when bound to the FBO and then re solved automatically | 58 * Instead the texture is multisampled when bound to the FBO and then re solved automatically |
59 * when read. It also defines an alternate value for GL_MAX_SAMPLES (whi ch we call | 59 * when read. It also defines an alternate value for GL_MAX_SAMPLES (whi ch we call |
60 * GR_GL_MAX_SAMPLES_IMG). | 60 * GR_GL_MAX_SAMPLES_IMG). |
61 */ | 61 */ |
62 kES_IMG_MsToTexture_MSFBOType, | 62 kES_IMG_MsToTexture_MSFBOType, |
63 /** | 63 /** |
64 * GL_EXT_multisampled_render_to_texture. Same as the IMG one above but uses the standard | 64 * GL_EXT_multisampled_render_to_texture. Same as the IMG one above but uses the standard |
65 * GL_MAX_SAMPLES value. | 65 * GL_MAX_SAMPLES value. |
66 */ | 66 */ |
67 kES_EXT_MsToTexture_MSFBOType, | 67 kES_EXT_MsToTexture_MSFBOType, |
68 /** | |
69 * GL_NV_framebuffer_mixed_samples. | |
70 */ | |
71 kStencil_MSFBOType, | |
bsalomon
2015/03/31 16:37:33
Maybe we should call this something a little more
Chris Dalton
2015/03/31 19:47:30
I really like the name "MixedSamples" too. I'd lik
vbuzinov
2015/04/02 13:10:37
Done.
| |
68 | 72 |
69 kLast_MSFBOType = kES_EXT_MsToTexture_MSFBOType | 73 kLast_MSFBOType = kStencil_MSFBOType |
70 }; | 74 }; |
71 | 75 |
72 enum InvalidateFBType { | 76 enum InvalidateFBType { |
73 kNone_InvalidateFBType, | 77 kNone_InvalidateFBType, |
74 kDiscard_InvalidateFBType, //<! glDiscardFramebuffer() | 78 kDiscard_InvalidateFBType, //<! glDiscardFramebuffer() |
75 kInvalidate_InvalidateFBType, //<! glInvalidateFramebuffer() | 79 kInvalidate_InvalidateFBType, //<! glInvalidateFramebuffer() |
76 | 80 |
77 kLast_InvalidateFBType = kInvalidate_InvalidateFBType | 81 kLast_InvalidateFBType = kInvalidate_InvalidateFBType |
78 }; | 82 }; |
79 | 83 |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
146 * Reports the type of MSAA FBO support. | 150 * Reports the type of MSAA FBO support. |
147 */ | 151 */ |
148 MSFBOType msFBOType() const { return fMSFBOType; } | 152 MSFBOType msFBOType() const { return fMSFBOType; } |
149 | 153 |
150 /** | 154 /** |
151 * Does the supported MSAA FBO extension have MSAA renderbuffers? | 155 * Does the supported MSAA FBO extension have MSAA renderbuffers? |
152 */ | 156 */ |
153 bool usesMSAARenderBuffers() const { | 157 bool usesMSAARenderBuffers() const { |
154 return kNone_MSFBOType != fMSFBOType && | 158 return kNone_MSFBOType != fMSFBOType && |
155 kES_IMG_MsToTexture_MSFBOType != fMSFBOType && | 159 kES_IMG_MsToTexture_MSFBOType != fMSFBOType && |
156 kES_EXT_MsToTexture_MSFBOType != fMSFBOType; | 160 kES_EXT_MsToTexture_MSFBOType != fMSFBOType && |
161 kStencil_MSFBOType != fMSFBOType; | |
157 } | 162 } |
158 | 163 |
159 /** | 164 /** |
160 * Is the MSAA FBO extension one where the texture is multisampled when boun d to an FBO and | 165 * Is the MSAA FBO extension one where the texture is multisampled when boun d to an FBO and |
161 * then implicitly resolved when read. | 166 * then implicitly resolved when read. |
162 */ | 167 */ |
163 bool usesImplicitMSAAResolve() const { | 168 bool usesImplicitMSAAResolve() const { |
164 return kES_IMG_MsToTexture_MSFBOType == fMSFBOType || | 169 return kES_IMG_MsToTexture_MSFBOType == fMSFBOType || |
165 kES_EXT_MsToTexture_MSFBOType == fMSFBOType; | 170 kES_EXT_MsToTexture_MSFBOType == fMSFBOType; |
166 } | 171 } |
(...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
411 } | 416 } |
412 }; | 417 }; |
413 | 418 |
414 mutable SkTHashMap<ReadPixelsSupportedFormat, bool, ReadPixelsSupportedForma t::Hash> | 419 mutable SkTHashMap<ReadPixelsSupportedFormat, bool, ReadPixelsSupportedForma t::Hash> |
415 fReadPixelsSupportedCache; | 420 fReadPixelsSupportedCache; |
416 | 421 |
417 typedef GrDrawTargetCaps INHERITED; | 422 typedef GrDrawTargetCaps INHERITED; |
418 }; | 423 }; |
419 | 424 |
420 #endif | 425 #endif |
OLD | NEW |