| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "gpu/command_buffer/service/texture_definition.h" | 5 #include "gpu/command_buffer/service/texture_definition.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 | 8 |
| 9 #include <list> | 9 #include <list> |
| 10 | 10 |
| (...skipping 26 matching lines...) Expand all Loading... |
| 37 // Implement GLImage. | 37 // Implement GLImage. |
| 38 void Destroy(bool have_context) override; | 38 void Destroy(bool have_context) override; |
| 39 gfx::Size GetSize() override; | 39 gfx::Size GetSize() override; |
| 40 unsigned GetInternalFormat() override; | 40 unsigned GetInternalFormat() override; |
| 41 bool BindTexImage(unsigned target, gl::GLFence* fence) override; | 41 bool BindTexImage(unsigned target, gl::GLFence* fence) override; |
| 42 void ReleaseTexImage(unsigned target) override; | 42 void ReleaseTexImage(unsigned target) override; |
| 43 bool CopyTexImage(unsigned target) override; | 43 bool CopyTexImage(unsigned target) override; |
| 44 bool CopyTexSubImage(unsigned target, | 44 bool CopyTexSubImage(unsigned target, |
| 45 const gfx::Point& offset, | 45 const gfx::Point& offset, |
| 46 const gfx::Rect& rect) override; | 46 const gfx::Rect& rect) override; |
| 47 bool CopySubImageData(unsigned texture_id, |
| 48 const gfx::Point& offset, |
| 49 const gfx::Rect& rect, |
| 50 gl::GLFence* in_fence, |
| 51 gl::GLFence* out_fence) override; |
| 47 bool ScheduleOverlayPlane(gfx::AcceleratedWidget widget, | 52 bool ScheduleOverlayPlane(gfx::AcceleratedWidget widget, |
| 48 int z_order, | 53 int z_order, |
| 49 gfx::OverlayTransform transform, | 54 gfx::OverlayTransform transform, |
| 50 const gfx::Rect& bounds_rect, | 55 const gfx::Rect& bounds_rect, |
| 51 const gfx::RectF& crop_rect) override; | 56 const gfx::RectF& crop_rect) override; |
| 52 void Flush() override {} | 57 void Flush() override {} |
| 53 void OnMemoryDump(base::trace_event::ProcessMemoryDump* pmd, | 58 void OnMemoryDump(base::trace_event::ProcessMemoryDump* pmd, |
| 54 uint64_t process_tracing_id, | 59 uint64_t process_tracing_id, |
| 55 const std::string& dump_name) override; | 60 const std::string& dump_name) override; |
| 56 | 61 |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 99 bool GLImageSync::CopyTexImage(unsigned target) { | 104 bool GLImageSync::CopyTexImage(unsigned target) { |
| 100 return false; | 105 return false; |
| 101 } | 106 } |
| 102 | 107 |
| 103 bool GLImageSync::CopyTexSubImage(unsigned target, | 108 bool GLImageSync::CopyTexSubImage(unsigned target, |
| 104 const gfx::Point& offset, | 109 const gfx::Point& offset, |
| 105 const gfx::Rect& rect) { | 110 const gfx::Rect& rect) { |
| 106 return false; | 111 return false; |
| 107 } | 112 } |
| 108 | 113 |
| 114 bool GLImageSync::CopySubImageData(unsigned texture_id, |
| 115 const gfx::Point& offset, |
| 116 const gfx::Rect& rect, |
| 117 gl::GLFence* in_fence, |
| 118 gl::GLFence* out_fence) { |
| 119 return false; |
| 120 } |
| 121 |
| 109 bool GLImageSync::ScheduleOverlayPlane(gfx::AcceleratedWidget widget, | 122 bool GLImageSync::ScheduleOverlayPlane(gfx::AcceleratedWidget widget, |
| 110 int z_order, | 123 int z_order, |
| 111 gfx::OverlayTransform transform, | 124 gfx::OverlayTransform transform, |
| 112 const gfx::Rect& bounds_rect, | 125 const gfx::Rect& bounds_rect, |
| 113 const gfx::RectF& crop_rect) { | 126 const gfx::RectF& crop_rect) { |
| 114 NOTREACHED(); | 127 NOTREACHED(); |
| 115 return false; | 128 return false; |
| 116 } | 129 } |
| 117 | 130 |
| 118 void GLImageSync::OnMemoryDump(base::trace_event::ProcessMemoryDump* pmd, | 131 void GLImageSync::OnMemoryDump(base::trace_event::ProcessMemoryDump* pmd, |
| (...skipping 346 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 465 return true; | 478 return true; |
| 466 } | 479 } |
| 467 | 480 |
| 468 bool TextureDefinition::SafeToRenderFrom() const { | 481 bool TextureDefinition::SafeToRenderFrom() const { |
| 469 return level_info_.cleared_rect.Contains( | 482 return level_info_.cleared_rect.Contains( |
| 470 gfx::Rect(level_info_.width, level_info_.height)); | 483 gfx::Rect(level_info_.width, level_info_.height)); |
| 471 } | 484 } |
| 472 | 485 |
| 473 } // namespace gles2 | 486 } // namespace gles2 |
| 474 } // namespace gpu | 487 } // namespace gpu |
| OLD | NEW |