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

Side by Side Diff: third_party/WebKit/Source/platform/graphics/UnacceleratedImageBufferSurface.h

Issue 2822263004: Remove PaintCanvas::writePixels (Closed)
Patch Set: rm-writepixels: rmdcheck Created 3 years, 8 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2013, Google Inc. All rights reserved. 2 * Copyright (c) 2013, Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 UnacceleratedImageBufferSurface( 46 UnacceleratedImageBufferSurface(
47 const IntSize&, 47 const IntSize&,
48 OpacityMode = kNonOpaque, 48 OpacityMode = kNonOpaque,
49 ImageInitializationMode = kInitializeImagePixels, 49 ImageInitializationMode = kInitializeImagePixels,
50 const CanvasColorParams& = CanvasColorParams(kLegacyCanvasColorSpace, 50 const CanvasColorParams& = CanvasColorParams(kLegacyCanvasColorSpace,
51 kRGBA8CanvasPixelFormat)); 51 kRGBA8CanvasPixelFormat));
52 ~UnacceleratedImageBufferSurface() override; 52 ~UnacceleratedImageBufferSurface() override;
53 53
54 PaintCanvas* Canvas() override; 54 PaintCanvas* Canvas() override;
55 bool IsValid() const override; 55 bool IsValid() const override;
56 bool WritePixels(const SkImageInfo& orig_info,
57 const void* pixels,
58 size_t row_bytes,
59 int x,
60 int y) override;
56 61
57 sk_sp<SkImage> NewImageSnapshot(AccelerationHint, SnapshotReason) override; 62 sk_sp<SkImage> NewImageSnapshot(AccelerationHint, SnapshotReason) override;
58 63
59 private: 64 private:
60 sk_sp<SkSurface> surface_; 65 sk_sp<SkSurface> surface_;
61 std::unique_ptr<PaintCanvas> canvas_; 66 std::unique_ptr<PaintCanvas> canvas_;
62 }; 67 };
63 68
64 } // namespace blink 69 } // namespace blink
65 70
66 #endif 71 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698