Index: include/gpu/GrTypes.h |
diff --git a/include/gpu/GrTypes.h b/include/gpu/GrTypes.h |
index 3f02c62bfd07aab21c647c673beef0850a782c32..868c8fe7bb05c85ff4b721aac17e13fb74121d13 100644 |
--- a/include/gpu/GrTypes.h |
+++ b/include/gpu/GrTypes.h |
@@ -423,6 +423,18 @@ enum GrSurfaceOrigin { |
}; |
/** |
+ * Sample config clarifies the meaning of samples count. |
+ * In default kUnified_GrSampleConfig sample count refers to MSAA sample count. |
+ * If NV_framebuffer_mixed_samples is available and sample config is chosen to be |
+ * kStencil_GrSampleConfig, sample count refers to the stencil sample count only, |
+ * and the color sample count is assumed to be zero. |
+ */ |
+enum GrSampleConfig { |
+ kUnified_GrSampleConfig, |
+ kStencil_GrSampleConfig, |
+}; |
+ |
+/** |
* Describes a surface to be created. |
*/ |
struct GrSurfaceDesc { |
@@ -549,6 +561,13 @@ struct GrBackendRenderTargetDesc { |
*/ |
int fSampleCnt; |
/** |
+ * If fSampleCnt is > 1, which buffers are multisampled (color and stencil, |
+ * or just stencil?). The default is both. Note that mixing multisampled |
+ * and aliased buffers is only possible if NV_framebuffer_mixed_samples is |
+ * available. |
+ */ |
+ GrSampleConfig fSampleConfig; |
+ /** |
* Number of bits of stencil per-pixel. |
*/ |
int fStencilBits; |