| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 GPU_COMMAND_BUFFER_CLIENT_CONTEXT_SUPPORT_H_ | 5 #ifndef GPU_COMMAND_BUFFER_CLIENT_CONTEXT_SUPPORT_H_ |
| 6 #define GPU_COMMAND_BUFFER_CLIENT_CONTEXT_SUPPORT_H_ | 6 #define GPU_COMMAND_BUFFER_CLIENT_CONTEXT_SUPPORT_H_ |
| 7 | 7 |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 #include "ui/gfx/buffer_types.h" |
| 9 #include "ui/gfx/overlay_transform.h" | 10 #include "ui/gfx/overlay_transform.h" |
| 10 | 11 |
| 11 namespace gfx { | 12 namespace gfx { |
| 12 class Rect; | 13 class Rect; |
| 13 class RectF; | 14 class RectF; |
| 14 } | 15 } |
| 15 | 16 |
| 16 namespace gpu { | 17 namespace gpu { |
| 17 | 18 |
| 18 struct SyncToken; | 19 struct SyncToken; |
| (...skipping 20 matching lines...) Expand all Loading... |
| 39 | 40 |
| 40 virtual void Swap() = 0; | 41 virtual void Swap() = 0; |
| 41 virtual void PartialSwapBuffers(const gfx::Rect& sub_buffer) = 0; | 42 virtual void PartialSwapBuffers(const gfx::Rect& sub_buffer) = 0; |
| 42 virtual void CommitOverlayPlanes() = 0; | 43 virtual void CommitOverlayPlanes() = 0; |
| 43 | 44 |
| 44 // Schedule a texture to be presented as an overlay synchronously with the | 45 // Schedule a texture to be presented as an overlay synchronously with the |
| 45 // primary surface during the next buffer swap or CommitOverlayPlanes. | 46 // primary surface during the next buffer swap or CommitOverlayPlanes. |
| 46 // This method is not stateful and needs to be re-scheduled every frame. | 47 // This method is not stateful and needs to be re-scheduled every frame. |
| 47 virtual void ScheduleOverlayPlane(int plane_z_order, | 48 virtual void ScheduleOverlayPlane(int plane_z_order, |
| 48 gfx::OverlayTransform plane_transform, | 49 gfx::OverlayTransform plane_transform, |
| 50 gfx::BufferFormat storage_format, |
| 49 unsigned overlay_texture_id, | 51 unsigned overlay_texture_id, |
| 50 const gfx::Rect& display_bounds, | 52 const gfx::Rect& display_bounds, |
| 51 const gfx::RectF& uv_rect) = 0; | 53 const gfx::RectF& uv_rect, |
| 54 bool handle_scaling) = 0; |
| 52 | 55 |
| 53 virtual uint32 InsertFutureSyncPointCHROMIUM() = 0; | 56 virtual uint32 InsertFutureSyncPointCHROMIUM() = 0; |
| 54 virtual void RetireSyncPointCHROMIUM(uint32 sync_point) = 0; | 57 virtual void RetireSyncPointCHROMIUM(uint32 sync_point) = 0; |
| 55 | 58 |
| 56 // Returns an ID that can be used to globally identify the share group that | 59 // Returns an ID that can be used to globally identify the share group that |
| 57 // this context's resources belong to. | 60 // this context's resources belong to. |
| 58 virtual uint64_t ShareGroupTracingGUID() const = 0; | 61 virtual uint64_t ShareGroupTracingGUID() const = 0; |
| 59 | 62 |
| 60 protected: | 63 protected: |
| 61 ContextSupport() {} | 64 ContextSupport() {} |
| 62 virtual ~ContextSupport() {} | 65 virtual ~ContextSupport() {} |
| 63 }; | 66 }; |
| 64 | 67 |
| 65 } | 68 } |
| 66 | 69 |
| 67 #endif // GPU_COMMAND_BUFFER_CLIENT_CONTEXT_SUPPORT_H_ | 70 #endif // GPU_COMMAND_BUFFER_CLIENT_CONTEXT_SUPPORT_H_ |
| OLD | NEW |