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

Side by Side Diff: content/common/gpu/media/dxva_video_decode_accelerator.cc

Issue 1244883002: Fix dxva_video_decode_accelerator.cc to compile with Win 10 SDK (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 5 months 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/common/gpu/media/dxva_video_decode_accelerator.h" 5 #include "content/common/gpu/media/dxva_video_decode_accelerator.h"
6 6
7 #if !defined(OS_WIN) 7 #if !defined(OS_WIN)
8 #error This file should only be built on Windows. 8 #error This file should only be built on Windows.
9 #endif // !defined(OS_WIN) 9 #endif // !defined(OS_WIN)
10 10
11 #include <ks.h> 11 #include <ks.h>
12 #include <codecapi.h> 12 #include <codecapi.h>
13 #include <dxgi1_2.h> 13 #include <dxgi1_2.h>
14 #include <mfapi.h> 14 #include <mfapi.h>
15 #include <mferror.h> 15 #include <mferror.h>
16 #include <ntverp.h>
16 #include <wmcodecdsp.h> 17 #include <wmcodecdsp.h>
17 18
18 #include "base/base_paths_win.h" 19 #include "base/base_paths_win.h"
19 #include "base/bind.h" 20 #include "base/bind.h"
20 #include "base/callback.h" 21 #include "base/callback.h"
21 #include "base/command_line.h" 22 #include "base/command_line.h"
22 #include "base/debug/alias.h" 23 #include "base/debug/alias.h"
23 #include "base/file_version_info.h" 24 #include "base/file_version_info.h"
24 #include "base/files/file_path.h" 25 #include "base/files/file_path.h"
25 #include "base/logging.h" 26 #include "base/logging.h"
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
82 83
83 const CLSID MEDIASUBTYPE_VP90 = { 84 const CLSID MEDIASUBTYPE_VP90 = {
84 0x30395056, 85 0x30395056,
85 0x0000, 86 0x0000,
86 0x0010, 87 0x0010,
87 { 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71 } 88 { 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71 }
88 }; 89 };
89 90
90 // The CLSID of the video processor media foundation transform which we use for 91 // The CLSID of the video processor media foundation transform which we use for
91 // texture color conversion in DX11. 92 // texture color conversion in DX11.
93 // Defined in mfidl.h in the Windows 10 SDK. ntverp.h provides VER_PRODUCTBUILD
94 // to detect which SDK we are compiling with.
95 #if VER_PRODUCTBUILD < 10011 // VER_PRODUCTBUILD for 10.0.10158.0 SDK.
92 DEFINE_GUID(CLSID_VideoProcessorMFT, 96 DEFINE_GUID(CLSID_VideoProcessorMFT,
93 0x88753b26, 0x5b24, 0x49bd, 0xb2, 0xe7, 0xc, 0x44, 0x5c, 0x78, 97 0x88753b26, 0x5b24, 0x49bd, 0xb2, 0xe7, 0xc, 0x44, 0x5c, 0x78,
94 0xc9, 0x82); 98 0xc9, 0x82);
99 #endif
95 100
96 // MF_XVP_PLAYBACK_MODE 101 // MF_XVP_PLAYBACK_MODE
97 // Data type: UINT32 (treat as BOOL) 102 // Data type: UINT32 (treat as BOOL)
98 // If this attribute is TRUE, the video processor will run in playback mode 103 // If this attribute is TRUE, the video processor will run in playback mode
99 // where it allows callers to allocate output samples and allows last frame 104 // where it allows callers to allocate output samples and allows last frame
100 // regeneration (repaint). 105 // regeneration (repaint).
101 DEFINE_GUID(MF_XVP_PLAYBACK_MODE, 0x3c5d293f, 0xad67, 0x4e29, 0xaf, 0x12, 106 DEFINE_GUID(MF_XVP_PLAYBACK_MODE, 0x3c5d293f, 0xad67, 0x4e29, 0xaf, 0x12,
102 0xcf, 0x3e, 0x23, 0x8a, 0xcc, 0xe9); 107 0xcf, 0x3e, 0x23, 0x8a, 0xcc, 0xe9);
103 108
104 } // namespace 109 } // namespace
(...skipping 2093 matching lines...) Expand 10 before | Expand all | Expand 10 after
2198 D3DSURFACE_DESC surface_desc; 2203 D3DSURFACE_DESC surface_desc;
2199 hr = surface->GetDesc(&surface_desc); 2204 hr = surface->GetDesc(&surface_desc);
2200 RETURN_ON_HR_FAILURE(hr, "Failed to get surface description", false); 2205 RETURN_ON_HR_FAILURE(hr, "Failed to get surface description", false);
2201 *width = surface_desc.Width; 2206 *width = surface_desc.Width;
2202 *height = surface_desc.Height; 2207 *height = surface_desc.Height;
2203 } 2208 }
2204 return true; 2209 return true;
2205 } 2210 }
2206 2211
2207 } // namespace content 2212 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698