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

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

Issue 2632593003: Notify listeners on OffScreenCanvas changes (Closed)
Patch Set: Created 3 years, 10 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
« no previous file with comments | « third_party/WebKit/Source/platform/graphics/OffscreenCanvasPlaceholder.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef SkiaTextureHolder_h 5 #ifndef SkiaTextureHolder_h
6 #define SkiaTextureHolder_h 6 #define SkiaTextureHolder_h
7 7
8 #include "platform/PlatformExport.h" 8 #include "platform/PlatformExport.h"
9 #include "platform/graphics/TextureHolder.h" 9 #include "platform/graphics/TextureHolder.h"
10 10
11 namespace blink { 11 namespace blink {
12 12
13 class PLATFORM_EXPORT SkiaTextureHolder final : public TextureHolder { 13 class PLATFORM_EXPORT SkiaTextureHolder final : public TextureHolder {
14 public: 14 public:
15 ~SkiaTextureHolder() override; 15 ~SkiaTextureHolder() override;
16 16
17 // Methods overriding TextureHolder
18 void updateSyncToken(gpu::SyncToken) override {}
19
17 bool isSkiaTextureHolder() final { return true; } 20 bool isSkiaTextureHolder() final { return true; }
18 bool isMailboxTextureHolder() final { return false; } 21 bool isMailboxTextureHolder() final { return false; }
19 unsigned sharedContextId() final; 22 unsigned sharedContextId() final;
20 IntSize size() const final { 23 IntSize size() const final {
21 return IntSize(m_image->width(), m_image->height()); 24 return IntSize(m_image->width(), m_image->height());
22 } 25 }
23 bool currentFrameKnownToBeOpaque(Image::MetadataMode) final { 26 bool currentFrameKnownToBeOpaque(Image::MetadataMode) final {
24 return m_image->isOpaque(); 27 return m_image->isOpaque();
25 } 28 }
26 29
(...skipping 14 matching lines...) Expand all
41 44
42 // The m_image should always be texture-backed 45 // The m_image should always be texture-backed
43 sk_sp<SkImage> m_image; 46 sk_sp<SkImage> m_image;
44 // Id of the shared context where m_image was created 47 // Id of the shared context where m_image was created
45 unsigned m_sharedContextId = 0; 48 unsigned m_sharedContextId = 0;
46 }; 49 };
47 50
48 } // namespace blink 51 } // namespace blink
49 52
50 #endif // SkiaTextureHolder_h 53 #endif // SkiaTextureHolder_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/platform/graphics/OffscreenCanvasPlaceholder.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698