OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "media/mojo/services/mojo_video_decoder.h" | 5 #include "media/mojo/services/mojo_video_decoder.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/location.h" | 8 #include "base/location.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/single_thread_task_runner.h" | 10 #include "base/single_thread_task_runner.h" |
(...skipping 26 matching lines...) Expand all Loading... |
37 // Pretend to be able to decode anything. | 37 // Pretend to be able to decode anything. |
38 task_runner_->PostTask(FROM_HERE, base::Bind(init_cb, true)); | 38 task_runner_->PostTask(FROM_HERE, base::Bind(init_cb, true)); |
39 } | 39 } |
40 | 40 |
41 void MojoVideoDecoder::Decode(const scoped_refptr<DecoderBuffer>& buffer, | 41 void MojoVideoDecoder::Decode(const scoped_refptr<DecoderBuffer>& buffer, |
42 const DecodeCB& decode_cb) { | 42 const DecodeCB& decode_cb) { |
43 DVLOG(3) << __FUNCTION__; | 43 DVLOG(3) << __FUNCTION__; |
44 NOTIMPLEMENTED(); | 44 NOTIMPLEMENTED(); |
45 | 45 |
46 // Actually we can't decode anything. | 46 // Actually we can't decode anything. |
47 task_runner_->PostTask(FROM_HERE, base::Bind(decode_cb, kDecodeError)); | 47 task_runner_->PostTask(FROM_HERE, |
| 48 base::Bind(decode_cb, DecodeStatus::DECODE_ERROR)); |
48 } | 49 } |
49 | 50 |
50 void MojoVideoDecoder::Reset(const base::Closure& closure) { | 51 void MojoVideoDecoder::Reset(const base::Closure& closure) { |
51 DVLOG(2) << __FUNCTION__; | 52 DVLOG(2) << __FUNCTION__; |
52 NOTIMPLEMENTED(); | 53 NOTIMPLEMENTED(); |
53 } | 54 } |
54 | 55 |
55 bool MojoVideoDecoder::NeedsBitstreamConversion() const { | 56 bool MojoVideoDecoder::NeedsBitstreamConversion() const { |
56 DVLOG(1) << __FUNCTION__; | 57 DVLOG(1) << __FUNCTION__; |
57 NOTIMPLEMENTED(); | 58 NOTIMPLEMENTED(); |
58 return false; | 59 return false; |
59 } | 60 } |
60 | 61 |
61 bool MojoVideoDecoder::CanReadWithoutStalling() const { | 62 bool MojoVideoDecoder::CanReadWithoutStalling() const { |
62 DVLOG(1) << __FUNCTION__; | 63 DVLOG(1) << __FUNCTION__; |
63 NOTIMPLEMENTED(); | 64 NOTIMPLEMENTED(); |
64 return true; | 65 return true; |
65 } | 66 } |
66 | 67 |
67 int MojoVideoDecoder::GetMaxDecodeRequests() const { | 68 int MojoVideoDecoder::GetMaxDecodeRequests() const { |
68 DVLOG(1) << __FUNCTION__; | 69 DVLOG(1) << __FUNCTION__; |
69 NOTIMPLEMENTED(); | 70 NOTIMPLEMENTED(); |
70 return 1; | 71 return 1; |
71 } | 72 } |
72 | 73 |
73 } // namespace media | 74 } // namespace media |
OLD | NEW |