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 // The bulk of this file is support code; sorry about that. Here's an overview | 5 // The bulk of this file is support code; sorry about that. Here's an overview |
6 // to hopefully help readers of this code: | 6 // to hopefully help readers of this code: |
7 // - RenderingHelper is charged with interacting with X11, EGL, and GLES2. | 7 // - RenderingHelper is charged with interacting with X11, EGL, and GLES2. |
8 // - ClientState is an enum for the state of the decode client used by the test. | 8 // - ClientState is an enum for the state of the decode client used by the test. |
9 // - ClientStateNotification is a barrier abstraction that allows the test code | 9 // - ClientStateNotification is a barrier abstraction that allows the test code |
10 // to be written sequentially and wait for the decode client to see certain | 10 // to be written sequentially and wait for the decode client to see certain |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 | 45 |
46 #if defined(OS_WIN) | 46 #if defined(OS_WIN) |
47 #include "content/common/gpu/media/dxva_video_decode_accelerator.h" | 47 #include "content/common/gpu/media/dxva_video_decode_accelerator.h" |
48 #else // OS_WIN | 48 #else // OS_WIN |
49 #include "content/common/gpu/media/omx_video_decode_accelerator.h" | 49 #include "content/common/gpu/media/omx_video_decode_accelerator.h" |
50 #endif // defined(OS_WIN) | 50 #endif // defined(OS_WIN) |
51 | 51 |
52 #include "third_party/angle/include/EGL/egl.h" | 52 #include "third_party/angle/include/EGL/egl.h" |
53 | 53 |
54 #if defined(OS_WIN) | 54 #if defined(OS_WIN) |
55 #include "ui/gfx/gl/gl_bindings.h" | 55 #include "ui/gl/gl_bindings.h" |
56 #include "ui/gfx/gl/gl_context.h" | 56 #include "ui/gl/gl_context.h" |
57 #include "ui/gfx/gl/gl_implementation.h" | 57 #include "ui/gl/gl_implementation.h" |
58 #include "ui/gfx/gl/gl_surface.h" | 58 #include "ui/gl/gl_surface.h" |
59 #else // OS_WIN | 59 #else // OS_WIN |
60 #include "third_party/angle/include/GLES2/gl2.h" | 60 #include "third_party/angle/include/GLES2/gl2.h" |
61 #endif // OS_WIN | 61 #endif // OS_WIN |
62 | 62 |
63 using media::VideoDecodeAccelerator; | 63 using media::VideoDecodeAccelerator; |
64 | 64 |
65 namespace { | 65 namespace { |
66 | 66 |
67 // Values optionally filled in from flags; see main() below. | 67 // Values optionally filled in from flags; see main() below. |
68 // The syntax of this variable is: | 68 // The syntax of this variable is: |
(...skipping 1097 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1166 gfx::GLSurface::CreateOffscreenGLSurface(false, gfx::Size(1, 1))); | 1166 gfx::GLSurface::CreateOffscreenGLSurface(false, gfx::Size(1, 1))); |
1167 scoped_refptr<gfx::GLContext> context( | 1167 scoped_refptr<gfx::GLContext> context( |
1168 gfx::GLContext::CreateGLContext(NULL, surface.get(), | 1168 gfx::GLContext::CreateGLContext(NULL, surface.get(), |
1169 gfx::PreferIntegratedGpu)); | 1169 gfx::PreferIntegratedGpu)); |
1170 context->MakeCurrent(surface.get()); | 1170 context->MakeCurrent(surface.get()); |
1171 } | 1171 } |
1172 DXVAVideoDecodeAccelerator::PreSandboxInitialization(); | 1172 DXVAVideoDecodeAccelerator::PreSandboxInitialization(); |
1173 #endif // OS_WIN | 1173 #endif // OS_WIN |
1174 return RUN_ALL_TESTS(); | 1174 return RUN_ALL_TESTS(); |
1175 } | 1175 } |
OLD | NEW |