Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1819)

Unified Diff: content/common/gpu/media/gpu_video_decode_accelerator.cc

Issue 11198060: VDA implementation for Exynos, using V4L2 (Closed) Base URL: https://git.chromium.org/git/chromium/src@git-svn
Patch Set: Added H264 parsing for frame boundaries. Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/common/gpu/media/gpu_video_decode_accelerator.cc
diff --git a/content/common/gpu/media/gpu_video_decode_accelerator.cc b/content/common/gpu/media/gpu_video_decode_accelerator.cc
index cf869ad408c697578e019f22b744f417920657ae..920e9a46324734c2255ad989748f1ab580a607f3 100644
--- a/content/common/gpu/media/gpu_video_decode_accelerator.cc
+++ b/content/common/gpu/media/gpu_video_decode_accelerator.cc
@@ -7,11 +7,13 @@
#include <vector>
#include "base/bind.h"
+#include "base/command_line.h"
#include "base/logging.h"
#include "base/stl_util.h"
#include "content/common/gpu/gpu_channel.h"
#include "content/common/gpu/gpu_messages.h"
+#include "content/public/common/content_switches.h"
#include "gpu/command_buffer/common/command_buffer.h"
#include "ipc/ipc_message_macros.h"
#include "ipc/ipc_message_utils.h"
@@ -22,6 +24,7 @@
#include "base/win/windows_version.h"
#include "content/common/gpu/media/dxva_video_decode_accelerator.h"
#elif defined(OS_CHROMEOS) && defined(ARCH_CPU_ARMEL)
+#include "content/common/gpu/media/exynos_video_decode_accelerator.h"
#include "content/common/gpu/media/omx_video_decode_accelerator.h"
#elif defined(OS_CHROMEOS) && defined(ARCH_CPU_X86_FAMILY)
#include "ui/gl/gl_context_glx.h"
@@ -174,11 +177,19 @@ void GpuVideoDecodeAccelerator::Initialize(
video_decode_accelerator_.reset(new DXVAVideoDecodeAccelerator(
this, make_context_current_));
#elif defined(OS_CHROMEOS) && defined(ARCH_CPU_ARMEL)
- video_decode_accelerator_.reset(new OmxVideoDecodeAccelerator(
- gfx::GLSurfaceEGL::GetHardwareDisplay(),
- stub_->decoder()->GetGLContext()->GetHandle(),
- this,
- make_context_current_));
+ if (CommandLine::ForCurrentProcess()->HasSwitch(switches::kUseExynosVda)) {
+ video_decode_accelerator_.reset(new ExynosVideoDecodeAccelerator(
+ gfx::GLSurfaceEGL::GetHardwareDisplay(),
+ stub_->decoder()->GetGLContext()->GetHandle(),
+ this,
+ make_context_current_));
+ } else {
+ video_decode_accelerator_.reset(new OmxVideoDecodeAccelerator(
+ gfx::GLSurfaceEGL::GetHardwareDisplay(),
+ stub_->decoder()->GetGLContext()->GetHandle(),
+ this,
+ make_context_current_));
+ }
#elif defined(OS_CHROMEOS) && defined(ARCH_CPU_X86_FAMILY)
gfx::GLContextGLX* glx_context =
static_cast<gfx::GLContextGLX*>(stub_->decoder()->GetGLContext());

Powered by Google App Engine
This is Rietveld 408576698