Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(20)

Unified Diff: include/gpu/GrRenderTarget.h

Issue 1232103002: Enable stencil clipping in mixed sampled render targets (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Predefined sample locations, glcaps, render target priv Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: include/gpu/GrRenderTarget.h
diff --git a/include/gpu/GrRenderTarget.h b/include/gpu/GrRenderTarget.h
index 2309dbd876f6cf4e9d58b715730088045e83fb65..24ca6603db0f0e13bb420165604e58fa0c31f787 100644
--- a/include/gpu/GrRenderTarget.h
+++ b/include/gpu/GrRenderTarget.h
@@ -81,6 +81,13 @@ public:
}
/**
+ * @return the number of actual raster samples-per-pixel, or zero if non-MSAA.
+ */
+ int numRasterSamples() const {
+ return fStencilAttachment ? this->numStencilSamples() : this->numColorSamples();
+ }
+
+ /**
* @return true if the surface is mixed sampled, false otherwise.
*/
bool hasMixedSamples() const {
@@ -175,6 +182,11 @@ private:
GrStencilAttachment* fStencilAttachment;
SampleConfig fSampleConfig;
+ // Configures sample locations to be either default or programmable, if MSAA.
+ bool fProgrammableSampleLocationsEnabled;
+ // True if sample locations colocated at pixel center are currently in use, false if default
+ // sample locations are currently in use.
+ bool fUsesCenteredSampleLocations;
SkIRect fResolveRect;
« no previous file with comments | « include/gpu/GrCaps.h ('k') | include/gpu/gl/GrGLFunctions.h » ('j') | src/gpu/gl/GrGLDefines.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698