Skip to content

Commit

Permalink
Use SkStrikeServer::makeAnalysisCanvas() instead of canvas subclass d…
Browse files Browse the repository at this point in the history
…irectly

This lets Skia remove the SkTextBlobCacheDiffCanvas and switch the
analysis canvas to just SkCanvas backed by the analysis device. This
will let drawn text blobs with image filters automatically see the
modified transform produced by the base canvases auto-layer for filters.

Bug: 1187246
Change-Id: I29da3759e276ed664ac68bc4b7b16b0a12a70ed2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2846901
Auto-Submit: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Vasiliy Telezhnikov <vasilyt@chromium.org>
Reviewed-by: Vasiliy Telezhnikov <vasilyt@chromium.org>
Cr-Commit-Position: refs/heads/master@{#877181}
  • Loading branch information
lhkbob authored and Chromium LUCI CQ committed Apr 28, 2021
1 parent 895d69a commit a11b1d0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cc/paint/paint_op_buffer_serializer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,11 @@ std::unique_ptr<SkCanvas> MakeAnalysisCanvas(
const int kMaxExtent = std::numeric_limits<int>::max() >> 1;

return options.strike_server
? std::make_unique<SkTextBlobCacheDiffCanvas>(
? options.strike_server->makeAnalysisCanvas(
kMaxExtent, kMaxExtent,
skia::LegacyDisplayGlobals::ComputeSurfaceProps(
options.can_use_lcd_text),
options.strike_server, options.color_space,
options.color_space,
options.context_supports_distance_field_text)
: std::make_unique<SkNoDrawCanvas>(kMaxExtent, kMaxExtent);
}
Expand Down

0 comments on commit a11b1d0

Please sign in to comment.