| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/pepper_platform_video_decoder_impl.h" | 5 #include "content/renderer/pepper_platform_video_decoder_impl.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 89 } | 89 } |
| 90 | 90 |
| 91 void PlatformVideoDecoderImpl::NotifyError( | 91 void PlatformVideoDecoderImpl::NotifyError( |
| 92 VideoDecodeAccelerator::Error error) { | 92 VideoDecodeAccelerator::Error error) { |
| 93 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); | 93 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); |
| 94 client_->NotifyError(error); | 94 client_->NotifyError(error); |
| 95 } | 95 } |
| 96 | 96 |
| 97 void PlatformVideoDecoderImpl::ProvidePictureBuffers( | 97 void PlatformVideoDecoderImpl::ProvidePictureBuffers( |
| 98 uint32 requested_num_of_buffers, | 98 uint32 requested_num_of_buffers, |
| 99 const gfx::Size& dimensions, | 99 const gfx::Size& dimensions) { |
| 100 media::VideoDecodeAccelerator::MemoryType type) { | |
| 101 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); | 100 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); |
| 102 client_->ProvidePictureBuffers(requested_num_of_buffers, dimensions, type); | 101 client_->ProvidePictureBuffers(requested_num_of_buffers, dimensions); |
| 103 } | 102 } |
| 104 | 103 |
| 105 void PlatformVideoDecoderImpl::DismissPictureBuffer(int32 picture_buffer_id) { | 104 void PlatformVideoDecoderImpl::DismissPictureBuffer(int32 picture_buffer_id) { |
| 106 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); | 105 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); |
| 107 client_->DismissPictureBuffer(picture_buffer_id); | 106 client_->DismissPictureBuffer(picture_buffer_id); |
| 108 } | 107 } |
| 109 | 108 |
| 110 void PlatformVideoDecoderImpl::PictureReady(const media::Picture& picture) { | 109 void PlatformVideoDecoderImpl::PictureReady(const media::Picture& picture) { |
| 111 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); | 110 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); |
| 112 client_->PictureReady(picture); | 111 client_->PictureReady(picture); |
| (...skipping 12 matching lines...) Expand all Loading... |
| 125 | 124 |
| 126 void PlatformVideoDecoderImpl::NotifyFlushDone() { | 125 void PlatformVideoDecoderImpl::NotifyFlushDone() { |
| 127 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); | 126 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); |
| 128 client_->NotifyFlushDone(); | 127 client_->NotifyFlushDone(); |
| 129 } | 128 } |
| 130 | 129 |
| 131 void PlatformVideoDecoderImpl::NotifyResetDone() { | 130 void PlatformVideoDecoderImpl::NotifyResetDone() { |
| 132 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); | 131 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); |
| 133 client_->NotifyResetDone(); | 132 client_->NotifyResetDone(); |
| 134 } | 133 } |
| OLD | NEW |