Index: content/common/gpu/media/vt_video_decode_accelerator.cc |
diff --git a/content/common/gpu/media/vt_video_decode_accelerator.cc b/content/common/gpu/media/vt_video_decode_accelerator.cc |
new file mode 100644 |
index 0000000000000000000000000000000000000000..fe12f1ea35278cbe90f2985c1e41c0eb54961c0d |
--- /dev/null |
+++ b/content/common/gpu/media/vt_video_decode_accelerator.cc |
@@ -0,0 +1,60 @@ |
+// Copyright (c) 2014 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#include "content/common/gpu/media/vt_video_decode_accelerator.h" |
+ |
+namespace content { |
+ |
+VTVideoDecodeAccelerator::VTVideoDecodeAccelerator(CGLContextObj cgl_context) |
+ : weak_this_factory_(this), |
+ loop_proxy_(base::MessageLoopProxy::current()), |
+ cgl_context_(cgl_context), |
+ client_(NULL) { |
+ weak_this_ = weak_this_factory_.GetWeakPtr(); |
+} |
+ |
+VTVideoDecodeAccelerator::~VTVideoDecodeAccelerator() { |
+ 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.
|
+} |
+ |
+bool VTVideoDecodeAccelerator::Initialize( |
+ media::VideoCodecProfile profile, |
+ Client* client) { |
+ DCHECK(CalledOnValidThread()); |
+ client_ = client; |
+ |
+ // Only H.264 is supported. |
+ if (profile < media::H264PROFILE_MIN || profile > media::H264PROFILE_MAX) |
+ return false; |
+ |
+ // 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.
|
+ return false; |
+} |
+ |
+void VTVideoDecodeAccelerator::Decode(const media::BitstreamBuffer& bitstream) { |
+ DCHECK(CalledOnValidThread()); |
+} |
+ |
+void VTVideoDecodeAccelerator::AssignPictureBuffers( |
+ const std::vector<media::PictureBuffer>& pictures) { |
+ DCHECK(CalledOnValidThread()); |
+} |
+ |
+void VTVideoDecodeAccelerator::ReusePictureBuffer(int32_t picture_id) { |
+ DCHECK(CalledOnValidThread()); |
+} |
+ |
+void VTVideoDecodeAccelerator::Flush() { |
+ DCHECK(CalledOnValidThread()); |
+} |
+ |
+void VTVideoDecodeAccelerator::Reset() { |
+ DCHECK(CalledOnValidThread()); |
+} |
+ |
+void VTVideoDecodeAccelerator::Destroy() { |
+ DCHECK(CalledOnValidThread()); |
+} |
+ |
+} // namespace content |