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

Side by Side Diff: media/gpu/dxva_video_decode_accelerator_win.cc

Issue 2909943003: Removing useless Win7 checks + standardize its use (Closed)
Patch Set: Various nits Created 3 years, 6 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
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 "media/gpu/dxva_video_decode_accelerator_win.h" 5 #include "media/gpu/dxva_video_decode_accelerator_win.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #if !defined(OS_WIN) 9 #if !defined(OS_WIN)
10 #error This file should only be built on Windows. 10 #error This file should only be built on Windows.
(...skipping 1236 matching lines...) Expand 10 before | Expand all | Expand 10 after
1247 return profiles; 1247 return profiles;
1248 } 1248 }
1249 1249
1250 // static 1250 // static
1251 void DXVAVideoDecodeAccelerator::PreSandboxInitialization() { 1251 void DXVAVideoDecodeAccelerator::PreSandboxInitialization() {
1252 g_catcher_tls_slot.Initialize(nullptr); 1252 g_catcher_tls_slot.Initialize(nullptr);
1253 for (const wchar_t* mfdll : kMediaFoundationVideoDecoderDLLs) 1253 for (const wchar_t* mfdll : kMediaFoundationVideoDecoderDLLs)
1254 ::LoadLibrary(mfdll); 1254 ::LoadLibrary(mfdll);
1255 ::LoadLibrary(L"dxva2.dll"); 1255 ::LoadLibrary(L"dxva2.dll");
1256 1256
1257 if (base::win::GetVersion() > base::win::VERSION_WIN7) { 1257 if (base::win::GetVersion() >= base::win::VERSION_WIN8) {
1258 LoadLibrary(L"msvproc.dll"); 1258 LoadLibrary(L"msvproc.dll");
1259 } else { 1259 } else {
1260 #if defined(ENABLE_DX11_FOR_WIN7) 1260 #if defined(ENABLE_DX11_FOR_WIN7)
1261 LoadLibrary(L"mshtmlmedia.dll"); 1261 LoadLibrary(L"mshtmlmedia.dll");
1262 #endif 1262 #endif
1263 } 1263 }
1264 } 1264 }
1265 1265
1266 // static 1266 // static
1267 std::pair<int, int> DXVAVideoDecodeAccelerator::GetMinResolution( 1267 std::pair<int, int> DXVAVideoDecodeAccelerator::GetMinResolution(
(...skipping 1812 matching lines...) Expand 10 before | Expand all | Expand 10 after
3080 return false; 3080 return false;
3081 } 3081 }
3082 NOTREACHED(); 3082 NOTREACHED();
3083 return false; 3083 return false;
3084 } 3084 }
3085 ID3D11Device* DXVAVideoDecodeAccelerator::D3D11Device() const { 3085 ID3D11Device* DXVAVideoDecodeAccelerator::D3D11Device() const {
3086 return ShouldUseANGLEDevice() ? angle_device_.Get() : d3d11_device_.Get(); 3086 return ShouldUseANGLEDevice() ? angle_device_.Get() : d3d11_device_.Get();
3087 } 3087 }
3088 3088
3089 } // namespace media 3089 } // namespace media
OLDNEW
« no previous file with comments | « media/capture/video/win/video_capture_device_factory_win.cc ('k') | media/gpu/gpu_video_decode_accelerator_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698