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

Side by Side Diff: content/browser/renderer_host/media/video_capture_gpu_jpeg_decoder.cc

Issue 1823763003: Move more files to gpu/ipc/common (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed Android Build Created 4 years, 9 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/browser/renderer_host/media/video_capture_gpu_jpeg_decoder.h" 5 #include "content/browser/renderer_host/media/video_capture_gpu_jpeg_decoder.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after
191 } 191 }
192 192
193 // static 193 // static
194 void VideoCaptureGpuJpegDecoder::EstablishGpuChannelOnUIThread( 194 void VideoCaptureGpuJpegDecoder::EstablishGpuChannelOnUIThread(
195 const scoped_refptr<base::SingleThreadTaskRunner>& task_runner, 195 const scoped_refptr<base::SingleThreadTaskRunner>& task_runner,
196 base::WeakPtr<VideoCaptureGpuJpegDecoder> weak_this) { 196 base::WeakPtr<VideoCaptureGpuJpegDecoder> weak_this) {
197 DCHECK_CURRENTLY_ON(BrowserThread::UI); 197 DCHECK_CURRENTLY_ON(BrowserThread::UI);
198 DCHECK(BrowserGpuChannelHostFactory::instance()); 198 DCHECK(BrowserGpuChannelHostFactory::instance());
199 199
200 BrowserGpuChannelHostFactory::instance()->EstablishGpuChannel( 200 BrowserGpuChannelHostFactory::instance()->EstablishGpuChannel(
201 CAUSE_FOR_GPU_LAUNCH_JPEGDECODEACCELERATOR_INITIALIZE, 201 gpu::CAUSE_FOR_GPU_LAUNCH_JPEGDECODEACCELERATOR_INITIALIZE,
202 base::Bind(&VideoCaptureGpuJpegDecoder::GpuChannelEstablishedOnUIThread, 202 base::Bind(&VideoCaptureGpuJpegDecoder::GpuChannelEstablishedOnUIThread,
203 task_runner, weak_this)); 203 task_runner, weak_this));
204 } 204 }
205 205
206 // static 206 // static
207 void VideoCaptureGpuJpegDecoder::GpuChannelEstablishedOnUIThread( 207 void VideoCaptureGpuJpegDecoder::GpuChannelEstablishedOnUIThread(
208 const scoped_refptr<base::SingleThreadTaskRunner>& task_runner, 208 const scoped_refptr<base::SingleThreadTaskRunner>& task_runner,
209 base::WeakPtr<VideoCaptureGpuJpegDecoder> weak_this) { 209 base::WeakPtr<VideoCaptureGpuJpegDecoder> weak_this) {
210 DCHECK_CURRENTLY_ON(BrowserThread::UI); 210 DCHECK_CURRENTLY_ON(BrowserThread::UI);
211 211
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
248 lock_.AssertAcquired(); 248 lock_.AssertAcquired();
249 return !decode_done_closure_.is_null(); 249 return !decode_done_closure_.is_null();
250 } 250 }
251 251
252 void VideoCaptureGpuJpegDecoder::RecordInitDecodeUMA_Locked() { 252 void VideoCaptureGpuJpegDecoder::RecordInitDecodeUMA_Locked() {
253 UMA_HISTOGRAM_BOOLEAN("Media.VideoCaptureGpuJpegDecoder.InitDecodeSuccess", 253 UMA_HISTOGRAM_BOOLEAN("Media.VideoCaptureGpuJpegDecoder.InitDecodeSuccess",
254 decoder_status_ == INIT_PASSED); 254 decoder_status_ == INIT_PASSED);
255 } 255 }
256 256
257 } // namespace content 257 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698