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

Side by Side Diff: public/platform/WebExternalTextureLayerClient.h

Issue 369043003: Let canvas decide how to handle the case of resource lost reported by client: 2D part (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: re-order logical operator for contextLost Created 6 years, 5 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 | « Source/platform/graphics/gpu/DrawingBuffer.cpp ('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 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 25 matching lines...) Expand all
36 struct WebExternalTextureMailbox; 36 struct WebExternalTextureMailbox;
37 37
38 class BLINK_PLATFORM_EXPORT WebExternalTextureLayerClient { 38 class BLINK_PLATFORM_EXPORT WebExternalTextureLayerClient {
39 public: 39 public:
40 // Returns true and provides a mailbox if a new frame is available. If the W ebExternalBitmap 40 // Returns true and provides a mailbox if a new frame is available. If the W ebExternalBitmap
41 // isn't 0, then it should also be filled in with the contents of this frame . 41 // isn't 0, then it should also be filled in with the contents of this frame .
42 // Returns false if no new data is available and the old mailbox and bitmap are to be reused. 42 // Returns false if no new data is available and the old mailbox and bitmap are to be reused.
43 virtual bool prepareMailbox(WebExternalTextureMailbox*, WebExternalBitmap* = 0) = 0; 43 virtual bool prepareMailbox(WebExternalTextureMailbox*, WebExternalBitmap* = 0) = 0;
44 44
45 // Notifies the client when a mailbox is no longer in use by the compositor and provides 45 // Notifies the client when a mailbox is no longer in use by the compositor and provides
46 // a sync point to wait on before the mailbox could be consumes again by the client. 46 // a sync point to wait on before the mailbox could be consumes again by the client. The
47 virtual void mailboxReleased(const WebExternalTextureMailbox&) = 0; 47 // boolean flag indicates if the mailbox resource is treated as lost by clie nt.
48 // FIXME(hmin): Remove the default value for lostResource once the chromium part CL at
49 // https://codereview.chromium.org/369823002 is landed.
50 virtual void mailboxReleased(const WebExternalTextureMailbox&, bool lostReso urce = false) = 0;
48 51
49 protected: 52 protected:
50 virtual ~WebExternalTextureLayerClient() { } 53 virtual ~WebExternalTextureLayerClient() { }
51 }; 54 };
52 55
53 } // namespace blink 56 } // namespace blink
54 57
55 #endif // WebExternalTextureLayerClient_h 58 #endif // WebExternalTextureLayerClient_h
OLDNEW
« no previous file with comments | « Source/platform/graphics/gpu/DrawingBuffer.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698