| 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 #include "gpu/command_buffer/service/in_process_command_buffer.h" | 5 #include "gpu/command_buffer/service/in_process_command_buffer.h" |
| 6 | 6 |
| 7 #include <queue> | 7 #include <queue> |
| 8 #include <set> | 8 #include <set> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 completion->Signal(); | 55 completion->Signal(); |
| 56 } | 56 } |
| 57 | 57 |
| 58 class GpuInProcessThread | 58 class GpuInProcessThread |
| 59 : public base::Thread, | 59 : public base::Thread, |
| 60 public InProcessCommandBuffer::Service, | 60 public InProcessCommandBuffer::Service, |
| 61 public base::RefCountedThreadSafe<GpuInProcessThread> { | 61 public base::RefCountedThreadSafe<GpuInProcessThread> { |
| 62 public: | 62 public: |
| 63 GpuInProcessThread(); | 63 GpuInProcessThread(); |
| 64 | 64 |
| 65 virtual void AddRef() const OVERRIDE { | 65 virtual void AddRef() const override { |
| 66 base::RefCountedThreadSafe<GpuInProcessThread>::AddRef(); | 66 base::RefCountedThreadSafe<GpuInProcessThread>::AddRef(); |
| 67 } | 67 } |
| 68 virtual void Release() const OVERRIDE { | 68 virtual void Release() const override { |
| 69 base::RefCountedThreadSafe<GpuInProcessThread>::Release(); | 69 base::RefCountedThreadSafe<GpuInProcessThread>::Release(); |
| 70 } | 70 } |
| 71 | 71 |
| 72 virtual void ScheduleTask(const base::Closure& task) OVERRIDE; | 72 virtual void ScheduleTask(const base::Closure& task) override; |
| 73 virtual void ScheduleIdleWork(const base::Closure& callback) OVERRIDE; | 73 virtual void ScheduleIdleWork(const base::Closure& callback) override; |
| 74 virtual bool UseVirtualizedGLContexts() OVERRIDE { return false; } | 74 virtual bool UseVirtualizedGLContexts() override { return false; } |
| 75 virtual scoped_refptr<gles2::ShaderTranslatorCache> shader_translator_cache() | 75 virtual scoped_refptr<gles2::ShaderTranslatorCache> shader_translator_cache() |
| 76 OVERRIDE; | 76 override; |
| 77 | 77 |
| 78 private: | 78 private: |
| 79 virtual ~GpuInProcessThread(); | 79 virtual ~GpuInProcessThread(); |
| 80 friend class base::RefCountedThreadSafe<GpuInProcessThread>; | 80 friend class base::RefCountedThreadSafe<GpuInProcessThread>; |
| 81 | 81 |
| 82 scoped_refptr<gpu::gles2::ShaderTranslatorCache> shader_translator_cache_; | 82 scoped_refptr<gpu::gles2::ShaderTranslatorCache> shader_translator_cache_; |
| 83 DISALLOW_COPY_AND_ASSIGN(GpuInProcessThread); | 83 DISALLOW_COPY_AND_ASSIGN(GpuInProcessThread); |
| 84 }; | 84 }; |
| 85 | 85 |
| 86 GpuInProcessThread::GpuInProcessThread() : base::Thread("GpuThread") { | 86 GpuInProcessThread::GpuInProcessThread() : base::Thread("GpuThread") { |
| (...skipping 682 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 769 | 769 |
| 770 #if defined(OS_ANDROID) | 770 #if defined(OS_ANDROID) |
| 771 scoped_refptr<gfx::SurfaceTexture> | 771 scoped_refptr<gfx::SurfaceTexture> |
| 772 InProcessCommandBuffer::GetSurfaceTexture(uint32 stream_id) { | 772 InProcessCommandBuffer::GetSurfaceTexture(uint32 stream_id) { |
| 773 DCHECK(stream_texture_manager_); | 773 DCHECK(stream_texture_manager_); |
| 774 return stream_texture_manager_->GetSurfaceTexture(stream_id); | 774 return stream_texture_manager_->GetSurfaceTexture(stream_id); |
| 775 } | 775 } |
| 776 #endif | 776 #endif |
| 777 | 777 |
| 778 } // namespace gpu | 778 } // namespace gpu |
| OLD | NEW |