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

Side by Side Diff: content/common/gpu/media/vt_video_decode_accelerator.cc

Issue 322433004: Create VTVideoDecodeAccelerator (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix compilation issues. Created 6 years, 6 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
(Empty)
1 // Copyright (c) 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "content/common/gpu/media/vt_video_decode_accelerator.h"
6
7 namespace content {
8
9 VTVideoDecodeAccelerator::VTVideoDecodeAccelerator(CGLContextObj cgl_context)
10 : weak_this_factory_(this),
11 loop_proxy_(base::MessageLoopProxy::current()),
12 cgl_context_(cgl_context),
13 client_(NULL) {
14 weak_this_ = weak_this_factory_.GetWeakPtr();
15 }
16
17 VTVideoDecodeAccelerator::~VTVideoDecodeAccelerator() {
18 client_ = NULL;
scherkus (not reviewing) 2014/06/09 16:02:07 paranoid NULL setting? :) (it's fine to leave it
sandersd (OOO until July 31) 2014/06/10 01:02:44 Done.
19 }
20
21 bool VTVideoDecodeAccelerator::Initialize(
22 media::VideoCodecProfile profile,
23 Client* client) {
24 DCHECK(CalledOnValidThread());
25 client_ = client;
26
27 // Only H.264 is supported.
28 if (profile < media::H264PROFILE_MIN || profile > media::H264PROFILE_MAX)
29 return false;
30
31 // Prevent anyone from using VTVideoDecoder for now.
scherkus (not reviewing) 2014/06/09 16:02:06 link to bug would be nice
sandersd (OOO until July 31) 2014/06/10 01:02:44 Done.
32 return false;
33 }
34
35 void VTVideoDecodeAccelerator::Decode(const media::BitstreamBuffer& bitstream) {
36 DCHECK(CalledOnValidThread());
37 }
38
39 void VTVideoDecodeAccelerator::AssignPictureBuffers(
40 const std::vector<media::PictureBuffer>& pictures) {
41 DCHECK(CalledOnValidThread());
42 }
43
44 void VTVideoDecodeAccelerator::ReusePictureBuffer(int32_t picture_id) {
45 DCHECK(CalledOnValidThread());
46 }
47
48 void VTVideoDecodeAccelerator::Flush() {
49 DCHECK(CalledOnValidThread());
50 }
51
52 void VTVideoDecodeAccelerator::Reset() {
53 DCHECK(CalledOnValidThread());
54 }
55
56 void VTVideoDecodeAccelerator::Destroy() {
57 DCHECK(CalledOnValidThread());
58 }
59
60 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698