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 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
119 void tryToRecreateContext(); | 119 void tryToRecreateContext(); |
120 | 120 |
121 // Called on impl thread | 121 // Called on impl thread |
122 struct ReadbackRequest { | 122 struct ReadbackRequest { |
123 CCCompletionEvent completion; | 123 CCCompletionEvent completion; |
124 bool success; | 124 bool success; |
125 void* pixels; | 125 void* pixels; |
126 IntRect rect; | 126 IntRect rect; |
127 }; | 127 }; |
128 void forceBeginFrameOnImplThread(CCCompletionEvent*); | 128 void forceBeginFrameOnImplThread(CCCompletionEvent*); |
129 void beginFrameCompleteOnImplThread(CCCompletionEvent*, PassOwnPtr<CCTexture
UpdateQueue>); | 129 void beginFrameCompleteOnImplThread(CCCompletionEvent*, PassOwnPtr<CCTexture
UpdateQueue>, bool contentsTexturesWereDeleted); |
130 void beginFrameAbortedOnImplThread(); | 130 void beginFrameAbortedOnImplThread(); |
131 void requestReadbackOnImplThread(ReadbackRequest*); | 131 void requestReadbackOnImplThread(ReadbackRequest*); |
132 void requestStartPageScaleAnimationOnImplThread(IntSize targetPosition, bool
useAnchor, float scale, double durationSec); | 132 void requestStartPageScaleAnimationOnImplThread(IntSize targetPosition, bool
useAnchor, float scale, double durationSec); |
133 void finishAllRenderingOnImplThread(CCCompletionEvent*); | 133 void finishAllRenderingOnImplThread(CCCompletionEvent*); |
134 void initializeImplOnImplThread(CCCompletionEvent*); | 134 void initializeImplOnImplThread(CCCompletionEvent*); |
135 void setSurfaceReadyOnImplThread(); | 135 void setSurfaceReadyOnImplThread(); |
136 void setVisibleOnImplThread(CCCompletionEvent*, bool); | 136 void setVisibleOnImplThread(CCCompletionEvent*, bool); |
137 void initializeContextOnImplThread(CCGraphicsContext*); | 137 void initializeContextOnImplThread(CCGraphicsContext*); |
138 void initializeLayerRendererOnImplThread(CCCompletionEvent*, bool* initializ
eSucceeded, LayerRendererCapabilities*); | 138 void initializeLayerRendererOnImplThread(CCCompletionEvent*, bool* initializ
eSucceeded, LayerRendererCapabilities*); |
139 void layerTreeHostClosedOnImplThread(CCCompletionEvent*); | 139 void layerTreeHostClosedOnImplThread(CCCompletionEvent*); |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
177 ReadbackRequest* m_readbackRequestOnImplThread; | 177 ReadbackRequest* m_readbackRequestOnImplThread; |
178 | 178 |
179 // Set when the main thread is waiting on a commit to complete. | 179 // Set when the main thread is waiting on a commit to complete. |
180 CCCompletionEvent* m_commitCompletionEventOnImplThread; | 180 CCCompletionEvent* m_commitCompletionEventOnImplThread; |
181 | 181 |
182 // Set when the main thread is waiting on layers to be drawn. | 182 // Set when the main thread is waiting on layers to be drawn. |
183 CCCompletionEvent* m_textureAcquisitionCompletionEventOnImplThread; | 183 CCCompletionEvent* m_textureAcquisitionCompletionEventOnImplThread; |
184 | 184 |
185 OwnPtr<CCTextureUpdateController> m_currentTextureUpdateControllerOnImplThre
ad; | 185 OwnPtr<CCTextureUpdateController> m_currentTextureUpdateControllerOnImplThre
ad; |
186 | 186 |
| 187 // Set when we need to reset the contentsTexturesPurged flag after the |
| 188 // commit. |
| 189 bool m_resetContentsTexturesPurgedAfterCommitOnImplThread; |
| 190 |
187 // Set when the next draw should post didCommitAndDrawFrame to the main thre
ad. | 191 // Set when the next draw should post didCommitAndDrawFrame to the main thre
ad. |
188 bool m_nextFrameIsNewlyCommittedFrameOnImplThread; | 192 bool m_nextFrameIsNewlyCommittedFrameOnImplThread; |
189 | 193 |
190 bool m_renderVSyncEnabled; | 194 bool m_renderVSyncEnabled; |
191 }; | 195 }; |
192 | 196 |
193 } | 197 } |
194 | 198 |
195 #endif | 199 #endif |
OLD | NEW |