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

Side by Side Diff: Source/platform/graphics/ImageBufferSurface.h

Issue 429643002: Add non-blocking frame rate limiting logic to display list 2D canvas (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 4 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 | Annotate | Revision Log
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 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 Opaque, 53 Opaque,
54 }; 54 };
55 55
56 class PLATFORM_EXPORT ImageBufferSurface { 56 class PLATFORM_EXPORT ImageBufferSurface {
57 WTF_MAKE_NONCOPYABLE(ImageBufferSurface); WTF_MAKE_FAST_ALLOCATED; 57 WTF_MAKE_NONCOPYABLE(ImageBufferSurface); WTF_MAKE_FAST_ALLOCATED;
58 public: 58 public:
59 virtual ~ImageBufferSurface() { } 59 virtual ~ImageBufferSurface() { }
60 60
61 virtual SkCanvas* canvas() const = 0; 61 virtual SkCanvas* canvas() const = 0;
62 virtual const SkBitmap& bitmap(); 62 virtual const SkBitmap& bitmap();
63 virtual void willUse() { } // Called by ImageBuffer before reading or writin g to the surface. 63 virtual void didDraw() { }
64 virtual void willReadback() { } 64 virtual void willReadback() { }
65 virtual bool isValid() const = 0; 65 virtual bool isValid() const = 0;
66 virtual bool restore() { return false; }; 66 virtual bool restore() { return false; };
67 virtual blink::WebLayer* layer() const { return 0; }; 67 virtual blink::WebLayer* layer() const { return 0; };
68 virtual bool isAccelerated() const { return false; } 68 virtual bool isAccelerated() const { return false; }
69 virtual Platform3DObject getBackingTexture() const { return 0; } 69 virtual Platform3DObject getBackingTexture() const { return 0; }
70 virtual bool cachedBitmapEnabled() const { return false; } 70 virtual bool cachedBitmapEnabled() const { return false; }
71 virtual const SkBitmap& cachedBitmap() const; 71 virtual const SkBitmap& cachedBitmap() const;
72 virtual void invalidateCachedBitmap() { } 72 virtual void invalidateCachedBitmap() { }
73 virtual void updateCachedBitmapIfNeeded() { } 73 virtual void updateCachedBitmapIfNeeded() { }
(...skipping 11 matching lines...) Expand all
85 void clear(); 85 void clear();
86 86
87 private: 87 private:
88 OpacityMode m_opacityMode; 88 OpacityMode m_opacityMode;
89 IntSize m_size; 89 IntSize m_size;
90 }; 90 };
91 91
92 } // namespace blink 92 } // namespace blink
93 93
94 #endif 94 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698