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

Unified Diff: cc/quads/shared_quad_state.cc

Issue 2502373003: stop using SkXfermode -- use SkBlendMode instead (Closed)
Patch Set: rebase Created 4 years, 1 month 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 | « cc/quads/shared_quad_state.h ('k') | cc/quads/texture_draw_quad.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/quads/shared_quad_state.cc
diff --git a/cc/quads/shared_quad_state.cc b/cc/quads/shared_quad_state.cc
index cd75f947396c4f99271c47bbcc25aa0bad0bd4f8..de2d75e722ce0cd85675e9b3d3e19b654830342e 100644
--- a/cc/quads/shared_quad_state.cc
+++ b/cc/quads/shared_quad_state.cc
@@ -9,15 +9,15 @@
#include "base/values.h"
#include "cc/base/math_util.h"
#include "cc/debug/traced_value.h"
+#include "third_party/skia/include/core/SkBlendMode.h"
namespace cc {
SharedQuadState::SharedQuadState()
: is_clipped(false),
opacity(0.f),
- blend_mode(SkXfermode::kSrcOver_Mode),
- sorting_context_id(0) {
-}
+ blend_mode(SkBlendMode::kSrcOver),
+ sorting_context_id(0) {}
SharedQuadState::SharedQuadState(const SharedQuadState& other) = default;
@@ -33,7 +33,7 @@ void SharedQuadState::SetAll(const gfx::Transform& quad_to_target_transform,
const gfx::Rect& clip_rect,
bool is_clipped,
float opacity,
- SkXfermode::Mode blend_mode,
+ SkBlendMode blend_mode,
int sorting_context_id) {
this->quad_to_target_transform = quad_to_target_transform;
this->quad_layer_bounds = quad_layer_bounds;
@@ -56,7 +56,7 @@ void SharedQuadState::AsValueInto(base::trace_event::TracedValue* value) const {
MathUtil::AddToTracedValue("clip_rect", clip_rect, value);
value->SetDouble("opacity", opacity);
- value->SetString("blend_mode", SkXfermode::ModeName(blend_mode));
+ value->SetString("blend_mode", SkBlendMode_Name(blend_mode));
TracedValue::MakeDictIntoImplicitSnapshotWithCategory(
TRACE_DISABLED_BY_DEFAULT("cc.debug.quads"),
value,
« no previous file with comments | « cc/quads/shared_quad_state.h ('k') | cc/quads/texture_draw_quad.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698