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 #include "GrGLCaps.h" | 9 #include "GrGLCaps.h" |
10 | 10 |
(...skipping 330 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
341 ctxInfo.hasExtension("GL_OES_standard_derivatives"); | 341 ctxInfo.hasExtension("GL_OES_standard_derivatives"); |
342 } | 342 } |
343 | 343 |
344 // We need dual source blending and the ability to disable multisample in or der to support mixed | 344 // We need dual source blending and the ability to disable multisample in or der to support mixed |
345 // samples in every corner case. | 345 // samples in every corner case. |
346 if (fMultisampleDisableSupport && glslCaps->fDualSourceBlendingSupport) { | 346 if (fMultisampleDisableSupport && glslCaps->fDualSourceBlendingSupport) { |
347 // We understand "mixed samples" to mean the collective capability of 3 different extensions | 347 // We understand "mixed samples" to mean the collective capability of 3 different extensions |
348 glslCaps->fMixedSamplesSupport = | 348 glslCaps->fMixedSamplesSupport = |
349 ctxInfo.hasExtension("GL_NV_framebuffer_mixed_samples") && | 349 ctxInfo.hasExtension("GL_NV_framebuffer_mixed_samples") && |
350 ctxInfo.hasExtension("GL_NV_sample_mask_override_coverage") && | 350 ctxInfo.hasExtension("GL_NV_sample_mask_override_coverage") && |
351 ctxInfo.hasExtension("GL_EXT_raster_multisample"); | 351 ctxInfo.hasExtension("GL_EXT_raster_multisample") && |
352 ctxInfo.hasExtension("GL_NV_sample_locations"); | |
Chris Dalton
2015/09/22 08:35:24
With our current plans to just put basic mixed sam
| |
352 } | 353 } |
353 // Workaround NVIDIA bug related to glInvalidateFramebuffer and mixed sample s. | 354 // Workaround NVIDIA bug related to glInvalidateFramebuffer and mixed sample s. |
354 if (kNVIDIA_GrGLDriver == ctxInfo.driver() && fShaderCaps->mixedSamplesSuppo rt()) { | 355 if (kNVIDIA_GrGLDriver == ctxInfo.driver() && fShaderCaps->mixedSamplesSuppo rt()) { |
355 fDiscardRenderTargetSupport = false; | 356 fDiscardRenderTargetSupport = false; |
356 fInvalidateFBType = kNone_InvalidateFBType; | 357 fInvalidateFBType = kNone_InvalidateFBType; |
357 } | 358 } |
358 | 359 |
359 /************************************************************************** | 360 /************************************************************************** |
360 * GrCaps fields | 361 * GrCaps fields |
361 **************************************************************************/ | 362 **************************************************************************/ |
(...skipping 830 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1192 for (int p = 0; p < kGrSLPrecisionCount; ++p) { | 1193 for (int p = 0; p < kGrSLPrecisionCount; ++p) { |
1193 glslCaps->fFloatPrecisions[kGeometry_GrShaderType][p] = | 1194 glslCaps->fFloatPrecisions[kGeometry_GrShaderType][p] = |
1194 glslCaps->fFloatPrecisions[kVerte x_GrShaderType][p]; | 1195 glslCaps->fFloatPrecisions[kVerte x_GrShaderType][p]; |
1195 } | 1196 } |
1196 } | 1197 } |
1197 } | 1198 } |
1198 | 1199 |
1199 | 1200 |
1200 | 1201 |
1201 | 1202 |
OLD | NEW |