[go: nahoru, domu]

cc: Use SkMultiPicture for GPU rasterization

GpuRasterWorkerPool holds an SkMultiPicture, the RasterBufferImpl is
created with a pointer to SkMultiPicture, and returns the
SkPictureRecorder's canvas when AquireSkCanvas is called.  When the
canvas is released, we get the surface canvas and pass it to the
multipicture along with the recorded picture.

When we're finished with all of the tiles, we draw the multipicture.

Updated Picture::Raster() to call canvas->drawPicture(), instead of
picture->draw().  This is required to prevent parsing the skia ops
twice when using the multipicturedraw, since picture->draw() always
parses the ops, whereas canvas->drawPicture() might parse the ops,
or it might simply place the whole picture on the canvas (as it will
for the recorder's canvas)

BUG=skia:2315

Review URL: https://codereview.chromium.org/595553002

Cr-Commit-Position: refs/heads/master@{#296227}
3 files changed