Commit 1cf21ca0 authored by Matthew Cary's avatar Matthew Cary Committed by Commit Bot

media/gpu: Add mojo/edk initialization to unittest.

This adds mojo/edk initialization to
media/gpu/video_decode_accelerator_unittest. This is necessary for
future changes that use mojo machinary for shared memory manipulation.

Bug: 849207
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
Change-Id: I6d04891a4d306f7c458eb2bb4ce3fd42a1b77759
Reviewed-on: https://chromium-review.googlesource.com/1122095
Commit-Queue: Matthew Cary <mattcary@chromium.org>
Reviewed-by: default avatarPawel Osciak <posciak@chromium.org>
Reviewed-by: default avatarKen Rockot <rockot@chromium.org>
Cr-Commit-Position: refs/heads/master@{#576121}
parent 95845389
......@@ -387,6 +387,7 @@ if (is_win || is_android || use_v4l2_codec || use_vaapi) {
"video_decode_accelerator_unittest.cc",
]
deps += [
"//mojo/core/embedder",
"//ui/display",
"//ui/display/types",
"//ui/platform_window",
......
# Do NOT add net/ or ui/base without a great reason, they're huge!
include_rules = [
"+mojo/core/embedder",
"+services/service_manager/public",
"+third_party/angle",
"+third_party/libyuv",
......
......@@ -67,6 +67,7 @@
#include "media/gpu/test/video_accelerator_unittest_helpers.h"
#include "media/gpu/test/video_decode_accelerator_unittest_helpers.h"
#include "media/video/h264_parser.h"
#include "mojo/core/embedder/embedder.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/gfx/codec/png_codec.h"
#include "ui/gl/gl_image.h"
......@@ -1591,6 +1592,8 @@ class VDATestSuite : public base::TestSuite {
int Run() {
#if defined(OS_WIN) || defined(OS_CHROMEOS)
mojo::core::Init(); // Required only for Win7 tests.
// For windows the decoding thread initializes the media foundation decoder
// which uses COM. We need the thread to be a UI thread.
// On Ozone, the backend initializes the event system using a UI
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment