OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CONTENT_COMMON_GPU_IMAGE_TRANSPORT_SURFACE_H_ | 5 #ifndef CONTENT_COMMON_GPU_IMAGE_TRANSPORT_SURFACE_H_ |
6 #define CONTENT_COMMON_GPU_IMAGE_TRANSPORT_SURFACE_H_ | 6 #define CONTENT_COMMON_GPU_IMAGE_TRANSPORT_SURFACE_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #if defined(ENABLE_GPU) | 9 #if defined(ENABLE_GPU) |
10 | 10 |
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
102 void SendResizeView(const gfx::Size& size); | 102 void SendResizeView(const gfx::Size& size); |
103 | 103 |
104 // Whether or not we should execute more commands. | 104 // Whether or not we should execute more commands. |
105 void SetScheduled(bool is_scheduled); | 105 void SetScheduled(bool is_scheduled); |
106 | 106 |
107 void DeferToFence(base::Closure task); | 107 void DeferToFence(base::Closure task); |
108 | 108 |
109 // Make the surface's context current. | 109 // Make the surface's context current. |
110 bool MakeCurrent(); | 110 bool MakeCurrent(); |
111 | 111 |
| 112 void Suspend(); |
| 113 |
112 private: | 114 private: |
113 gpu::GpuScheduler* Scheduler(); | 115 gpu::GpuScheduler* Scheduler(); |
114 gpu::gles2::GLES2Decoder* Decoder(); | 116 gpu::gles2::GLES2Decoder* Decoder(); |
115 | 117 |
116 // IPC::Message handlers. | 118 // IPC::Message handlers. |
117 void OnNewSurfaceACK(uint64 surface_handle, TransportDIB::Handle shm_handle); | 119 void OnNewSurfaceACK(uint64 surface_handle, TransportDIB::Handle shm_handle); |
118 void OnBuffersSwappedACK(); | 120 void OnBuffersSwappedACK(); |
119 void OnPostSubBufferACK(); | 121 void OnPostSubBufferACK(); |
120 void OnResizeViewACK(); | 122 void OnResizeViewACK(); |
121 | 123 |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
164 private: | 166 private: |
165 scoped_ptr<ImageTransportHelper> helper_; | 167 scoped_ptr<ImageTransportHelper> helper_; |
166 gfx::Size new_size_; | 168 gfx::Size new_size_; |
167 | 169 |
168 DISALLOW_COPY_AND_ASSIGN(PassThroughImageTransportSurface); | 170 DISALLOW_COPY_AND_ASSIGN(PassThroughImageTransportSurface); |
169 }; | 171 }; |
170 | 172 |
171 #endif // defined(ENABLE_GPU) | 173 #endif // defined(ENABLE_GPU) |
172 | 174 |
173 #endif // CONTENT_COMMON_GPU_IMAGE_TRANSPORT_SURFACE_H_ | 175 #endif // CONTENT_COMMON_GPU_IMAGE_TRANSPORT_SURFACE_H_ |
OLD | NEW |