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

Unified Diff: tools/debugger/SkDrawCommand.cpp

Issue 2396953002: Revert[8] "replace SkXfermode obj with SkBlendMode enum in paints" (Closed)
Patch Set: add tmp virtual to unroll legacy arithmodes Created 4 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
« no previous file with comments | « tools/debugger/SkDebugCanvas.cpp ('k') | tools/sk_tool_utils.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/debugger/SkDrawCommand.cpp
diff --git a/tools/debugger/SkDrawCommand.cpp b/tools/debugger/SkDrawCommand.cpp
index ba6302ca3adcb1529b05a9e9a5598fa8b6375959..156ca4f74da4c8d3144f9e2e77222e2723f50519 100644
--- a/tools/debugger/SkDrawCommand.cpp
+++ b/tools/debugger/SkDrawCommand.cpp
@@ -1116,16 +1116,6 @@ static void apply_paint_shader(const SkPaint& paint, Json::Value* target,
}
}
-static void apply_paint_xfermode(const SkPaint& paint, Json::Value* target,
- UrlDataManager& urlDataManager) {
- SkFlattenable* xfermode = paint.getXfermode();
- if (xfermode != nullptr) {
- Json::Value jsonXfermode;
- SkDrawCommand::flatten(xfermode, &jsonXfermode, urlDataManager);
- (*target)[SKDEBUGCANVAS_ATTRIBUTE_XFERMODE] = jsonXfermode;
- }
-}
-
static void apply_paint_imagefilter(const SkPaint& paint, Json::Value* target,
UrlDataManager& urlDataManager) {
SkFlattenable* imageFilter = paint.getImageFilter();
@@ -1177,7 +1167,6 @@ Json::Value SkDrawCommand::MakeJsonPaint(const SkPaint& paint, UrlDataManager& u
apply_paint_patheffect(paint, &result, urlDataManager);
apply_paint_maskfilter(paint, &result, urlDataManager);
apply_paint_shader(paint, &result, urlDataManager);
- apply_paint_xfermode(paint, &result, urlDataManager);
apply_paint_looper(paint, &result, urlDataManager);
apply_paint_imagefilter(paint, &result, urlDataManager);
apply_paint_colorfilter(paint, &result, urlDataManager);
@@ -1246,17 +1235,6 @@ static void extract_json_paint_colorfilter(Json::Value& jsonPaint, UrlDataManage
}
}
-static void extract_json_paint_xfermode(Json::Value& jsonPaint, UrlDataManager& urlDataManager,
- SkPaint* target) {
- if (jsonPaint.isMember(SKDEBUGCANVAS_ATTRIBUTE_XFERMODE)) {
- Json::Value jsonXfermode = jsonPaint[SKDEBUGCANVAS_ATTRIBUTE_XFERMODE];
- sk_sp<SkXfermode> xfermode((SkXfermode*) load_flattenable(jsonXfermode, urlDataManager));
- if (xfermode != nullptr) {
- target->setXfermode(xfermode);
- }
- }
-}
-
static void extract_json_paint_looper(Json::Value& jsonPaint, UrlDataManager& urlDataManager,
SkPaint* target) {
if (jsonPaint.isMember(SKDEBUGCANVAS_ATTRIBUTE_LOOPER)) {
@@ -1503,7 +1481,6 @@ static void extract_json_paint(Json::Value& paint, UrlDataManager& urlDataManage
extract_json_paint_patheffect(paint, urlDataManager, result);
extract_json_paint_maskfilter(paint, urlDataManager, result);
extract_json_paint_colorfilter(paint, urlDataManager, result);
- extract_json_paint_xfermode(paint, urlDataManager, result);
extract_json_paint_looper(paint, urlDataManager, result);
extract_json_paint_imagefilter(paint, urlDataManager, result);
extract_json_paint_typeface(paint, urlDataManager, result);
« no previous file with comments | « tools/debugger/SkDebugCanvas.cpp ('k') | tools/sk_tool_utils.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698