OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/ppb_video_decoder_impl.h" | 5 #include "content/renderer/pepper/ppb_video_decoder_impl.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/message_loop/message_loop.h" | 10 #include "base/message_loop/message_loop.h" |
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
232 FlushCommandBuffer(); | 232 FlushCommandBuffer(); |
233 | 233 |
234 decoder_.reset(); | 234 decoder_.reset(); |
235 ppp_videodecoder_ = NULL; | 235 ppp_videodecoder_ = NULL; |
236 | 236 |
237 ::ppapi::PPB_VideoDecoder_Shared::Destroy(); | 237 ::ppapi::PPB_VideoDecoder_Shared::Destroy(); |
238 } | 238 } |
239 | 239 |
240 void PPB_VideoDecoder_Impl::ProvidePictureBuffers( | 240 void PPB_VideoDecoder_Impl::ProvidePictureBuffers( |
241 uint32_t requested_num_of_buffers, | 241 uint32_t requested_num_of_buffers, |
| 242 media::VideoPixelFormat format, |
242 uint32_t textures_per_buffer, | 243 uint32_t textures_per_buffer, |
243 const gfx::Size& dimensions, | 244 const gfx::Size& dimensions, |
244 uint32_t texture_target) { | 245 uint32_t texture_target) { |
245 DCHECK(RenderThreadImpl::current()); | 246 DCHECK(RenderThreadImpl::current()); |
246 DCHECK_EQ(1u, textures_per_buffer); | 247 DCHECK_EQ(1u, textures_per_buffer); |
247 if (!GetPPP()) | 248 if (!GetPPP()) |
248 return; | 249 return; |
249 | 250 |
250 PP_Size out_dim = PP_MakeSize(dimensions.width(), dimensions.height()); | 251 PP_Size out_dim = PP_MakeSize(dimensions.width(), dimensions.height()); |
251 GetPPP()->ProvidePictureBuffers(pp_instance(), pp_resource(), | 252 GetPPP()->ProvidePictureBuffers(pp_instance(), pp_resource(), |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
296 DCHECK(RenderThreadImpl::current()); | 297 DCHECK(RenderThreadImpl::current()); |
297 RunBitstreamBufferCallback(bitstream_buffer_id, PP_OK); | 298 RunBitstreamBufferCallback(bitstream_buffer_id, PP_OK); |
298 } | 299 } |
299 | 300 |
300 void PPB_VideoDecoder_Impl::NotifyFlushDone() { | 301 void PPB_VideoDecoder_Impl::NotifyFlushDone() { |
301 DCHECK(RenderThreadImpl::current()); | 302 DCHECK(RenderThreadImpl::current()); |
302 RunFlushCallback(PP_OK); | 303 RunFlushCallback(PP_OK); |
303 } | 304 } |
304 | 305 |
305 } // namespace content | 306 } // namespace content |
OLD | NEW |