| OLD | NEW | 
|---|
| 1 /* | 1 /* | 
| 2  * Copyright (C) 2011 Google Inc. All rights reserved. | 2  * Copyright (C) 2011 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  * 1.  Redistributions of source code must retain the above copyright | 7  * 1.  Redistributions of source code must retain the above copyright | 
| 8  *     notice, this list of conditions and the following disclaimer. | 8  *     notice, this list of conditions and the following disclaimer. | 
| 9  * 2.  Redistributions in binary form must reproduce the above copyright | 9  * 2.  Redistributions in binary form must reproduce the above copyright | 
| 10  *     notice, this list of conditions and the following disclaimer in the | 10  *     notice, this list of conditions and the following disclaimer in the | 
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 63 | 63 | 
| 64     virtual bool isStarted() const = 0; | 64     virtual bool isStarted() const = 0; | 
| 65 | 65 | 
| 66     // Attempts to initialize a context to use for rendering. Returns false if t
     he context could not be created. | 66     // Attempts to initialize a context to use for rendering. Returns false if t
     he context could not be created. | 
| 67     // The context will not be used and no frames may be produced until initiali
     zeLayerRenderer() is called. | 67     // The context will not be used and no frames may be produced until initiali
     zeLayerRenderer() is called. | 
| 68     virtual bool initializeContext() = 0; | 68     virtual bool initializeContext() = 0; | 
| 69 | 69 | 
| 70     // Indicates that the compositing surface associated with our context is rea
     dy to use. | 70     // Indicates that the compositing surface associated with our context is rea
     dy to use. | 
| 71     virtual void setSurfaceReady() = 0; | 71     virtual void setSurfaceReady() = 0; | 
| 72 | 72 | 
|  | 73     virtual void setVisible(bool) = 0; | 
|  | 74 | 
| 73     // Attempts to initialize the layer renderer. Returns false if the context i
     sn't usable for compositing. | 75     // Attempts to initialize the layer renderer. Returns false if the context i
     sn't usable for compositing. | 
| 74     virtual bool initializeLayerRenderer() = 0; | 76     virtual bool initializeLayerRenderer() = 0; | 
| 75 | 77 | 
| 76     // Attempts to recreate the context and layer renderer after a context lost.
      Returns false if the renderer couldn't be | 78     // Attempts to recreate the context and layer renderer after a context lost.
      Returns false if the renderer couldn't be | 
| 77     // reinitialized. | 79     // reinitialized. | 
| 78     virtual bool recreateContext() = 0; | 80     virtual bool recreateContext() = 0; | 
| 79 | 81 | 
| 80     virtual int compositorIdentifier() const = 0; | 82     virtual int compositorIdentifier() const = 0; | 
| 81 | 83 | 
| 82     virtual const LayerRendererCapabilities& layerRendererCapabilities() const =
      0; | 84     virtual const LayerRendererCapabilities& layerRendererCapabilities() const =
      0; | 
| 83 | 85 | 
| 84     virtual void setNeedsAnimate() = 0; | 86     virtual void setNeedsAnimate() = 0; | 
| 85     virtual void setNeedsCommit() = 0; | 87     virtual void setNeedsCommit() = 0; | 
| 86     virtual void setNeedsForcedCommit() = 0; |  | 
| 87     virtual void setNeedsRedraw() = 0; | 88     virtual void setNeedsRedraw() = 0; | 
| 88 | 89 | 
| 89     virtual void didAddAnimation() = 0; | 90     virtual void didAddAnimation() = 0; | 
| 90 | 91 | 
| 91     virtual bool commitRequested() const = 0; | 92     virtual bool commitRequested() const = 0; | 
| 92 | 93 | 
| 93     virtual void start() = 0; // Must be called before using the proxy. | 94     virtual void start() = 0; // Must be called before using the proxy. | 
| 94     virtual void stop() = 0; // Must be called before deleting the proxy. | 95     virtual void stop() = 0; // Must be called before deleting the proxy. | 
| 95 | 96 | 
| 96     // Forces 3D commands on all contexts to wait for all previous SwapBuffers t
     o finish before executing in the GPU | 97     // Forces 3D commands on all contexts to wait for all previous SwapBuffers t
     o finish before executing in the GPU | 
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 142 #if !ASSERT_DISABLED | 143 #if !ASSERT_DISABLED | 
| 143         ASSERT(CCProxy::isMainThreadBlocked()); | 144         ASSERT(CCProxy::isMainThreadBlocked()); | 
| 144         CCProxy::setMainThreadBlocked(false); | 145         CCProxy::setMainThreadBlocked(false); | 
| 145 #endif | 146 #endif | 
| 146     } | 147     } | 
| 147 }; | 148 }; | 
| 148 | 149 | 
| 149 } | 150 } | 
| 150 | 151 | 
| 151 #endif | 152 #endif | 
| OLD | NEW | 
|---|