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

Unified Diff: src/gpu/GrOptDrawState.cpp

Issue 678953002: Default geometry processor (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: fix dm bug Created 6 years, 2 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/GrOptDrawState.cpp
diff --git a/src/gpu/GrOptDrawState.cpp b/src/gpu/GrOptDrawState.cpp
index 77a9fc8dc454a25672d849f9ec8d5fb1f10c2081..efec551bfeb4c15ff3fa806217912a845cf169c4 100644
--- a/src/gpu/GrOptDrawState.cpp
+++ b/src/gpu/GrOptDrawState.cpp
@@ -9,6 +9,7 @@
#include "GrDrawState.h"
#include "GrDrawTargetCaps.h"
+#include "GrDefaultGeoProcFactory.h"
GrOptDrawState::GrOptDrawState(const GrDrawState& drawState,
BlendOptFlags blendOptFlags,
@@ -58,7 +59,9 @@ GrOptDrawState::GrOptDrawState(const GrDrawState& drawState,
if (drawState.hasGeometryProcessor()) {
fGeometryProcessor.initAndRef(drawState.fGeometryProcessor);
} else {
- fGeometryProcessor.reset(NULL);
+ // Install default GP, this will be ignored if we are rendering with fragment shader only
+ // TODO(joshualitt) processors should do this themselves
+ fGeometryProcessor.reset(GrDefaultGeoProcFactory::Create());
}
// Copy Color Stages from DS to ODS

Powered by Google App Engine
This is Rietveld 408576698