Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1495)

Side by Side Diff: content/renderer/media/renderer_gpu_video_accelerator_factories.cc

Issue 480233007: Remove implicit conversions from scoped_refptr to T* in content/renderer/media/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 "content/renderer/media/renderer_gpu_video_accelerator_factories.h" 5 #include "content/renderer/media/renderer_gpu_video_accelerator_factories.h"
6 6
7 #include <GLES2/gl2.h> 7 #include <GLES2/gl2.h>
8 #include <GLES2/gl2ext.h> 8 #include <GLES2/gl2ext.h>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 52
53 void RendererGpuVideoAcceleratorFactories::BindContext() { 53 void RendererGpuVideoAcceleratorFactories::BindContext() {
54 DCHECK(task_runner_->BelongsToCurrentThread()); 54 DCHECK(task_runner_->BelongsToCurrentThread());
55 if (!context_provider_->BindToCurrentThread()) 55 if (!context_provider_->BindToCurrentThread())
56 context_provider_ = NULL; 56 context_provider_ = NULL;
57 } 57 }
58 58
59 WebGraphicsContext3DCommandBufferImpl* 59 WebGraphicsContext3DCommandBufferImpl*
60 RendererGpuVideoAcceleratorFactories::GetContext3d() { 60 RendererGpuVideoAcceleratorFactories::GetContext3d() {
61 DCHECK(task_runner_->BelongsToCurrentThread()); 61 DCHECK(task_runner_->BelongsToCurrentThread());
62 if (!context_provider_) 62 if (!context_provider_.get())
63 return NULL; 63 return NULL;
64 if (context_provider_->IsContextLost()) { 64 if (context_provider_->IsContextLost()) {
65 context_provider_->VerifyContexts(); 65 context_provider_->VerifyContexts();
66 context_provider_ = NULL; 66 context_provider_ = NULL;
67 return NULL; 67 return NULL;
68 } 68 }
69 return context_provider_->WebContext3D(); 69 return context_provider_->WebContext3D();
70 } 70 }
71 71
72 scoped_ptr<media::VideoDecodeAccelerator> 72 scoped_ptr<media::VideoDecodeAccelerator>
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after
253 DCHECK(task_runner_->BelongsToCurrentThread()); 253 DCHECK(task_runner_->BelongsToCurrentThread());
254 return ChildThread::AllocateSharedMemory(size, thread_safe_sender_.get()); 254 return ChildThread::AllocateSharedMemory(size, thread_safe_sender_.get());
255 } 255 }
256 256
257 scoped_refptr<base::SingleThreadTaskRunner> 257 scoped_refptr<base::SingleThreadTaskRunner>
258 RendererGpuVideoAcceleratorFactories::GetTaskRunner() { 258 RendererGpuVideoAcceleratorFactories::GetTaskRunner() {
259 return task_runner_; 259 return task_runner_;
260 } 260 }
261 261
262 } // namespace content 262 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/media/media_stream_video_track.cc ('k') | content/renderer/media/rtc_peer_connection_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698