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

Unified Diff: src/gpu/gl/GrGLProgramDesc.cpp

Issue 1717393002: Add "sample locations" feature to GrProcessor (Closed) Base URL: https://skia.googlesource.com/skia.git@upload_getmultisamp
Patch Set: addressed comments Created 4 years, 10 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: src/gpu/gl/GrGLProgramDesc.cpp
diff --git a/src/gpu/gl/GrGLProgramDesc.cpp b/src/gpu/gl/GrGLProgramDesc.cpp
index a2dea8739206cbcab2e356ca4e4c4e49da865502..e4ad0b1b089194011b3097284de7b2d9a6427c5b 100644
--- a/src/gpu/gl/GrGLProgramDesc.cpp
+++ b/src/gpu/gl/GrGLProgramDesc.cpp
@@ -163,6 +163,13 @@ bool GrGLProgramDescBuilder::Build(GrProgramDesc* desc,
header->fSnapVerticesToPixelCenters = pipeline.snapVerticesToPixelCenters();
header->fColorEffectCnt = pipeline.numColorFragmentProcessors();
header->fCoverageEffectCnt = pipeline.numCoverageFragmentProcessors();
+
+ if (pipeline.hasSampleLocations()) {
+ header->fSamplePatternKey = pipeline.getSamplePatternID();
+ } else {
+ header->fSamplePatternKey = 0;
+ }
+
glDesc->finalize();
return true;
}

Powered by Google App Engine
This is Rietveld 408576698