| Index: content/common/gpu/media/exynos_video_decode_accelerator.cc
|
| diff --git a/content/common/gpu/media/exynos_video_decode_accelerator.cc b/content/common/gpu/media/exynos_video_decode_accelerator.cc
|
| index edce5f3ef8bcb6b08fb4aadc7ccb1cc1c34c4c5c..26794a47b8fbb5d1fb1af19632795372eaf2fafa 100644
|
| --- a/content/common/gpu/media/exynos_video_decode_accelerator.cc
|
| +++ b/content/common/gpu/media/exynos_video_decode_accelerator.cc
|
| @@ -241,8 +241,7 @@ ExynosVideoDecodeAccelerator::ExynosVideoDecodeAccelerator(
|
| make_context_current_(make_context_current),
|
| egl_display_(egl_display),
|
| egl_context_(egl_context),
|
| - video_profile_(media::VIDEO_CODEC_PROFILE_UNKNOWN) {
|
| -}
|
| + video_profile_(media::VIDEO_CODEC_PROFILE_UNKNOWN) {}
|
|
|
| ExynosVideoDecodeAccelerator::~ExynosVideoDecodeAccelerator() {
|
| DCHECK(!decoder_thread_.IsRunning());
|
| @@ -440,14 +439,6 @@ void ExynosVideoDecodeAccelerator::AssignPictureBuffers(
|
| return;
|
| }
|
|
|
| - for (size_t i = 0; i < buffers.size(); ++i) {
|
| - if (buffers[i].size() != frame_buffer_size_) {
|
| - DLOG(ERROR) << "AssignPictureBuffers(): invalid buffer size";
|
| - NOTIFY_ERROR(INVALID_ARGUMENT);
|
| - return;
|
| - }
|
| - }
|
| -
|
| if (!make_context_current_.Run()) {
|
| DLOG(ERROR) << "AssignPictureBuffers(): could not make context current";
|
| NOTIFY_ERROR(PLATFORM_FAILURE);
|
| @@ -464,12 +455,16 @@ void ExynosVideoDecodeAccelerator::AssignPictureBuffers(
|
| Display* x_display = base::MessagePumpForUI::GetDefaultXDisplay();
|
| gfx::ScopedTextureBinder bind_restore(GL_TEXTURE_2D, 0);
|
| for (size_t i = 0; i < pic_buffers_ref->picture_buffers.size(); ++i) {
|
| + DCHECK(buffers[i].size() == frame_buffer_size_);
|
| PictureBufferArrayRef::PictureBufferRef& buffer =
|
| pic_buffers_ref->picture_buffers[i];
|
| // Create the X pixmap and then create an EGLImageKHR from it, so we can
|
| // get dma_buf backing.
|
| - Pixmap pixmap = XCreatePixmap(x_display, RootWindow(x_display, 0),
|
| - buffers[i].size().width(), buffers[i].size().height(), 32);
|
| + Pixmap pixmap = XCreatePixmap(x_display,
|
| + RootWindow(x_display, 0),
|
| + frame_buffer_size_.width(),
|
| + frame_buffer_size_.height(),
|
| + 32);
|
| if (!pixmap) {
|
| DLOG(ERROR) << "AssignPictureBuffers(): could not create X pixmap";
|
| NOTIFY_ERROR(PLATFORM_FAILURE);
|
|
|