summaryrefslogtreecommitdiff
path: root/chromium/cc/playback/skip_image_canvas.h
blob: 67206b7cb91991b73225ef89506c5aeca187b9bb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
// Copyright 2016 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef CC_PLAYBACK_SKIP_IMAGE_CANVAS_H_
#define CC_PLAYBACK_SKIP_IMAGE_CANVAS_H_

#include "third_party/skia/include/utils/SkPaintFilterCanvas.h"

namespace cc {

class SkipImageCanvas : public SkPaintFilterCanvas {
 public:
  explicit SkipImageCanvas(SkCanvas* canvas);

 private:
  bool onFilter(SkTCopyOnFirstWrite<SkPaint>* paint, Type type) const override;

  void onDrawPicture(const SkPicture* picture,
                     const SkMatrix* matrix,
                     const SkPaint* paint) override;
};

}  // namespace cc

#endif  // CC_PLAYBACK_SKIP_IMAGE_CANVAS_H_