mirror of
https://github.com/ncblakely/GiantsTools
synced 2024-11-01 05:15:36 +01:00
Compare commits
2 Commits
23d3136e3f
...
71b675f5cb
Author | SHA1 | Date | |
---|---|---|---|
|
71b675f5cb | ||
|
d2cdbcf440 |
@ -1,19 +0,0 @@
|
||||
xcopy "%GIANTS_PATH%\gg_dx7r.dll" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\gg_dx9r.dll" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\gg_null.dll" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\dedicated.exe" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\Giants.exe" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\GiantsMain.exe" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\GiantsDedicated.exe" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\gs_ds.dll" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\Giants.WebApi.Clients.dll" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\fmt.dll" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\crashrpt_lang.ini" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\CrashRpt1403.dll" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\CrashSender1403.exe" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\dbghelp.dll" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\cpprest_2_10.dll" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\Newtonsoft.Json.dll" "Files\" /Y
|
||||
xcopy "%GIANTS_PATH%\zlib1.dll" "Files\" /Y
|
||||
|
||||
pause
|
@ -1,127 +0,0 @@
|
||||
!macro CheckNetFramework FrameworkVersion
|
||||
Var /GLOBAL dotNetUrl${FrameworkVersion}
|
||||
Var /GLOBAL dotNetReadableVersion${FrameworkVersion}
|
||||
|
||||
!ifndef DOTNET472_URL
|
||||
!define DOTNET472_URL "https://go.microsoft.com/fwlink/?LinkId=863265"
|
||||
!define DOTNET471_URL "https://go.microsoft.com/fwlink/?LinkId=852104"
|
||||
!define DOTNET47_URL "https://go.microsoft.com/fwlink/?LinkId=825302"
|
||||
!define DOTNET462_URL "https://go.microsoft.com/fwlink/?LinkId=780600"
|
||||
!define DOTNET461_URL "https://go.microsoft.com/fwlink/?LinkId=671743"
|
||||
!define DOTNET46_URL "https://go.microsoft.com/fwlink/?LinkId=528232"
|
||||
!define DOTNET452_URL "https://go.microsoft.com/fwlink/?LinkId=397708"
|
||||
!define DOTNET451_URL "https://go.microsoft.com/fwlink/?LinkId=322116"
|
||||
!define DOTNET45_URL "https://go.microsoft.com/fwlink/?LinkId=225702"
|
||||
!define DOTNET40Full_URL "https://www.microsoft.com/downloads/info.aspx?na=41&srcfamilyid=0a391abd-25c1-4fc0-919f-b21f31ab88b7&srcdisplaylang=en&u=http%3a%2f%2fdownload.microsoft.com%2fdownload%2f9%2f5%2fA%2f95A9616B-7A37-4AF6-BC36-D6EA96C8DAAE%2fdotNetFx40_Full_x86_x64.exe"
|
||||
!define DOTNET40Client_URL "https://www.microsoft.com/downloads/info.aspx?na=41&srcfamilyid=e5ad0459-cbcc-4b4f-97b6-fb17111cf544&srcdisplaylang=en&u=http%3a%2f%2fdownload.microsoft.com%2fdownload%2f5%2f6%2f2%2f562A10F9-C9F4-4313-A044-9C94E0A8FAC8%2fdotNetFx40_Client_x86_x64.exe"
|
||||
!define DOTNET35_URL "https://download.microsoft.com/download/2/0/e/20e90413-712f-438c-988e-fdaa79a8ac3d/dotnetfx35.exe"
|
||||
!define DOTNET30_URL "https://download.microsoft.com/download/2/0/e/20e90413-712f-438c-988e-fdaa79a8ac3d/dotnetfx35.exe"
|
||||
!define DOTNET20_URL "https://www.microsoft.com/downloads/info.aspx?na=41&srcfamilyid=0856eacb-4362-4b0d-8edd-aab15c5e04f5&srcdisplaylang=en&u=http%3a%2f%2fdownload.microsoft.com%2fdownload%2f5%2f6%2f7%2f567758a3-759e-473e-bf8f-52154438565a%2fdotnetfx.exe"
|
||||
!define DOTNET11_URL "https://www.microsoft.com/downloads/info.aspx?na=41&srcfamilyid=262d25e3-f589-4842-8157-034d1e7cf3a3&srcdisplaylang=en&u=http%3a%2f%2fdownload.microsoft.com%2fdownload%2fa%2fa%2fc%2faac39226-8825-44ce-90e3-bf8203e74006%2fdotnetfx.exe"
|
||||
!define DOTNET10_URL "https://www.microsoft.com/downloads/info.aspx?na=41&srcfamilyid=262d25e3-f589-4842-8157-034d1e7cf3a3&srcdisplaylang=en&u=http%3a%2f%2fdownload.microsoft.com%2fdownload%2fa%2fa%2fc%2faac39226-8825-44ce-90e3-bf8203e74006%2fdotnetfx.exe"
|
||||
!endif
|
||||
|
||||
${If} ${FrameworkVersion} == "472"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET472_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "4.7.2"
|
||||
${ElseIf} ${FrameworkVersion} == "471"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET471_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "4.7.1"
|
||||
${ElseIf} ${FrameworkVersion} == "47"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET47_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "4.7"
|
||||
${ElseIf} ${FrameworkVersion} == "462"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET462_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "4.6.2"
|
||||
${ElseIf} ${FrameworkVersion} == "461"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET461_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "4.6.1"
|
||||
${ElseIf} ${FrameworkVersion} == "46"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET46_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "4.6"
|
||||
${ElseIf} ${FrameworkVersion} == "452"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET452_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "4.52"
|
||||
${ElseIf} ${FrameworkVersion} == "451"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET451_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "4.51"
|
||||
${ElseIf} ${FrameworkVersion} == "45"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET45_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "4.5"
|
||||
${ElseIf} ${FrameworkVersion} == "40Full"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET40Full_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "4.0 Full"
|
||||
${ElseIf} ${FrameworkVersion} == "40Client"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET40Client_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "4.0 Client"
|
||||
${ElseIf} ${FrameworkVersion} == "35"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET35_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "3.5"
|
||||
${ElseIf} ${FrameworkVersion} == "30"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET30_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "3.0"
|
||||
${ElseIf} ${FrameworkVersion} == "20"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET20_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "2.0"
|
||||
${ElseIf} ${FrameworkVersion} == "11"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET11_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "1.1"
|
||||
${ElseIf} ${FrameworkVersion} == "10"
|
||||
StrCpy $dotNetUrl${FrameworkVersion} ${DOTNET10_URL}
|
||||
StrCpy $dotNetReadableVersion${FrameworkVersion} "1.0"
|
||||
${EndIf}
|
||||
|
||||
DetailPrint "Checking .NET Framework version..."
|
||||
|
||||
Push $0
|
||||
Push $1
|
||||
Push $2
|
||||
Push $3
|
||||
Push $4
|
||||
Push $5
|
||||
Push $6
|
||||
Push $7
|
||||
|
||||
DotNetChecker::IsDotNet${FrameworkVersion}Installed
|
||||
Pop $0
|
||||
|
||||
${If} $0 == "false"
|
||||
${OrIf} $0 == "f" ; if script is compiled in ANSI mode then we get only an "f" https://github.com/ReVolly/NsisDotNetChecker/issues/4
|
||||
DetailPrint ".NET Framework $dotNetReadableVersion${FrameworkVersion} not found, download is required for program to run."
|
||||
Goto NoDotNET${FrameworkVersion}
|
||||
${Else}
|
||||
DetailPrint ".NET Framework $dotNetReadableVersion${FrameworkVersion} found, no need to install."
|
||||
Goto NewDotNET${FrameworkVersion}
|
||||
${EndIf}
|
||||
|
||||
NoDotNET${FrameworkVersion}:
|
||||
MessageBox MB_YESNOCANCEL|MB_ICONEXCLAMATION \
|
||||
".NET Framework not installed. Required version: $dotNetReadableVersion${FrameworkVersion}.$\nInstall now?" \
|
||||
/SD IDYES IDYES InstallDotNET${FrameworkVersion} IDNO NewDotNET${FrameworkVersion}
|
||||
goto GiveUpDotNET${FrameworkVersion} ;IDCANCEL
|
||||
|
||||
InstallDotNET${FrameworkVersion}:
|
||||
DetailPrint "Starting Microsoft .NET Framework v${NETVersion} Setup..."
|
||||
ExecWait "$TEMP\${NETInstallerFileName}"
|
||||
|
||||
DetailPrint "Completed .NET Framework install/update. Removing .NET Framework installer."
|
||||
Delete "$TEMP\${NETInstallerFileName}"
|
||||
|
||||
DetailPrint ".NET Framework installer removed."
|
||||
goto NewDotNet${FrameworkVersion}
|
||||
|
||||
GiveUpDotNET${FrameworkVersion}:
|
||||
Abort "Installation canceled by user."
|
||||
|
||||
NewDotNET${FrameworkVersion}:
|
||||
DetailPrint "Proceeding with remainder of installation."
|
||||
Pop $7
|
||||
Pop $6
|
||||
Pop $5
|
||||
Pop $4
|
||||
Pop $3
|
||||
Pop $2
|
||||
Pop $1
|
||||
Pop $0
|
||||
|
||||
!macroend
|
Binary file not shown.
Before Width: | Height: | Size: 2.2 KiB |
@ -1,128 +0,0 @@
|
||||
Unicode True
|
||||
SetCompressor /SOLID zlib ; LZMA compresses about 20% better but is more likely to trigger AV false positives
|
||||
|
||||
!define PRODUCT_NAME "Giants: Citizen Kabuto"
|
||||
!define PRODUCT_VERSION "1.499"
|
||||
|
||||
; MUI 1.67 compatible ------
|
||||
!include "MUI2.nsh"
|
||||
!include "DotNetChecker.nsh"
|
||||
|
||||
; MUI Settings
|
||||
!define MUI_ABORTWARNING
|
||||
!define MUI_ICON "GPatch.ico"
|
||||
|
||||
; Welcome page
|
||||
; Directory page
|
||||
!insertmacro MUI_PAGE_DIRECTORY
|
||||
; Instfiles page
|
||||
!insertmacro MUI_PAGE_INSTFILES
|
||||
; Finish page
|
||||
;!define MUI_FINISHPAGE_SHOWREADME $INSTDIR\readme.txt
|
||||
|
||||
!define MUI_FINISHPAGE_SHOWREADME_NOTCHECKED
|
||||
!insertmacro MUI_PAGE_FINISH
|
||||
|
||||
!define MUI_LANGDLL_REGISTRY_ROOT "HKCU"
|
||||
!define MUI_LANGDLL_REGISTRY_KEY "Software\PlanetMoon\Giants"
|
||||
!define MUI_LANGDLL_REGISTRY_VALUENAME "SetupLanguage"
|
||||
|
||||
; Language files
|
||||
!insertmacro MUI_LANGUAGE "English"
|
||||
!insertmacro MUI_LANGUAGE "French"
|
||||
!insertmacro MUI_LANGUAGE "German"
|
||||
!insertmacro MUI_LANGUAGE "Italian"
|
||||
!insertmacro MUI_LANGUAGE "Spanish"
|
||||
|
||||
; Language selection settings
|
||||
!define MUI_LANGDLL_WINDOWTITLE "Setup Language"
|
||||
|
||||
!include LogicLib.nsh
|
||||
|
||||
; MUI end ------
|
||||
|
||||
Name "${PRODUCT_NAME} ${PRODUCT_VERSION}"
|
||||
OutFile "Output\GPatch1_499_0_0.exe"
|
||||
InstallDir "$PROGRAMFILES\Giants\"
|
||||
InstallDirRegKey HKCU "SOFTWARE\PlanetMoon\Giants" "DestDir"
|
||||
ShowInstDetails hide
|
||||
|
||||
;Request application privileges for Windows Vista+
|
||||
RequestExecutionLevel admin
|
||||
|
||||
Section
|
||||
SetDetailsView hide
|
||||
SectionIn RO
|
||||
SetOverwrite on
|
||||
|
||||
nsExec::Exec "taskkill /F /IM Giants.exe"
|
||||
nsExec::Exec "taskkill /F /IM GiantsMain.exe"
|
||||
|
||||
; Install DX redist for DX9 renderer
|
||||
SetOutPath "$INSTDIR\Redist"
|
||||
File /r "Files\Redist\*.*"
|
||||
ExecWait "$INSTDIR\Redist\dxsetup.exe /silent" $0
|
||||
|
||||
${If} $0 != 0
|
||||
MessageBox MB_OK "Setup failed to update DirectX ($0). Please visit www.microsoft.com and download the latest version of the DirectX end user redistributable."
|
||||
${EndIf}
|
||||
|
||||
ExecWait "$INSTDIR\Redist\VC_redist.x86.exe /install /quiet /norestart /log $\"$Temp\GPatch_VCRedist.txt$\"" $0
|
||||
${If} $0 != 0
|
||||
${AndIf} $0 != 1638 ;0x666 - Newer version installed
|
||||
MessageBox MB_OK "Setup failed to install the Visual C++ Runtime. Please visit www.microsoft.com and download the latest version of the Visual C++ 2019 redistributable."
|
||||
${EndIf}
|
||||
|
||||
RMDir /r "$INSTDIR\Redist" ; Delete temporary files
|
||||
|
||||
; Delete old files
|
||||
Delete $INSTDIR\bin\Shaders\*.*
|
||||
Delete $INSTDIR\gg_dx7r.dll
|
||||
Delete $INSTDIR\gg_dx8r.dll
|
||||
Delete $INSTDIR\gg_dx9r.dll
|
||||
Delete $INSTDIR\gg_null.dll
|
||||
Delete $INSTDIR\Giants.exe
|
||||
Delete $INSTDIR\BugTrap.dll
|
||||
Delete $INSTDIR\GiantsMain.exe
|
||||
Delete $INSTDIR\*.vso
|
||||
Delete $INSTDIR\*.pso
|
||||
|
||||
SetOutPath "$INSTDIR"
|
||||
File /r "Files\*.*"
|
||||
|
||||
; remove old mods (may have compatibility issues)
|
||||
Delete $INSTDIR\bin\worldlist2.bin
|
||||
Delete $INSTDIR\bin\worldlist3.bin
|
||||
Delete $INSTDIR\bin\worldlist4.bin
|
||||
Delete $INSTDIR\bin\worldlist5.bin
|
||||
Delete $INSTDIR\bin\mappack1.gzp
|
||||
Delete $INSTDIR\bin\A-GRM1.gzp
|
||||
|
||||
SectionEnd
|
||||
|
||||
!define NETVersion "4.7.2"
|
||||
!define NETInstallerFileName "NDP472-KB4054531-Web.exe"
|
||||
!define NETInstallerPath "Files\Redist\NDP472-KB4054531-Web.exe"
|
||||
|
||||
Section "MS .NET Framework v${NETVersion}" SecFramework
|
||||
IfFileExists "$WINDIR\Microsoft.NET\Framework\v${NETVersion}" NETFrameworkInstalled 0
|
||||
File /oname=$TEMP\${NETInstallerFileName} "${NETInstallerPath}"
|
||||
|
||||
!insertmacro CheckNetFramework 472
|
||||
Return
|
||||
|
||||
NETFrameworkInstalled:
|
||||
DetailPrint "Microsoft .NET Framework is already installed!"
|
||||
SectionEnd
|
||||
|
||||
|
||||
;--------------------------------
|
||||
;Installer Functions
|
||||
|
||||
Function .onInit
|
||||
|
||||
!insertmacro MUI_LANGDLL_DISPLAY
|
||||
|
||||
FunctionEnd
|
||||
|
||||
;--------------------------------
|
Binary file not shown.
Before Width: | Height: | Size: 2.2 KiB |
@ -1,75 +0,0 @@
|
||||
SetCompressor /SOLID lzma
|
||||
|
||||
!define PRODUCT_NAME "Giants Launcher"
|
||||
!define PRODUCT_VERSION "1.0.0.2"
|
||||
|
||||
; MUI 1.67 compatible ------
|
||||
!include "MUI.nsh"
|
||||
|
||||
; MUI Settings
|
||||
!define MUI_ABORTWARNING
|
||||
!define MUI_ICON "GPatch.ico"
|
||||
|
||||
; Welcome page
|
||||
;!insertmacro MUI_PAGE_WELCOME
|
||||
; Directory page
|
||||
!insertmacro MUI_PAGE_DIRECTORY
|
||||
; Instfiles page
|
||||
!insertmacro MUI_PAGE_INSTFILES
|
||||
|
||||
!define MUI_LANGDLL_REGISTRY_ROOT "HKCU"
|
||||
!define MUI_LANGDLL_REGISTRY_KEY "Software\PlanetMoon\Giants"
|
||||
!define MUI_LANGDLL_REGISTRY_VALUENAME "SetupLanguage"
|
||||
|
||||
; Language files
|
||||
!insertmacro MUI_LANGUAGE "English"
|
||||
|
||||
; MUI end ------
|
||||
|
||||
Name "Giants Launcher Update"
|
||||
OutFile "LauncherUpdate_1002.exe"
|
||||
InstallDir "C:\Program Files\Giants"
|
||||
InstallDirRegKey HKCU "SOFTWARE\PlanetMoon\Giants" "DestDir"
|
||||
ShowInstDetails hide
|
||||
|
||||
;Request application privileges for Windows Vista
|
||||
RequestExecutionLevel admin
|
||||
|
||||
Section
|
||||
SetDetailsView hide
|
||||
SectionIn RO
|
||||
SetOverwrite on
|
||||
|
||||
|
||||
SetOutPath "$INSTDIR"
|
||||
File /r "Giants.exe"
|
||||
|
||||
|
||||
SectionEnd
|
||||
|
||||
Function .onInit
|
||||
Processes::KillProcess "Giants.exe"
|
||||
Processes::FindProcess "Giants.exe"
|
||||
${If} $R0 == 1
|
||||
MessageBox MB_OK "Please close the Giants launcher before installing this update."
|
||||
Abort
|
||||
${EndIf}
|
||||
|
||||
ClearErrors
|
||||
FileOpen $R0 "$INSTDIR\Giants.exe" w
|
||||
${If} ${Errors}
|
||||
MessageBox MB_OK "Could not write to Giants.exe. Please ensure the Giants launcher is closed."
|
||||
Abort
|
||||
${Else}
|
||||
FileClose $R0
|
||||
${EndIf}
|
||||
FunctionEnd
|
||||
|
||||
Function .onInstFailed
|
||||
MessageBox MB_OK "Update failed. Please visit www.giantswd.org and download the latest version manually."
|
||||
FunctionEnd
|
||||
|
||||
Function .onInstSuccess
|
||||
MessageBox MB_OK "Update complete!"
|
||||
Exec "$INSTDIR\Giants.exe"
|
||||
FunctionEnd
|
@ -59,7 +59,7 @@ int main(int argc, char** argv)
|
||||
{
|
||||
try
|
||||
{
|
||||
copy_file(outputPath, outputPath2);
|
||||
copy_file(outputPath, outputPath2, copy_options::overwrite_existing);
|
||||
}
|
||||
catch (const filesystem_error& ex)
|
||||
{
|
||||
|
@ -47,7 +47,7 @@ private:
|
||||
float m_agentHeight = 2.0f;
|
||||
float m_agentRadius = 0.6f;
|
||||
float m_agentMaxClimb = 0.9f;
|
||||
float m_agentMaxSlope = 60.0f; // Sample: 45.0f
|
||||
float m_agentMaxSlope = 50.0f; // Sample: 45.0f
|
||||
float m_regionMinSize = 8;
|
||||
float m_regionMergeSize = 20;
|
||||
float m_edgeMaxLen = 12.0f;
|
||||
|
31
Sdk/External/DirectXMath/.nuget/directxmath.nuspec
vendored
Normal file
31
Sdk/External/DirectXMath/.nuget/directxmath.nuspec
vendored
Normal file
@ -0,0 +1,31 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
|
||||
<metadata minClientVersion="2.8.6">
|
||||
<id>directxmath</id>
|
||||
<version>0.0.0-SpecifyVersionOnCommandline</version>
|
||||
<title>DirectXMath</title>
|
||||
<authors>Microsoft</authors>
|
||||
<owners>microsoft,directxtk</owners>
|
||||
<summary>DirectXMath is an all inline SIMD C++ linear algebra library for use in games and graphics apps.</summary>
|
||||
<description>The DirectXMath API provides SIMD-friendly C++ types and functions for common linear algebra and graphics math operations common to DirectX applications. The library provides optimized versions for Windows 32-bit (x86), Windows 64-bit (x64), and Windows on ARM through SSE2 and ARM-NEON intrinsics support in the Visual Studio compiler.</description>
|
||||
<releaseNotes>Matches the August 2020 release.</releaseNotes>
|
||||
<projectUrl>http://go.microsoft.com/fwlink/?LinkID=615560</projectUrl>
|
||||
<icon>images\icon.jpg</icon>
|
||||
<license type="expression">MIT</license>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<copyright>© Microsoft Corporation. All rights reserved.</copyright>
|
||||
<tags>C++ native DirectX math nativepackage</tags>
|
||||
</metadata>
|
||||
|
||||
<files>
|
||||
|
||||
<file target="docs" src="Readme.*" />
|
||||
|
||||
<file target="include" src="Inc\*" />
|
||||
|
||||
<file src=".nuget/directxmath.targets" target="build\native" />
|
||||
|
||||
<file src=".nuget/icon.jpg" target="images\" />
|
||||
|
||||
</files>
|
||||
</package>
|
11
Sdk/External/DirectXMath/.nuget/directxmath.targets
vendored
Normal file
11
Sdk/External/DirectXMath/.nuget/directxmath.targets
vendored
Normal file
@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
<PreprocessorDefinitions>HAS_DIRECTXMATH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>$(MSBuildThisFileDirectory)..\..\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
||||
</Project>
|
BIN
Sdk/External/DirectXMath/.nuget/icon.jpg
vendored
Normal file
BIN
Sdk/External/DirectXMath/.nuget/icon.jpg
vendored
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.4 KiB |
6
Sdk/External/DirectXMath/.nuget/signconfig.xml
vendored
Normal file
6
Sdk/External/DirectXMath/.nuget/signconfig.xml
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<SignConfigXML>
|
||||
<job dest="__OUTPATHROOT__" certSubject="NuGet" jobname="NugetSigningTest">
|
||||
<file src="__INPATHROOT__\directxmath*.nupkg" signType="CP-401405" dest="__OUTPATHROOT__\directxmath*.nupkg" />
|
||||
</job>
|
||||
</SignConfigXML>
|
275
Sdk/External/DirectXMath/Extensions/DirectXMathAVX.h
vendored
Normal file
275
Sdk/External/DirectXMath/Extensions/DirectXMathAVX.h
vendored
Normal file
@ -0,0 +1,275 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// DirectXMathAVX.h -- AVX (version 1) extensions for SIMD C++ Math library
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615560
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#if defined(_M_ARM) || defined(_M_ARM64) || defined(_M_HYBRID_X86_ARM64) || __arm__ || __aarch64__
|
||||
#error AVX not supported on ARM platform
|
||||
#endif
|
||||
|
||||
#include <DirectXMath.h>
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
|
||||
namespace AVX
|
||||
{
|
||||
|
||||
inline bool XMVerifyAVXSupport()
|
||||
{
|
||||
// Should return true for AMD Bulldozer, Intel "Sandy Bridge", and Intel "Ivy Bridge" or later processors
|
||||
// with OS support for AVX (Windows 7 Service Pack 1, Windows Server 2008 R2 Service Pack 1, Windows 8, Windows Server 2012)
|
||||
|
||||
// See http://msdn.microsoft.com/en-us/library/hskdteyh.aspx
|
||||
int CPUInfo[4] = {-1};
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(0, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid( CPUInfo, 0 );
|
||||
#endif
|
||||
|
||||
if ( CPUInfo[0] < 1 )
|
||||
return false;
|
||||
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(1, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 1 );
|
||||
#endif
|
||||
|
||||
// We check for AVX, OSXSAVE, SSSE4.1, and SSE3
|
||||
return ( (CPUInfo[2] & 0x18080001) == 0x18080001 );
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Vector
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorReplicatePtr( _In_ const float *pValue )
|
||||
{
|
||||
return _mm_broadcast_ss( pValue );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSplatX( FXMVECTOR V )
|
||||
{
|
||||
return _mm_permute_ps( V, _MM_SHUFFLE(0, 0, 0, 0) );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSplatY( FXMVECTOR V )
|
||||
{
|
||||
return _mm_permute_ps( V, _MM_SHUFFLE(1, 1, 1, 1) );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSplatZ( FXMVECTOR V )
|
||||
{
|
||||
return _mm_permute_ps( V, _MM_SHUFFLE(2, 2, 2, 2) );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSplatW( FXMVECTOR V )
|
||||
{
|
||||
return _mm_permute_ps( V, _MM_SHUFFLE(3, 3, 3, 3) );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSwizzle( FXMVECTOR V, uint32_t E0, uint32_t E1, uint32_t E2, uint32_t E3 )
|
||||
{
|
||||
assert( (E0 < 4) && (E1 < 4) && (E2 < 4) && (E3 < 4) );
|
||||
_Analysis_assume_( (E0 < 4) && (E1 < 4) && (E2 < 4) && (E3 < 4) );
|
||||
|
||||
unsigned int elem[4] = { E0, E1, E2, E3 };
|
||||
__m128i vControl = _mm_loadu_si128( reinterpret_cast<const __m128i *>(&elem[0]) );
|
||||
return _mm_permutevar_ps( V, vControl );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorPermute( FXMVECTOR V1, FXMVECTOR V2, uint32_t PermuteX, uint32_t PermuteY, uint32_t PermuteZ, uint32_t PermuteW )
|
||||
{
|
||||
assert( PermuteX <= 7 && PermuteY <= 7 && PermuteZ <= 7 && PermuteW <= 7 );
|
||||
_Analysis_assume_( PermuteX <= 7 && PermuteY <= 7 && PermuteZ <= 7 && PermuteW <= 7 );
|
||||
|
||||
static const XMVECTORU32 three = { { { 3, 3, 3, 3 } } };
|
||||
|
||||
XM_ALIGNED_DATA(16) unsigned int elem[4] = { PermuteX, PermuteY, PermuteZ, PermuteW };
|
||||
__m128i vControl = _mm_load_si128( reinterpret_cast<const __m128i *>(&elem[0]) );
|
||||
|
||||
__m128i vSelect = _mm_cmpgt_epi32( vControl, three );
|
||||
vControl = _mm_castps_si128( _mm_and_ps( _mm_castsi128_ps( vControl ), three ) );
|
||||
|
||||
__m128 shuffled1 = _mm_permutevar_ps( V1, vControl );
|
||||
__m128 shuffled2 = _mm_permutevar_ps( V2, vControl );
|
||||
|
||||
__m128 masked1 = _mm_andnot_ps( _mm_castsi128_ps( vSelect ), shuffled1 );
|
||||
__m128 masked2 = _mm_and_ps( _mm_castsi128_ps( vSelect ), shuffled2 );
|
||||
|
||||
return _mm_or_ps( masked1, masked2 );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorShiftLeft(FXMVECTOR V1, FXMVECTOR V2, uint32_t Elements)
|
||||
{
|
||||
assert( Elements < 4 );
|
||||
_Analysis_assume_( Elements < 4 );
|
||||
return AVX::XMVectorPermute(V1, V2, Elements, ((Elements) + 1), ((Elements) + 2), ((Elements) + 3));
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorRotateLeft(FXMVECTOR V, uint32_t Elements)
|
||||
{
|
||||
assert( Elements < 4 );
|
||||
_Analysis_assume_( Elements < 4 );
|
||||
return AVX::XMVectorSwizzle( V, Elements & 3, (Elements + 1) & 3, (Elements + 2) & 3, (Elements + 3) & 3 );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorRotateRight(FXMVECTOR V, uint32_t Elements)
|
||||
{
|
||||
assert( Elements < 4 );
|
||||
_Analysis_assume_( Elements < 4 );
|
||||
return AVX::XMVectorSwizzle( V, (4 - (Elements)) & 3, (5 - (Elements)) & 3, (6 - (Elements)) & 3, (7 - (Elements)) & 3 );
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Permute Templates
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
namespace Internal
|
||||
{
|
||||
// Slow path fallback for permutes that do not map to a single SSE opcode.
|
||||
template<uint32_t Shuffle, bool WhichX, bool WhichY, bool WhichZ, bool WhichW> struct PermuteHelper
|
||||
{
|
||||
static XMVECTOR XM_CALLCONV Permute(FXMVECTOR v1, FXMVECTOR v2)
|
||||
{
|
||||
static const XMVECTORU32 selectMask =
|
||||
{
|
||||
WhichX ? 0xFFFFFFFF : 0,
|
||||
WhichY ? 0xFFFFFFFF : 0,
|
||||
WhichZ ? 0xFFFFFFFF : 0,
|
||||
WhichW ? 0xFFFFFFFF : 0,
|
||||
};
|
||||
|
||||
XMVECTOR shuffled1 = _mm_permute_ps(v1, Shuffle);
|
||||
XMVECTOR shuffled2 = _mm_permute_ps(v2, Shuffle);
|
||||
|
||||
XMVECTOR masked1 = _mm_andnot_ps(selectMask, shuffled1);
|
||||
XMVECTOR masked2 = _mm_and_ps(selectMask, shuffled2);
|
||||
|
||||
return _mm_or_ps(masked1, masked2);
|
||||
}
|
||||
};
|
||||
|
||||
// Fast path for permutes that only read from the first vector.
|
||||
template<uint32_t Shuffle> struct PermuteHelper<Shuffle, false, false, false, false>
|
||||
{
|
||||
static XMVECTOR XM_CALLCONV Permute(FXMVECTOR v1, FXMVECTOR v2) { (v2); return _mm_permute_ps(v1, Shuffle); }
|
||||
};
|
||||
|
||||
// Fast path for permutes that only read from the second vector.
|
||||
template<uint32_t Shuffle> struct PermuteHelper<Shuffle, true, true, true, true>
|
||||
{
|
||||
static XMVECTOR XM_CALLCONV Permute(FXMVECTOR v1, FXMVECTOR v2){ (v1); return _mm_permute_ps(v2, Shuffle); }
|
||||
};
|
||||
|
||||
// Fast path for permutes that read XY from the first vector, ZW from the second.
|
||||
template<uint32_t Shuffle> struct PermuteHelper<Shuffle, false, false, true, true>
|
||||
{
|
||||
static XMVECTOR XM_CALLCONV Permute(FXMVECTOR v1, FXMVECTOR v2) { return _mm_shuffle_ps(v1, v2, Shuffle); }
|
||||
};
|
||||
|
||||
// Fast path for permutes that read XY from the second vector, ZW from the first.
|
||||
template<uint32_t Shuffle> struct PermuteHelper<Shuffle, true, true, false, false>
|
||||
{
|
||||
static XMVECTOR XM_CALLCONV Permute(FXMVECTOR v1, FXMVECTOR v2) { return _mm_shuffle_ps(v2, v1, Shuffle); }
|
||||
};
|
||||
};
|
||||
|
||||
// General permute template
|
||||
template<uint32_t PermuteX, uint32_t PermuteY, uint32_t PermuteZ, uint32_t PermuteW>
|
||||
inline XMVECTOR XM_CALLCONV XMVectorPermute(FXMVECTOR V1, FXMVECTOR V2)
|
||||
{
|
||||
static_assert(PermuteX <= 7, "PermuteX template parameter out of range");
|
||||
static_assert(PermuteY <= 7, "PermuteY template parameter out of range");
|
||||
static_assert(PermuteZ <= 7, "PermuteZ template parameter out of range");
|
||||
static_assert(PermuteW <= 7, "PermuteW template parameter out of range");
|
||||
|
||||
const uint32_t Shuffle = _MM_SHUFFLE(PermuteW & 3, PermuteZ & 3, PermuteY & 3, PermuteX & 3);
|
||||
|
||||
const bool WhichX = PermuteX > 3;
|
||||
const bool WhichY = PermuteY > 3;
|
||||
const bool WhichZ = PermuteZ > 3;
|
||||
const bool WhichW = PermuteW > 3;
|
||||
|
||||
return AVX::Internal::PermuteHelper<Shuffle, WhichX, WhichY, WhichZ, WhichW>::Permute(V1, V2);
|
||||
}
|
||||
|
||||
// Special-case permute templates
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<0,1,2,3>(FXMVECTOR V1, FXMVECTOR) { return V1; }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<4,5,6,7>(FXMVECTOR, FXMVECTOR V2) { return V2; }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<4,1,2,3>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0x1); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<0,5,2,3>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0x2); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<4,5,2,3>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0x3); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<0,1,6,3>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0x4); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<4,1,6,3>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0x5); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<0,5,6,3>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0x6); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<4,5,6,3>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0x7); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<0,1,2,7>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0x8); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<4,1,2,7>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0x9); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<0,5,2,7>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0xA); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<4,5,2,7>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0xB); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<0,1,6,7>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0xC); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<4,1,6,7>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0xD); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorPermute<0,5,6,7>(FXMVECTOR V1, FXMVECTOR V2) { return _mm_blend_ps(V1,V2,0xE); }
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Swizzle Templates
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
// General swizzle template
|
||||
template<uint32_t SwizzleX, uint32_t SwizzleY, uint32_t SwizzleZ, uint32_t SwizzleW>
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSwizzle(FXMVECTOR V)
|
||||
{
|
||||
static_assert(SwizzleX <= 3, "SwizzleX template parameter out of range");
|
||||
static_assert(SwizzleY <= 3, "SwizzleY template parameter out of range");
|
||||
static_assert(SwizzleZ <= 3, "SwizzleZ template parameter out of range");
|
||||
static_assert(SwizzleW <= 3, "SwizzleW template parameter out of range");
|
||||
|
||||
return _mm_permute_ps( V, _MM_SHUFFLE( SwizzleW, SwizzleZ, SwizzleY, SwizzleX ) );
|
||||
}
|
||||
|
||||
// Specialized swizzles
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorSwizzle<0,1,2,3>(FXMVECTOR V) { return V; }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorSwizzle<0,0,2,2>(FXMVECTOR V) { return _mm_moveldup_ps(V); }
|
||||
template<> inline XMVECTOR XM_CALLCONV XMVectorSwizzle<1,1,3,3>(FXMVECTOR V) { return _mm_movehdup_ps(V); }
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Other Templates
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
template<uint32_t Elements>
|
||||
inline XMVECTOR XM_CALLCONV XMVectorShiftLeft(FXMVECTOR V1, FXMVECTOR V2)
|
||||
{
|
||||
static_assert( Elements < 4, "Elements template parameter out of range" );
|
||||
return AVX::XMVectorPermute<Elements, (Elements + 1), (Elements + 2), (Elements + 3)>(V1, V2);
|
||||
}
|
||||
|
||||
template<uint32_t Elements>
|
||||
inline XMVECTOR XM_CALLCONV XMVectorRotateLeft(FXMVECTOR V)
|
||||
{
|
||||
static_assert( Elements < 4, "Elements template parameter out of range" );
|
||||
return AVX::XMVectorSwizzle<Elements & 3, (Elements + 1) & 3, (Elements + 2) & 3, (Elements + 3) & 3>(V);
|
||||
}
|
||||
|
||||
template<uint32_t Elements>
|
||||
inline XMVECTOR XM_CALLCONV XMVectorRotateRight(FXMVECTOR V)
|
||||
{
|
||||
static_assert( Elements < 4, "Elements template parameter out of range" );
|
||||
return AVX::XMVectorSwizzle<(4 - Elements) & 3, (5 - Elements) & 3, (6 - Elements) & 3, (7 - Elements) & 3>(V);
|
||||
}
|
||||
|
||||
} // namespace AVX
|
||||
|
||||
} // namespace DirectX;
|
1037
Sdk/External/DirectXMath/Extensions/DirectXMathAVX2.h
vendored
Normal file
1037
Sdk/External/DirectXMath/Extensions/DirectXMathAVX2.h
vendored
Normal file
File diff suppressed because it is too large
Load Diff
95
Sdk/External/DirectXMath/Extensions/DirectXMathBE.h
vendored
Normal file
95
Sdk/External/DirectXMath/Extensions/DirectXMathBE.h
vendored
Normal file
@ -0,0 +1,95 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// DirectXMathBE.h -- Big-endian swap extensions for SIMD C++ Math library
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615560
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#if (defined(_M_IX86) || defined(_M_X64) || __i386__ || __x86_64__) && !defined(_M_HYBRID_X86_ARM64)
|
||||
#include <tmmintrin.h>
|
||||
#endif
|
||||
|
||||
#include <DirectXMath.h>
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorEndian
|
||||
(
|
||||
FXMVECTOR V
|
||||
)
|
||||
{
|
||||
#if defined(_XM_ARM_NEON_INTRINSICS_) && !defined(_XM_NO_INTRINSICS_)
|
||||
static const XMVECTORU32 idx = { { { 0x00010203u, 0x04050607u, 0x08090A0Bu, 0x0C0D0E0Fu } } };
|
||||
|
||||
uint8x8x2_t tbl;
|
||||
tbl.val[0] = vreinterpret_u8_f32(vget_low_f32(V));
|
||||
tbl.val[1] = vreinterpret_u8_f32(vget_high_f32(V));
|
||||
|
||||
const uint8x8_t rL = vtbl2_u8(tbl, vget_low_u32(idx));
|
||||
const uint8x8_t rH = vtbl2_u8(tbl, vget_high_u32(idx));
|
||||
return vcombine_f32(vreinterpret_f32_u8(rL), vreinterpret_f32_u8(rH));
|
||||
#else
|
||||
XMVECTORU32 E;
|
||||
E.v = V;
|
||||
uint32_t value = E.u[0];
|
||||
E.u[0] = ( (value << 24) | ((value & 0xFF00) << 8) | ((value & 0xFF0000) >> 8) | (value >> 24) );
|
||||
value = E.u[1];
|
||||
E.u[1] = ( (value << 24) | ((value & 0xFF00) << 8) | ((value & 0xFF0000) >> 8) | (value >> 24) );
|
||||
value = E.u[2];
|
||||
E.u[2] = ( (value << 24) | ((value & 0xFF00) << 8) | ((value & 0xFF0000) >> 8) | (value >> 24) );
|
||||
value = E.u[3];
|
||||
E.u[3] = ( (value << 24) | ((value & 0xFF00) << 8) | ((value & 0xFF0000) >> 8) | (value >> 24) );
|
||||
return E.v;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
#if (defined(_M_IX86) || defined(_M_X64) || __i386__ || __x86_64__) && !defined(_M_HYBRID_X86_ARM64)
|
||||
namespace SSSE3
|
||||
{
|
||||
|
||||
inline bool XMVerifySSSE3Support()
|
||||
{
|
||||
// Should return true on AMD Bulldozer, Intel Core i7/i5/i3, Intel Atom, or later processors
|
||||
|
||||
// See http://msdn.microsoft.com/en-us/library/hskdteyh.aspx
|
||||
int CPUInfo[4] = { -1 };
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(0, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 0);
|
||||
#endif
|
||||
|
||||
if ( CPUInfo[0] < 1 )
|
||||
return false;
|
||||
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(1, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 1);
|
||||
#endif
|
||||
|
||||
// Check for SSSE3 instruction set.
|
||||
return ( (CPUInfo[2] & 0x200) != 0 );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorEndian
|
||||
(
|
||||
FXMVECTOR V
|
||||
)
|
||||
{
|
||||
static const XMVECTORU32 idx = { { { 0x00010203u, 0x04050607u, 0x08090A0Bu, 0x0C0D0E0Fu } } };
|
||||
|
||||
__m128i Result = _mm_shuffle_epi8( _mm_castps_si128(V), idx );
|
||||
return _mm_castsi128_ps( Result );
|
||||
}
|
||||
|
||||
} // namespace SSSE3
|
||||
#endif // X86 || X64
|
||||
|
||||
} // namespace DirectX
|
471
Sdk/External/DirectXMath/Extensions/DirectXMathF16C.h
vendored
Normal file
471
Sdk/External/DirectXMath/Extensions/DirectXMathF16C.h
vendored
Normal file
@ -0,0 +1,471 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// DirectXMathF16C.h -- F16C/CVT16 extensions for SIMD C++ Math library
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615560
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#if defined(_M_ARM) || defined(_M_ARM64) || defined(_M_HYBRID_X86_ARM64) || __arm__ || __aarch64__
|
||||
#error F16C not supported on ARM platform
|
||||
#endif
|
||||
|
||||
#include <DirectXMath.h>
|
||||
#include <DirectXPackedVector.h>
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
|
||||
namespace F16C
|
||||
{
|
||||
|
||||
inline bool XMVerifyF16CSupport()
|
||||
{
|
||||
// Should return true for AMD "Piledriver" and Intel "Ivy Bridge" processors
|
||||
// with OS support for AVX (Windows 7 Service Pack 1, Windows Server 2008 R2 Service Pack 1, Windows 8, Windows Server 2012)
|
||||
|
||||
// See http://msdn.microsoft.com/en-us/library/hskdteyh.aspx
|
||||
int CPUInfo[4] = { -1 };
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(0, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 0);
|
||||
#endif
|
||||
|
||||
if ( CPUInfo[0] < 1 )
|
||||
return false;
|
||||
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(1, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 1);
|
||||
#endif
|
||||
|
||||
// We check for F16C, AVX, OSXSAVE, and SSE4.1
|
||||
return ( (CPUInfo[2] & 0x38080000 ) == 0x38080000 );
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Data conversion
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline float XMConvertHalfToFloat( PackedVector::HALF Value )
|
||||
{
|
||||
__m128i V1 = _mm_cvtsi32_si128( static_cast<int>(Value) );
|
||||
__m128 V2 = _mm_cvtph_ps( V1 );
|
||||
return _mm_cvtss_f32( V2 );
|
||||
}
|
||||
|
||||
inline PackedVector::HALF XMConvertFloatToHalf( float Value )
|
||||
{
|
||||
__m128 V1 = _mm_set_ss( Value );
|
||||
__m128i V2 = _mm_cvtps_ph( V1, 0 );
|
||||
return static_cast<PackedVector::HALF>( _mm_cvtsi128_si32(V2) );
|
||||
}
|
||||
|
||||
inline float* XMConvertHalfToFloatStream
|
||||
(
|
||||
_Out_writes_bytes_(sizeof(float) + OutputStride * (HalfCount - 1)) float* pOutputStream,
|
||||
_In_ size_t OutputStride,
|
||||
_In_reads_bytes_(2 + InputStride * (HalfCount - 1)) const PackedVector::HALF* pInputStream,
|
||||
_In_ size_t InputStride,
|
||||
_In_ size_t HalfCount
|
||||
)
|
||||
{
|
||||
using namespace PackedVector;
|
||||
|
||||
assert(pOutputStream);
|
||||
assert(pInputStream);
|
||||
|
||||
assert(InputStride >= sizeof(HALF));
|
||||
assert(OutputStride >= sizeof(float));
|
||||
|
||||
auto pHalf = reinterpret_cast<const uint8_t*>(pInputStream);
|
||||
auto pFloat = reinterpret_cast<uint8_t*>(pOutputStream);
|
||||
|
||||
size_t i = 0;
|
||||
size_t four = HalfCount >> 2;
|
||||
if (four > 0)
|
||||
{
|
||||
if (InputStride == sizeof(HALF))
|
||||
{
|
||||
if (OutputStride == sizeof(float))
|
||||
{
|
||||
if ((reinterpret_cast<uintptr_t>(pFloat) & 0xF) == 0)
|
||||
{
|
||||
// Packed input, aligned & packed output
|
||||
for (size_t j = 0; j < four; ++j)
|
||||
{
|
||||
__m128i HV = _mm_loadl_epi64(reinterpret_cast<const __m128i*>(pHalf));
|
||||
pHalf += InputStride * 4;
|
||||
|
||||
__m128 FV = _mm_cvtph_ps(HV);
|
||||
|
||||
_mm_stream_ps(reinterpret_cast<float*>(pFloat), FV);
|
||||
pFloat += OutputStride * 4;
|
||||
i += 4;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Packed input, packed output
|
||||
for (size_t j = 0; j < four; ++j)
|
||||
{
|
||||
__m128i HV = _mm_loadl_epi64(reinterpret_cast<const __m128i*>(pHalf));
|
||||
pHalf += InputStride * 4;
|
||||
|
||||
__m128 FV = _mm_cvtph_ps(HV);
|
||||
|
||||
_mm_storeu_ps(reinterpret_cast<float*>(pFloat), FV);
|
||||
pFloat += OutputStride * 4;
|
||||
i += 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Packed input, scattered output
|
||||
for (size_t j = 0; j < four; ++j)
|
||||
{
|
||||
__m128i HV = _mm_loadl_epi64(reinterpret_cast<const __m128i*>(pHalf));
|
||||
pHalf += InputStride * 4;
|
||||
|
||||
__m128 FV = _mm_cvtph_ps(HV);
|
||||
|
||||
_mm_store_ss(reinterpret_cast<float*>(pFloat), FV);
|
||||
pFloat += OutputStride;
|
||||
*reinterpret_cast<int*>(pFloat) = _mm_extract_ps(FV, 1);
|
||||
pFloat += OutputStride;
|
||||
*reinterpret_cast<int*>(pFloat) = _mm_extract_ps(FV, 2);
|
||||
pFloat += OutputStride;
|
||||
*reinterpret_cast<int*>(pFloat) = _mm_extract_ps(FV, 3);
|
||||
pFloat += OutputStride;
|
||||
i += 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (OutputStride == sizeof(float))
|
||||
{
|
||||
if ((reinterpret_cast<uintptr_t>(pFloat) & 0xF) == 0)
|
||||
{
|
||||
// Scattered input, aligned & packed output
|
||||
for (size_t j = 0; j < four; ++j)
|
||||
{
|
||||
uint16_t H1 = *reinterpret_cast<const HALF*>(pHalf);
|
||||
pHalf += InputStride;
|
||||
uint16_t H2 = *reinterpret_cast<const HALF*>(pHalf);
|
||||
pHalf += InputStride;
|
||||
uint16_t H3 = *reinterpret_cast<const HALF*>(pHalf);
|
||||
pHalf += InputStride;
|
||||
uint16_t H4 = *reinterpret_cast<const HALF*>(pHalf);
|
||||
pHalf += InputStride;
|
||||
|
||||
__m128i HV = _mm_setzero_si128();
|
||||
HV = _mm_insert_epi16(HV, H1, 0);
|
||||
HV = _mm_insert_epi16(HV, H2, 1);
|
||||
HV = _mm_insert_epi16(HV, H3, 2);
|
||||
HV = _mm_insert_epi16(HV, H4, 3);
|
||||
__m128 FV = _mm_cvtph_ps(HV);
|
||||
|
||||
_mm_stream_ps(reinterpret_cast<float*>(pFloat), FV);
|
||||
pFloat += OutputStride * 4;
|
||||
i += 4;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Scattered input, packed output
|
||||
for (size_t j = 0; j < four; ++j)
|
||||
{
|
||||
uint16_t H1 = *reinterpret_cast<const HALF*>(pHalf);
|
||||
pHalf += InputStride;
|
||||
uint16_t H2 = *reinterpret_cast<const HALF*>(pHalf);
|
||||
pHalf += InputStride;
|
||||
uint16_t H3 = *reinterpret_cast<const HALF*>(pHalf);
|
||||
pHalf += InputStride;
|
||||
uint16_t H4 = *reinterpret_cast<const HALF*>(pHalf);
|
||||
pHalf += InputStride;
|
||||
|
||||
__m128i HV = _mm_setzero_si128();
|
||||
HV = _mm_insert_epi16(HV, H1, 0);
|
||||
HV = _mm_insert_epi16(HV, H2, 1);
|
||||
HV = _mm_insert_epi16(HV, H3, 2);
|
||||
HV = _mm_insert_epi16(HV, H4, 3);
|
||||
__m128 FV = _mm_cvtph_ps(HV);
|
||||
|
||||
_mm_storeu_ps(reinterpret_cast<float*>(pFloat), FV);
|
||||
pFloat += OutputStride * 4;
|
||||
i += 4;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Scattered input, scattered output
|
||||
for (size_t j = 0; j < four; ++j)
|
||||
{
|
||||
uint16_t H1 = *reinterpret_cast<const HALF*>(pHalf);
|
||||
pHalf += InputStride;
|
||||
uint16_t H2 = *reinterpret_cast<const HALF*>(pHalf);
|
||||
pHalf += InputStride;
|
||||
uint16_t H3 = *reinterpret_cast<const HALF*>(pHalf);
|
||||
pHalf += InputStride;
|
||||
uint16_t H4 = *reinterpret_cast<const HALF*>(pHalf);
|
||||
pHalf += InputStride;
|
||||
|
||||
__m128i HV = _mm_setzero_si128();
|
||||
HV = _mm_insert_epi16(HV, H1, 0);
|
||||
HV = _mm_insert_epi16(HV, H2, 1);
|
||||
HV = _mm_insert_epi16(HV, H3, 2);
|
||||
HV = _mm_insert_epi16(HV, H4, 3);
|
||||
__m128 FV = _mm_cvtph_ps(HV);
|
||||
|
||||
_mm_store_ss(reinterpret_cast<float*>(pFloat), FV);
|
||||
pFloat += OutputStride;
|
||||
*reinterpret_cast<int*>(pFloat) = _mm_extract_ps(FV, 1);
|
||||
pFloat += OutputStride;
|
||||
*reinterpret_cast<int*>(pFloat) = _mm_extract_ps(FV, 2);
|
||||
pFloat += OutputStride;
|
||||
*reinterpret_cast<int*>(pFloat) = _mm_extract_ps(FV, 3);
|
||||
pFloat += OutputStride;
|
||||
i += 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
for (; i < HalfCount; ++i)
|
||||
{
|
||||
*reinterpret_cast<float*>(pFloat) = XMConvertHalfToFloat(reinterpret_cast<const HALF*>(pHalf)[0]);
|
||||
pHalf += InputStride;
|
||||
pFloat += OutputStride;
|
||||
}
|
||||
|
||||
return pOutputStream;
|
||||
}
|
||||
|
||||
|
||||
inline PackedVector::HALF* XMConvertFloatToHalfStream
|
||||
(
|
||||
_Out_writes_bytes_(2 + OutputStride * (FloatCount - 1)) PackedVector::HALF* pOutputStream,
|
||||
_In_ size_t OutputStride,
|
||||
_In_reads_bytes_(sizeof(float) + InputStride * (FloatCount - 1)) const float* pInputStream,
|
||||
_In_ size_t InputStride,
|
||||
_In_ size_t FloatCount
|
||||
)
|
||||
{
|
||||
using namespace PackedVector;
|
||||
|
||||
assert(pOutputStream);
|
||||
assert(pInputStream);
|
||||
|
||||
assert(InputStride >= sizeof(float));
|
||||
assert(OutputStride >= sizeof(HALF));
|
||||
|
||||
auto pFloat = reinterpret_cast<const uint8_t*>(pInputStream);
|
||||
auto pHalf = reinterpret_cast<uint8_t*>(pOutputStream);
|
||||
|
||||
size_t i = 0;
|
||||
size_t four = FloatCount >> 2;
|
||||
if (four > 0)
|
||||
{
|
||||
if (InputStride == sizeof(float))
|
||||
{
|
||||
if (OutputStride == sizeof(HALF))
|
||||
{
|
||||
if ((reinterpret_cast<uintptr_t>(pFloat) & 0xF) == 0)
|
||||
{
|
||||
// Aligned and packed input, packed output
|
||||
for (size_t j = 0; j < four; ++j)
|
||||
{
|
||||
__m128 FV = _mm_load_ps(reinterpret_cast<const float*>(pFloat));
|
||||
pFloat += InputStride * 4;
|
||||
|
||||
__m128i HV = _mm_cvtps_ph(FV, 0);
|
||||
|
||||
_mm_storel_epi64(reinterpret_cast<__m128i*>(pHalf), HV);
|
||||
pHalf += OutputStride * 4;
|
||||
i += 4;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Packed input, packed output
|
||||
for (size_t j = 0; j < four; ++j)
|
||||
{
|
||||
__m128 FV = _mm_loadu_ps(reinterpret_cast<const float*>(pFloat));
|
||||
pFloat += InputStride * 4;
|
||||
|
||||
__m128i HV = _mm_cvtps_ph(FV, 0);
|
||||
|
||||
_mm_storel_epi64(reinterpret_cast<__m128i*>(pHalf), HV);
|
||||
pHalf += OutputStride * 4;
|
||||
i += 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if ((reinterpret_cast<uintptr_t>(pFloat) & 0xF) == 0)
|
||||
{
|
||||
// Aligned & packed input, scattered output
|
||||
for (size_t j = 0; j < four; ++j)
|
||||
{
|
||||
__m128 FV = _mm_load_ps(reinterpret_cast<const float*>(pFloat));
|
||||
pFloat += InputStride * 4;
|
||||
|
||||
__m128i HV = _mm_cvtps_ph(FV, 0);
|
||||
|
||||
*reinterpret_cast<HALF*>(pHalf) = static_cast<HALF>(_mm_extract_epi16(HV, 0));
|
||||
pHalf += OutputStride;
|
||||
*reinterpret_cast<HALF*>(pHalf) = static_cast<HALF>(_mm_extract_epi16(HV, 1));
|
||||
pHalf += OutputStride;
|
||||
*reinterpret_cast<HALF*>(pHalf) = static_cast<HALF>(_mm_extract_epi16(HV, 2));
|
||||
pHalf += OutputStride;
|
||||
*reinterpret_cast<HALF*>(pHalf) = static_cast<HALF>(_mm_extract_epi16(HV, 3));
|
||||
pHalf += OutputStride;
|
||||
i += 4;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Packed input, scattered output
|
||||
for (size_t j = 0; j < four; ++j)
|
||||
{
|
||||
__m128 FV = _mm_loadu_ps(reinterpret_cast<const float*>(pFloat));
|
||||
pFloat += InputStride * 4;
|
||||
|
||||
__m128i HV = _mm_cvtps_ph(FV, 0);
|
||||
|
||||
*reinterpret_cast<HALF*>(pHalf) = static_cast<HALF>(_mm_extract_epi16(HV, 0));
|
||||
pHalf += OutputStride;
|
||||
*reinterpret_cast<HALF*>(pHalf) = static_cast<HALF>(_mm_extract_epi16(HV, 1));
|
||||
pHalf += OutputStride;
|
||||
*reinterpret_cast<HALF*>(pHalf) = static_cast<HALF>(_mm_extract_epi16(HV, 2));
|
||||
pHalf += OutputStride;
|
||||
*reinterpret_cast<HALF*>(pHalf) = static_cast<HALF>(_mm_extract_epi16(HV, 3));
|
||||
pHalf += OutputStride;
|
||||
i += 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (OutputStride == sizeof(HALF))
|
||||
{
|
||||
// Scattered input, packed output
|
||||
for (size_t j = 0; j < four; ++j)
|
||||
{
|
||||
__m128 FV1 = _mm_load_ss(reinterpret_cast<const float*>(pFloat));
|
||||
pFloat += InputStride;
|
||||
|
||||
__m128 FV2 = _mm_broadcast_ss(reinterpret_cast<const float*>(pFloat));
|
||||
pFloat += InputStride;
|
||||
|
||||
__m128 FV3 = _mm_broadcast_ss(reinterpret_cast<const float*>(pFloat));
|
||||
pFloat += InputStride;
|
||||
|
||||
__m128 FV4 = _mm_broadcast_ss(reinterpret_cast<const float*>(pFloat));
|
||||
pFloat += InputStride;
|
||||
|
||||
__m128 FV = _mm_blend_ps(FV1, FV2, 0x2);
|
||||
__m128 FT = _mm_blend_ps(FV3, FV4, 0x8);
|
||||
FV = _mm_blend_ps(FV, FT, 0xC);
|
||||
|
||||
__m128i HV = _mm_cvtps_ph(FV, 0);
|
||||
|
||||
_mm_storel_epi64(reinterpret_cast<__m128i*>(pHalf), HV);
|
||||
pHalf += OutputStride * 4;
|
||||
i += 4;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Scattered input, scattered output
|
||||
for (size_t j = 0; j < four; ++j)
|
||||
{
|
||||
__m128 FV1 = _mm_load_ss(reinterpret_cast<const float*>(pFloat));
|
||||
pFloat += InputStride;
|
||||
|
||||
__m128 FV2 = _mm_broadcast_ss(reinterpret_cast<const float*>(pFloat));
|
||||
pFloat += InputStride;
|
||||
|
||||
__m128 FV3 = _mm_broadcast_ss(reinterpret_cast<const float*>(pFloat));
|
||||
pFloat += InputStride;
|
||||
|
||||
__m128 FV4 = _mm_broadcast_ss(reinterpret_cast<const float*>(pFloat));
|
||||
pFloat += InputStride;
|
||||
|
||||
__m128 FV = _mm_blend_ps(FV1, FV2, 0x2);
|
||||
__m128 FT = _mm_blend_ps(FV3, FV4, 0x8);
|
||||
FV = _mm_blend_ps(FV, FT, 0xC);
|
||||
|
||||
__m128i HV = _mm_cvtps_ph(FV, 0);
|
||||
|
||||
*reinterpret_cast<HALF*>(pHalf) = static_cast<HALF>(_mm_extract_epi16(HV, 0));
|
||||
pHalf += OutputStride;
|
||||
*reinterpret_cast<HALF*>(pHalf) = static_cast<HALF>(_mm_extract_epi16(HV, 1));
|
||||
pHalf += OutputStride;
|
||||
*reinterpret_cast<HALF*>(pHalf) = static_cast<HALF>(_mm_extract_epi16(HV, 2));
|
||||
pHalf += OutputStride;
|
||||
*reinterpret_cast<HALF*>(pHalf) = static_cast<HALF>(_mm_extract_epi16(HV, 3));
|
||||
pHalf += OutputStride;
|
||||
i += 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
for (; i < FloatCount; ++i)
|
||||
{
|
||||
*reinterpret_cast<HALF*>(pHalf) = XMConvertFloatToHalf(reinterpret_cast<const float*>(pFloat)[0]);
|
||||
pFloat += InputStride;
|
||||
pHalf += OutputStride;
|
||||
}
|
||||
|
||||
return pOutputStream;
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Half2
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMLoadHalf2( _In_ const PackedVector::XMHALF2* pSource )
|
||||
{
|
||||
assert(pSource);
|
||||
__m128 V = _mm_load_ss( reinterpret_cast<const float*>(pSource) );
|
||||
return _mm_cvtph_ps( _mm_castps_si128( V ) );
|
||||
}
|
||||
|
||||
inline void XM_CALLCONV XMStoreHalf2( _Out_ PackedVector::XMHALF2* pDestination, _In_ FXMVECTOR V )
|
||||
{
|
||||
assert(pDestination);
|
||||
__m128i V1 = _mm_cvtps_ph( V, 0 );
|
||||
_mm_store_ss( reinterpret_cast<float*>(pDestination), _mm_castsi128_ps(V1) );
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Half4
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMLoadHalf4( _In_ const PackedVector::XMHALF4* pSource )
|
||||
{
|
||||
assert(pSource);
|
||||
__m128i V = _mm_loadl_epi64( reinterpret_cast<const __m128i*>(pSource) );
|
||||
return _mm_cvtph_ps( V );
|
||||
}
|
||||
|
||||
inline void XM_CALLCONV XMStoreHalf4( _Out_ PackedVector::XMHALF4* pDestination, _In_ FXMVECTOR V )
|
||||
{
|
||||
assert(pDestination);
|
||||
__m128i V1 = _mm_cvtps_ph( V, 0 );
|
||||
_mm_storel_epi64( reinterpret_cast<__m128i*>(pDestination), V1 );
|
||||
}
|
||||
|
||||
} // namespace F16C
|
||||
|
||||
} // namespace DirectX
|
391
Sdk/External/DirectXMath/Extensions/DirectXMathFMA3.h
vendored
Normal file
391
Sdk/External/DirectXMath/Extensions/DirectXMathFMA3.h
vendored
Normal file
@ -0,0 +1,391 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// DirectXMathFMA3.h -- FMA3 extensions for SIMD C++ Math library
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615560
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#if defined(_M_ARM) || defined(_M_ARM64) || defined(_M_HYBRID_X86_ARM64) || __arm__ || __aarch64__
|
||||
#error FMA3 not supported on ARM platform
|
||||
#endif
|
||||
|
||||
#include <DirectXMath.h>
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
|
||||
namespace FMA3
|
||||
{
|
||||
|
||||
inline bool XMVerifyFMA3Support()
|
||||
{
|
||||
// Should return true for AMD "Pildriver" and Intel "Haswell" processors
|
||||
// with OS support for AVX (Windows 7 Service Pack 1, Windows Server 2008 R2 Service Pack 1, Windows 8, Windows Server 2012)
|
||||
|
||||
// See http://msdn.microsoft.com/en-us/library/hskdteyh.aspx
|
||||
int CPUInfo[4] = {-1};
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(0, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 0);
|
||||
#endif
|
||||
|
||||
if ( CPUInfo[0] < 1 )
|
||||
return false;
|
||||
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(1, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 1);
|
||||
#endif
|
||||
|
||||
// We check for FMA3, AVX, OSXSAVE
|
||||
return ( (CPUInfo[2] & 0x18001000) == 0x18001000 );
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Vector
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorMultiplyAdd
|
||||
(
|
||||
FXMVECTOR V1,
|
||||
FXMVECTOR V2,
|
||||
FXMVECTOR V3
|
||||
)
|
||||
{
|
||||
return _mm_fmadd_ps( V1, V2, V3 );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorNegativeMultiplySubtract
|
||||
(
|
||||
FXMVECTOR V1,
|
||||
FXMVECTOR V2,
|
||||
FXMVECTOR V3
|
||||
)
|
||||
{
|
||||
return _mm_fnmadd_ps( V1, V2, V3 );
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Vector2
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2Transform
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_fmadd_ps( vResult, M.r[1], M.r[3] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_fmadd_ps( vTemp, M.r[0], vResult );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2TransformCoord
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_fmadd_ps( vResult, M.r[1], M.r[3] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_fmadd_ps( vTemp, M.r[0], vResult );
|
||||
XMVECTOR W = _mm_permute_ps(vResult,_MM_SHUFFLE(3,3,3,3));
|
||||
vResult = _mm_div_ps( vResult, W );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2TransformNormal
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_mul_ps( vResult, M.r[1] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_fmadd_ps( vTemp, M.r[0], vResult );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Vector3
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3Transform
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(2,2,2,2)); // Z
|
||||
vResult = _mm_fmadd_ps( vResult, M.r[2], M.r[3] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_fmadd_ps( vTemp, M.r[1], vResult );
|
||||
vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_fmadd_ps( vTemp, M.r[0], vResult );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3TransformCoord
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(2,2,2,2)); // Z
|
||||
vResult = _mm_fmadd_ps( vResult, M.r[2], M.r[3] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_fmadd_ps( vTemp, M.r[1], vResult );
|
||||
vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_fmadd_ps( vTemp, M.r[0], vResult );
|
||||
XMVECTOR W = _mm_permute_ps(vResult,_MM_SHUFFLE(3,3,3,3));
|
||||
vResult = _mm_div_ps( vResult, W );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3TransformNormal
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(2,2,2,2)); // Z
|
||||
vResult = _mm_mul_ps( vResult, M.r[2] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_fmadd_ps( vTemp, M.r[1], vResult );
|
||||
vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_fmadd_ps( vTemp, M.r[0], vResult );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
XMMATRIX XM_CALLCONV XMMatrixMultiply(CXMMATRIX M1, CXMMATRIX M2);
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3Project
|
||||
(
|
||||
FXMVECTOR V,
|
||||
float ViewportX,
|
||||
float ViewportY,
|
||||
float ViewportWidth,
|
||||
float ViewportHeight,
|
||||
float ViewportMinZ,
|
||||
float ViewportMaxZ,
|
||||
CXMMATRIX Projection,
|
||||
CXMMATRIX View,
|
||||
CXMMATRIX World
|
||||
)
|
||||
{
|
||||
const float HalfViewportWidth = ViewportWidth * 0.5f;
|
||||
const float HalfViewportHeight = ViewportHeight * 0.5f;
|
||||
|
||||
XMVECTOR Scale = XMVectorSet(HalfViewportWidth, -HalfViewportHeight, ViewportMaxZ - ViewportMinZ, 0.0f);
|
||||
XMVECTOR Offset = XMVectorSet(ViewportX + HalfViewportWidth, ViewportY + HalfViewportHeight, ViewportMinZ, 0.0f);
|
||||
|
||||
XMMATRIX Transform = FMA3::XMMatrixMultiply(World, View);
|
||||
Transform = FMA3::XMMatrixMultiply(Transform, Projection);
|
||||
|
||||
XMVECTOR Result = FMA3::XMVector3TransformCoord(V, Transform);
|
||||
|
||||
Result = FMA3::XMVectorMultiplyAdd(Result, Scale, Offset);
|
||||
|
||||
return Result;
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3Unproject
|
||||
(
|
||||
FXMVECTOR V,
|
||||
float ViewportX,
|
||||
float ViewportY,
|
||||
float ViewportWidth,
|
||||
float ViewportHeight,
|
||||
float ViewportMinZ,
|
||||
float ViewportMaxZ,
|
||||
CXMMATRIX Projection,
|
||||
CXMMATRIX View,
|
||||
CXMMATRIX World
|
||||
)
|
||||
{
|
||||
static const XMVECTORF32 D = { { { -1.0f, 1.0f, 0.0f, 0.0f } } };
|
||||
|
||||
XMVECTOR Scale = XMVectorSet(ViewportWidth * 0.5f, -ViewportHeight * 0.5f, ViewportMaxZ - ViewportMinZ, 1.0f);
|
||||
Scale = XMVectorReciprocal(Scale);
|
||||
|
||||
XMVECTOR Offset = XMVectorSet(-ViewportX, -ViewportY, -ViewportMinZ, 0.0f);
|
||||
Offset = FMA3::XMVectorMultiplyAdd(Scale, Offset, D.v);
|
||||
|
||||
XMMATRIX Transform = FMA3::XMMatrixMultiply(World, View);
|
||||
Transform = FMA3::XMMatrixMultiply(Transform, Projection);
|
||||
Transform = XMMatrixInverse(nullptr, Transform);
|
||||
|
||||
XMVECTOR Result = FMA3::XMVectorMultiplyAdd(V, Scale, Offset);
|
||||
|
||||
return FMA3::XMVector3TransformCoord(Result, Transform);
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Vector4
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector4Transform
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(3,3,3,3)); // W
|
||||
vResult = _mm_mul_ps( vResult, M.r[3] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(2,2,2,2)); // Z
|
||||
vResult = _mm_fmadd_ps( vTemp, M.r[2], vResult );
|
||||
vTemp = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_fmadd_ps( vTemp, M.r[1], vResult );
|
||||
vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_fmadd_ps( vTemp, M.r[0], vResult );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Matrix
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMMATRIX XM_CALLCONV XMMatrixMultiply
|
||||
(
|
||||
CXMMATRIX M1,
|
||||
CXMMATRIX M2
|
||||
)
|
||||
{
|
||||
XMMATRIX mResult;
|
||||
// Use vW to hold the original row
|
||||
XMVECTOR vW = M1.r[0];
|
||||
// Splat the component X,Y,Z then W
|
||||
XMVECTOR vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
XMVECTOR vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
XMVECTOR vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
// Perform the operation on the first row
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_fmadd_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_fmadd_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_fmadd_ps(vW,M2.r[3],vX);
|
||||
mResult.r[0] = vX;
|
||||
// Repeat for the other 3 rows
|
||||
vW = M1.r[1];
|
||||
vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_fmadd_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_fmadd_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_fmadd_ps(vW,M2.r[3],vX);
|
||||
mResult.r[1] = vX;
|
||||
vW = M1.r[2];
|
||||
vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_fmadd_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_fmadd_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_fmadd_ps(vW,M2.r[3],vX);
|
||||
mResult.r[2] = vX;
|
||||
vW = M1.r[3];
|
||||
vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_fmadd_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_fmadd_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_fmadd_ps(vW,M2.r[3],vX);
|
||||
mResult.r[3] = vX;
|
||||
return mResult;
|
||||
}
|
||||
|
||||
inline XMMATRIX XM_CALLCONV XMMatrixMultiplyTranspose
|
||||
(
|
||||
FXMMATRIX M1,
|
||||
CXMMATRIX M2
|
||||
)
|
||||
{
|
||||
// Use vW to hold the original row
|
||||
XMVECTOR vW = M1.r[0];
|
||||
// Splat the component X,Y,Z then W
|
||||
XMVECTOR vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
XMVECTOR vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
XMVECTOR vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
// Perform the operation on the first row
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_fmadd_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_fmadd_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_fmadd_ps(vW,M2.r[3],vX);
|
||||
__m128 r0 = vX;
|
||||
// Repeat for the other 3 rows
|
||||
vW = M1.r[1];
|
||||
vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_fmadd_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_fmadd_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_fmadd_ps(vW,M2.r[3],vX);
|
||||
__m128 r1 = vX;
|
||||
vW = M1.r[2];
|
||||
vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_fmadd_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_fmadd_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_fmadd_ps(vW,M2.r[3],vX);
|
||||
__m128 r2 = vX;
|
||||
vW = M1.r[3];
|
||||
vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_fmadd_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_fmadd_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_fmadd_ps(vW,M2.r[3],vX);
|
||||
__m128 r3 = vX;
|
||||
|
||||
// x.x,x.y,y.x,y.y
|
||||
XMVECTOR vTemp1 = _mm_shuffle_ps(r0,r1,_MM_SHUFFLE(1,0,1,0));
|
||||
// x.z,x.w,y.z,y.w
|
||||
XMVECTOR vTemp3 = _mm_shuffle_ps(r0,r1,_MM_SHUFFLE(3,2,3,2));
|
||||
// z.x,z.y,w.x,w.y
|
||||
XMVECTOR vTemp2 = _mm_shuffle_ps(r2,r3,_MM_SHUFFLE(1,0,1,0));
|
||||
// z.z,z.w,w.z,w.w
|
||||
XMVECTOR vTemp4 = _mm_shuffle_ps(r2,r3,_MM_SHUFFLE(3,2,3,2));
|
||||
|
||||
XMMATRIX mResult;
|
||||
// x.x,y.x,z.x,w.x
|
||||
mResult.r[0] = _mm_shuffle_ps(vTemp1, vTemp2,_MM_SHUFFLE(2,0,2,0));
|
||||
// x.y,y.y,z.y,w.y
|
||||
mResult.r[1] = _mm_shuffle_ps(vTemp1, vTemp2,_MM_SHUFFLE(3,1,3,1));
|
||||
// x.z,y.z,z.z,w.z
|
||||
mResult.r[2] = _mm_shuffle_ps(vTemp3, vTemp4,_MM_SHUFFLE(2,0,2,0));
|
||||
// x.w,y.w,z.w,w.w
|
||||
mResult.r[3] = _mm_shuffle_ps(vTemp3, vTemp4,_MM_SHUFFLE(3,1,3,1));
|
||||
return mResult;
|
||||
}
|
||||
|
||||
} // namespace FMA3
|
||||
|
||||
} // namespace DirectX;
|
415
Sdk/External/DirectXMath/Extensions/DirectXMathFMA4.h
vendored
Normal file
415
Sdk/External/DirectXMath/Extensions/DirectXMathFMA4.h
vendored
Normal file
@ -0,0 +1,415 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// DirectXMathFMA4.h -- FMA4 extensions for SIMD C++ Math library
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615560
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#if defined(_M_ARM) || defined(_M_ARM64) || defined(_M_HYBRID_X86_ARM64) || __arm__ || __aarch64__
|
||||
#error FMA4 not supported on ARM platform
|
||||
#endif
|
||||
|
||||
#include <DirectXMath.h>
|
||||
#include <ammintrin.h>
|
||||
|
||||
#ifdef __GNUC__
|
||||
#include <x86intrin.h>
|
||||
#endif
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
|
||||
namespace FMA4
|
||||
{
|
||||
|
||||
inline bool XMVerifyFMA4Support()
|
||||
{
|
||||
// Should return true for AMD Bulldozer processors
|
||||
// with OS support for AVX (Windows 7 Service Pack 1, Windows Server 2008 R2 Service Pack 1, Windows 8, Windows Server 2012)
|
||||
|
||||
// See http://msdn.microsoft.com/en-us/library/hskdteyh.aspx
|
||||
int CPUInfo[4] = {-1};
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(0, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 0);
|
||||
#endif
|
||||
|
||||
if ( CPUInfo[0] < 1 )
|
||||
return false;
|
||||
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(1, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 1);
|
||||
#endif
|
||||
|
||||
// We check for AVX, OSXSAVE (required to access FMA4)
|
||||
if ( (CPUInfo[2] & 0x18000000) != 0x18000000 )
|
||||
return false;
|
||||
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(0x80000000, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 0x80000000);
|
||||
#endif
|
||||
|
||||
if ( uint32_t(CPUInfo[0]) < 0x80000001u )
|
||||
return false;
|
||||
|
||||
// We check for FMA4
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(0x80000001, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 0x80000001);
|
||||
#endif
|
||||
|
||||
return ( CPUInfo[2] & 0x10000 );
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Vector
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorMultiplyAdd
|
||||
(
|
||||
FXMVECTOR V1,
|
||||
FXMVECTOR V2,
|
||||
FXMVECTOR V3
|
||||
)
|
||||
{
|
||||
return _mm_macc_ps( V1, V2, V3 );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorNegativeMultiplySubtract
|
||||
(
|
||||
FXMVECTOR V1,
|
||||
FXMVECTOR V2,
|
||||
FXMVECTOR V3
|
||||
)
|
||||
{
|
||||
return _mm_nmacc_ps( V1, V2, V3 );
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Vector2
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2Transform
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_macc_ps( vResult, M.r[1], M.r[3] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_macc_ps( vTemp, M.r[0], vResult );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2TransformCoord
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_macc_ps( vResult, M.r[1], M.r[3] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_macc_ps( vTemp, M.r[0], vResult );
|
||||
XMVECTOR W = _mm_permute_ps(vResult,_MM_SHUFFLE(3,3,3,3));
|
||||
vResult = _mm_div_ps( vResult, W );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2TransformNormal
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_mul_ps( vResult, M.r[1] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_macc_ps( vTemp, M.r[0], vResult );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Vector3
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3Transform
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(2,2,2,2)); // Z
|
||||
vResult = _mm_macc_ps( vResult, M.r[2], M.r[3] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_macc_ps( vTemp, M.r[1], vResult );
|
||||
vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_macc_ps( vTemp, M.r[0], vResult );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3TransformCoord
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(2,2,2,2)); // Z
|
||||
vResult = _mm_macc_ps( vResult, M.r[2], M.r[3] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_macc_ps( vTemp, M.r[1], vResult );
|
||||
vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_macc_ps( vTemp, M.r[0], vResult );
|
||||
XMVECTOR W = _mm_permute_ps(vResult,_MM_SHUFFLE(3,3,3,3));
|
||||
vResult = _mm_div_ps( vResult, W );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3TransformNormal
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(2,2,2,2)); // Z
|
||||
vResult = _mm_mul_ps( vResult, M.r[2] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_macc_ps( vTemp, M.r[1], vResult );
|
||||
vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_macc_ps( vTemp, M.r[0], vResult );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
XMMATRIX XM_CALLCONV XMMatrixMultiply(CXMMATRIX M1, CXMMATRIX M2);
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3Project
|
||||
(
|
||||
FXMVECTOR V,
|
||||
float ViewportX,
|
||||
float ViewportY,
|
||||
float ViewportWidth,
|
||||
float ViewportHeight,
|
||||
float ViewportMinZ,
|
||||
float ViewportMaxZ,
|
||||
CXMMATRIX Projection,
|
||||
CXMMATRIX View,
|
||||
CXMMATRIX World
|
||||
)
|
||||
{
|
||||
const float HalfViewportWidth = ViewportWidth * 0.5f;
|
||||
const float HalfViewportHeight = ViewportHeight * 0.5f;
|
||||
|
||||
XMVECTOR Scale = XMVectorSet(HalfViewportWidth, -HalfViewportHeight, ViewportMaxZ - ViewportMinZ, 0.0f);
|
||||
XMVECTOR Offset = XMVectorSet(ViewportX + HalfViewportWidth, ViewportY + HalfViewportHeight, ViewportMinZ, 0.0f);
|
||||
|
||||
XMMATRIX Transform = FMA4::XMMatrixMultiply(World, View);
|
||||
Transform = FMA4::XMMatrixMultiply(Transform, Projection);
|
||||
|
||||
XMVECTOR Result = FMA4::XMVector3TransformCoord(V, Transform);
|
||||
|
||||
Result = FMA4::XMVectorMultiplyAdd(Result, Scale, Offset);
|
||||
|
||||
return Result;
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3Unproject
|
||||
(
|
||||
FXMVECTOR V,
|
||||
float ViewportX,
|
||||
float ViewportY,
|
||||
float ViewportWidth,
|
||||
float ViewportHeight,
|
||||
float ViewportMinZ,
|
||||
float ViewportMaxZ,
|
||||
CXMMATRIX Projection,
|
||||
CXMMATRIX View,
|
||||
CXMMATRIX World
|
||||
)
|
||||
{
|
||||
static const XMVECTORF32 D = { { { -1.0f, 1.0f, 0.0f, 0.0f } } };
|
||||
|
||||
XMVECTOR Scale = XMVectorSet(ViewportWidth * 0.5f, -ViewportHeight * 0.5f, ViewportMaxZ - ViewportMinZ, 1.0f);
|
||||
Scale = XMVectorReciprocal(Scale);
|
||||
|
||||
XMVECTOR Offset = XMVectorSet(-ViewportX, -ViewportY, -ViewportMinZ, 0.0f);
|
||||
Offset = FMA4::XMVectorMultiplyAdd(Scale, Offset, D.v);
|
||||
|
||||
XMMATRIX Transform = FMA4::XMMatrixMultiply(World, View);
|
||||
Transform = FMA4::XMMatrixMultiply(Transform, Projection);
|
||||
Transform = XMMatrixInverse(nullptr, Transform);
|
||||
|
||||
XMVECTOR Result = FMA4::XMVectorMultiplyAdd(V, Scale, Offset);
|
||||
|
||||
return FMA4::XMVector3TransformCoord(Result, Transform);
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Vector4
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector4Transform
|
||||
(
|
||||
FXMVECTOR V,
|
||||
CXMMATRIX M
|
||||
)
|
||||
{
|
||||
XMVECTOR vResult = _mm_permute_ps(V,_MM_SHUFFLE(3,3,3,3)); // W
|
||||
vResult = _mm_mul_ps( vResult, M.r[3] );
|
||||
XMVECTOR vTemp = _mm_permute_ps(V,_MM_SHUFFLE(2,2,2,2)); // Z
|
||||
vResult = _mm_macc_ps( vTemp, M.r[2], vResult );
|
||||
vTemp = _mm_permute_ps(V,_MM_SHUFFLE(1,1,1,1)); // Y
|
||||
vResult = _mm_macc_ps( vTemp, M.r[1], vResult );
|
||||
vTemp = _mm_permute_ps(V,_MM_SHUFFLE(0,0,0,0)); // X
|
||||
vResult = _mm_macc_ps( vTemp, M.r[0], vResult );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Matrix
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMMATRIX XM_CALLCONV XMMatrixMultiply
|
||||
(
|
||||
CXMMATRIX M1,
|
||||
CXMMATRIX M2
|
||||
)
|
||||
{
|
||||
XMMATRIX mResult;
|
||||
// Use vW to hold the original row
|
||||
XMVECTOR vW = M1.r[0];
|
||||
// Splat the component X,Y,Z then W
|
||||
XMVECTOR vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
XMVECTOR vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
XMVECTOR vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
// Perform the operation on the first row
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_macc_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_macc_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_macc_ps(vW,M2.r[3],vX);
|
||||
mResult.r[0] = vX;
|
||||
// Repeat for the other 3 rows
|
||||
vW = M1.r[1];
|
||||
vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_macc_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_macc_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_macc_ps(vW,M2.r[3],vX);
|
||||
mResult.r[1] = vX;
|
||||
vW = M1.r[2];
|
||||
vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_macc_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_macc_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_macc_ps(vW,M2.r[3],vX);
|
||||
mResult.r[2] = vX;
|
||||
vW = M1.r[3];
|
||||
vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_macc_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_macc_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_macc_ps(vW,M2.r[3],vX);
|
||||
mResult.r[3] = vX;
|
||||
return mResult;
|
||||
}
|
||||
|
||||
inline XMMATRIX XM_CALLCONV XMMatrixMultiplyTranspose
|
||||
(
|
||||
FXMMATRIX M1,
|
||||
CXMMATRIX M2
|
||||
)
|
||||
{
|
||||
// Use vW to hold the original row
|
||||
XMVECTOR vW = M1.r[0];
|
||||
// Splat the component X,Y,Z then W
|
||||
XMVECTOR vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
XMVECTOR vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
XMVECTOR vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
// Perform the operation on the first row
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_macc_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_macc_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_macc_ps(vW,M2.r[3],vX);
|
||||
__m128 r0 = vX;
|
||||
// Repeat for the other 3 rows
|
||||
vW = M1.r[1];
|
||||
vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_macc_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_macc_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_macc_ps(vW,M2.r[3],vX);
|
||||
__m128 r1 = vX;
|
||||
vW = M1.r[2];
|
||||
vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_macc_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_macc_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_macc_ps(vW,M2.r[3],vX);
|
||||
__m128 r2 = vX;
|
||||
vW = M1.r[3];
|
||||
vX = _mm_permute_ps(vW,_MM_SHUFFLE(0,0,0,0));
|
||||
vY = _mm_permute_ps(vW,_MM_SHUFFLE(1,1,1,1));
|
||||
vZ = _mm_permute_ps(vW,_MM_SHUFFLE(2,2,2,2));
|
||||
vW = _mm_permute_ps(vW,_MM_SHUFFLE(3,3,3,3));
|
||||
vX = _mm_mul_ps(vX,M2.r[0]);
|
||||
vX = _mm_macc_ps(vY,M2.r[1],vX);
|
||||
vX = _mm_macc_ps(vZ,M2.r[2],vX);
|
||||
vX = _mm_macc_ps(vW,M2.r[3],vX);
|
||||
__m128 r3 = vX;
|
||||
|
||||
// x.x,x.y,y.x,y.y
|
||||
XMVECTOR vTemp1 = _mm_shuffle_ps(r0,r1,_MM_SHUFFLE(1,0,1,0));
|
||||
// x.z,x.w,y.z,y.w
|
||||
XMVECTOR vTemp3 = _mm_shuffle_ps(r0,r1,_MM_SHUFFLE(3,2,3,2));
|
||||
// z.x,z.y,w.x,w.y
|
||||
XMVECTOR vTemp2 = _mm_shuffle_ps(r2,r3,_MM_SHUFFLE(1,0,1,0));
|
||||
// z.z,z.w,w.z,w.w
|
||||
XMVECTOR vTemp4 = _mm_shuffle_ps(r2,r3,_MM_SHUFFLE(3,2,3,2));
|
||||
|
||||
XMMATRIX mResult;
|
||||
// x.x,y.x,z.x,w.x
|
||||
mResult.r[0] = _mm_shuffle_ps(vTemp1, vTemp2,_MM_SHUFFLE(2,0,2,0));
|
||||
// x.y,y.y,z.y,w.y
|
||||
mResult.r[1] = _mm_shuffle_ps(vTemp1, vTemp2,_MM_SHUFFLE(3,1,3,1));
|
||||
// x.z,y.z,z.z,w.z
|
||||
mResult.r[2] = _mm_shuffle_ps(vTemp3, vTemp4,_MM_SHUFFLE(2,0,2,0));
|
||||
// x.w,y.w,z.w,w.w
|
||||
mResult.r[3] = _mm_shuffle_ps(vTemp3, vTemp4,_MM_SHUFFLE(3,1,3,1));
|
||||
return mResult;
|
||||
}
|
||||
|
||||
} // namespace FMA4
|
||||
|
||||
} // namespace DirectX;
|
111
Sdk/External/DirectXMath/Extensions/DirectXMathSSE3.h
vendored
Normal file
111
Sdk/External/DirectXMath/Extensions/DirectXMathSSE3.h
vendored
Normal file
@ -0,0 +1,111 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// DirectXMathSSE3.h -- SSE3 extensions for SIMD C++ Math library
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615560
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#if defined(_M_ARM) || defined(_M_ARM64) || defined(_M_HYBRID_X86_ARM64) || __arm__ || __aarch64__
|
||||
#error SSE3 not supported on ARM platform
|
||||
#endif
|
||||
|
||||
#include <pmmintrin.h>
|
||||
|
||||
#include <DirectXMath.h>
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
|
||||
namespace SSE3
|
||||
{
|
||||
|
||||
inline bool XMVerifySSE3Support()
|
||||
{
|
||||
// Should return true on AMD Athlon 64, AMD Phenom, and Intel Pentium 4 or later processors
|
||||
|
||||
// See http://msdn.microsoft.com/en-us/library/hskdteyh.aspx
|
||||
int CPUInfo[4] = { -1 };
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(0, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 0);
|
||||
#endif
|
||||
if ( CPUInfo[0] < 1 )
|
||||
return false;
|
||||
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(1, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 1);
|
||||
#endif
|
||||
|
||||
// We only check for SSE3 instruction set. SSSE3 instructions are not used.
|
||||
return ( (CPUInfo[2] & 0x1) != 0 );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2Dot
|
||||
(
|
||||
FXMVECTOR V1,
|
||||
FXMVECTOR V2
|
||||
)
|
||||
{
|
||||
XMVECTOR vTemp = _mm_mul_ps(V1,V2);
|
||||
vTemp = _mm_hadd_ps(vTemp,vTemp);
|
||||
return _mm_shuffle_ps(vTemp,vTemp,_MM_SHUFFLE(0,0,0,0));
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2LengthSq( FXMVECTOR V )
|
||||
{
|
||||
return SSE3::XMVector2Dot(V, V);
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3Dot
|
||||
(
|
||||
FXMVECTOR V1,
|
||||
FXMVECTOR V2
|
||||
)
|
||||
{
|
||||
XMVECTOR vTemp = _mm_mul_ps(V1,V2);
|
||||
vTemp = _mm_and_ps( vTemp, g_XMMask3 );
|
||||
vTemp = _mm_hadd_ps(vTemp,vTemp);
|
||||
return _mm_hadd_ps(vTemp,vTemp);
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3LengthSq( FXMVECTOR V )
|
||||
{
|
||||
return SSE3::XMVector3Dot(V, V);
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector4Dot
|
||||
(
|
||||
FXMVECTOR V1,
|
||||
FXMVECTOR V2
|
||||
)
|
||||
{
|
||||
XMVECTOR vTemp = _mm_mul_ps(V1,V2);
|
||||
vTemp = _mm_hadd_ps( vTemp, vTemp );
|
||||
return _mm_hadd_ps( vTemp, vTemp );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector4LengthSq( FXMVECTOR V )
|
||||
{
|
||||
return SSE3::XMVector4Dot(V, V);
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSwizzle_0022( FXMVECTOR V )
|
||||
{
|
||||
return _mm_moveldup_ps(V);
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSwizzle_1133( FXMVECTOR V )
|
||||
{
|
||||
return _mm_movehdup_ps(V);
|
||||
}
|
||||
|
||||
} // namespace SSE3
|
||||
|
||||
} // namespace DirectX
|
417
Sdk/External/DirectXMath/Extensions/DirectXMathSSE4.h
vendored
Normal file
417
Sdk/External/DirectXMath/Extensions/DirectXMathSSE4.h
vendored
Normal file
@ -0,0 +1,417 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// DirectXMathSSE4.h -- SSE4.1 extensions for SIMD C++ Math library
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615560
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#if defined(_M_ARM) || defined(_M_ARM64) || defined(_M_HYBRID_X86_ARM64) || __arm__ || __aarch64__
|
||||
#error SSE4 not supported on ARM platform
|
||||
#endif
|
||||
|
||||
#include <smmintrin.h>
|
||||
|
||||
#include <DirectXMath.h>
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
|
||||
namespace SSE4
|
||||
{
|
||||
|
||||
inline bool XMVerifySSE4Support()
|
||||
{
|
||||
// Should return true on AMD Bulldozer, Intel Core 2 ("Penryn"), and Intel Core i7 ("Nehalem") or later processors
|
||||
|
||||
// See http://msdn.microsoft.com/en-us/library/hskdteyh.aspx
|
||||
int CPUInfo[4] = { -1 };
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(0, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 0);
|
||||
#endif
|
||||
if ( CPUInfo[0] < 1 )
|
||||
return false;
|
||||
|
||||
#if defined(__clang__) || defined(__GNUC__)
|
||||
__cpuid(1, CPUInfo[0], CPUInfo[1], CPUInfo[2], CPUInfo[3]);
|
||||
#else
|
||||
__cpuid(CPUInfo, 1);
|
||||
#endif
|
||||
|
||||
// We only check for SSE4.1 instruction set. SSE4.2 instructions are not used.
|
||||
return ( (CPUInfo[2] & 0x80000) == 0x80000 );
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Vector
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic ignored "-Wundefined-reinterpret-cast"
|
||||
#endif
|
||||
|
||||
inline void XM_CALLCONV XMVectorGetYPtr(_Out_ float *y, _In_ FXMVECTOR V)
|
||||
{
|
||||
assert( y != nullptr );
|
||||
*reinterpret_cast<int*>(y) = _mm_extract_ps( V, 1 );
|
||||
}
|
||||
|
||||
inline void XM_CALLCONV XMVectorGetZPtr(_Out_ float *z, _In_ FXMVECTOR V)
|
||||
{
|
||||
assert( z != nullptr );
|
||||
*reinterpret_cast<int*>(z) = _mm_extract_ps( V, 2 );
|
||||
}
|
||||
|
||||
inline void XM_CALLCONV XMVectorGetWPtr(_Out_ float *w, _In_ FXMVECTOR V)
|
||||
{
|
||||
assert( w != nullptr );
|
||||
*reinterpret_cast<int*>(w) = _mm_extract_ps( V, 3 );
|
||||
}
|
||||
|
||||
inline uint32_t XM_CALLCONV XMVectorGetIntY(FXMVECTOR V)
|
||||
{
|
||||
__m128i V1 = _mm_castps_si128( V );
|
||||
return static_cast<uint32_t>( _mm_extract_epi32( V1, 1 ) );
|
||||
}
|
||||
|
||||
inline uint32_t XM_CALLCONV XMVectorGetIntZ(FXMVECTOR V)
|
||||
{
|
||||
__m128i V1 = _mm_castps_si128( V );
|
||||
return static_cast<uint32_t>( _mm_extract_epi32( V1, 2 ) );
|
||||
}
|
||||
|
||||
inline uint32_t XM_CALLCONV XMVectorGetIntW(FXMVECTOR V)
|
||||
{
|
||||
__m128i V1 = _mm_castps_si128( V );
|
||||
return static_cast<uint32_t>( _mm_extract_epi32( V1, 3 ) );
|
||||
}
|
||||
|
||||
inline void XM_CALLCONV XMVectorGetIntYPtr(_Out_ uint32_t *y, _In_ FXMVECTOR V)
|
||||
{
|
||||
assert( y != nullptr );
|
||||
__m128i V1 = _mm_castps_si128( V );
|
||||
*y = static_cast<uint32_t>( _mm_extract_epi32( V1, 1 ) );
|
||||
}
|
||||
|
||||
inline void XM_CALLCONV XMVectorGetIntZPtr(_Out_ uint32_t *z, _In_ FXMVECTOR V)
|
||||
{
|
||||
assert( z != nullptr );
|
||||
__m128i V1 = _mm_castps_si128( V );
|
||||
*z = static_cast<uint32_t>( _mm_extract_epi32( V1, 2 ) );
|
||||
}
|
||||
|
||||
inline void XM_CALLCONV XMVectorGetIntWPtr(_Out_ uint32_t *w, _In_ FXMVECTOR V)
|
||||
{
|
||||
assert( w != nullptr );
|
||||
__m128i V1 = _mm_castps_si128( V );
|
||||
*w = static_cast<uint32_t>( _mm_extract_epi32( V1, 3 ) );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSetY(FXMVECTOR V, float y)
|
||||
{
|
||||
XMVECTOR vResult = _mm_set_ss(y);
|
||||
vResult = _mm_insert_ps( V, vResult, 0x10 );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSetZ(FXMVECTOR V, float z)
|
||||
{
|
||||
XMVECTOR vResult = _mm_set_ss(z);
|
||||
vResult = _mm_insert_ps( V, vResult, 0x20 );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSetW(FXMVECTOR V, float w)
|
||||
{
|
||||
XMVECTOR vResult = _mm_set_ss(w);
|
||||
vResult = _mm_insert_ps( V, vResult, 0x30 );
|
||||
return vResult;
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSetIntY(FXMVECTOR V, uint32_t y)
|
||||
{
|
||||
__m128i vResult = _mm_castps_si128( V );
|
||||
vResult = _mm_insert_epi32( vResult, static_cast<int>(y), 1 );
|
||||
return _mm_castsi128_ps( vResult );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSetIntZ(FXMVECTOR V, uint32_t z)
|
||||
{
|
||||
__m128i vResult = _mm_castps_si128( V );
|
||||
vResult = _mm_insert_epi32( vResult, static_cast<int>(z), 2 );
|
||||
return _mm_castsi128_ps( vResult );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorSetIntW(FXMVECTOR V, uint32_t w)
|
||||
{
|
||||
__m128i vResult = _mm_castps_si128( V );
|
||||
vResult = _mm_insert_epi32( vResult, static_cast<int>(w), 3 );
|
||||
return _mm_castsi128_ps( vResult );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorRound( FXMVECTOR V )
|
||||
{
|
||||
return _mm_round_ps( V, _MM_FROUND_TO_NEAREST_INT | _MM_FROUND_NO_EXC );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorTruncate( FXMVECTOR V )
|
||||
{
|
||||
return _mm_round_ps( V, _MM_FROUND_TO_ZERO | _MM_FROUND_NO_EXC );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorFloor( FXMVECTOR V )
|
||||
{
|
||||
return _mm_floor_ps( V );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVectorCeiling( FXMVECTOR V )
|
||||
{
|
||||
return _mm_ceil_ps( V );
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Vector2
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2Dot( FXMVECTOR V1, FXMVECTOR V2 )
|
||||
{
|
||||
return _mm_dp_ps( V1, V2, 0x3f );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2LengthSq( FXMVECTOR V )
|
||||
{
|
||||
return SSE4::XMVector2Dot(V, V);
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2ReciprocalLengthEst( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0x3f );
|
||||
return _mm_rsqrt_ps( vTemp );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2ReciprocalLength( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0x3f );
|
||||
XMVECTOR vLengthSq = _mm_sqrt_ps( vTemp );
|
||||
return _mm_div_ps( g_XMOne, vLengthSq );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2LengthEst( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0x3f );
|
||||
return _mm_sqrt_ps( vTemp );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2Length( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0x3f );
|
||||
return _mm_sqrt_ps( vTemp );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2NormalizeEst( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0x3f );
|
||||
XMVECTOR vResult = _mm_rsqrt_ps( vTemp );
|
||||
return _mm_mul_ps(vResult, V);
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector2Normalize( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vLengthSq = _mm_dp_ps( V, V, 0x3f );
|
||||
// Prepare for the division
|
||||
XMVECTOR vResult = _mm_sqrt_ps(vLengthSq);
|
||||
// Create zero with a single instruction
|
||||
XMVECTOR vZeroMask = _mm_setzero_ps();
|
||||
// Test for a divide by zero (Must be FP to detect -0.0)
|
||||
vZeroMask = _mm_cmpneq_ps(vZeroMask,vResult);
|
||||
// Failsafe on zero (Or epsilon) length planes
|
||||
// If the length is infinity, set the elements to zero
|
||||
vLengthSq = _mm_cmpneq_ps(vLengthSq,g_XMInfinity);
|
||||
// Reciprocal mul to perform the normalization
|
||||
vResult = _mm_div_ps(V,vResult);
|
||||
// Any that are infinity, set to zero
|
||||
vResult = _mm_and_ps(vResult,vZeroMask);
|
||||
// Select qnan or result based on infinite length
|
||||
XMVECTOR vTemp1 = _mm_andnot_ps(vLengthSq,g_XMQNaN);
|
||||
XMVECTOR vTemp2 = _mm_and_ps(vResult,vLengthSq);
|
||||
vResult = _mm_or_ps(vTemp1,vTemp2);
|
||||
return vResult;
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Vector3
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3Dot( FXMVECTOR V1, FXMVECTOR V2 )
|
||||
{
|
||||
return _mm_dp_ps( V1, V2, 0x7f );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3LengthSq( FXMVECTOR V )
|
||||
{
|
||||
return SSE4::XMVector3Dot(V, V);
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3ReciprocalLengthEst( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0x7f );
|
||||
return _mm_rsqrt_ps( vTemp );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3ReciprocalLength( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0x7f );
|
||||
XMVECTOR vLengthSq = _mm_sqrt_ps( vTemp );
|
||||
return _mm_div_ps( g_XMOne, vLengthSq );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3LengthEst( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0x7f );
|
||||
return _mm_sqrt_ps( vTemp );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3Length( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0x7f );
|
||||
return _mm_sqrt_ps( vTemp );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3NormalizeEst( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0x7f );
|
||||
XMVECTOR vResult = _mm_rsqrt_ps( vTemp );
|
||||
return _mm_mul_ps(vResult, V);
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector3Normalize( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vLengthSq = _mm_dp_ps( V, V, 0x7f );
|
||||
// Prepare for the division
|
||||
XMVECTOR vResult = _mm_sqrt_ps(vLengthSq);
|
||||
// Create zero with a single instruction
|
||||
XMVECTOR vZeroMask = _mm_setzero_ps();
|
||||
// Test for a divide by zero (Must be FP to detect -0.0)
|
||||
vZeroMask = _mm_cmpneq_ps(vZeroMask,vResult);
|
||||
// Failsafe on zero (Or epsilon) length planes
|
||||
// If the length is infinity, set the elements to zero
|
||||
vLengthSq = _mm_cmpneq_ps(vLengthSq,g_XMInfinity);
|
||||
// Divide to perform the normalization
|
||||
vResult = _mm_div_ps(V,vResult);
|
||||
// Any that are infinity, set to zero
|
||||
vResult = _mm_and_ps(vResult,vZeroMask);
|
||||
// Select qnan or result based on infinite length
|
||||
XMVECTOR vTemp1 = _mm_andnot_ps(vLengthSq,g_XMQNaN);
|
||||
XMVECTOR vTemp2 = _mm_and_ps(vResult,vLengthSq);
|
||||
vResult = _mm_or_ps(vTemp1,vTemp2);
|
||||
return vResult;
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Vector4
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector4Dot( FXMVECTOR V1, FXMVECTOR V2 )
|
||||
{
|
||||
return _mm_dp_ps( V1, V2, 0xff );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector4LengthSq( FXMVECTOR V )
|
||||
{
|
||||
return SSE4::XMVector4Dot(V, V);
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector4ReciprocalLengthEst( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0xff );
|
||||
return _mm_rsqrt_ps( vTemp );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector4ReciprocalLength( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0xff );
|
||||
XMVECTOR vLengthSq = _mm_sqrt_ps( vTemp );
|
||||
return _mm_div_ps( g_XMOne, vLengthSq );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector4LengthEst( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0xff );
|
||||
return _mm_sqrt_ps( vTemp );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector4Length( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0xff );
|
||||
return _mm_sqrt_ps( vTemp );
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector4NormalizeEst( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( V, V, 0xff );
|
||||
XMVECTOR vResult = _mm_rsqrt_ps( vTemp );
|
||||
return _mm_mul_ps(vResult, V);
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMVector4Normalize( FXMVECTOR V )
|
||||
{
|
||||
XMVECTOR vLengthSq = _mm_dp_ps( V, V, 0xff );
|
||||
// Prepare for the division
|
||||
XMVECTOR vResult = _mm_sqrt_ps(vLengthSq);
|
||||
// Create zero with a single instruction
|
||||
XMVECTOR vZeroMask = _mm_setzero_ps();
|
||||
// Test for a divide by zero (Must be FP to detect -0.0)
|
||||
vZeroMask = _mm_cmpneq_ps(vZeroMask,vResult);
|
||||
// Failsafe on zero (Or epsilon) length planes
|
||||
// If the length is infinity, set the elements to zero
|
||||
vLengthSq = _mm_cmpneq_ps(vLengthSq,g_XMInfinity);
|
||||
// Divide to perform the normalization
|
||||
vResult = _mm_div_ps(V,vResult);
|
||||
// Any that are infinity, set to zero
|
||||
vResult = _mm_and_ps(vResult,vZeroMask);
|
||||
// Select qnan or result based on infinite length
|
||||
XMVECTOR vTemp1 = _mm_andnot_ps(vLengthSq,g_XMQNaN);
|
||||
XMVECTOR vTemp2 = _mm_and_ps(vResult,vLengthSq);
|
||||
vResult = _mm_or_ps(vTemp1,vTemp2);
|
||||
return vResult;
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Plane
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMPlaneNormalizeEst( FXMVECTOR P )
|
||||
{
|
||||
XMVECTOR vTemp = _mm_dp_ps( P, P, 0x7f );
|
||||
XMVECTOR vResult = _mm_rsqrt_ps( vTemp );
|
||||
return _mm_mul_ps(vResult, P);
|
||||
}
|
||||
|
||||
inline XMVECTOR XM_CALLCONV XMPlaneNormalize( FXMVECTOR P )
|
||||
{
|
||||
XMVECTOR vLengthSq = _mm_dp_ps( P, P, 0x7f );
|
||||
// Prepare for the division
|
||||
XMVECTOR vResult = _mm_sqrt_ps(vLengthSq);
|
||||
// Failsafe on zero (Or epsilon) length planes
|
||||
// If the length is infinity, set the elements to zero
|
||||
vLengthSq = _mm_cmpneq_ps(vLengthSq,g_XMInfinity);
|
||||
// Reciprocal mul to perform the normalization
|
||||
vResult = _mm_div_ps(P,vResult);
|
||||
// Any that are infinity, set to zero
|
||||
vResult = _mm_and_ps(vResult,vLengthSq);
|
||||
return vResult;
|
||||
}
|
||||
|
||||
} // namespace SSE4
|
||||
|
||||
} // namespace DirectX
|
172
Sdk/External/DirectXMath/HISTORY.md
vendored
Normal file
172
Sdk/External/DirectXMath/HISTORY.md
vendored
Normal file
@ -0,0 +1,172 @@
|
||||
# DirectXMath
|
||||
|
||||
https://github.com/Microsoft/DirectXMath
|
||||
|
||||
Release available for download on [GitHub](https://github.com/microsoft/DirectXMath/releases)
|
||||
|
||||
## Release History
|
||||
|
||||
### August 2020 (3.16)
|
||||
* Added ``XMVectorLog10`` / ``XMVectorExp10``
|
||||
* Added ``XMColorRGBToYUV_UHD`` / ``XMColorYUVToRGB_UHD`` for Rec. 2020 YUV
|
||||
* Added optional ``rhcoords`` parameter for BoundingFrustum ``CreateFromMatrix``
|
||||
* Added use of Intel® Short Vector Matrix Library (SVML) supported by VS 2019
|
||||
* Opt-in with ``_XM_SVML_INTRINSICS_``; opt-out with ``_XM_DISABLE_INTEL_SVML_``
|
||||
* Fixed denorm handling for ``XMConvertFloatToHalf``
|
||||
* Fixed flush (too small for denorm) handling for ``XMStoreFloat3PK``
|
||||
* Fixed clamping bug in ``XMStoreByteN4``
|
||||
* Cleaned up ARM-NEON intrinsics type issues for improved portability on GNUC
|
||||
* Fixed ``GXMVECTOR`` for x86 ``__vectorcall``
|
||||
* Code review
|
||||
|
||||
### April 2020 (3.15)
|
||||
* Added ``XMMatrixVectorTensorProduct`` for creating a matrix from two vectors
|
||||
* Use of m256 registers and FMA3 with ``/arch:AVX2`` for stream and some matrix functions
|
||||
* Optimized load/stores for SSE2 float2 & float3 functions
|
||||
* Optimized some instruction choices for better AMD CPU support
|
||||
* Improved conformance for clang/LLVM, GCC, and MinGW compilers
|
||||
* Code review (``constexpr`` / ``noexcept`` usage)
|
||||
* Retired VS 2015 support
|
||||
|
||||
### August 2019 (3.14)
|
||||
* Added float control around IsNan functions to resolve issue with VS 2019 with ``/fp:fast``
|
||||
* XMVerifyCPUSupport updated for clang/LLVM cpuid implementation on x86/x64
|
||||
* Added support for clang/LLVM built-in platform defines as well as the MSVC ones
|
||||
* Cleaned up ARM-NEON intrinsics type issues for improved portability
|
||||
* Removed unneeded malloc.h include in DirectXMath.h
|
||||
* Whitespace cleanup
|
||||
|
||||
### July 2018 (3.13)
|
||||
* ``XMFLOAT3X4``, ``XMFLOAT3X4A``, and associated Load/Store functions
|
||||
* Move/copy constructors and assignment operators for C++ types
|
||||
* Minor fix for XMVectorClamp behavior with NaN
|
||||
* Fixed compilation warnings with VS 2017 (15.7 update), Intel C++ 18.0 compiler, and clang 6
|
||||
* Retired VS 2013 support
|
||||
* Minor code cleanup
|
||||
|
||||
### February 2018 (3.12)
|
||||
* ARM64 use of fused multiply-accumulate intriniscs
|
||||
* Conformance fix for XMConvertFloatToHalf
|
||||
* Minor code cleanup
|
||||
|
||||
### June 2017 (3.11)
|
||||
* AVX optimization of XMMatrixMultiply and XMMatrixMultiplyTranspose
|
||||
* AVX2 optimization for XMVectorSplatX
|
||||
* FMA3 optimization of XMVectorMultiplyAdd and XMVectorNegativeMultiplySubtract (implied by /arch:AVX2)
|
||||
* Conformance fixes to support compilation with Clang 3.7
|
||||
|
||||
### January 2017 (3.10)
|
||||
* Added XMVectorSum for horizontal adds
|
||||
* ARMv8 intrinsics use for ARM64 platform (division, rounding, half-precision conversion)
|
||||
* Added SSE3 codepaths using opt-in ``_XM_SSE3_INTRINSICS_``
|
||||
* XMVectorRound fix for no-intrinsics to match round to nearest (even)
|
||||
* XMStoreFloat3SE fix when max channel isn't a perfect power of 2
|
||||
* constexpr conformance fix and workaround for compiler bug in VS 2015 RTM
|
||||
* Remove support for VS 2012 compilers
|
||||
* Remove ``__vector4i`` deprecated type
|
||||
|
||||
### June 2016 (3.09)
|
||||
* Includes support for additional optimizations when built with /arch:AVX or /arch:AVX2
|
||||
* Added use of constexpr for type constructors, XMConvertToRadians, and XMConvertToDegrees
|
||||
* Marked ``__vector4i``, ``XMXDEC4``, ``XMDECN4``, ``XMDEC4``, and associated Load & Store functions as deprecated.
|
||||
+ These are vestiges of Xbox 360 support and will be removed in a future release
|
||||
* Renamed parameter in XMMatrixPerspectiveFov* to reduce user confusion when relying on IntelliSense
|
||||
* XMU565, XMUNIBBLE4 constructors take uint8_t instead of int8_t
|
||||
|
||||
### May 2016
|
||||
* DirectXMath 3.08 released under the MIT license
|
||||
|
||||
### November 2015 (3.08)
|
||||
* Added use of ``_mm_sfence`` for Stream methods
|
||||
* Fixed bug with non-uniform scaling transforms for BoundingOrientedBox
|
||||
* Added asserts for Near/FarZ in XMMatrix* methods
|
||||
* Added use of ``=default`` for PODs with VS 2013/2015
|
||||
* Additional SSE and ARM-NEON optimizations for PackedVector functions
|
||||
|
||||
### April 2015 (3.07)
|
||||
* Fix customer reported bugs in BoundingBox methods
|
||||
* Fix customer reported bug in XMStoreFloat3SE
|
||||
* Fix customer reported bug in XMVectorATan2, XMVectorATan2Est
|
||||
* Fix customer reported bug in XMVectorRound
|
||||
|
||||
### October 2013 (3.06)
|
||||
* Fixed load/store of XMFLOAT3SE to properly match the ``DXGI_FORMAT_R9G9B9E5_SHAREDEXP``
|
||||
* Added ``XMLoadUDecN4_XR`` and ``XMStoreUDecN4_XR`` to match ``DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM``
|
||||
* Added ``XMColorRGBToSRGB`` and ``XMColorSRGBToRGB`` to convert linear RGB <-> sRGB
|
||||
|
||||
### July 2013 (3.05)
|
||||
* Use x86/x64 ``__vectorcall`` calling-convention when available (``XM_CALLCONV``, ``HXMVECTOR``, ``FXMMATRIX`` introduced)
|
||||
* Fixed bug with XMVectorFloor and XMVectorCeiling when given whole odd numbers (i.e. 105.0)
|
||||
* Improved XMVectorRound algorithm
|
||||
* ARM-NEON optimizations for XMVectorExp2, XMVectorLog2, XMVectorExpE, and XMVectorLogE
|
||||
* ARM-NEON code paths use multiply-by-scalar intrinsics when supported
|
||||
* Additional optimizations for ARM-NEON Stream functions
|
||||
* Fixed potential warning C4723 using ``operator/`` or ``operator/=``
|
||||
|
||||
### March 2013 (3.04)
|
||||
* ``XMVectorExp2``, ``XMVectorLog2``, ``XMVectorExpE``, and ``XMVectorLogE`` functions added to provide base-e support in addition to the existing base-2 support
|
||||
* ``XMVectorExp`` and ``XMVectorLog`` are now aliases for XMVectorExp2 and XMVectorLog2
|
||||
* Additional optimizations for Stream functions
|
||||
* XMVector3Cross now ensures w component is zero on ARM
|
||||
* XMConvertHalfToFloat and XMConvertFloatToHalf now use IEEE 754 standard float16 behavior for INF/QNAN
|
||||
* Updated matrix version Transform for BoundingOrientedBox and BoundingFrustum to handle scaling
|
||||
|
||||
### March 2012 (3.03)
|
||||
* *breaking change* Removed union members from XMMATRIX type to make it a fully 'opaque' type
|
||||
* Marked single-parameter C++ constructors for XMFLOAT2, XMFLOAT2A, XMFLOAT3, XMFLOAT3A, XMFLOAT4, and XMFLOAT4A explicit
|
||||
|
||||
### February 2012 (3.02)
|
||||
* ARM-NEON intrinsics (selected by default for the ARM platform)
|
||||
* Reworked XMVectorPermute, change of ``XM_PERMUTE_`` defines, removal of XMVectorPermuteControl
|
||||
* Addition of ``XM_SWIZZLE_`` defines
|
||||
* Optimizations for transcendental functions
|
||||
* Template forms for permute, swizzle, shift-left, rotate-left, rotation-right, and insert
|
||||
* Removal of deprecated types and functions
|
||||
+ ``XM_CACHE_LINE_SIZE`` define, XMVectorExpEst, XMVectorLogEst, XMVectorPowEst, XMVectorSinHEs, XMVectorCosHEst, XMVectorTanHEst, XMVector2InBoundsR, XMVector3InBoundsR, XMVector4InBoundsR
|
||||
* Removed ``XM_STRICT_VECTOR4``; XMVECTOR in NO-INTRINSICS always defined without .x, .y, .z, .w, .v, or .u
|
||||
* Additional bounding types
|
||||
* SAL fixes and improvements
|
||||
|
||||
### September 2011 (3.00)
|
||||
* Renamed and reorganized the headers
|
||||
* Introduced C++ namespaces
|
||||
* Removed the Xbox 360-specific GPU types
|
||||
+ HENDN3, XMHEND3, XMUHENDN3, XMUHEND3, XMDHENN3, XMDHEN3, XMUDHENN3, XMUDHEN3, XMXICON4, XMXICO4, XMICON4, XMICO4, XMUICON4, XMUICO4
|
||||
|
||||
### July 2012 (XNAMath 2.05)
|
||||
* Template forms have been added for `XMVectorPermute`, `XMVectorSwizzle`, `XMVectorShiftLeft`, `XMVectorRotateLeft`, `XMVectorRotateRight`, and `XMVectorInsert`
|
||||
* The `XM_STRICT_XMMATRIX` compilation define has been added for opaque `XMMATRIX`.
|
||||
* Stream stride and count arguments have been changed to `size_t`
|
||||
* The ``pDeterminant`` parameter of `XMMatrixInverse` is now optional
|
||||
* Additional operator= overloads for `XMBYTEN4`, `XMBYTE4`, `XMUBYTEN4`, and `XMUBYTE4` types are now available
|
||||
|
||||
### February 2011 (XNAMath 2.04)
|
||||
* Addition of new data types and associated load-store functions:
|
||||
+ `XMBYTEN2, XMBYTE2, XMUBYTEN2, XMUBYTE2`
|
||||
+ `XMLoadByteN2, XMLoadByte2, XMLoadUByteN2, XMLoadUByte2`
|
||||
+ `XMStoreByteN2, XMStoreByte2, XMStoreUByteN2, XMStoreUByte2`
|
||||
+ `XMINT2, XMUINT2, XMINT3, XMUINT3, XMINT4, XMUINT4`
|
||||
+ `XMLoadSInt2, XMLoadUInt2, XMLoadSInt3, XMLoadUInt3, XMLoadSInt4, XMLoadUInt4`
|
||||
+ `XMStoreSInt2, XMStoreUInt2, XMStoreSInt3, XMStoreUInt3, XMStoreSInt4, XMStoreUInt4`
|
||||
* Marked most single-parameter C++ constructors with `explicit` keyword
|
||||
* Corrected range issues with SSE implementations of `XMVectorFloor` and `XMVectorCeiling`
|
||||
|
||||
|
||||
### June 2010 (XNAMath 2.03)
|
||||
* Addition of ``XMVectorDivide`` to optimize SSE2 vector division operations
|
||||
* Unified handling of floating-point specials between the Windows SSE2 and no-intrinsics implementations
|
||||
* Use of Visual Studio style SAL annotations
|
||||
* Modifications to the C++ declarations for `XMFLOAT2A/3A/4A/4X3A/4X4A` to better support these types in C++ templates
|
||||
|
||||
### February 2010 (XNAMath 2.02)
|
||||
* Fixes to `XMStoreColor`, `XMQuaternionRotationMatrix`, `XMVectorATan2`, and `XMVectorATan2Est`
|
||||
|
||||
### August 2009 (XNAMath 2.01)
|
||||
* Adds ``XM_STRICT_VECTOR4``. This opt-in directive disallows the usage of XboxMath-like member accessors such as .x, .y, and .z. This makes it easier to write portable XNA Math code.
|
||||
* Added conversion support for the following Windows graphics formats:
|
||||
+ 16-bit color formats (565, 555X, 5551)
|
||||
+ 4-bits per channel color formats (4444)
|
||||
+ Unique Direct3D 10/11 formats (``DXGI_FORMAT_R9G9B9E5_SHAREDEXP`` and ``DXGI_FORMAT_R11G11B10_FLOAT``)
|
||||
|
||||
### March 2009 (XNAMath 2.00)
|
||||
* Initial release (based on the Xbox 360 Xbox math library)
|
353
Sdk/External/DirectXMath/Inc/DirectXCollision.h
vendored
Normal file
353
Sdk/External/DirectXMath/Inc/DirectXCollision.h
vendored
Normal file
@ -0,0 +1,353 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// DirectXCollision.h -- C++ Collision Math library
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615560
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "DirectXMath.h"
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
|
||||
enum ContainmentType
|
||||
{
|
||||
DISJOINT = 0,
|
||||
INTERSECTS = 1,
|
||||
CONTAINS = 2
|
||||
};
|
||||
|
||||
enum PlaneIntersectionType
|
||||
{
|
||||
FRONT = 0,
|
||||
INTERSECTING = 1,
|
||||
BACK = 2
|
||||
};
|
||||
|
||||
struct BoundingBox;
|
||||
struct BoundingOrientedBox;
|
||||
struct BoundingFrustum;
|
||||
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable:4324 4820)
|
||||
// C4324: alignment padding warnings
|
||||
// C4820: Off by default noise
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Bounding sphere
|
||||
//-------------------------------------------------------------------------------------
|
||||
struct BoundingSphere
|
||||
{
|
||||
XMFLOAT3 Center; // Center of the sphere.
|
||||
float Radius; // Radius of the sphere.
|
||||
|
||||
// Creators
|
||||
BoundingSphere() noexcept : Center(0, 0, 0), Radius(1.f) {}
|
||||
|
||||
BoundingSphere(const BoundingSphere&) = default;
|
||||
BoundingSphere& operator=(const BoundingSphere&) = default;
|
||||
|
||||
BoundingSphere(BoundingSphere&&) = default;
|
||||
BoundingSphere& operator=(BoundingSphere&&) = default;
|
||||
|
||||
constexpr BoundingSphere(_In_ const XMFLOAT3& center, _In_ float radius) noexcept
|
||||
: Center(center), Radius(radius) {}
|
||||
|
||||
// Methods
|
||||
void XM_CALLCONV Transform(_Out_ BoundingSphere& Out, _In_ FXMMATRIX M) const noexcept;
|
||||
void XM_CALLCONV Transform(_Out_ BoundingSphere& Out, _In_ float Scale, _In_ FXMVECTOR Rotation, _In_ FXMVECTOR Translation) const noexcept;
|
||||
// Transform the sphere
|
||||
|
||||
ContainmentType XM_CALLCONV Contains(_In_ FXMVECTOR Point) const noexcept;
|
||||
ContainmentType XM_CALLCONV Contains(_In_ FXMVECTOR V0, _In_ FXMVECTOR V1, _In_ FXMVECTOR V2) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingSphere& sh) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingBox& box) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingOrientedBox& box) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingFrustum& fr) const noexcept;
|
||||
|
||||
bool Intersects(_In_ const BoundingSphere& sh) const noexcept;
|
||||
bool Intersects(_In_ const BoundingBox& box) const noexcept;
|
||||
bool Intersects(_In_ const BoundingOrientedBox& box) const noexcept;
|
||||
bool Intersects(_In_ const BoundingFrustum& fr) const noexcept;
|
||||
|
||||
bool XM_CALLCONV Intersects(_In_ FXMVECTOR V0, _In_ FXMVECTOR V1, _In_ FXMVECTOR V2) const noexcept;
|
||||
// Triangle-sphere test
|
||||
|
||||
PlaneIntersectionType XM_CALLCONV Intersects(_In_ FXMVECTOR Plane) const noexcept;
|
||||
// Plane-sphere test
|
||||
|
||||
bool XM_CALLCONV Intersects(_In_ FXMVECTOR Origin, _In_ FXMVECTOR Direction, _Out_ float& Dist) const noexcept;
|
||||
// Ray-sphere test
|
||||
|
||||
ContainmentType XM_CALLCONV ContainedBy(_In_ FXMVECTOR Plane0, _In_ FXMVECTOR Plane1, _In_ FXMVECTOR Plane2,
|
||||
_In_ GXMVECTOR Plane3, _In_ HXMVECTOR Plane4, _In_ HXMVECTOR Plane5) const noexcept;
|
||||
// Test sphere against six planes (see BoundingFrustum::GetPlanes)
|
||||
|
||||
// Static methods
|
||||
static void CreateMerged(_Out_ BoundingSphere& Out, _In_ const BoundingSphere& S1, _In_ const BoundingSphere& S2) noexcept;
|
||||
|
||||
static void CreateFromBoundingBox(_Out_ BoundingSphere& Out, _In_ const BoundingBox& box) noexcept;
|
||||
static void CreateFromBoundingBox(_Out_ BoundingSphere& Out, _In_ const BoundingOrientedBox& box) noexcept;
|
||||
|
||||
static void CreateFromPoints(_Out_ BoundingSphere& Out, _In_ size_t Count,
|
||||
_In_reads_bytes_(sizeof(XMFLOAT3) + Stride * (Count - 1)) const XMFLOAT3* pPoints, _In_ size_t Stride) noexcept;
|
||||
|
||||
static void CreateFromFrustum(_Out_ BoundingSphere& Out, _In_ const BoundingFrustum& fr) noexcept;
|
||||
};
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Axis-aligned bounding box
|
||||
//-------------------------------------------------------------------------------------
|
||||
struct BoundingBox
|
||||
{
|
||||
static const size_t CORNER_COUNT = 8;
|
||||
|
||||
XMFLOAT3 Center; // Center of the box.
|
||||
XMFLOAT3 Extents; // Distance from the center to each side.
|
||||
|
||||
// Creators
|
||||
BoundingBox() noexcept : Center(0, 0, 0), Extents(1.f, 1.f, 1.f) {}
|
||||
|
||||
BoundingBox(const BoundingBox&) = default;
|
||||
BoundingBox& operator=(const BoundingBox&) = default;
|
||||
|
||||
BoundingBox(BoundingBox&&) = default;
|
||||
BoundingBox& operator=(BoundingBox&&) = default;
|
||||
|
||||
constexpr BoundingBox(_In_ const XMFLOAT3& center, _In_ const XMFLOAT3& extents) noexcept
|
||||
: Center(center), Extents(extents) {}
|
||||
|
||||
// Methods
|
||||
void XM_CALLCONV Transform(_Out_ BoundingBox& Out, _In_ FXMMATRIX M) const noexcept;
|
||||
void XM_CALLCONV Transform(_Out_ BoundingBox& Out, _In_ float Scale, _In_ FXMVECTOR Rotation, _In_ FXMVECTOR Translation) const noexcept;
|
||||
|
||||
void GetCorners(_Out_writes_(8) XMFLOAT3* Corners) const noexcept;
|
||||
// Gets the 8 corners of the box
|
||||
|
||||
ContainmentType XM_CALLCONV Contains(_In_ FXMVECTOR Point) const noexcept;
|
||||
ContainmentType XM_CALLCONV Contains(_In_ FXMVECTOR V0, _In_ FXMVECTOR V1, _In_ FXMVECTOR V2) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingSphere& sh) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingBox& box) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingOrientedBox& box) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingFrustum& fr) const noexcept;
|
||||
|
||||
bool Intersects(_In_ const BoundingSphere& sh) const noexcept;
|
||||
bool Intersects(_In_ const BoundingBox& box) const noexcept;
|
||||
bool Intersects(_In_ const BoundingOrientedBox& box) const noexcept;
|
||||
bool Intersects(_In_ const BoundingFrustum& fr) const noexcept;
|
||||
|
||||
bool XM_CALLCONV Intersects(_In_ FXMVECTOR V0, _In_ FXMVECTOR V1, _In_ FXMVECTOR V2) const noexcept;
|
||||
// Triangle-Box test
|
||||
|
||||
PlaneIntersectionType XM_CALLCONV Intersects(_In_ FXMVECTOR Plane) const noexcept;
|
||||
// Plane-box test
|
||||
|
||||
bool XM_CALLCONV Intersects(_In_ FXMVECTOR Origin, _In_ FXMVECTOR Direction, _Out_ float& Dist) const noexcept;
|
||||
// Ray-Box test
|
||||
|
||||
ContainmentType XM_CALLCONV ContainedBy(_In_ FXMVECTOR Plane0, _In_ FXMVECTOR Plane1, _In_ FXMVECTOR Plane2,
|
||||
_In_ GXMVECTOR Plane3, _In_ HXMVECTOR Plane4, _In_ HXMVECTOR Plane5) const noexcept;
|
||||
// Test box against six planes (see BoundingFrustum::GetPlanes)
|
||||
|
||||
// Static methods
|
||||
static void CreateMerged(_Out_ BoundingBox& Out, _In_ const BoundingBox& b1, _In_ const BoundingBox& b2) noexcept;
|
||||
|
||||
static void CreateFromSphere(_Out_ BoundingBox& Out, _In_ const BoundingSphere& sh) noexcept;
|
||||
|
||||
static void XM_CALLCONV CreateFromPoints(_Out_ BoundingBox& Out, _In_ FXMVECTOR pt1, _In_ FXMVECTOR pt2) noexcept;
|
||||
static void CreateFromPoints(_Out_ BoundingBox& Out, _In_ size_t Count,
|
||||
_In_reads_bytes_(sizeof(XMFLOAT3) + Stride * (Count - 1)) const XMFLOAT3* pPoints, _In_ size_t Stride) noexcept;
|
||||
};
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Oriented bounding box
|
||||
//-------------------------------------------------------------------------------------
|
||||
struct BoundingOrientedBox
|
||||
{
|
||||
static const size_t CORNER_COUNT = 8;
|
||||
|
||||
XMFLOAT3 Center; // Center of the box.
|
||||
XMFLOAT3 Extents; // Distance from the center to each side.
|
||||
XMFLOAT4 Orientation; // Unit quaternion representing rotation (box -> world).
|
||||
|
||||
// Creators
|
||||
BoundingOrientedBox() noexcept : Center(0, 0, 0), Extents(1.f, 1.f, 1.f), Orientation(0, 0, 0, 1.f) {}
|
||||
|
||||
BoundingOrientedBox(const BoundingOrientedBox&) = default;
|
||||
BoundingOrientedBox& operator=(const BoundingOrientedBox&) = default;
|
||||
|
||||
BoundingOrientedBox(BoundingOrientedBox&&) = default;
|
||||
BoundingOrientedBox& operator=(BoundingOrientedBox&&) = default;
|
||||
|
||||
constexpr BoundingOrientedBox(_In_ const XMFLOAT3& _Center, _In_ const XMFLOAT3& _Extents, _In_ const XMFLOAT4& _Orientation) noexcept
|
||||
: Center(_Center), Extents(_Extents), Orientation(_Orientation) {}
|
||||
|
||||
// Methods
|
||||
void XM_CALLCONV Transform(_Out_ BoundingOrientedBox& Out, _In_ FXMMATRIX M) const noexcept;
|
||||
void XM_CALLCONV Transform(_Out_ BoundingOrientedBox& Out, _In_ float Scale, _In_ FXMVECTOR Rotation, _In_ FXMVECTOR Translation) const noexcept;
|
||||
|
||||
void GetCorners(_Out_writes_(8) XMFLOAT3* Corners) const noexcept;
|
||||
// Gets the 8 corners of the box
|
||||
|
||||
ContainmentType XM_CALLCONV Contains(_In_ FXMVECTOR Point) const noexcept;
|
||||
ContainmentType XM_CALLCONV Contains(_In_ FXMVECTOR V0, _In_ FXMVECTOR V1, _In_ FXMVECTOR V2) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingSphere& sh) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingBox& box) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingOrientedBox& box) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingFrustum& fr) const noexcept;
|
||||
|
||||
bool Intersects(_In_ const BoundingSphere& sh) const noexcept;
|
||||
bool Intersects(_In_ const BoundingBox& box) const noexcept;
|
||||
bool Intersects(_In_ const BoundingOrientedBox& box) const noexcept;
|
||||
bool Intersects(_In_ const BoundingFrustum& fr) const noexcept;
|
||||
|
||||
bool XM_CALLCONV Intersects(_In_ FXMVECTOR V0, _In_ FXMVECTOR V1, _In_ FXMVECTOR V2) const noexcept;
|
||||
// Triangle-OrientedBox test
|
||||
|
||||
PlaneIntersectionType XM_CALLCONV Intersects(_In_ FXMVECTOR Plane) const noexcept;
|
||||
// Plane-OrientedBox test
|
||||
|
||||
bool XM_CALLCONV Intersects(_In_ FXMVECTOR Origin, _In_ FXMVECTOR Direction, _Out_ float& Dist) const noexcept;
|
||||
// Ray-OrientedBox test
|
||||
|
||||
ContainmentType XM_CALLCONV ContainedBy(_In_ FXMVECTOR Plane0, _In_ FXMVECTOR Plane1, _In_ FXMVECTOR Plane2,
|
||||
_In_ GXMVECTOR Plane3, _In_ HXMVECTOR Plane4, _In_ HXMVECTOR Plane5) const noexcept;
|
||||
// Test OrientedBox against six planes (see BoundingFrustum::GetPlanes)
|
||||
|
||||
// Static methods
|
||||
static void CreateFromBoundingBox(_Out_ BoundingOrientedBox& Out, _In_ const BoundingBox& box) noexcept;
|
||||
|
||||
static void CreateFromPoints(_Out_ BoundingOrientedBox& Out, _In_ size_t Count,
|
||||
_In_reads_bytes_(sizeof(XMFLOAT3) + Stride * (Count - 1)) const XMFLOAT3* pPoints, _In_ size_t Stride) noexcept;
|
||||
};
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Bounding frustum
|
||||
//-------------------------------------------------------------------------------------
|
||||
struct BoundingFrustum
|
||||
{
|
||||
static const size_t CORNER_COUNT = 8;
|
||||
|
||||
XMFLOAT3 Origin; // Origin of the frustum (and projection).
|
||||
XMFLOAT4 Orientation; // Quaternion representing rotation.
|
||||
|
||||
float RightSlope; // Positive X (X/Z)
|
||||
float LeftSlope; // Negative X
|
||||
float TopSlope; // Positive Y (Y/Z)
|
||||
float BottomSlope; // Negative Y
|
||||
float Near, Far; // Z of the near plane and far plane.
|
||||
|
||||
// Creators
|
||||
BoundingFrustum() noexcept :
|
||||
Origin(0, 0, 0), Orientation(0, 0, 0, 1.f), RightSlope(1.f), LeftSlope(-1.f),
|
||||
TopSlope(1.f), BottomSlope(-1.f), Near(0), Far(1.f) {}
|
||||
|
||||
BoundingFrustum(const BoundingFrustum&) = default;
|
||||
BoundingFrustum& operator=(const BoundingFrustum&) = default;
|
||||
|
||||
BoundingFrustum(BoundingFrustum&&) = default;
|
||||
BoundingFrustum& operator=(BoundingFrustum&&) = default;
|
||||
|
||||
constexpr BoundingFrustum(_In_ const XMFLOAT3& _Origin, _In_ const XMFLOAT4& _Orientation,
|
||||
_In_ float _RightSlope, _In_ float _LeftSlope, _In_ float _TopSlope, _In_ float _BottomSlope,
|
||||
_In_ float _Near, _In_ float _Far) noexcept
|
||||
: Origin(_Origin), Orientation(_Orientation),
|
||||
RightSlope(_RightSlope), LeftSlope(_LeftSlope), TopSlope(_TopSlope), BottomSlope(_BottomSlope),
|
||||
Near(_Near), Far(_Far) {}
|
||||
BoundingFrustum(_In_ CXMMATRIX Projection, bool rhcoords = false) noexcept;
|
||||
|
||||
// Methods
|
||||
void XM_CALLCONV Transform(_Out_ BoundingFrustum& Out, _In_ FXMMATRIX M) const noexcept;
|
||||
void XM_CALLCONV Transform(_Out_ BoundingFrustum& Out, _In_ float Scale, _In_ FXMVECTOR Rotation, _In_ FXMVECTOR Translation) const noexcept;
|
||||
|
||||
void GetCorners(_Out_writes_(8) XMFLOAT3* Corners) const noexcept;
|
||||
// Gets the 8 corners of the frustum
|
||||
|
||||
ContainmentType XM_CALLCONV Contains(_In_ FXMVECTOR Point) const noexcept;
|
||||
ContainmentType XM_CALLCONV Contains(_In_ FXMVECTOR V0, _In_ FXMVECTOR V1, _In_ FXMVECTOR V2) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingSphere& sp) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingBox& box) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingOrientedBox& box) const noexcept;
|
||||
ContainmentType Contains(_In_ const BoundingFrustum& fr) const noexcept;
|
||||
// Frustum-Frustum test
|
||||
|
||||
bool Intersects(_In_ const BoundingSphere& sh) const noexcept;
|
||||
bool Intersects(_In_ const BoundingBox& box) const noexcept;
|
||||
bool Intersects(_In_ const BoundingOrientedBox& box) const noexcept;
|
||||
bool Intersects(_In_ const BoundingFrustum& fr) const noexcept;
|
||||
|
||||
bool XM_CALLCONV Intersects(_In_ FXMVECTOR V0, _In_ FXMVECTOR V1, _In_ FXMVECTOR V2) const noexcept;
|
||||
// Triangle-Frustum test
|
||||
|
||||
PlaneIntersectionType XM_CALLCONV Intersects(_In_ FXMVECTOR Plane) const noexcept;
|
||||
// Plane-Frustum test
|
||||
|
||||
bool XM_CALLCONV Intersects(_In_ FXMVECTOR rayOrigin, _In_ FXMVECTOR Direction, _Out_ float& Dist) const noexcept;
|
||||
// Ray-Frustum test
|
||||
|
||||
ContainmentType XM_CALLCONV ContainedBy(_In_ FXMVECTOR Plane0, _In_ FXMVECTOR Plane1, _In_ FXMVECTOR Plane2,
|
||||
_In_ GXMVECTOR Plane3, _In_ HXMVECTOR Plane4, _In_ HXMVECTOR Plane5) const noexcept;
|
||||
// Test frustum against six planes (see BoundingFrustum::GetPlanes)
|
||||
|
||||
void GetPlanes(_Out_opt_ XMVECTOR* NearPlane, _Out_opt_ XMVECTOR* FarPlane, _Out_opt_ XMVECTOR* RightPlane,
|
||||
_Out_opt_ XMVECTOR* LeftPlane, _Out_opt_ XMVECTOR* TopPlane, _Out_opt_ XMVECTOR* BottomPlane) const noexcept;
|
||||
// Create 6 Planes representation of Frustum
|
||||
|
||||
// Static methods
|
||||
static void XM_CALLCONV CreateFromMatrix(_Out_ BoundingFrustum& Out, _In_ FXMMATRIX Projection, bool rhcoords = false) noexcept;
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Triangle intersection testing routines.
|
||||
//-----------------------------------------------------------------------------
|
||||
namespace TriangleTests
|
||||
{
|
||||
bool XM_CALLCONV Intersects(_In_ FXMVECTOR Origin, _In_ FXMVECTOR Direction, _In_ FXMVECTOR V0, _In_ GXMVECTOR V1, _In_ HXMVECTOR V2, _Out_ float& Dist) noexcept;
|
||||
// Ray-Triangle
|
||||
|
||||
bool XM_CALLCONV Intersects(_In_ FXMVECTOR A0, _In_ FXMVECTOR A1, _In_ FXMVECTOR A2, _In_ GXMVECTOR B0, _In_ HXMVECTOR B1, _In_ HXMVECTOR B2) noexcept;
|
||||
// Triangle-Triangle
|
||||
|
||||
PlaneIntersectionType XM_CALLCONV Intersects(_In_ FXMVECTOR V0, _In_ FXMVECTOR V1, _In_ FXMVECTOR V2, _In_ GXMVECTOR Plane) noexcept;
|
||||
// Plane-Triangle
|
||||
|
||||
ContainmentType XM_CALLCONV ContainedBy(_In_ FXMVECTOR V0, _In_ FXMVECTOR V1, _In_ FXMVECTOR V2,
|
||||
_In_ GXMVECTOR Plane0, _In_ HXMVECTOR Plane1, _In_ HXMVECTOR Plane2,
|
||||
_In_ CXMVECTOR Plane3, _In_ CXMVECTOR Plane4, _In_ CXMVECTOR Plane5) noexcept;
|
||||
// Test a triangle against six planes at once (see BoundingFrustum::GetPlanes)
|
||||
}
|
||||
|
||||
#pragma warning(pop)
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* Implementation
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable : 4068 4365 4616 6001)
|
||||
// C4068/4616: ignore unknown pragmas
|
||||
// C4365: Off by default noise
|
||||
// C6001: False positives
|
||||
|
||||
#ifdef _PREFAST_
|
||||
#pragma prefast(push)
|
||||
#pragma prefast(disable : 25000, "FXMVECTOR is 16 bytes")
|
||||
#pragma prefast(disable : 26495, "Union initialization confuses /analyze")
|
||||
#endif
|
||||
|
||||
#include "DirectXCollision.inl"
|
||||
|
||||
#ifdef _PREFAST_
|
||||
#pragma prefast(pop)
|
||||
#endif
|
||||
|
||||
#pragma warning(pop)
|
||||
|
||||
} // namespace DirectX
|
||||
|
4816
Sdk/External/DirectXMath/Inc/DirectXCollision.inl
vendored
Normal file
4816
Sdk/External/DirectXMath/Inc/DirectXCollision.inl
vendored
Normal file
File diff suppressed because it is too large
Load Diff
165
Sdk/External/DirectXMath/Inc/DirectXColors.h
vendored
Normal file
165
Sdk/External/DirectXMath/Inc/DirectXColors.h
vendored
Normal file
@ -0,0 +1,165 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// DirectXColors.h -- C++ Color Math library
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615560
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "DirectXMath.h"
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
|
||||
namespace Colors
|
||||
{
|
||||
// Standard colors (Red/Green/Blue/Alpha)
|
||||
XMGLOBALCONST XMVECTORF32 AliceBlue = { { { 0.941176534f, 0.972549081f, 1.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 AntiqueWhite = { { { 0.980392218f, 0.921568692f, 0.843137324f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Aqua = { { { 0.000000000f, 1.000000000f, 1.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Aquamarine = { { { 0.498039246f, 1.000000000f, 0.831372619f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Azure = { { { 0.941176534f, 1.000000000f, 1.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Beige = { { { 0.960784376f, 0.960784376f, 0.862745166f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Bisque = { { { 1.000000000f, 0.894117713f, 0.768627524f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Black = { { { 0.000000000f, 0.000000000f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 BlanchedAlmond = { { { 1.000000000f, 0.921568692f, 0.803921640f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Blue = { { { 0.000000000f, 0.000000000f, 1.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 BlueViolet = { { { 0.541176498f, 0.168627456f, 0.886274576f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Brown = { { { 0.647058845f, 0.164705887f, 0.164705887f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 BurlyWood = { { { 0.870588303f, 0.721568644f, 0.529411793f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 CadetBlue = { { { 0.372549027f, 0.619607866f, 0.627451003f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Chartreuse = { { { 0.498039246f, 1.000000000f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Chocolate = { { { 0.823529482f, 0.411764741f, 0.117647067f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Coral = { { { 1.000000000f, 0.498039246f, 0.313725501f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 CornflowerBlue = { { { 0.392156899f, 0.584313750f, 0.929411829f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Cornsilk = { { { 1.000000000f, 0.972549081f, 0.862745166f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Crimson = { { { 0.862745166f, 0.078431375f, 0.235294133f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Cyan = { { { 0.000000000f, 1.000000000f, 1.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkBlue = { { { 0.000000000f, 0.000000000f, 0.545098066f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkCyan = { { { 0.000000000f, 0.545098066f, 0.545098066f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkGoldenrod = { { { 0.721568644f, 0.525490224f, 0.043137256f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkGray = { { { 0.662745118f, 0.662745118f, 0.662745118f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkGreen = { { { 0.000000000f, 0.392156899f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkKhaki = { { { 0.741176486f, 0.717647076f, 0.419607878f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkMagenta = { { { 0.545098066f, 0.000000000f, 0.545098066f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkOliveGreen = { { { 0.333333343f, 0.419607878f, 0.184313729f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkOrange = { { { 1.000000000f, 0.549019635f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkOrchid = { { { 0.600000024f, 0.196078449f, 0.800000072f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkRed = { { { 0.545098066f, 0.000000000f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkSalmon = { { { 0.913725555f, 0.588235319f, 0.478431404f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkSeaGreen = { { { 0.560784340f, 0.737254918f, 0.545098066f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkSlateBlue = { { { 0.282352954f, 0.239215702f, 0.545098066f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkSlateGray = { { { 0.184313729f, 0.309803933f, 0.309803933f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkTurquoise = { { { 0.000000000f, 0.807843208f, 0.819607913f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DarkViolet = { { { 0.580392182f, 0.000000000f, 0.827451050f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DeepPink = { { { 1.000000000f, 0.078431375f, 0.576470613f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DeepSkyBlue = { { { 0.000000000f, 0.749019623f, 1.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DimGray = { { { 0.411764741f, 0.411764741f, 0.411764741f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 DodgerBlue = { { { 0.117647067f, 0.564705908f, 1.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Firebrick = { { { 0.698039234f, 0.133333340f, 0.133333340f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 FloralWhite = { { { 1.000000000f, 0.980392218f, 0.941176534f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 ForestGreen = { { { 0.133333340f, 0.545098066f, 0.133333340f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Fuchsia = { { { 1.000000000f, 0.000000000f, 1.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Gainsboro = { { { 0.862745166f, 0.862745166f, 0.862745166f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 GhostWhite = { { { 0.972549081f, 0.972549081f, 1.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Gold = { { { 1.000000000f, 0.843137324f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Goldenrod = { { { 0.854902029f, 0.647058845f, 0.125490203f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Gray = { { { 0.501960814f, 0.501960814f, 0.501960814f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Green = { { { 0.000000000f, 0.501960814f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 GreenYellow = { { { 0.678431392f, 1.000000000f, 0.184313729f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Honeydew = { { { 0.941176534f, 1.000000000f, 0.941176534f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 HotPink = { { { 1.000000000f, 0.411764741f, 0.705882370f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 IndianRed = { { { 0.803921640f, 0.360784322f, 0.360784322f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Indigo = { { { 0.294117659f, 0.000000000f, 0.509803951f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Ivory = { { { 1.000000000f, 1.000000000f, 0.941176534f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Khaki = { { { 0.941176534f, 0.901960850f, 0.549019635f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Lavender = { { { 0.901960850f, 0.901960850f, 0.980392218f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LavenderBlush = { { { 1.000000000f, 0.941176534f, 0.960784376f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LawnGreen = { { { 0.486274540f, 0.988235354f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LemonChiffon = { { { 1.000000000f, 0.980392218f, 0.803921640f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LightBlue = { { { 0.678431392f, 0.847058892f, 0.901960850f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LightCoral = { { { 0.941176534f, 0.501960814f, 0.501960814f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LightCyan = { { { 0.878431439f, 1.000000000f, 1.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LightGoldenrodYellow = { { { 0.980392218f, 0.980392218f, 0.823529482f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LightGreen = { { { 0.564705908f, 0.933333397f, 0.564705908f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LightGray = { { { 0.827451050f, 0.827451050f, 0.827451050f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LightPink = { { { 1.000000000f, 0.713725507f, 0.756862819f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LightSalmon = { { { 1.000000000f, 0.627451003f, 0.478431404f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LightSeaGreen = { { { 0.125490203f, 0.698039234f, 0.666666687f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LightSkyBlue = { { { 0.529411793f, 0.807843208f, 0.980392218f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LightSlateGray = { { { 0.466666698f, 0.533333361f, 0.600000024f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LightSteelBlue = { { { 0.690196097f, 0.768627524f, 0.870588303f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LightYellow = { { { 1.000000000f, 1.000000000f, 0.878431439f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Lime = { { { 0.000000000f, 1.000000000f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 LimeGreen = { { { 0.196078449f, 0.803921640f, 0.196078449f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Linen = { { { 0.980392218f, 0.941176534f, 0.901960850f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Magenta = { { { 1.000000000f, 0.000000000f, 1.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Maroon = { { { 0.501960814f, 0.000000000f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 MediumAquamarine = { { { 0.400000036f, 0.803921640f, 0.666666687f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 MediumBlue = { { { 0.000000000f, 0.000000000f, 0.803921640f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 MediumOrchid = { { { 0.729411781f, 0.333333343f, 0.827451050f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 MediumPurple = { { { 0.576470613f, 0.439215720f, 0.858823597f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 MediumSeaGreen = { { { 0.235294133f, 0.701960802f, 0.443137288f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 MediumSlateBlue = { { { 0.482352972f, 0.407843173f, 0.933333397f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 MediumSpringGreen = { { { 0.000000000f, 0.980392218f, 0.603921592f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 MediumTurquoise = { { { 0.282352954f, 0.819607913f, 0.800000072f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 MediumVioletRed = { { { 0.780392230f, 0.082352944f, 0.521568656f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 MidnightBlue = { { { 0.098039225f, 0.098039225f, 0.439215720f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 MintCream = { { { 0.960784376f, 1.000000000f, 0.980392218f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 MistyRose = { { { 1.000000000f, 0.894117713f, 0.882353008f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Moccasin = { { { 1.000000000f, 0.894117713f, 0.709803939f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 NavajoWhite = { { { 1.000000000f, 0.870588303f, 0.678431392f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Navy = { { { 0.000000000f, 0.000000000f, 0.501960814f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 OldLace = { { { 0.992156923f, 0.960784376f, 0.901960850f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Olive = { { { 0.501960814f, 0.501960814f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 OliveDrab = { { { 0.419607878f, 0.556862772f, 0.137254909f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Orange = { { { 1.000000000f, 0.647058845f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 OrangeRed = { { { 1.000000000f, 0.270588249f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Orchid = { { { 0.854902029f, 0.439215720f, 0.839215755f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 PaleGoldenrod = { { { 0.933333397f, 0.909803987f, 0.666666687f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 PaleGreen = { { { 0.596078455f, 0.984313786f, 0.596078455f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 PaleTurquoise = { { { 0.686274529f, 0.933333397f, 0.933333397f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 PaleVioletRed = { { { 0.858823597f, 0.439215720f, 0.576470613f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 PapayaWhip = { { { 1.000000000f, 0.937254965f, 0.835294187f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 PeachPuff = { { { 1.000000000f, 0.854902029f, 0.725490212f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Peru = { { { 0.803921640f, 0.521568656f, 0.247058839f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Pink = { { { 1.000000000f, 0.752941251f, 0.796078503f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Plum = { { { 0.866666734f, 0.627451003f, 0.866666734f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 PowderBlue = { { { 0.690196097f, 0.878431439f, 0.901960850f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Purple = { { { 0.501960814f, 0.000000000f, 0.501960814f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Red = { { { 1.000000000f, 0.000000000f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 RosyBrown = { { { 0.737254918f, 0.560784340f, 0.560784340f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 RoyalBlue = { { { 0.254901975f, 0.411764741f, 0.882353008f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 SaddleBrown = { { { 0.545098066f, 0.270588249f, 0.074509807f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Salmon = { { { 0.980392218f, 0.501960814f, 0.447058856f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 SandyBrown = { { { 0.956862807f, 0.643137276f, 0.376470625f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 SeaGreen = { { { 0.180392161f, 0.545098066f, 0.341176480f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 SeaShell = { { { 1.000000000f, 0.960784376f, 0.933333397f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Sienna = { { { 0.627451003f, 0.321568638f, 0.176470593f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Silver = { { { 0.752941251f, 0.752941251f, 0.752941251f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 SkyBlue = { { { 0.529411793f, 0.807843208f, 0.921568692f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 SlateBlue = { { { 0.415686309f, 0.352941185f, 0.803921640f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 SlateGray = { { { 0.439215720f, 0.501960814f, 0.564705908f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Snow = { { { 1.000000000f, 0.980392218f, 0.980392218f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 SpringGreen = { { { 0.000000000f, 1.000000000f, 0.498039246f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 SteelBlue = { { { 0.274509817f, 0.509803951f, 0.705882370f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Tan = { { { 0.823529482f, 0.705882370f, 0.549019635f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Teal = { { { 0.000000000f, 0.501960814f, 0.501960814f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Thistle = { { { 0.847058892f, 0.749019623f, 0.847058892f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Tomato = { { { 1.000000000f, 0.388235331f, 0.278431386f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Transparent = { { { 0.000000000f, 0.000000000f, 0.000000000f, 0.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Turquoise = { { { 0.250980407f, 0.878431439f, 0.815686345f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Violet = { { { 0.933333397f, 0.509803951f, 0.933333397f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Wheat = { { { 0.960784376f, 0.870588303f, 0.701960802f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 White = { { { 1.000000000f, 1.000000000f, 1.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 WhiteSmoke = { { { 0.960784376f, 0.960784376f, 0.960784376f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 Yellow = { { { 1.000000000f, 1.000000000f, 0.000000000f, 1.000000000f } } };
|
||||
XMGLOBALCONST XMVECTORF32 YellowGreen = { { { 0.603921592f, 0.803921640f, 0.196078449f, 1.000000000f } } };
|
||||
|
||||
} // namespace Colors
|
||||
|
||||
} // namespace DirectX
|
||||
|
2242
Sdk/External/DirectXMath/Inc/DirectXMath.h
vendored
Normal file
2242
Sdk/External/DirectXMath/Inc/DirectXMath.h
vendored
Normal file
File diff suppressed because it is too large
Load Diff
2187
Sdk/External/DirectXMath/Inc/DirectXMathConvert.inl
vendored
Normal file
2187
Sdk/External/DirectXMath/Inc/DirectXMathConvert.inl
vendored
Normal file
File diff suppressed because it is too large
Load Diff
3422
Sdk/External/DirectXMath/Inc/DirectXMathMatrix.inl
vendored
Normal file
3422
Sdk/External/DirectXMath/Inc/DirectXMathMatrix.inl
vendored
Normal file
File diff suppressed because it is too large
Load Diff
2452
Sdk/External/DirectXMath/Inc/DirectXMathMisc.inl
vendored
Normal file
2452
Sdk/External/DirectXMath/Inc/DirectXMathMisc.inl
vendored
Normal file
File diff suppressed because it is too large
Load Diff
14819
Sdk/External/DirectXMath/Inc/DirectXMathVector.inl
vendored
Normal file
14819
Sdk/External/DirectXMath/Inc/DirectXMathVector.inl
vendored
Normal file
File diff suppressed because it is too large
Load Diff
1216
Sdk/External/DirectXMath/Inc/DirectXPackedVector.h
vendored
Normal file
1216
Sdk/External/DirectXMath/Inc/DirectXPackedVector.h
vendored
Normal file
File diff suppressed because it is too large
Load Diff
4438
Sdk/External/DirectXMath/Inc/DirectXPackedVector.inl
vendored
Normal file
4438
Sdk/External/DirectXMath/Inc/DirectXPackedVector.inl
vendored
Normal file
File diff suppressed because it is too large
Load Diff
21
Sdk/External/DirectXMath/LICENSE
vendored
Normal file
21
Sdk/External/DirectXMath/LICENSE
vendored
Normal file
@ -0,0 +1,21 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2011-2020 Microsoft Corp
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this
|
||||
software and associated documentation files (the "Software"), to deal in the Software
|
||||
without restriction, including without limitation the rights to use, copy, modify,
|
||||
merge, publish, distribute, sublicense, and/or sell copies of the Software, and to
|
||||
permit persons to whom the Software is furnished to do so, subject to the following
|
||||
conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies
|
||||
or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
|
||||
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
|
||||
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE
|
||||
OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
78
Sdk/External/DirectXMath/README.md
vendored
Normal file
78
Sdk/External/DirectXMath/README.md
vendored
Normal file
@ -0,0 +1,78 @@
|
||||
![DirectX Logo](https://github.com/Microsoft/DirectXMath/wiki/X_jpg.jpg)
|
||||
|
||||
# DirectXMath
|
||||
|
||||
https://github.com/Microsoft/DirectXMath
|
||||
|
||||
Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
|
||||
**August 2020**
|
||||
|
||||
This package contains the DirectXMath library, an all inline SIMD C++ linear algebra library for use in games and graphics apps
|
||||
|
||||
This code is designed to build with Visual Studio 2017, Visual Studio 2019, or clang for Windows. It is recommended that you make use of the latest updates (VS 2017 15.9 update, or VS 2019 Update 4 or later).
|
||||
|
||||
These components are designed to work without requiring any content from the legacy DirectX SDK. For details, see [Where is the DirectX SDK?](https://aka.ms/dxsdk).
|
||||
|
||||
## Directory Layout
|
||||
|
||||
* ``Inc\``
|
||||
|
||||
+ DirectXMath Files (in the DirectX C++ namespace)
|
||||
|
||||
* DirectXMath.h - Core library
|
||||
* DirectXPackedVector.h - Load/Store functions and types for working with various compressed GPU formats
|
||||
* DirectXColors.h - .NET-style Color defines in sRGB color space
|
||||
* DirectXCollision.h - Bounding volume collision library
|
||||
|
||||
* ``Extentions\``
|
||||
|
||||
+ Advanced instruction set variants for guarded codepaths
|
||||
|
||||
* DirectXMathSSE3.h - SSE3
|
||||
* DirectXMathBE.h - Supplemental SSE3 (SSSE3)
|
||||
* DirectXMathSSE4.h - SSE4.1
|
||||
* DirectXMathAVX.h - Advanced Vector Extensions (AVX)
|
||||
* DirectXMathAVX2.h - Advanced Vector Extensions 2 (AVX2)
|
||||
* DirectXMathF16C.h - Half-precision conversions (F16C)
|
||||
* DirectXMathFMA3.h - Fused multiply-accumulate (FMA3)
|
||||
* DirectXMathFMA4.h - Fused multiply-accumulate (FMA4)
|
||||
|
||||
* ``SHMath\``
|
||||
|
||||
+ Spherical Harmonics math functions
|
||||
|
||||
* DirectXSH.h - Header for SHMath functions
|
||||
* DirectXSH.cpp, DirectXSHD3D11.cpp, DirectXSHD3D12.cpp - Implementation
|
||||
|
||||
* ``XDSP\``
|
||||
|
||||
+ XDSP.h - Digital Signal Processing helper functions
|
||||
|
||||
## Documentation
|
||||
|
||||
Documentation is available on the [Microsoft Docs](https://docs.microsoft.com/en-us/windows/desktop/dxmath/directxmath-portal). Additional information can be found on the [project wiki](https://github.com/microsoft/DirectXMath/wiki).
|
||||
|
||||
## Compiler support
|
||||
|
||||
Officially the library is supported with Microsoft Visual C++ and clang/LLVM. It should also compile with the Intel C++ compiler, GCC, and MinGW compilers.
|
||||
|
||||
To build for non-Windows platforms, you need to provide a ``sal.h`` header in your include path. You can obtain an open source version from [GitHub](https://github.com/dotnet/corert/blob/master/src/Native/inc/unix/sal.h).
|
||||
|
||||
## Notices
|
||||
|
||||
All content and source code for this package are subject to the terms of the [MIT License](http://opensource.org/licenses/MIT).
|
||||
|
||||
For the latest version of DirectXMath, bug reports, etc. please visit the project site on [GitHub](https://github.com/microsoft/DirectXMath).
|
||||
|
||||
## Contributing
|
||||
|
||||
This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.
|
||||
|
||||
When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.
|
||||
|
||||
This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.
|
||||
|
||||
## Trademarks
|
||||
|
||||
This project may contain trademarks or logos for projects, products, or services. Authorized use of Microsoft trademarks or logos is subject to and must follow [Microsoft's Trademark & Brand Guidelines](https://www.microsoft.com/en-us/legal/intellectualproperty/trademarks/usage/general). Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship. Any use of third-party trademarks or logos are subject to those third-party's policies.
|
41
Sdk/External/DirectXMath/SECURITY.md
vendored
Normal file
41
Sdk/External/DirectXMath/SECURITY.md
vendored
Normal file
@ -0,0 +1,41 @@
|
||||
<!-- BEGIN MICROSOFT SECURITY.MD V0.0.5 BLOCK -->
|
||||
|
||||
## Security
|
||||
|
||||
Microsoft takes the security of our software products and services seriously, which includes all source code repositories managed through our GitHub organizations, which include [Microsoft](https://github.com/Microsoft), [Azure](https://github.com/Azure), [DotNet](https://github.com/dotnet), [AspNet](https://github.com/aspnet), [Xamarin](https://github.com/xamarin), and [our GitHub organizations](https://opensource.microsoft.com/).
|
||||
|
||||
If you believe you have found a security vulnerability in any Microsoft-owned repository that meets [Microsoft's definition of a security vulnerability](https://docs.microsoft.com/en-us/previous-versions/tn-archive/cc751383(v=technet.10)), please report it to us as described below.
|
||||
|
||||
## Reporting Security Issues
|
||||
|
||||
**Please do not report security vulnerabilities through public GitHub issues.**
|
||||
|
||||
Instead, please report them to the Microsoft Security Response Center (MSRC) at [https://msrc.microsoft.com/create-report](https://msrc.microsoft.com/create-report).
|
||||
|
||||
If you prefer to submit without logging in, send email to [secure@microsoft.com](mailto:secure@microsoft.com). If possible, encrypt your message with our PGP key; please download it from the [Microsoft Security Response Center PGP Key page](https://www.microsoft.com/en-us/msrc/pgp-key-msrc).
|
||||
|
||||
You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Additional information can be found at [microsoft.com/msrc](https://www.microsoft.com/msrc).
|
||||
|
||||
Please include the requested information listed below (as much as you can provide) to help us better understand the nature and scope of the possible issue:
|
||||
|
||||
* Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.)
|
||||
* Full paths of source file(s) related to the manifestation of the issue
|
||||
* The location of the affected source code (tag/branch/commit or direct URL)
|
||||
* Any special configuration required to reproduce the issue
|
||||
* Step-by-step instructions to reproduce the issue
|
||||
* Proof-of-concept or exploit code (if possible)
|
||||
* Impact of the issue, including how an attacker might exploit the issue
|
||||
|
||||
This information will help us triage your report more quickly.
|
||||
|
||||
If you are reporting for a bug bounty, more complete reports can contribute to a higher bounty award. Please visit our [Microsoft Bug Bounty Program](https://microsoft.com/msrc/bounty) page for more details about our active programs.
|
||||
|
||||
## Preferred Languages
|
||||
|
||||
We prefer all communications to be in English.
|
||||
|
||||
## Policy
|
||||
|
||||
Microsoft follows the principle of [Coordinated Vulnerability Disclosure](https://www.microsoft.com/en-us/msrc/cvd).
|
||||
|
||||
<!-- END MICROSOFT SECURITY.MD BLOCK -->
|
4905
Sdk/External/DirectXMath/SHMath/DirectXSH.cpp
vendored
Normal file
4905
Sdk/External/DirectXMath/SHMath/DirectXSH.cpp
vendored
Normal file
File diff suppressed because it is too large
Load Diff
72
Sdk/External/DirectXMath/SHMath/DirectXSH.h
vendored
Normal file
72
Sdk/External/DirectXMath/SHMath/DirectXSH.h
vendored
Normal file
@ -0,0 +1,72 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// DirectXSH.h -- C++ Spherical Harmonics Math Library
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/p/?LinkId=262885
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#define DIRECTX_SHMATH_VERSION 106
|
||||
|
||||
#include <DirectXMath.h>
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
const size_t XM_SH_MINORDER = 2;
|
||||
const size_t XM_SH_MAXORDER = 6;
|
||||
|
||||
float* XM_CALLCONV XMSHEvalDirection(_Out_writes_(order*order) float *result, _In_ size_t order, _In_ FXMVECTOR dir) noexcept;
|
||||
|
||||
float* XM_CALLCONV XMSHRotate(_Out_writes_(order*order) float *result, _In_ size_t order, _In_ FXMMATRIX rotMatrix, _In_reads_(order*order) const float *input) noexcept;
|
||||
|
||||
float* XMSHRotateZ(_Out_writes_(order*order) float *result, _In_ size_t order, _In_ float angle, _In_reads_(order*order) const float *input) noexcept;
|
||||
|
||||
float* XMSHAdd(_Out_writes_(order*order) float *result, _In_ size_t order, _In_reads_(order*order) const float *inputA, _In_reads_(order*order) const float *inputB) noexcept;
|
||||
|
||||
float* XMSHScale(_Out_writes_(order*order) float *result, _In_ size_t order, _In_reads_(order*order) const float *input, _In_ float scale) noexcept;
|
||||
|
||||
float XMSHDot(_In_ size_t order, _In_reads_(order*order) const float *inputA, _In_reads_(order*order) const float *inputB) noexcept;
|
||||
|
||||
float* XMSHMultiply(_Out_writes_(order*order) float *result, _In_ size_t order, _In_reads_(order*order) const float *inputF, _In_reads_(order*order) const float *inputG) noexcept;
|
||||
|
||||
float* XMSHMultiply2(_Out_writes_(4) float *result, _In_reads_(4) const float *inputF, _In_reads_(4) const float *inputG) noexcept;
|
||||
|
||||
float* XMSHMultiply3(_Out_writes_(9) float *result, _In_reads_(9) const float *inputF, _In_reads_(9) const float *inputG) noexcept;
|
||||
|
||||
float* XMSHMultiply4(_Out_writes_(16) float *result, _In_reads_(16) const float *inputF, _In_reads_(16) const float *inputG) noexcept;
|
||||
|
||||
float* XMSHMultiply5(_Out_writes_(25) float *result, _In_reads_(25) const float *inputF, _In_reads_(25) const float *inputG) noexcept;
|
||||
|
||||
float* XMSHMultiply6(_Out_writes_(36) float *result, _In_reads_(36) const float *inputF, _In_reads_(36) const float *inputG) noexcept;
|
||||
|
||||
bool XM_CALLCONV XMSHEvalDirectionalLight(
|
||||
_In_ size_t order, _In_ FXMVECTOR dir, _In_ FXMVECTOR color,
|
||||
_Out_writes_(order*order) float *resultR, _Out_writes_opt_(order*order) float *resultG, _Out_writes_opt_(order*order) float *resultB) noexcept;
|
||||
|
||||
bool XM_CALLCONV XMSHEvalSphericalLight(
|
||||
_In_ size_t order, _In_ FXMVECTOR pos, _In_ float radius, _In_ FXMVECTOR color,
|
||||
_Out_writes_(order*order) float *resultR, _Out_writes_opt_(order*order) float *resultG, _Out_writes_opt_(order*order) float *resultB) noexcept;
|
||||
|
||||
bool XM_CALLCONV XMSHEvalConeLight(
|
||||
_In_ size_t order, _In_ FXMVECTOR dir, _In_ float radius, _In_ FXMVECTOR color,
|
||||
_Out_writes_(order*order) float *resultR, _Out_writes_opt_(order*order) float *resultG, _Out_writes_opt_(order*order) float *resultB) noexcept;
|
||||
|
||||
bool XM_CALLCONV XMSHEvalHemisphereLight(
|
||||
_In_ size_t order, _In_ FXMVECTOR dir, _In_ FXMVECTOR topColor, _In_ FXMVECTOR bottomColor,
|
||||
_Out_writes_(order*order) float *resultR, _Out_writes_opt_(order*order) float *resultG, _Out_writes_opt_(order*order) float *resultB) noexcept;
|
||||
|
||||
#if defined(__d3d11_h__) || defined(__d3d11_x_h__)
|
||||
HRESULT SHProjectCubeMap(
|
||||
_In_ ID3D11DeviceContext *context, _In_ size_t order, _In_ ID3D11Texture2D *cubeMap,
|
||||
_Out_writes_opt_(order*order) float *resultR, _Out_writes_opt_(order*order) float *resultG, _Out_writes_opt_(order*order) float *resultB) noexcept;
|
||||
#endif
|
||||
|
||||
#if defined(__d3d12_h__) || defined(__d3d12_x_h__) || defined(__XBOX_D3D12_X__)
|
||||
HRESULT SHProjectCubeMap(
|
||||
_In_ size_t order, _In_ const D3D12_RESOURCE_DESC& desc, _In_ const D3D12_SUBRESOURCE_DATA cubeMap[6],
|
||||
_Out_writes_opt_(order*order) float *resultR, _Out_writes_opt_(order*order) float *resultG, _Out_writes_opt_(order*order) float *resultB) noexcept;
|
||||
#endif
|
||||
} // namespace DirectX
|
376
Sdk/External/DirectXMath/SHMath/DirectXSHD3D11.cpp
vendored
Normal file
376
Sdk/External/DirectXMath/SHMath/DirectXSHD3D11.cpp
vendored
Normal file
@ -0,0 +1,376 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// DirectXSHD3D11.cpp -- C++ Spherical Harmonics Math Library
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/p/?LinkId=262885
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma warning( disable : 4616 4619 4061 4265 4626 5039 )
|
||||
// C4616/C4619 #pragma warning warnings
|
||||
// C4061 numerator 'identifier' in switch of enum 'enumeration' is not explicitly handled by a case label
|
||||
// C4265 class has virtual functions, but destructor is not virtual
|
||||
// C4626 assignment operator was implicitly defined as deleted
|
||||
// C5039 pointer or reference to potentially throwing function passed to extern C function under - EHc
|
||||
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable: 4365)
|
||||
#include <d3d11_1.h>
|
||||
#pragma warning(pop)
|
||||
|
||||
#include "DirectXSH.h"
|
||||
|
||||
#include <DirectXPackedVector.h>
|
||||
|
||||
#include <cassert>
|
||||
#include <memory>
|
||||
#include <malloc.h>
|
||||
|
||||
#include <wrl/client.h>
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic ignored "-Wcovered-switch-default"
|
||||
#pragma clang diagnostic ignored "-Wswitch-enum"
|
||||
#endif
|
||||
|
||||
using namespace DirectX;
|
||||
|
||||
using Microsoft::WRL::ComPtr;
|
||||
|
||||
namespace
|
||||
{
|
||||
struct aligned_deleter { void operator()(void* p) { _aligned_free(p); } };
|
||||
|
||||
using ScopedAlignedArrayXMVECTOR = std::unique_ptr<DirectX::XMVECTOR, aligned_deleter>;
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// This code is lifted from DirectXTex http://go.microsoft.com/fwlink/?LinkId=248926
|
||||
// If you need additional DXGI format support, see DirectXTexConvert.cpp
|
||||
//-------------------------------------------------------------------------------------
|
||||
#define LOAD_SCANLINE( type, func )\
|
||||
if ( size >= sizeof(type) )\
|
||||
{\
|
||||
const type * __restrict sPtr = reinterpret_cast<const type*>(pSource);\
|
||||
for( size_t icount = 0; icount < ( size - sizeof(type) + 1 ); icount += sizeof(type) )\
|
||||
{\
|
||||
if ( dPtr >= ePtr ) break;\
|
||||
*(dPtr++) = func( sPtr++ );\
|
||||
}\
|
||||
return true;\
|
||||
}\
|
||||
return false;
|
||||
|
||||
#define LOAD_SCANLINE3( type, func, defvec )\
|
||||
if ( size >= sizeof(type) )\
|
||||
{\
|
||||
const type * __restrict sPtr = reinterpret_cast<const type*>(pSource);\
|
||||
for( size_t icount = 0; icount < ( size - sizeof(type) + 1 ); icount += sizeof(type) )\
|
||||
{\
|
||||
XMVECTOR v = func( sPtr++ );\
|
||||
if ( dPtr >= ePtr ) break;\
|
||||
*(dPtr++) = XMVectorSelect( defvec, v, g_XMSelect1110 );\
|
||||
}\
|
||||
return true;\
|
||||
}\
|
||||
return false;
|
||||
|
||||
#define LOAD_SCANLINE2( type, func, defvec )\
|
||||
if ( size >= sizeof(type) )\
|
||||
{\
|
||||
const type * __restrict sPtr = reinterpret_cast<const type*>(pSource);\
|
||||
for( size_t icount = 0; icount < ( size - sizeof(type) + 1 ); icount += sizeof(type) )\
|
||||
{\
|
||||
XMVECTOR v = func( sPtr++ );\
|
||||
if ( dPtr >= ePtr ) break;\
|
||||
*(dPtr++) = XMVectorSelect( defvec, v, g_XMSelect1100 );\
|
||||
}\
|
||||
return true;\
|
||||
}\
|
||||
return false;
|
||||
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable : 6101)
|
||||
_Success_(return)
|
||||
bool _LoadScanline(
|
||||
_Out_writes_(count) DirectX::XMVECTOR* pDestination,
|
||||
size_t count,
|
||||
_In_reads_bytes_(size) LPCVOID pSource,
|
||||
size_t size,
|
||||
DXGI_FORMAT format)
|
||||
{
|
||||
assert(pDestination && count > 0 && ((reinterpret_cast<uintptr_t>(pDestination) & 0xF) == 0));
|
||||
assert(pSource && size > 0);
|
||||
|
||||
using namespace DirectX::PackedVector;
|
||||
|
||||
XMVECTOR* __restrict dPtr = pDestination;
|
||||
if (!dPtr)
|
||||
return false;
|
||||
|
||||
const XMVECTOR* ePtr = pDestination + count;
|
||||
|
||||
switch (format)
|
||||
{
|
||||
case DXGI_FORMAT_R32G32B32A32_FLOAT:
|
||||
{
|
||||
size_t msize = (size > (sizeof(XMVECTOR)*count)) ? (sizeof(XMVECTOR)*count) : size;
|
||||
memcpy_s(dPtr, sizeof(XMVECTOR)*count, pSource, msize);
|
||||
}
|
||||
return true;
|
||||
|
||||
case DXGI_FORMAT_R32G32B32_FLOAT:
|
||||
LOAD_SCANLINE3(XMFLOAT3, XMLoadFloat3, g_XMIdentityR3)
|
||||
|
||||
case DXGI_FORMAT_R16G16B16A16_FLOAT:
|
||||
LOAD_SCANLINE(XMHALF4, XMLoadHalf4)
|
||||
|
||||
case DXGI_FORMAT_R32G32_FLOAT:
|
||||
LOAD_SCANLINE2(XMFLOAT2, XMLoadFloat2, g_XMIdentityR3)
|
||||
|
||||
case DXGI_FORMAT_R11G11B10_FLOAT:
|
||||
LOAD_SCANLINE3(XMFLOAT3PK, XMLoadFloat3PK, g_XMIdentityR3)
|
||||
|
||||
case DXGI_FORMAT_R16G16_FLOAT:
|
||||
LOAD_SCANLINE2(XMHALF2, XMLoadHalf2, g_XMIdentityR3)
|
||||
|
||||
case DXGI_FORMAT_R32_FLOAT:
|
||||
if (size >= sizeof(float))
|
||||
{
|
||||
const float* __restrict sPtr = reinterpret_cast<const float*>(pSource);
|
||||
for (size_t icount = 0; icount < size; icount += sizeof(float))
|
||||
{
|
||||
XMVECTOR v = XMLoadFloat(sPtr++);
|
||||
if (dPtr >= ePtr) break;
|
||||
*(dPtr++) = XMVectorSelect(g_XMIdentityR3, v, g_XMSelect1000);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
||||
case DXGI_FORMAT_R16_FLOAT:
|
||||
if (size >= sizeof(HALF))
|
||||
{
|
||||
const HALF * __restrict sPtr = reinterpret_cast<const HALF*>(pSource);
|
||||
for (size_t icount = 0; icount < size; icount += sizeof(HALF))
|
||||
{
|
||||
if (dPtr >= ePtr) break;
|
||||
*(dPtr++) = XMVectorSet(XMConvertHalfToFloat(*sPtr++), 0.f, 0.f, 1.f);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
||||
#pragma warning(pop)
|
||||
|
||||
} // namespace anonymous
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Projects a function represented in a cube map into spherical harmonics.
|
||||
//
|
||||
// http://msdn.microsoft.com/en-us/library/windows/desktop/ff476300.aspx
|
||||
//-------------------------------------------------------------------------------------
|
||||
_Use_decl_annotations_
|
||||
HRESULT DirectX::SHProjectCubeMap(
|
||||
ID3D11DeviceContext *context,
|
||||
size_t order,
|
||||
ID3D11Texture2D *cubeMap,
|
||||
float *resultR,
|
||||
float *resultG,
|
||||
float* resultB) noexcept
|
||||
{
|
||||
if (!context || !cubeMap)
|
||||
return E_INVALIDARG;
|
||||
|
||||
if (order < XM_SH_MINORDER || order > XM_SH_MAXORDER)
|
||||
return E_INVALIDARG;
|
||||
|
||||
D3D11_TEXTURE2D_DESC desc;
|
||||
cubeMap->GetDesc(&desc);
|
||||
|
||||
if ((desc.ArraySize != 6)
|
||||
|| (desc.Width != desc.Height)
|
||||
|| (desc.SampleDesc.Count > 1))
|
||||
return E_FAIL;
|
||||
|
||||
switch (desc.Format)
|
||||
{
|
||||
case DXGI_FORMAT_R32G32B32A32_FLOAT:
|
||||
case DXGI_FORMAT_R32G32B32_FLOAT:
|
||||
case DXGI_FORMAT_R16G16B16A16_FLOAT:
|
||||
case DXGI_FORMAT_R32G32_FLOAT:
|
||||
case DXGI_FORMAT_R11G11B10_FLOAT:
|
||||
case DXGI_FORMAT_R16G16_FLOAT:
|
||||
case DXGI_FORMAT_R32_FLOAT:
|
||||
case DXGI_FORMAT_R16_FLOAT:
|
||||
// See _LoadScanline to support more pixel formats
|
||||
break;
|
||||
|
||||
default:
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
//--- Create a staging resource copy (if needed) to be able to read data
|
||||
ID3D11Texture2D* texture = nullptr;
|
||||
|
||||
ComPtr<ID3D11Texture2D> staging;
|
||||
if (!(desc.CPUAccessFlags & D3D11_CPU_ACCESS_READ))
|
||||
{
|
||||
D3D11_TEXTURE2D_DESC sdesc = desc;
|
||||
sdesc.BindFlags = 0;
|
||||
sdesc.CPUAccessFlags = D3D11_CPU_ACCESS_READ;
|
||||
sdesc.Usage = D3D11_USAGE_STAGING;
|
||||
|
||||
ComPtr<ID3D11Device> device;
|
||||
context->GetDevice(&device);
|
||||
|
||||
HRESULT hr = device->CreateTexture2D(&sdesc, nullptr, &staging);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
context->CopyResource(staging.Get(), cubeMap);
|
||||
|
||||
texture = staging.Get();
|
||||
}
|
||||
else
|
||||
texture = cubeMap;
|
||||
|
||||
assert(texture != nullptr);
|
||||
|
||||
//--- Setup for SH projection
|
||||
ScopedAlignedArrayXMVECTOR scanline(reinterpret_cast<XMVECTOR*>(_aligned_malloc(sizeof(XMVECTOR)*desc.Width, 16)));
|
||||
if (!scanline)
|
||||
return E_OUTOFMEMORY;
|
||||
|
||||
assert(desc.Width > 0);
|
||||
float fSize = static_cast<float>(desc.Width);
|
||||
float fPicSize = 1.0f / fSize;
|
||||
|
||||
// index from [0,W-1], f(0) maps to -1 + 1/W, f(W-1) maps to 1 - 1/w
|
||||
// linear function x*S +B, 1st constraint means B is (-1+1/W), plug into
|
||||
// second and solve for S: S = 2*(1-1/W)/(W-1). The old code that did
|
||||
// this was incorrect - but only for computing the differential solid
|
||||
// angle, where the final value was 1.0 instead of 1-1/w...
|
||||
|
||||
float fB = -1.0f + 1.0f / fSize;
|
||||
float fS = (desc.Width > 1) ? (2.0f*(1.0f - 1.0f / fSize) / (fSize - 1.0f)) : 0.f;
|
||||
|
||||
// clear out accumulation variables
|
||||
float fWt = 0.0f;
|
||||
|
||||
if (resultR)
|
||||
memset(resultR, 0, sizeof(float)*order*order);
|
||||
if (resultG)
|
||||
memset(resultG, 0, sizeof(float)*order*order);
|
||||
if (resultB)
|
||||
memset(resultB, 0, sizeof(float)*order*order);
|
||||
|
||||
float shBuff[XM_SH_MAXORDER*XM_SH_MAXORDER] = {};
|
||||
float shBuffB[XM_SH_MAXORDER*XM_SH_MAXORDER] = {};
|
||||
|
||||
//--- Process each face of the cubemap
|
||||
for (UINT face = 0; face < 6; ++face)
|
||||
{
|
||||
UINT dindex = D3D11CalcSubresource(0, face, desc.MipLevels);
|
||||
|
||||
D3D11_MAPPED_SUBRESOURCE mapped;
|
||||
HRESULT hr = context->Map(texture, dindex, D3D11_MAP_READ, 0, &mapped);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
const uint8_t *pSrc = reinterpret_cast<const uint8_t*>(mapped.pData);
|
||||
for (UINT y = 0; y < desc.Height; ++y)
|
||||
{
|
||||
XMVECTOR* ptr = scanline.get();
|
||||
if (!_LoadScanline(ptr, desc.Width, pSrc, mapped.RowPitch, desc.Format))
|
||||
{
|
||||
context->Unmap(texture, dindex);
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
const float v = float(y) * fS + fB;
|
||||
|
||||
XMVECTOR* pixel = ptr;
|
||||
for (UINT x = 0; x < desc.Width; ++x, ++pixel)
|
||||
{
|
||||
const float u = float(x) * fS + fB;
|
||||
|
||||
float ix, iy, iz;
|
||||
switch (face)
|
||||
{
|
||||
case 0: // Positive X
|
||||
iz = 1.0f - (2.0f * float(x) + 1.0f) * fPicSize;
|
||||
iy = 1.0f - (2.0f * float(y) + 1.0f) * fPicSize;
|
||||
ix = 1.0f;
|
||||
break;
|
||||
|
||||
case 1: // Negative X
|
||||
iz = -1.0f + (2.0f * float(x) + 1.0f) * fPicSize;
|
||||
iy = 1.0f - (2.0f * float(y) + 1.0f) * fPicSize;
|
||||
ix = -1;
|
||||
break;
|
||||
|
||||
case 2: // Positive Y
|
||||
iz = -1.0f + (2.0f * float(y) + 1.0f) * fPicSize;
|
||||
iy = 1.0f;
|
||||
ix = -1.0f + (2.0f * float(x) + 1.0f) * fPicSize;
|
||||
break;
|
||||
|
||||
case 3: // Negative Y
|
||||
iz = 1.0f - (2.0f * float(y) + 1.0f) * fPicSize;
|
||||
iy = -1.0f;
|
||||
ix = -1.0f + (2.0f * float(x) + 1.0f) * fPicSize;
|
||||
break;
|
||||
|
||||
case 4: // Positive Z
|
||||
iz = 1.0f;
|
||||
iy = 1.0f - (2.0f * float(y) + 1.0f) * fPicSize;
|
||||
ix = -1.0f + (2.0f * float(x) + 1.0f) * fPicSize;
|
||||
break;
|
||||
|
||||
case 5: // Negative Z
|
||||
iz = -1.0f;
|
||||
iy = 1.0f - (2.0f * float(y) + 1.0f) * fPicSize;
|
||||
ix = 1.0f - (2.0f * float(x) + 1.0f) * fPicSize;
|
||||
break;
|
||||
|
||||
default:
|
||||
ix = iy = iz = 0.f;
|
||||
assert(false);
|
||||
break;
|
||||
}
|
||||
|
||||
XMVECTOR dir = XMVectorSet(ix, iy, iz, 0);
|
||||
dir = XMVector3Normalize(dir);
|
||||
|
||||
const float fDiffSolid = 4.0f / ((1.0f + u * u + v * v)*sqrtf(1.0f + u * u + v * v));
|
||||
fWt += fDiffSolid;
|
||||
|
||||
XMSHEvalDirection(shBuff, order, dir);
|
||||
|
||||
XMFLOAT3A clr;
|
||||
XMStoreFloat3A(&clr, *pixel);
|
||||
|
||||
if (resultR) XMSHAdd(resultR, order, resultR, XMSHScale(shBuffB, order, shBuff, clr.x*fDiffSolid));
|
||||
if (resultG) XMSHAdd(resultG, order, resultG, XMSHScale(shBuffB, order, shBuff, clr.y*fDiffSolid));
|
||||
if (resultB) XMSHAdd(resultB, order, resultB, XMSHScale(shBuffB, order, shBuff, clr.z*fDiffSolid));
|
||||
}
|
||||
|
||||
pSrc += mapped.RowPitch;
|
||||
}
|
||||
|
||||
context->Unmap(texture, dindex);
|
||||
}
|
||||
|
||||
const float fNormProj = (4.0f*XM_PI) / fWt;
|
||||
|
||||
if (resultR) XMSHScale(resultR, order, resultR, fNormProj);
|
||||
if (resultG) XMSHScale(resultG, order, resultG, fNormProj);
|
||||
if (resultB) XMSHScale(resultB, order, resultB, fNormProj);
|
||||
|
||||
return S_OK;
|
||||
}
|
334
Sdk/External/DirectXMath/SHMath/DirectXSHD3D12.cpp
vendored
Normal file
334
Sdk/External/DirectXMath/SHMath/DirectXSHD3D12.cpp
vendored
Normal file
@ -0,0 +1,334 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// DirectXSHD3D12.cpp -- C++ Spherical Harmonics Math Library
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/p/?LinkId=262885
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma warning( disable : 4616 4619 4061 4265 4626 5039 )
|
||||
// C4616/C4619 #pragma warning warnings
|
||||
// C4061 numerator 'identifier' in switch of enum 'enumeration' is not explicitly handled by a case label
|
||||
// C4265 class has virtual functions, but destructor is not virtual
|
||||
// C4626 assignment operator was implicitly defined as deleted
|
||||
// C5039 pointer or reference to potentially throwing function passed to extern C function under - EHc
|
||||
|
||||
#include <d3d12.h>
|
||||
|
||||
#include "DirectXSH.h"
|
||||
|
||||
#include <DirectXPackedVector.h>
|
||||
|
||||
#include <cassert>
|
||||
#include <memory>
|
||||
#include <malloc.h>
|
||||
|
||||
#include <wrl/client.h>
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic ignored "-Wcovered-switch-default"
|
||||
#pragma clang diagnostic ignored "-Wswitch-enum"
|
||||
#endif
|
||||
|
||||
using namespace DirectX;
|
||||
|
||||
using Microsoft::WRL::ComPtr;
|
||||
|
||||
namespace
|
||||
{
|
||||
struct aligned_deleter { void operator()(void* p) { _aligned_free(p); } };
|
||||
|
||||
using ScopedAlignedArrayXMVECTOR = std::unique_ptr<DirectX::XMVECTOR, aligned_deleter>;
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// This code is lifted from DirectXTex http://go.microsoft.com/fwlink/?LinkId=248926
|
||||
// If you need additional DXGI format support, see DirectXTexConvert.cpp
|
||||
//-------------------------------------------------------------------------------------
|
||||
#define LOAD_SCANLINE( type, func )\
|
||||
if ( size >= sizeof(type) )\
|
||||
{\
|
||||
const type * __restrict sPtr = reinterpret_cast<const type*>(pSource);\
|
||||
for( size_t icount = 0; icount < ( size - sizeof(type) + 1 ); icount += sizeof(type) )\
|
||||
{\
|
||||
if ( dPtr >= ePtr ) break;\
|
||||
*(dPtr++) = func( sPtr++ );\
|
||||
}\
|
||||
return true;\
|
||||
}\
|
||||
return false;
|
||||
|
||||
#define LOAD_SCANLINE3( type, func, defvec )\
|
||||
if ( size >= sizeof(type) )\
|
||||
{\
|
||||
const type * __restrict sPtr = reinterpret_cast<const type*>(pSource);\
|
||||
for( size_t icount = 0; icount < ( size - sizeof(type) + 1 ); icount += sizeof(type) )\
|
||||
{\
|
||||
XMVECTOR v = func( sPtr++ );\
|
||||
if ( dPtr >= ePtr ) break;\
|
||||
*(dPtr++) = XMVectorSelect( defvec, v, g_XMSelect1110 );\
|
||||
}\
|
||||
return true;\
|
||||
}\
|
||||
return false;
|
||||
|
||||
#define LOAD_SCANLINE2( type, func, defvec )\
|
||||
if ( size >= sizeof(type) )\
|
||||
{\
|
||||
const type * __restrict sPtr = reinterpret_cast<const type*>(pSource);\
|
||||
for( size_t icount = 0; icount < ( size - sizeof(type) + 1 ); icount += sizeof(type) )\
|
||||
{\
|
||||
XMVECTOR v = func( sPtr++ );\
|
||||
if ( dPtr >= ePtr ) break;\
|
||||
*(dPtr++) = XMVectorSelect( defvec, v, g_XMSelect1100 );\
|
||||
}\
|
||||
return true;\
|
||||
}\
|
||||
return false;
|
||||
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable : 6101)
|
||||
_Success_(return)
|
||||
bool _LoadScanline(
|
||||
_Out_writes_(count) DirectX::XMVECTOR* pDestination,
|
||||
size_t count,
|
||||
_In_reads_bytes_(size) LPCVOID pSource,
|
||||
size_t size,
|
||||
DXGI_FORMAT format)
|
||||
{
|
||||
assert(pDestination && count > 0 && ((reinterpret_cast<uintptr_t>(pDestination) & 0xF) == 0));
|
||||
assert(pSource && size > 0);
|
||||
|
||||
using namespace DirectX::PackedVector;
|
||||
|
||||
XMVECTOR* __restrict dPtr = pDestination;
|
||||
if (!dPtr)
|
||||
return false;
|
||||
|
||||
const XMVECTOR* ePtr = pDestination + count;
|
||||
|
||||
switch (format)
|
||||
{
|
||||
case DXGI_FORMAT_R32G32B32A32_FLOAT:
|
||||
{
|
||||
size_t msize = (size > (sizeof(XMVECTOR)*count)) ? (sizeof(XMVECTOR)*count) : size;
|
||||
memcpy_s(dPtr, sizeof(XMVECTOR)*count, pSource, msize);
|
||||
}
|
||||
return true;
|
||||
|
||||
case DXGI_FORMAT_R32G32B32_FLOAT:
|
||||
LOAD_SCANLINE3(XMFLOAT3, XMLoadFloat3, g_XMIdentityR3)
|
||||
|
||||
case DXGI_FORMAT_R16G16B16A16_FLOAT:
|
||||
LOAD_SCANLINE(XMHALF4, XMLoadHalf4)
|
||||
|
||||
case DXGI_FORMAT_R32G32_FLOAT:
|
||||
LOAD_SCANLINE2(XMFLOAT2, XMLoadFloat2, g_XMIdentityR3)
|
||||
|
||||
case DXGI_FORMAT_R11G11B10_FLOAT:
|
||||
LOAD_SCANLINE3(XMFLOAT3PK, XMLoadFloat3PK, g_XMIdentityR3)
|
||||
|
||||
case DXGI_FORMAT_R16G16_FLOAT:
|
||||
LOAD_SCANLINE2(XMHALF2, XMLoadHalf2, g_XMIdentityR3)
|
||||
|
||||
case DXGI_FORMAT_R32_FLOAT:
|
||||
if (size >= sizeof(float))
|
||||
{
|
||||
const float* __restrict sPtr = reinterpret_cast<const float*>(pSource);
|
||||
for (size_t icount = 0; icount < size; icount += sizeof(float))
|
||||
{
|
||||
XMVECTOR v = XMLoadFloat(sPtr++);
|
||||
if (dPtr >= ePtr) break;
|
||||
*(dPtr++) = XMVectorSelect(g_XMIdentityR3, v, g_XMSelect1000);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
||||
case DXGI_FORMAT_R16_FLOAT:
|
||||
if (size >= sizeof(HALF))
|
||||
{
|
||||
const HALF * __restrict sPtr = reinterpret_cast<const HALF*>(pSource);
|
||||
for (size_t icount = 0; icount < size; icount += sizeof(HALF))
|
||||
{
|
||||
if (dPtr >= ePtr) break;
|
||||
*(dPtr++) = XMVectorSet(XMConvertHalfToFloat(*sPtr++), 0.f, 0.f, 1.f);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
||||
#pragma warning(pop)
|
||||
|
||||
} // namespace anonymous
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Projects a function represented in a cube map into spherical harmonics.
|
||||
//
|
||||
// http://msdn.microsoft.com/en-us/library/windows/desktop/ff476300.aspx
|
||||
//-------------------------------------------------------------------------------------
|
||||
_Use_decl_annotations_
|
||||
HRESULT DirectX::SHProjectCubeMap(
|
||||
size_t order,
|
||||
const D3D12_RESOURCE_DESC& desc,
|
||||
const D3D12_SUBRESOURCE_DATA cubeMap[6],
|
||||
float *resultR,
|
||||
float *resultG,
|
||||
float *resultB) noexcept
|
||||
{
|
||||
if (order < XM_SH_MINORDER || order > XM_SH_MAXORDER)
|
||||
return E_INVALIDARG;
|
||||
|
||||
if (desc.Dimension != D3D12_RESOURCE_DIMENSION_TEXTURE2D
|
||||
|| (desc.DepthOrArraySize != 6)
|
||||
|| (desc.Width != desc.Height)
|
||||
|| (desc.SampleDesc.Count > 1))
|
||||
return E_FAIL;
|
||||
|
||||
switch (desc.Format)
|
||||
{
|
||||
case DXGI_FORMAT_R32G32B32A32_FLOAT:
|
||||
case DXGI_FORMAT_R32G32B32_FLOAT:
|
||||
case DXGI_FORMAT_R16G16B16A16_FLOAT:
|
||||
case DXGI_FORMAT_R32G32_FLOAT:
|
||||
case DXGI_FORMAT_R11G11B10_FLOAT:
|
||||
case DXGI_FORMAT_R16G16_FLOAT:
|
||||
case DXGI_FORMAT_R32_FLOAT:
|
||||
case DXGI_FORMAT_R16_FLOAT:
|
||||
// See _LoadScanline to support more pixel formats
|
||||
break;
|
||||
|
||||
default:
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
//--- Setup for SH projection
|
||||
ScopedAlignedArrayXMVECTOR scanline(reinterpret_cast<XMVECTOR*>(_aligned_malloc(static_cast<size_t>(sizeof(XMVECTOR)*desc.Width), 16)));
|
||||
if (!scanline)
|
||||
return E_OUTOFMEMORY;
|
||||
|
||||
assert(desc.Width > 0);
|
||||
float fSize = static_cast<float>(desc.Width);
|
||||
float fPicSize = 1.0f / fSize;
|
||||
|
||||
// index from [0,W-1], f(0) maps to -1 + 1/W, f(W-1) maps to 1 - 1/w
|
||||
// linear function x*S +B, 1st constraint means B is (-1+1/W), plug into
|
||||
// second and solve for S: S = 2*(1-1/W)/(W-1). The old code that did
|
||||
// this was incorrect - but only for computing the differential solid
|
||||
// angle, where the final value was 1.0 instead of 1-1/w...
|
||||
|
||||
float fB = -1.0f + 1.0f / fSize;
|
||||
float fS = (desc.Width > 1) ? (2.0f*(1.0f - 1.0f / fSize) / (fSize - 1.0f)) : 0.f;
|
||||
|
||||
// clear out accumulation variables
|
||||
float fWt = 0.0f;
|
||||
|
||||
if (resultR)
|
||||
memset(resultR, 0, sizeof(float)*order*order);
|
||||
if (resultG)
|
||||
memset(resultG, 0, sizeof(float)*order*order);
|
||||
if (resultB)
|
||||
memset(resultB, 0, sizeof(float)*order*order);
|
||||
|
||||
float shBuff[XM_SH_MAXORDER*XM_SH_MAXORDER] = {};
|
||||
float shBuffB[XM_SH_MAXORDER*XM_SH_MAXORDER] = {};
|
||||
|
||||
//--- Process each face of the cubemap
|
||||
for (UINT face = 0; face < 6; ++face)
|
||||
{
|
||||
if (!cubeMap[face].pData)
|
||||
return E_POINTER;
|
||||
|
||||
const uint8_t *pSrc = reinterpret_cast<const uint8_t*>(cubeMap[face].pData);
|
||||
for (UINT y = 0; y < desc.Height; ++y)
|
||||
{
|
||||
XMVECTOR* ptr = scanline.get();
|
||||
if (!_LoadScanline(ptr, static_cast<size_t>(desc.Width), pSrc, static_cast<size_t>(cubeMap[face].RowPitch), desc.Format))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
const float v = float(y) * fS + fB;
|
||||
|
||||
XMVECTOR* pixel = ptr;
|
||||
for (UINT x = 0; x < desc.Width; ++x, ++pixel)
|
||||
{
|
||||
const float u = float(x) * fS + fB;
|
||||
|
||||
float ix, iy, iz;
|
||||
switch (face)
|
||||
{
|
||||
case 0: // Positive X
|
||||
iz = 1.0f - (2.0f * float(x) + 1.0f) * fPicSize;
|
||||
iy = 1.0f - (2.0f * float(y) + 1.0f) * fPicSize;
|
||||
ix = 1.0f;
|
||||
break;
|
||||
|
||||
case 1: // Negative X
|
||||
iz = -1.0f + (2.0f * float(x) + 1.0f) * fPicSize;
|
||||
iy = 1.0f - (2.0f * float(y) + 1.0f) * fPicSize;
|
||||
ix = -1;
|
||||
break;
|
||||
|
||||
case 2: // Positive Y
|
||||
iz = -1.0f + (2.0f * float(y) + 1.0f) * fPicSize;
|
||||
iy = 1.0f;
|
||||
ix = -1.0f + (2.0f * float(x) + 1.0f) * fPicSize;
|
||||
break;
|
||||
|
||||
case 3: // Negative Y
|
||||
iz = 1.0f - (2.0f * float(y) + 1.0f) * fPicSize;
|
||||
iy = -1.0f;
|
||||
ix = -1.0f + (2.0f * float(x) + 1.0f) * fPicSize;
|
||||
break;
|
||||
|
||||
case 4: // Positive Z
|
||||
iz = 1.0f;
|
||||
iy = 1.0f - (2.0f * float(y) + 1.0f) * fPicSize;
|
||||
ix = -1.0f + (2.0f * float(x) + 1.0f) * fPicSize;
|
||||
break;
|
||||
|
||||
case 5: // Negative Z
|
||||
iz = -1.0f;
|
||||
iy = 1.0f - (2.0f * float(y) + 1.0f) * fPicSize;
|
||||
ix = 1.0f - (2.0f * float(x) + 1.0f) * fPicSize;
|
||||
break;
|
||||
|
||||
default:
|
||||
ix = iy = iz = 0.f;
|
||||
assert(false);
|
||||
break;
|
||||
}
|
||||
|
||||
XMVECTOR dir = XMVectorSet(ix, iy, iz, 0);
|
||||
dir = XMVector3Normalize(dir);
|
||||
|
||||
const float fDiffSolid = 4.0f / ((1.0f + u * u + v * v)*sqrtf(1.0f + u * u + v * v));
|
||||
fWt += fDiffSolid;
|
||||
|
||||
XMSHEvalDirection(shBuff, order, dir);
|
||||
|
||||
XMFLOAT3A clr;
|
||||
XMStoreFloat3A(&clr, *pixel);
|
||||
|
||||
if (resultR) XMSHAdd(resultR, order, resultR, XMSHScale(shBuffB, order, shBuff, clr.x*fDiffSolid));
|
||||
if (resultG) XMSHAdd(resultG, order, resultG, XMSHScale(shBuffB, order, shBuff, clr.y*fDiffSolid));
|
||||
if (resultB) XMSHAdd(resultB, order, resultB, XMSHScale(shBuffB, order, shBuff, clr.z*fDiffSolid));
|
||||
}
|
||||
|
||||
pSrc += cubeMap[face].RowPitch;
|
||||
}
|
||||
}
|
||||
|
||||
const float fNormProj = (4.0f*XM_PI) / fWt;
|
||||
|
||||
if (resultR) XMSHScale(resultR, order, resultR, fNormProj);
|
||||
if (resultG) XMSHScale(resultG, order, resultG, fNormProj);
|
||||
if (resultB) XMSHScale(resultB, order, resultB, fNormProj);
|
||||
|
||||
return S_OK;
|
||||
}
|
257
Sdk/External/DirectXMath/Stereo3D/Stereo3DMatrixHelper.cpp
vendored
Normal file
257
Sdk/External/DirectXMath/Stereo3D/Stereo3DMatrixHelper.cpp
vendored
Normal file
@ -0,0 +1,257 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Stereo3DMatrixHelper.cpp -- SIMD C++ Math helper for Stereo 3D matricies
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#include "Stereo3DMatrixHelper.h"
|
||||
|
||||
using namespace DirectX;
|
||||
|
||||
namespace
|
||||
{
|
||||
inline bool StereoProjectionHelper
|
||||
(
|
||||
const STEREO_PARAMETERS& stereoParameters,
|
||||
_Out_ float* fVirtualProjection,
|
||||
_Out_ float* zNearWidth,
|
||||
_Out_ float* zNearHeight,
|
||||
float FovAngleY,
|
||||
float AspectRatio,
|
||||
float NearZ
|
||||
)
|
||||
{
|
||||
// note that most people have difficulty fusing images into 3D
|
||||
// if the separation equals even just the human average. by
|
||||
// reducing the separation (interocular distance) by 1/2, we
|
||||
// guarantee a larger subset of people will see full 3D
|
||||
|
||||
// the conservative setting should always be used. the only problem
|
||||
// with the conservative setting is that the 3D effect will be less
|
||||
// impressive on smaller screens (which makes sense, since your eye
|
||||
// cannot be tricked as easily based on the smaller fov). to simulate
|
||||
// the effect of a larger screen, use the liberal settings (debug only)
|
||||
|
||||
// Conservative Settings: * max acuity angle: 0.8f degrees * interoc distance: 1.25 inches
|
||||
|
||||
// Liberal Settings: * max acuity angle: 1.6f degrees * interoc distance: 2.5f inches
|
||||
|
||||
// maximum visual accuity angle allowed is 3.2 degrees for
|
||||
// a physical scene, and 1.6 degrees for a virtual one.
|
||||
// thus we cannot allow an object to appear any closer to
|
||||
// the viewer than 1.6 degrees (divided by two for most
|
||||
// half-angle calculations)
|
||||
|
||||
static const float fMaxStereoDistance = 780; // inches (should be between 10 and 20m)
|
||||
static const float fMaxVisualAcuityAngle = 1.6f * (XM_PI / 180.0f); // radians
|
||||
static const float fInterocularDistance = 1.25f; // inches
|
||||
|
||||
float fDisplayHeight = stereoParameters.fDisplaySizeInches / sqrtf(AspectRatio * AspectRatio + 1.0f);
|
||||
float fDisplayWidth = fDisplayHeight * AspectRatio;
|
||||
float fHalfInterocular = 0.5f * fInterocularDistance * stereoParameters.fStereoExaggerationFactor;
|
||||
float fHalfPixelWidth = fDisplayWidth / stereoParameters.fPixelResolutionWidth * 0.5f;
|
||||
float fHalfMaximumAcuityAngle = fMaxVisualAcuityAngle * 0.5f * stereoParameters.fStereoExaggerationFactor;
|
||||
// float fHalfWidth = fDisplayWidth * 0.5f;
|
||||
|
||||
float fMaxSeparationAcuityAngle = atanf(fHalfInterocular / fMaxStereoDistance);
|
||||
float fMaxSeparationDistance = fHalfPixelWidth / tanf(fMaxSeparationAcuityAngle);
|
||||
float fRefinedMaxStereoDistance = fMaxStereoDistance - fMaxSeparationDistance;
|
||||
float fFovHalfAngle = FovAngleY / 2.0f;
|
||||
|
||||
bool ComfortableResult = true;
|
||||
if (fRefinedMaxStereoDistance < 0.0f || fMaxSeparationDistance > 0.1f * fMaxStereoDistance)
|
||||
{
|
||||
// Pixel resolution is too low to offer a comfortable stereo experience
|
||||
ComfortableResult = false;
|
||||
}
|
||||
|
||||
float fRefinedMaxSeparationAcuityAngle = atanf(fHalfInterocular / (fRefinedMaxStereoDistance));
|
||||
float fPhysicalZNearDistance = fHalfInterocular / tanf(fHalfMaximumAcuityAngle);
|
||||
// float fScalingFactor = fHalfMaximumAcuityAngle / atanf(fHalfInterocular / stereoParameters.fViewerDistanceInches);
|
||||
|
||||
float fNearZSeparation = tanf(fRefinedMaxSeparationAcuityAngle) * (fRefinedMaxStereoDistance - fPhysicalZNearDistance);
|
||||
// float fNearZSeparation2 = fHalfInterocular * (fRefinedMaxStereoDistance - fPhysicalZNearDistance) / fRefinedMaxStereoDistance;
|
||||
|
||||
(*zNearHeight) = cosf(fFovHalfAngle) / sinf(fFovHalfAngle);
|
||||
(*zNearWidth) = (*zNearHeight) / AspectRatio;
|
||||
(*fVirtualProjection) = (fNearZSeparation * NearZ * (*zNearWidth * 4.0f)) / (2.0f * NearZ);
|
||||
|
||||
return ComfortableResult;
|
||||
}
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
void DirectX::StereoCreateDefaultParameters
|
||||
(
|
||||
STEREO_PARAMETERS& stereoParameters
|
||||
)
|
||||
{
|
||||
// Default assumption is 1920x1200 resolution, a 22" LCD monitor, and a 2' viewing distance
|
||||
stereoParameters.fViewerDistanceInches = 24.0f;
|
||||
stereoParameters.fPixelResolutionWidth = 1920.0f;
|
||||
stereoParameters.fPixelResolutionHeight = 1200.0f;
|
||||
stereoParameters.fDisplaySizeInches = 22.0f;
|
||||
|
||||
stereoParameters.fStereoSeparationFactor = 1.0f;
|
||||
stereoParameters.fStereoExaggerationFactor = 1.0f;
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
XMMATRIX DirectX::StereoProjectionFovLH
|
||||
(
|
||||
_In_opt_ const STEREO_PARAMETERS* pStereoParameters,
|
||||
STEREO_CHANNEL Channel,
|
||||
float FovAngleY,
|
||||
float AspectRatio,
|
||||
float NearZ,
|
||||
float FarZ,
|
||||
STEREO_MODE StereoMode
|
||||
)
|
||||
{
|
||||
assert(Channel == STEREO_CHANNEL_LEFT || Channel == STEREO_CHANNEL_RIGHT);
|
||||
assert(StereoMode == STEREO_MODE_NORMAL || StereoMode == STEREO_MODE_INVERTED);
|
||||
assert(!XMScalarNearEqual(FovAngleY, 0.0f, 0.00001f * 2.0f));
|
||||
assert(!XMScalarNearEqual(AspectRatio, 0.0f, 0.00001f));
|
||||
assert(!XMScalarNearEqual(FarZ, NearZ, 0.00001f));
|
||||
|
||||
STEREO_PARAMETERS DefaultParameters = {};
|
||||
if (pStereoParameters == nullptr)
|
||||
{
|
||||
StereoCreateDefaultParameters(DefaultParameters);
|
||||
pStereoParameters = &DefaultParameters;
|
||||
}
|
||||
|
||||
assert(pStereoParameters->fStereoSeparationFactor >= 0.0f && pStereoParameters->fStereoSeparationFactor <= 1.0f);
|
||||
assert(pStereoParameters->fStereoExaggerationFactor >= 1.0f && pStereoParameters->fStereoExaggerationFactor <= 2.0f);
|
||||
|
||||
float fVirtualProjection = 0.0f;
|
||||
float zNearWidth = 0.0f;
|
||||
float zNearHeight = 0.0f;
|
||||
StereoProjectionHelper(*pStereoParameters, &fVirtualProjection, &zNearWidth, &zNearHeight, FovAngleY, AspectRatio, NearZ);
|
||||
|
||||
fVirtualProjection *= pStereoParameters->fStereoSeparationFactor; // incorporate developer defined bias
|
||||
|
||||
//
|
||||
// By applying a translation, we are forcing our cameras to be parallel
|
||||
//
|
||||
|
||||
float fInvertedAngle = atanf(fVirtualProjection / (2.0f * NearZ));
|
||||
|
||||
XMMATRIX proj = XMMatrixPerspectiveFovLH(FovAngleY, AspectRatio, NearZ, FarZ);
|
||||
|
||||
XMMATRIX patchedProjection;
|
||||
if (Channel == STEREO_CHANNEL_LEFT)
|
||||
{
|
||||
if (StereoMode > STEREO_MODE_NORMAL)
|
||||
{
|
||||
XMMATRIX rots = XMMatrixRotationY(fInvertedAngle);
|
||||
XMMATRIX trans = XMMatrixTranslation(-fVirtualProjection, 0, 0);
|
||||
patchedProjection = XMMatrixMultiply(XMMatrixMultiply(rots, trans), proj);
|
||||
}
|
||||
else
|
||||
{
|
||||
XMMATRIX trans = XMMatrixTranslation(-fVirtualProjection, 0, 0);
|
||||
patchedProjection = XMMatrixMultiply(trans, proj);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (StereoMode > STEREO_MODE_NORMAL)
|
||||
{
|
||||
XMMATRIX rots = XMMatrixRotationY(-fInvertedAngle);
|
||||
XMMATRIX trans = XMMatrixTranslation(fVirtualProjection, 0, 0);
|
||||
patchedProjection = XMMatrixMultiply(XMMatrixMultiply(rots, trans), proj);
|
||||
}
|
||||
else
|
||||
{
|
||||
XMMATRIX trans = XMMatrixTranslation(fVirtualProjection, 0, 0);
|
||||
patchedProjection = XMMatrixMultiply(trans, proj);
|
||||
}
|
||||
}
|
||||
|
||||
return patchedProjection;
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
XMMATRIX DirectX::StereoProjectionFovRH
|
||||
(
|
||||
_In_opt_ const STEREO_PARAMETERS* pStereoParameters,
|
||||
STEREO_CHANNEL Channel,
|
||||
float FovAngleY,
|
||||
float AspectRatio,
|
||||
float NearZ,
|
||||
float FarZ,
|
||||
STEREO_MODE StereoMode
|
||||
)
|
||||
{
|
||||
assert(Channel == STEREO_CHANNEL_LEFT || Channel == STEREO_CHANNEL_RIGHT);
|
||||
assert(StereoMode == STEREO_MODE_NORMAL || StereoMode == STEREO_MODE_INVERTED);
|
||||
assert(!XMScalarNearEqual(FovAngleY, 0.0f, 0.00001f * 2.0f));
|
||||
assert(!XMScalarNearEqual(AspectRatio, 0.0f, 0.00001f));
|
||||
assert(!XMScalarNearEqual(FarZ, NearZ, 0.00001f));
|
||||
|
||||
STEREO_PARAMETERS DefaultParameters = {};
|
||||
if (pStereoParameters == nullptr)
|
||||
{
|
||||
StereoCreateDefaultParameters(DefaultParameters);
|
||||
pStereoParameters = &DefaultParameters;
|
||||
}
|
||||
|
||||
assert(pStereoParameters->fStereoSeparationFactor >= 0.0f && pStereoParameters->fStereoSeparationFactor <= 1.0f);
|
||||
assert(pStereoParameters->fStereoExaggerationFactor >= 1.0f && pStereoParameters->fStereoExaggerationFactor <= 2.0f);
|
||||
|
||||
float fVirtualProjection = 0.0f;
|
||||
float zNearWidth = 0.0f;
|
||||
float zNearHeight = 0.0f;
|
||||
StereoProjectionHelper(*pStereoParameters, &fVirtualProjection, &zNearWidth, &zNearHeight, FovAngleY, AspectRatio, NearZ);
|
||||
|
||||
fVirtualProjection *= pStereoParameters->fStereoSeparationFactor; // incorporate developer defined bias
|
||||
|
||||
//
|
||||
// By applying a translation, we are forcing our cameras to be parallel
|
||||
//
|
||||
|
||||
float fInvertedAngle = atanf(fVirtualProjection / (2.0f * NearZ));
|
||||
|
||||
XMMATRIX proj = XMMatrixPerspectiveFovRH(FovAngleY, AspectRatio, NearZ, FarZ);
|
||||
|
||||
//
|
||||
// By applying a translation, we are forcing our cameras to be parallel
|
||||
//
|
||||
|
||||
XMMATRIX patchedProjection;
|
||||
if (Channel == STEREO_CHANNEL_LEFT)
|
||||
{
|
||||
if (StereoMode > STEREO_MODE_NORMAL)
|
||||
{
|
||||
XMMATRIX rots = XMMatrixRotationY(fInvertedAngle);
|
||||
XMMATRIX trans = XMMatrixTranslation(-fVirtualProjection, 0, 0);
|
||||
patchedProjection = XMMatrixMultiply(XMMatrixMultiply(rots, trans), proj);
|
||||
}
|
||||
else
|
||||
{
|
||||
XMMATRIX trans = XMMatrixTranslation(-fVirtualProjection, 0, 0);
|
||||
patchedProjection = XMMatrixMultiply(trans, proj);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (StereoMode > STEREO_MODE_NORMAL)
|
||||
{
|
||||
XMMATRIX rots = XMMatrixRotationY(-fInvertedAngle);
|
||||
XMMATRIX trans = XMMatrixTranslation(fVirtualProjection, 0, 0);
|
||||
patchedProjection = XMMatrixMultiply(XMMatrixMultiply(rots, trans), proj);
|
||||
}
|
||||
else
|
||||
{
|
||||
XMMATRIX trans = XMMatrixTranslation(fVirtualProjection, 0, 0);
|
||||
patchedProjection = XMMatrixMultiply(trans, proj);
|
||||
}
|
||||
}
|
||||
|
||||
return patchedProjection;
|
||||
}
|
64
Sdk/External/DirectXMath/Stereo3D/Stereo3DMatrixHelper.h
vendored
Normal file
64
Sdk/External/DirectXMath/Stereo3D/Stereo3DMatrixHelper.h
vendored
Normal file
@ -0,0 +1,64 @@
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Stereo3DMatrixHelper.h -- SIMD C++ Math helper for Stereo 3D matrices
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "DirectXMath.h"
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
// Enumeration for stereo channels (left and right).
|
||||
enum STEREO_CHANNEL
|
||||
{
|
||||
STEREO_CHANNEL_LEFT = 0,
|
||||
STEREO_CHANNEL_RIGHT
|
||||
};
|
||||
|
||||
// Enumeration for stereo mode (normal or inverted).
|
||||
enum STEREO_MODE
|
||||
{
|
||||
STEREO_MODE_NORMAL = 0,
|
||||
STEREO_MODE_INVERTED,
|
||||
};
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
//
|
||||
// Stereo calibration settings
|
||||
//
|
||||
// * Viewer distance to the display
|
||||
// * Physical display size
|
||||
// * Render resolution
|
||||
//
|
||||
// The stereo separation factor indicates how much separation is between the left and right
|
||||
// eyes. 0 is no separation, 1 is full separation. It defaults to 1.0.
|
||||
//
|
||||
// The debug stereo exaggeration factor indicates how much to increase the interocular spacing and
|
||||
// maximum acuity angle from comfortable defaults. For retail builds, this value should always
|
||||
// be 1.0, but during development, on small screens, this value can be raised to up to 2.0 in
|
||||
// order to exaggerate the 3D effect. Values over 1.0 may cause discomfort on normal sized
|
||||
// displays. It defaults to 1.0.
|
||||
//
|
||||
struct STEREO_PARAMETERS
|
||||
{
|
||||
float fViewerDistanceInches;
|
||||
float fDisplaySizeInches;
|
||||
float fPixelResolutionWidth;
|
||||
float fPixelResolutionHeight;
|
||||
float fStereoSeparationFactor;
|
||||
float fStereoExaggerationFactor;
|
||||
};
|
||||
|
||||
void StereoCreateDefaultParameters(STEREO_PARAMETERS& stereoParameters);
|
||||
|
||||
XMMATRIX StereoProjectionFovLH(_In_opt_ const STEREO_PARAMETERS* pStereoParameters,
|
||||
STEREO_CHANNEL Channel, float FovAngleY, float AspectRatio, float NearZ, float FarZ,
|
||||
STEREO_MODE StereoMode = STEREO_MODE_NORMAL);
|
||||
|
||||
XMMATRIX StereoProjectionFovRH(_In_opt_ const STEREO_PARAMETERS* pStereoParameters,
|
||||
STEREO_CHANNEL Channel, float FovAngleY, float AspectRatio, float NearZ, float FarZ,
|
||||
STEREO_MODE StereoMode = STEREO_MODE_NORMAL);
|
||||
}
|
813
Sdk/External/DirectXMath/XDSP/XDSP.h
vendored
Normal file
813
Sdk/External/DirectXMath/XDSP/XDSP.h
vendored
Normal file
@ -0,0 +1,813 @@
|
||||
//--------------------------------------------------------------------------------------
|
||||
// File: XDSP.h
|
||||
//
|
||||
// DirectXMath based Digital Signal Processing (DSP) functions for audio,
|
||||
// primarily Fast Fourier Transform (FFT)
|
||||
//
|
||||
// All buffer parameters must be 16-byte aligned
|
||||
//
|
||||
// All FFT functions support only single-precision floating-point audio
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615557
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <cassert>
|
||||
#include <DirectXMath.h>
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable: 6001 6262)
|
||||
|
||||
namespace XDSP
|
||||
{
|
||||
using XMVECTOR = DirectX::XMVECTOR;
|
||||
using FXMVECTOR = DirectX::FXMVECTOR;
|
||||
using GXMVECTOR = DirectX::GXMVECTOR;
|
||||
using CXMVECTOR = DirectX::CXMVECTOR;
|
||||
|
||||
inline bool ISPOWEROF2(size_t n) { return ( ((n)&((n)-1)) == 0 && (n) != 0 ); }
|
||||
|
||||
// Parallel multiplication of four complex numbers, assuming real and imaginary values are stored in separate vectors.
|
||||
inline void XM_CALLCONV vmulComplex(
|
||||
_Out_ XMVECTOR& rResult, _Out_ XMVECTOR& iResult,
|
||||
_In_ FXMVECTOR r1, _In_ FXMVECTOR i1, _In_ FXMVECTOR r2, _In_ GXMVECTOR i2) noexcept
|
||||
{
|
||||
using namespace DirectX;
|
||||
// (r1, i1) * (r2, i2) = (r1r2 - i1i2, r1i2 + r2i1)
|
||||
XMVECTOR vr1r2 = XMVectorMultiply(r1, r2);
|
||||
XMVECTOR vr1i2 = XMVectorMultiply(r1, i2);
|
||||
rResult = XMVectorNegativeMultiplySubtract(i1, i2, vr1r2); // real: (r1*r2 - i1*i2)
|
||||
iResult = XMVectorMultiplyAdd(r2, i1, vr1i2); // imaginary: (r1*i2 + r2*i1)
|
||||
}
|
||||
|
||||
inline void XM_CALLCONV vmulComplex(
|
||||
_Inout_ XMVECTOR& r1, _Inout_ XMVECTOR& i1, _In_ FXMVECTOR r2, _In_ FXMVECTOR i2) noexcept
|
||||
{
|
||||
using namespace DirectX;
|
||||
// (r1, i1) * (r2, i2) = (r1r2 - i1i2, r1i2 + r2i1)
|
||||
XMVECTOR vr1r2 = XMVectorMultiply(r1, r2);
|
||||
XMVECTOR vr1i2 = XMVectorMultiply(r1, i2);
|
||||
r1 = XMVectorNegativeMultiplySubtract(i1, i2, vr1r2); // real: (r1*r2 - i1*i2)
|
||||
i1 = XMVectorMultiplyAdd(r2, i1, vr1i2); // imaginary: (r1*i2 + r2*i1)
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
// Radix-4 decimation-in-time FFT butterfly.
|
||||
// This version assumes that all four elements of the butterfly are
|
||||
// adjacent in a single vector.
|
||||
//
|
||||
// Compute the product of the complex input vector and the
|
||||
// 4-element DFT matrix:
|
||||
// | 1 1 1 1 | | (r1X,i1X) |
|
||||
// | 1 -j -1 j | | (r1Y,i1Y) |
|
||||
// | 1 -1 1 -1 | | (r1Z,i1Z) |
|
||||
// | 1 j -1 -j | | (r1W,i1W) |
|
||||
//
|
||||
// This matrix can be decomposed into two simpler ones to reduce the
|
||||
// number of additions needed. The decomposed matrices look like this:
|
||||
// | 1 0 1 0 | | 1 0 1 0 |
|
||||
// | 0 1 0 -j | | 1 0 -1 0 |
|
||||
// | 1 0 -1 0 | | 0 1 0 1 |
|
||||
// | 0 1 0 j | | 0 1 0 -1 |
|
||||
//
|
||||
// Combine as follows:
|
||||
// | 1 0 1 0 | | (r1X,i1X) | | (r1X + r1Z, i1X + i1Z) |
|
||||
// Temp = | 1 0 -1 0 | * | (r1Y,i1Y) | = | (r1X - r1Z, i1X - i1Z) |
|
||||
// | 0 1 0 1 | | (r1Z,i1Z) | | (r1Y + r1W, i1Y + i1W) |
|
||||
// | 0 1 0 -1 | | (r1W,i1W) | | (r1Y - r1W, i1Y - i1W) |
|
||||
//
|
||||
// | 1 0 1 0 | | (rTempX,iTempX) | | (rTempX + rTempZ, iTempX + iTempZ) |
|
||||
// Result = | 0 1 0 -j | * | (rTempY,iTempY) | = | (rTempY + iTempW, iTempY - rTempW) |
|
||||
// | 1 0 -1 0 | | (rTempZ,iTempZ) | | (rTempX - rTempZ, iTempX - iTempZ) |
|
||||
// | 0 1 0 j | | (rTempW,iTempW) | | (rTempY - iTempW, iTempY + rTempW) |
|
||||
//----------------------------------------------------------------------------------
|
||||
inline void ButterflyDIT4_1 (_Inout_ XMVECTOR& r1, _Inout_ XMVECTOR& i1) noexcept
|
||||
{
|
||||
using namespace DirectX;
|
||||
|
||||
// sign constants for radix-4 butterflies
|
||||
static const XMVECTORF32 vDFT4SignBits1 = { { { 1.0f, -1.0f, 1.0f, -1.0f } } };
|
||||
static const XMVECTORF32 vDFT4SignBits2 = { { { 1.0f, 1.0f, -1.0f, -1.0f } } };
|
||||
static const XMVECTORF32 vDFT4SignBits3 = { { { 1.0f, -1.0f, -1.0f, 1.0f } } };
|
||||
|
||||
// calculating Temp
|
||||
// [r1X| r1X|r1Y| r1Y] + [r1Z|-r1Z|r1W|-r1W]
|
||||
// [i1X| i1X|i1Y| i1Y] + [i1Z|-i1Z|i1W|-i1W]
|
||||
XMVECTOR r1L = XMVectorSwizzle<0,0,1,1>( r1 );
|
||||
XMVECTOR r1H = XMVectorSwizzle<2,2,3,3>( r1 );
|
||||
|
||||
XMVECTOR i1L = XMVectorSwizzle<0,0,1,1>( i1 );
|
||||
XMVECTOR i1H = XMVectorSwizzle<2,2,3,3>( i1 );
|
||||
|
||||
XMVECTOR rTemp = XMVectorMultiplyAdd( r1H, vDFT4SignBits1, r1L );
|
||||
XMVECTOR iTemp = XMVectorMultiplyAdd( i1H, vDFT4SignBits1, i1L );
|
||||
|
||||
// calculating Result
|
||||
XMVECTOR rZrWiZiW = XMVectorPermute<2,3,6,7>(rTemp,iTemp); // [rTempZ|rTempW|iTempZ|iTempW]
|
||||
XMVECTOR rZiWrZiW = XMVectorSwizzle<0,3,0,3>(rZrWiZiW); // [rTempZ|iTempW|rTempZ|iTempW]
|
||||
XMVECTOR iZrWiZrW = XMVectorSwizzle<2,1,2,1>(rZrWiZiW); // [rTempZ|iTempW|rTempZ|iTempW]
|
||||
|
||||
// [rTempX| rTempY| rTempX| rTempY] + [rTempZ| iTempW|-rTempZ|-iTempW]
|
||||
// [iTempX| iTempY| iTempX| iTempY] + // [iTempZ|-rTempW|-iTempZ| rTempW]
|
||||
XMVECTOR rTempL = XMVectorSwizzle<0,1,0,1>(rTemp);
|
||||
XMVECTOR iTempL = XMVectorSwizzle<0,1,0,1>(iTemp);
|
||||
|
||||
r1 = XMVectorMultiplyAdd( rZiWrZiW, vDFT4SignBits2, rTempL );
|
||||
i1 = XMVectorMultiplyAdd( iZrWiZrW, vDFT4SignBits3, iTempL );
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
// Radix-4 decimation-in-time FFT butterfly.
|
||||
// This version assumes that elements of the butterfly are
|
||||
// in different vectors, so that each vector in the input
|
||||
// contains elements from four different butterflies.
|
||||
// The four separate butterflies are processed in parallel.
|
||||
//
|
||||
// The calculations here are the same as the ones in the single-vector
|
||||
// radix-4 DFT, but instead of being done on a single vector (X,Y,Z,W)
|
||||
// they are done in parallel on sixteen independent complex values.
|
||||
// There is no interdependence between the vector elements:
|
||||
// | 1 0 1 0 | | (rIn0,iIn0) | | (rIn0 + rIn2, iIn0 + iIn2) |
|
||||
// | 1 0 -1 0 | * | (rIn1,iIn1) | = Temp = | (rIn0 - rIn2, iIn0 - iIn2) |
|
||||
// | 0 1 0 1 | | (rIn2,iIn2) | | (rIn1 + rIn3, iIn1 + iIn3) |
|
||||
// | 0 1 0 -1 | | (rIn3,iIn3) | | (rIn1 - rIn3, iIn1 - iIn3) |
|
||||
//
|
||||
// | 1 0 1 0 | | (rTemp0,iTemp0) | | (rTemp0 + rTemp2, iTemp0 + iTemp2) |
|
||||
// Result = | 0 1 0 -j | * | (rTemp1,iTemp1) | = | (rTemp1 + iTemp3, iTemp1 - rTemp3) |
|
||||
// | 1 0 -1 0 | | (rTemp2,iTemp2) | | (rTemp0 - rTemp2, iTemp0 - iTemp2) |
|
||||
// | 0 1 0 j | | (rTemp3,iTemp3) | | (rTemp1 - iTemp3, iTemp1 + rTemp3) |
|
||||
//----------------------------------------------------------------------------------
|
||||
inline void ButterflyDIT4_4(
|
||||
_Inout_ XMVECTOR& r0,
|
||||
_Inout_ XMVECTOR& r1,
|
||||
_Inout_ XMVECTOR& r2,
|
||||
_Inout_ XMVECTOR& r3,
|
||||
_Inout_ XMVECTOR& i0,
|
||||
_Inout_ XMVECTOR& i1,
|
||||
_Inout_ XMVECTOR& i2,
|
||||
_Inout_ XMVECTOR& i3,
|
||||
_In_reads_(uStride * 4) const XMVECTOR* __restrict pUnityTableReal,
|
||||
_In_reads_(uStride * 4) const XMVECTOR* __restrict pUnityTableImaginary,
|
||||
_In_ size_t uStride,
|
||||
_In_ const bool fLast) noexcept
|
||||
{
|
||||
using namespace DirectX;
|
||||
|
||||
assert(pUnityTableReal);
|
||||
assert(pUnityTableImaginary);
|
||||
assert(reinterpret_cast<uintptr_t>(pUnityTableReal) % 16 == 0);
|
||||
assert(reinterpret_cast<uintptr_t>(pUnityTableImaginary) % 16 == 0);
|
||||
assert(ISPOWEROF2(uStride));
|
||||
|
||||
// calculating Temp
|
||||
XMVECTOR rTemp0 = XMVectorAdd(r0, r2);
|
||||
XMVECTOR iTemp0 = XMVectorAdd(i0, i2);
|
||||
|
||||
XMVECTOR rTemp2 = XMVectorAdd(r1, r3);
|
||||
XMVECTOR iTemp2 = XMVectorAdd(i1, i3);
|
||||
|
||||
XMVECTOR rTemp1 = XMVectorSubtract(r0, r2);
|
||||
XMVECTOR iTemp1 = XMVectorSubtract(i0, i2);
|
||||
|
||||
XMVECTOR rTemp3 = XMVectorSubtract(r1, r3);
|
||||
XMVECTOR iTemp3 = XMVectorSubtract(i1, i3);
|
||||
|
||||
XMVECTOR rTemp4 = XMVectorAdd(rTemp0, rTemp2);
|
||||
XMVECTOR iTemp4 = XMVectorAdd(iTemp0, iTemp2);
|
||||
|
||||
XMVECTOR rTemp5 = XMVectorAdd(rTemp1, iTemp3);
|
||||
XMVECTOR iTemp5 = XMVectorSubtract(iTemp1, rTemp3);
|
||||
|
||||
XMVECTOR rTemp6 = XMVectorSubtract(rTemp0, rTemp2);
|
||||
XMVECTOR iTemp6 = XMVectorSubtract(iTemp0, iTemp2);
|
||||
|
||||
XMVECTOR rTemp7 = XMVectorSubtract(rTemp1, iTemp3);
|
||||
XMVECTOR iTemp7 = XMVectorAdd(iTemp1, rTemp3);
|
||||
|
||||
// calculating Result
|
||||
// vmulComplex(rTemp0, iTemp0, rTemp0, iTemp0, pUnityTableReal[0], pUnityTableImaginary[0]); // first one is always trivial
|
||||
vmulComplex(rTemp5, iTemp5, pUnityTableReal[uStride], pUnityTableImaginary[uStride]);
|
||||
vmulComplex(rTemp6, iTemp6, pUnityTableReal[uStride * 2], pUnityTableImaginary[uStride * 2]);
|
||||
vmulComplex(rTemp7, iTemp7, pUnityTableReal[uStride * 3], pUnityTableImaginary[uStride * 3]);
|
||||
|
||||
if (fLast)
|
||||
{
|
||||
ButterflyDIT4_1(rTemp4, iTemp4);
|
||||
ButterflyDIT4_1(rTemp5, iTemp5);
|
||||
ButterflyDIT4_1(rTemp6, iTemp6);
|
||||
ButterflyDIT4_1(rTemp7, iTemp7);
|
||||
}
|
||||
|
||||
r0 = rTemp4; i0 = iTemp4;
|
||||
r1 = rTemp5; i1 = iTemp5;
|
||||
r2 = rTemp6; i2 = iTemp6;
|
||||
r3 = rTemp7; i3 = iTemp7;
|
||||
}
|
||||
|
||||
//==================================================================================
|
||||
// F-U-N-C-T-I-O-N-S
|
||||
//==================================================================================
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
// DESCRIPTION:
|
||||
// 4-sample FFT.
|
||||
//
|
||||
// PARAMETERS:
|
||||
// pReal - [inout] real components, must have at least uCount elements
|
||||
// pImaginary - [inout] imaginary components, must have at least uCount elements
|
||||
// uCount - [in] number of FFT iterations
|
||||
//----------------------------------------------------------------------------------
|
||||
inline void FFT4(
|
||||
_Inout_updates_(uCount) XMVECTOR* __restrict pReal,
|
||||
_Inout_updates_(uCount) XMVECTOR* __restrict pImaginary,
|
||||
const size_t uCount = 1) noexcept
|
||||
{
|
||||
assert(pReal);
|
||||
assert(pImaginary);
|
||||
assert(reinterpret_cast<uintptr_t>(pReal) % 16 == 0);
|
||||
assert(reinterpret_cast<uintptr_t>(pImaginary) % 16 == 0);
|
||||
assert(ISPOWEROF2(uCount));
|
||||
|
||||
for (size_t uIndex = 0; uIndex < uCount; ++uIndex)
|
||||
{
|
||||
ButterflyDIT4_1(pReal[uIndex], pImaginary[uIndex]);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
// DESCRIPTION:
|
||||
// 8-sample FFT.
|
||||
//
|
||||
// PARAMETERS:
|
||||
// pReal - [inout] real components, must have at least uCount*2 elements
|
||||
// pImaginary - [inout] imaginary components, must have at least uCount*2 elements
|
||||
// uCount - [in] number of FFT iterations
|
||||
//----------------------------------------------------------------------------------
|
||||
inline void FFT8(
|
||||
_Inout_updates_(uCount * 2) XMVECTOR* __restrict pReal,
|
||||
_Inout_updates_(uCount * 2) XMVECTOR* __restrict pImaginary,
|
||||
_In_ const size_t uCount = 1) noexcept
|
||||
{
|
||||
using namespace DirectX;
|
||||
|
||||
assert(pReal);
|
||||
assert(pImaginary);
|
||||
assert(reinterpret_cast<uintptr_t>(pReal) % 16 == 0);
|
||||
assert(reinterpret_cast<uintptr_t>(pImaginary) % 16 == 0);
|
||||
assert(ISPOWEROF2(uCount));
|
||||
|
||||
static const XMVECTORF32 wr1 = { { { 1.0f, 0.70710677f, 0.0f, -0.70710677f } } };
|
||||
static const XMVECTORF32 wi1 = { { { 0.0f, -0.70710677f, -1.0f, -0.70710677f } } };
|
||||
static const XMVECTORF32 wr2 = { { { -1.0f, -0.70710677f, 0.0f, 0.70710677f } } };
|
||||
static const XMVECTORF32 wi2 = { { { 0.0f, 0.70710677f, 1.0f, 0.70710677f } } };
|
||||
|
||||
for (size_t uIndex = 0; uIndex < uCount; ++uIndex)
|
||||
{
|
||||
XMVECTOR* __restrict pR = pReal + uIndex * 2;
|
||||
XMVECTOR* __restrict pI = pImaginary + uIndex * 2;
|
||||
|
||||
XMVECTOR oddsR = XMVectorPermute<1, 3, 5, 7>(pR[0], pR[1]);
|
||||
XMVECTOR evensR = XMVectorPermute<0, 2, 4, 6>(pR[0], pR[1]);
|
||||
XMVECTOR oddsI = XMVectorPermute<1, 3, 5, 7>(pI[0], pI[1]);
|
||||
XMVECTOR evensI = XMVectorPermute<0, 2, 4, 6>(pI[0], pI[1]);
|
||||
ButterflyDIT4_1(oddsR, oddsI);
|
||||
ButterflyDIT4_1(evensR, evensI);
|
||||
|
||||
XMVECTOR r, i;
|
||||
vmulComplex(r, i, oddsR, oddsI, wr1, wi1);
|
||||
pR[0] = XMVectorAdd(evensR, r);
|
||||
pI[0] = XMVectorAdd(evensI, i);
|
||||
|
||||
vmulComplex(r, i, oddsR, oddsI, wr2, wi2);
|
||||
pR[1] = XMVectorAdd(evensR, r);
|
||||
pI[1] = XMVectorAdd(evensI, i);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
// DESCRIPTION:
|
||||
// 16-sample FFT.
|
||||
//
|
||||
// PARAMETERS:
|
||||
// pReal - [inout] real components, must have at least uCount*4 elements
|
||||
// pImaginary - [inout] imaginary components, must have at least uCount*4 elements
|
||||
// uCount - [in] number of FFT iterations
|
||||
//----------------------------------------------------------------------------------
|
||||
inline void FFT16(
|
||||
_Inout_updates_(uCount * 4) XMVECTOR* __restrict pReal,
|
||||
_Inout_updates_(uCount * 4) XMVECTOR* __restrict pImaginary,
|
||||
_In_ const size_t uCount = 1) noexcept
|
||||
{
|
||||
using namespace DirectX;
|
||||
|
||||
assert(pReal);
|
||||
assert(pImaginary);
|
||||
assert(reinterpret_cast<uintptr_t>(pReal) % 16 == 0);
|
||||
assert(reinterpret_cast<uintptr_t>(pImaginary) % 16 == 0);
|
||||
assert(ISPOWEROF2(uCount));
|
||||
|
||||
static const XMVECTORF32 aUnityTableReal[4] = {
|
||||
{ { { 1.0f, 1.0f, 1.0f, 1.0f } } },
|
||||
{ { { 1.0f, 0.92387950f, 0.70710677f, 0.38268343f } } },
|
||||
{ { { 1.0f, 0.70710677f, -4.3711388e-008f, -0.70710677f } } },
|
||||
{ { { 1.0f, 0.38268343f, -0.70710677f, -0.92387950f } } }
|
||||
};
|
||||
static const XMVECTORF32 aUnityTableImaginary[4] =
|
||||
{
|
||||
{ { { -0.0f, -0.0f, -0.0f, -0.0f } } },
|
||||
{ { { -0.0f, -0.38268343f, -0.70710677f, -0.92387950f } } },
|
||||
{ { { -0.0f, -0.70710677f, -1.0f, -0.70710677f } } },
|
||||
{ { { -0.0f, -0.92387950f, -0.70710677f, 0.38268343f } } }
|
||||
};
|
||||
|
||||
for (size_t uIndex = 0; uIndex < uCount; ++uIndex)
|
||||
{
|
||||
ButterflyDIT4_4(pReal[uIndex * 4],
|
||||
pReal[uIndex * 4 + 1],
|
||||
pReal[uIndex * 4 + 2],
|
||||
pReal[uIndex * 4 + 3],
|
||||
pImaginary[uIndex * 4],
|
||||
pImaginary[uIndex * 4 + 1],
|
||||
pImaginary[uIndex * 4 + 2],
|
||||
pImaginary[uIndex * 4 + 3],
|
||||
reinterpret_cast<const XMVECTOR*>(aUnityTableReal),
|
||||
reinterpret_cast<const XMVECTOR*>(aUnityTableImaginary),
|
||||
1, true);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
// DESCRIPTION:
|
||||
// 2^N-sample FFT.
|
||||
//
|
||||
// REMARKS:
|
||||
// For FFTs length 16 and below, call FFT16(), FFT8(), or FFT4().
|
||||
//
|
||||
// PARAMETERS:
|
||||
// pReal - [inout] real components, must have at least (uLength*uCount)/4 elements
|
||||
// pImaginary - [inout] imaginary components, must have at least (uLength*uCount)/4 elements
|
||||
// pUnityTable - [in] unity table, must have at least uLength*uCount elements, see FFTInitializeUnityTable()
|
||||
// uLength - [in] FFT length in samples, must be a power of 2 > 16
|
||||
// uCount - [in] number of FFT iterations
|
||||
//----------------------------------------------------------------------------------
|
||||
inline void FFT (
|
||||
_Inout_updates_((uLength*uCount)/4) XMVECTOR* __restrict pReal,
|
||||
_Inout_updates_((uLength*uCount)/4) XMVECTOR* __restrict pImaginary,
|
||||
_In_reads_(uLength*uCount) const XMVECTOR* __restrict pUnityTable,
|
||||
_In_ const size_t uLength,
|
||||
_In_ const size_t uCount=1) noexcept
|
||||
{
|
||||
assert(pReal);
|
||||
assert(pImaginary);
|
||||
assert(pUnityTable);
|
||||
assert(reinterpret_cast<uintptr_t>(pReal) % 16 == 0);
|
||||
assert(reinterpret_cast<uintptr_t>(pImaginary) % 16 == 0);
|
||||
assert(reinterpret_cast<uintptr_t>(pUnityTable) % 16 == 0);
|
||||
assert(uLength > 16);
|
||||
_Analysis_assume_(uLength > 16);
|
||||
assert(ISPOWEROF2(uLength));
|
||||
assert(ISPOWEROF2(uCount));
|
||||
|
||||
const XMVECTOR* __restrict pUnityTableReal = pUnityTable;
|
||||
const XMVECTOR* __restrict pUnityTableImaginary = pUnityTable + (uLength>>2);
|
||||
const size_t uTotal = uCount * uLength;
|
||||
const size_t uTotal_vectors = uTotal >> 2;
|
||||
const size_t uStage_vectors = uLength >> 2;
|
||||
const size_t uStage_vectors_mask = uStage_vectors - 1;
|
||||
const size_t uStride = uLength >> 4; // stride between butterfly elements
|
||||
const size_t uStrideMask = uStride - 1;
|
||||
const size_t uStride2 = uStride * 2;
|
||||
const size_t uStride3 = uStride * 3;
|
||||
const size_t uStrideInvMask = ~uStrideMask;
|
||||
|
||||
for (size_t uIndex=0; uIndex < (uTotal_vectors>>2); ++uIndex)
|
||||
{
|
||||
const size_t n = ((uIndex & uStrideInvMask) << 2) + (uIndex & uStrideMask);
|
||||
ButterflyDIT4_4(pReal[n],
|
||||
pReal[n + uStride],
|
||||
pReal[n + uStride2],
|
||||
pReal[n + uStride3],
|
||||
pImaginary[n ],
|
||||
pImaginary[n + uStride],
|
||||
pImaginary[n + uStride2],
|
||||
pImaginary[n + uStride3],
|
||||
pUnityTableReal + (n & uStage_vectors_mask),
|
||||
pUnityTableImaginary + (n & uStage_vectors_mask),
|
||||
uStride, false);
|
||||
}
|
||||
|
||||
if (uLength > 16*4)
|
||||
{
|
||||
FFT(pReal, pImaginary, pUnityTable+(uLength>>1), uLength>>2, uCount*4);
|
||||
}
|
||||
else if (uLength == 16*4)
|
||||
{
|
||||
FFT16(pReal, pImaginary, uCount*4);
|
||||
}
|
||||
else if (uLength == 8*4)
|
||||
{
|
||||
FFT8(pReal, pImaginary, uCount*4);
|
||||
}
|
||||
else if (uLength == 4*4)
|
||||
{
|
||||
FFT4(pReal, pImaginary, uCount*4);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
// DESCRIPTION:
|
||||
// Initializes unity roots lookup table used by FFT functions.
|
||||
// Once initialized, the table need not be initialized again unless a
|
||||
// different FFT length is desired.
|
||||
//
|
||||
// REMARKS:
|
||||
// The unity tables of FFT length 16 and below are hard coded into the
|
||||
// respective FFT functions and so need not be initialized.
|
||||
//
|
||||
// PARAMETERS:
|
||||
// pUnityTable - [out] unity table, receives unity roots lookup table, must have at least uLength elements
|
||||
// uLength - [in] FFT length in frames, must be a power of 2 > 16
|
||||
//----------------------------------------------------------------------------------
|
||||
inline void FFTInitializeUnityTable (_Out_writes_(uLength) XMVECTOR* __restrict pUnityTable, _In_ size_t uLength) noexcept
|
||||
{
|
||||
assert(pUnityTable);
|
||||
assert(uLength > 16);
|
||||
_Analysis_assume_(uLength > 16);
|
||||
assert(ISPOWEROF2(uLength));
|
||||
|
||||
float* __restrict pfUnityTable = reinterpret_cast<float* __restrict>(pUnityTable);
|
||||
|
||||
// initialize unity table for recursive FFT lengths: uLength, uLength/4, uLength/16... > 16
|
||||
do
|
||||
{
|
||||
float flStep = 6.283185307f / float(uLength); // 2PI / FFT length
|
||||
uLength >>= 2;
|
||||
|
||||
// pUnityTable[0 to uLength*4-1] contains real components for current FFT length
|
||||
// pUnityTable[uLength*4 to uLength*8-1] contains imaginary components for current FFT length
|
||||
for (size_t i=0; i<4; ++i)
|
||||
{
|
||||
for (size_t j=0; j<uLength; ++j)
|
||||
{
|
||||
size_t uIndex = (i*uLength) + j;
|
||||
pfUnityTable[uIndex] = cosf(float(i)*float(j)*flStep); // real component
|
||||
#pragma warning(suppress: 6386)
|
||||
pfUnityTable[uIndex + uLength*4] = -sinf(float(i)*float(j)*flStep); // imaginary component
|
||||
}
|
||||
}
|
||||
pfUnityTable += uLength*8;
|
||||
}
|
||||
while (uLength > 16);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
// DESCRIPTION:
|
||||
// The FFT functions generate output in bit reversed order.
|
||||
// Use this function to re-arrange them into order of increasing frequency.
|
||||
//
|
||||
// REMARKS:
|
||||
//
|
||||
// PARAMETERS:
|
||||
// pOutput - [out] output buffer, receives samples in order of increasing frequency, cannot overlap pInput, must have at least (1<<uLog2Length)/4 elements
|
||||
// pInput - [in] input buffer, samples in bit reversed order as generated by FFT functions, cannot overlap pOutput, must have at least (1<<uLog2Length)/4 elements
|
||||
// uLog2Length - [in] LOG (base 2) of FFT length in samples, must be >= 2
|
||||
//----------------------------------------------------------------------------------
|
||||
inline void FFTUnswizzle (
|
||||
_Out_writes_((1<<uLog2Length)/4) XMVECTOR* __restrict pOutput,
|
||||
_In_reads_((1<<uLog2Length)/4) const XMVECTOR* __restrict pInput,
|
||||
_In_ const size_t uLog2Length) noexcept
|
||||
{
|
||||
assert(pOutput);
|
||||
assert(pInput);
|
||||
assert(uLog2Length >= 2);
|
||||
_Analysis_assume_(uLog2Length >= 2);
|
||||
|
||||
float* __restrict pfOutput = reinterpret_cast<float*>(pOutput);
|
||||
const float* __restrict pfInput = reinterpret_cast<const float*>(pInput);
|
||||
const size_t uLength = size_t(1) << uLog2Length;
|
||||
|
||||
if ((uLog2Length & 0x1) == 0)
|
||||
{
|
||||
// even powers of two
|
||||
for (size_t uIndex=0; uIndex < uLength; ++uIndex)
|
||||
{
|
||||
size_t n = uIndex;
|
||||
n = ( (n & 0xcccccccc) >> 2 ) | ( (n & 0x33333333) << 2 );
|
||||
n = ( (n & 0xf0f0f0f0) >> 4 ) | ( (n & 0x0f0f0f0f) << 4 );
|
||||
n = ( (n & 0xff00ff00) >> 8 ) | ( (n & 0x00ff00ff) << 8 );
|
||||
n = ( (n & 0xffff0000) >> 16 ) | ( (n & 0x0000ffff) << 16 );
|
||||
n >>= (32 - uLog2Length);
|
||||
pfOutput[n] = pfInput[uIndex];
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// odd powers of two
|
||||
for (size_t uIndex=0; uIndex < uLength; ++uIndex)
|
||||
{
|
||||
size_t n = (uIndex>>3);
|
||||
n = ( (n & 0xcccccccc) >> 2 ) | ( (n & 0x33333333) << 2 );
|
||||
n = ( (n & 0xf0f0f0f0) >> 4 ) | ( (n & 0x0f0f0f0f) << 4 );
|
||||
n = ( (n & 0xff00ff00) >> 8 ) | ( (n & 0x00ff00ff) << 8 );
|
||||
n = ( (n & 0xffff0000) >> 16 ) | ( (n & 0x0000ffff) << 16 );
|
||||
n >>= (32 - (uLog2Length-3));
|
||||
n |= ((uIndex & 0x7) << (uLog2Length - 3));
|
||||
pfOutput[n] = pfInput[uIndex];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
// DESCRIPTION:
|
||||
// Convert complex components to polar form.
|
||||
//
|
||||
// PARAMETERS:
|
||||
// pOutput - [out] output buffer, receives samples in polar form, must have at least uLength/4 elements
|
||||
// pInputReal - [in] input buffer (real components), must have at least uLength/4 elements
|
||||
// pInputImaginary - [in] input buffer (imaginary components), must have at least uLength/4 elements
|
||||
// uLength - [in] FFT length in samples, must be a power of 2 >= 4
|
||||
//----------------------------------------------------------------------------------
|
||||
#pragma warning(suppress: 6101)
|
||||
inline void FFTPolar(
|
||||
_Out_writes_(uLength/4) XMVECTOR* __restrict pOutput,
|
||||
_In_reads_(uLength/4) const XMVECTOR* __restrict pInputReal,
|
||||
_In_reads_(uLength/4) const XMVECTOR* __restrict pInputImaginary,
|
||||
_In_ const size_t uLength) noexcept
|
||||
{
|
||||
using namespace DirectX;
|
||||
|
||||
assert(pOutput);
|
||||
assert(pInputReal);
|
||||
assert(pInputImaginary);
|
||||
assert(uLength >= 4);
|
||||
_Analysis_assume_(uLength >= 4);
|
||||
assert(ISPOWEROF2(uLength));
|
||||
|
||||
float flOneOverLength = 1.0f / float(uLength);
|
||||
|
||||
// result = sqrtf((real/uLength)^2 + (imaginary/uLength)^2) * 2
|
||||
XMVECTOR vOneOverLength = XMVectorReplicate( flOneOverLength );
|
||||
|
||||
for (size_t uIndex=0; uIndex < (uLength>>2); ++uIndex)
|
||||
{
|
||||
XMVECTOR vReal = XMVectorMultiply(pInputReal[uIndex], vOneOverLength);
|
||||
XMVECTOR vImaginary = XMVectorMultiply(pInputImaginary[uIndex], vOneOverLength);
|
||||
XMVECTOR vRR = XMVectorMultiply(vReal, vReal);
|
||||
XMVECTOR vII = XMVectorMultiply(vImaginary, vImaginary);
|
||||
XMVECTOR vRRplusII = XMVectorAdd(vRR, vII);
|
||||
XMVECTOR vTotal = XMVectorSqrt(vRRplusII);
|
||||
pOutput[uIndex] = XMVectorAdd(vTotal, vTotal);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
// DESCRIPTION:
|
||||
// Deinterleaves audio samples
|
||||
//
|
||||
// REMARKS:
|
||||
// For example, audio of the form [LRLRLR] becomes [LLLRRR].
|
||||
//
|
||||
// PARAMETERS:
|
||||
// pOutput - [out] output buffer, receives samples in deinterleaved form, cannot overlap pInput, must have at least (uChannelCount*uFrameCount)/4 elements
|
||||
// pInput - [in] input buffer, cannot overlap pOutput, must have at least (uChannelCount*uFrameCount)/4 elements
|
||||
// uChannelCount - [in] number of channels, must be > 1
|
||||
// uFrameCount - [in] number of frames of valid data, must be > 0
|
||||
//----------------------------------------------------------------------------------
|
||||
inline void Deinterleave (
|
||||
_Out_writes_((uChannelCount*uFrameCount)/4) XMVECTOR* __restrict pOutput,
|
||||
_In_reads_((uChannelCount*uFrameCount)/4) const XMVECTOR* __restrict pInput,
|
||||
_In_ const size_t uChannelCount,
|
||||
_In_ const size_t uFrameCount) noexcept
|
||||
{
|
||||
assert(pOutput);
|
||||
assert(pInput);
|
||||
assert(uChannelCount > 1);
|
||||
assert(uFrameCount > 0);
|
||||
|
||||
float* __restrict pfOutput = reinterpret_cast<float* __restrict>(pOutput);
|
||||
const float* __restrict pfInput = reinterpret_cast<const float* __restrict>(pInput);
|
||||
|
||||
for (size_t uChannel=0; uChannel < uChannelCount; ++uChannel)
|
||||
{
|
||||
for (size_t uFrame=0; uFrame < uFrameCount; ++uFrame)
|
||||
{
|
||||
pfOutput[uChannel * uFrameCount + uFrame] = pfInput[uFrame * uChannelCount + uChannel];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
// DESCRIPTION:
|
||||
// Interleaves audio samples
|
||||
//
|
||||
// REMARKS:
|
||||
// For example, audio of the form [LLLRRR] becomes [LRLRLR].
|
||||
//
|
||||
// PARAMETERS:
|
||||
// pOutput - [out] output buffer, receives samples in interleaved form, cannot overlap pInput, must have at least (uChannelCount*uFrameCount)/4 elements
|
||||
// pInput - [in] input buffer, cannot overlap pOutput, must have at least (uChannelCount*uFrameCount)/4 elements
|
||||
// uChannelCount - [in] number of channels, must be > 1
|
||||
// uFrameCount - [in] number of frames of valid data, must be > 0
|
||||
//----------------------------------------------------------------------------------
|
||||
inline void Interleave(
|
||||
_Out_writes_((uChannelCount*uFrameCount)/4) XMVECTOR* __restrict pOutput,
|
||||
_In_reads_((uChannelCount*uFrameCount)/4) const XMVECTOR* __restrict pInput,
|
||||
_In_ const size_t uChannelCount,
|
||||
_In_ const size_t uFrameCount) noexcept
|
||||
{
|
||||
assert(pOutput);
|
||||
assert(pInput);
|
||||
assert(uChannelCount > 1);
|
||||
assert(uFrameCount > 0);
|
||||
|
||||
float* __restrict pfOutput = reinterpret_cast<float* __restrict>(pOutput);
|
||||
const float* __restrict pfInput = reinterpret_cast<const float* __restrict>(pInput);
|
||||
|
||||
for (size_t uChannel=0; uChannel < uChannelCount; ++uChannel)
|
||||
{
|
||||
for (size_t uFrame=0; uFrame < uFrameCount; ++uFrame)
|
||||
{
|
||||
pfOutput[uFrame * uChannelCount + uChannel] = pfInput[uChannel * uFrameCount + uFrame];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
// DESCRIPTION:
|
||||
// This function applies a 2^N-sample FFT and unswizzles the result such
|
||||
// that the samples are in order of increasing frequency.
|
||||
// Audio is first deinterleaved if multichannel.
|
||||
//
|
||||
// PARAMETERS:
|
||||
// pReal - [inout] real components, must have at least (1<<uLog2Length*uChannelCount)/4 elements
|
||||
// pImaginary - [out] imaginary components, must have at least (1<<uLog2Length*uChannelCount)/4 elements
|
||||
// pUnityTable - [in] unity table, must have at least (1<<uLog2Length) elements, see FFTInitializeUnityTable()
|
||||
// uChannelCount - [in] number of channels, must be within [1, 6]
|
||||
// uLog2Length - [in] LOG (base 2) of FFT length in frames, must within [2, 9]
|
||||
//----------------------------------------------------------------------------------
|
||||
inline void FFTInterleaved(
|
||||
_Inout_updates_(((1<<uLog2Length)*uChannelCount)/4) XMVECTOR* __restrict pReal,
|
||||
_Out_writes_(((1<<uLog2Length)*uChannelCount)/4) XMVECTOR* __restrict pImaginary,
|
||||
_In_reads_(1<<uLog2Length) const XMVECTOR* __restrict pUnityTable,
|
||||
_In_ const size_t uChannelCount,
|
||||
_In_ const size_t uLog2Length) noexcept
|
||||
{
|
||||
assert(pReal);
|
||||
assert(pImaginary);
|
||||
assert(pUnityTable);
|
||||
assert(reinterpret_cast<uintptr_t>(pReal) % 16 == 0);
|
||||
assert(reinterpret_cast<uintptr_t>(pImaginary) % 16 == 0);
|
||||
assert(reinterpret_cast<uintptr_t>(pUnityTable) % 16 == 0);
|
||||
assert(uChannelCount > 0 && uChannelCount <= 6);
|
||||
assert(uLog2Length >= 2 && uLog2Length <= 9);
|
||||
|
||||
XMVECTOR vRealTemp[768];
|
||||
XMVECTOR vImaginaryTemp[768];
|
||||
const size_t uLength = size_t(1) << uLog2Length;
|
||||
|
||||
if (uChannelCount > 1)
|
||||
{
|
||||
Deinterleave(vRealTemp, pReal, uChannelCount, uLength);
|
||||
}
|
||||
else
|
||||
{
|
||||
memcpy_s(vRealTemp, sizeof(vRealTemp), pReal, (uLength>>2)*sizeof(XMVECTOR));
|
||||
}
|
||||
|
||||
memset( vImaginaryTemp, 0, (uChannelCount*(uLength>>2)) * sizeof(XMVECTOR) );
|
||||
|
||||
if (uLength > 16)
|
||||
{
|
||||
for (size_t uChannel=0; uChannel < uChannelCount; ++uChannel)
|
||||
{
|
||||
FFT(&vRealTemp[uChannel*(uLength>>2)], &vImaginaryTemp[uChannel*(uLength>>2)], pUnityTable, uLength);
|
||||
}
|
||||
}
|
||||
else if (uLength == 16)
|
||||
{
|
||||
for (size_t uChannel=0; uChannel < uChannelCount; ++uChannel)
|
||||
{
|
||||
FFT16(&vRealTemp[uChannel*(uLength>>2)], &vImaginaryTemp[uChannel*(uLength>>2)]);
|
||||
}
|
||||
}
|
||||
else if (uLength == 8)
|
||||
{
|
||||
for (size_t uChannel=0; uChannel < uChannelCount; ++uChannel)
|
||||
{
|
||||
FFT8(&vRealTemp[uChannel*(uLength>>2)], &vImaginaryTemp[uChannel*(uLength>>2)]);
|
||||
}
|
||||
}
|
||||
else if (uLength == 4)
|
||||
{
|
||||
for (size_t uChannel=0; uChannel < uChannelCount; ++uChannel)
|
||||
{
|
||||
FFT4(&vRealTemp[uChannel*(uLength>>2)], &vImaginaryTemp[uChannel*(uLength>>2)]);
|
||||
}
|
||||
}
|
||||
|
||||
for (size_t uChannel=0; uChannel < uChannelCount; ++uChannel)
|
||||
{
|
||||
FFTUnswizzle(&pReal[uChannel*(uLength>>2)], &vRealTemp[uChannel*(uLength>>2)], uLog2Length);
|
||||
FFTUnswizzle(&pImaginary[uChannel*(uLength>>2)], &vImaginaryTemp[uChannel*(uLength>>2)], uLog2Length);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
// DESCRIPTION:
|
||||
// This function applies a 2^N-sample inverse FFT.
|
||||
// Audio is interleaved if multichannel.
|
||||
//
|
||||
// PARAMETERS:
|
||||
// pReal - [inout] real components, must have at least (1<<uLog2Length*uChannelCount)/4 elements
|
||||
// pImaginary - [in] imaginary components, must have at least (1<<uLog2Length*uChannelCount)/4 elements
|
||||
// pUnityTable - [in] unity table, must have at least (1<<uLog2Length) elements, see FFTInitializeUnityTable()
|
||||
// uChannelCount - [in] number of channels, must be > 0
|
||||
// uLog2Length - [in] LOG (base 2) of FFT length in frames, must within [2, 9]
|
||||
//----------------------------------------------------------------------------------
|
||||
inline void IFFTDeinterleaved(
|
||||
_Inout_updates_(((1<<uLog2Length)*uChannelCount)/4) XMVECTOR* __restrict pReal,
|
||||
_In_reads_(((1<<uLog2Length)*uChannelCount)/4) const XMVECTOR* __restrict pImaginary,
|
||||
_In_reads_(1<<uLog2Length) const XMVECTOR* __restrict pUnityTable,
|
||||
_In_ const size_t uChannelCount,
|
||||
_In_ const size_t uLog2Length) noexcept
|
||||
{
|
||||
using namespace DirectX;
|
||||
|
||||
assert(pReal);
|
||||
assert(pImaginary);
|
||||
assert(pUnityTable);
|
||||
assert(reinterpret_cast<uintptr_t>(pReal) % 16 == 0);
|
||||
assert(reinterpret_cast<uintptr_t>(pImaginary) % 16 == 0);
|
||||
assert(reinterpret_cast<uintptr_t>(pUnityTable) % 16 == 0);
|
||||
assert(uChannelCount > 0 && uChannelCount <= 6);
|
||||
_Analysis_assume_(uChannelCount > 0 && uChannelCount <= 6);
|
||||
assert(uLog2Length >= 2 && uLog2Length <= 9);
|
||||
_Analysis_assume_(uLog2Length >= 2 && uLog2Length <= 9);
|
||||
|
||||
XMVECTOR vRealTemp[768] = {};
|
||||
XMVECTOR vImaginaryTemp[768] = {};
|
||||
|
||||
const size_t uLength = size_t(1) << uLog2Length;
|
||||
|
||||
const XMVECTOR vRnp = XMVectorReplicate(1.0f / float(uLength));
|
||||
const XMVECTOR vRnm = XMVectorReplicate(-1.0f / float(uLength));
|
||||
for (size_t u=0; u < uChannelCount*(uLength>>2); u++)
|
||||
{
|
||||
vRealTemp[u] = XMVectorMultiply(pReal[u], vRnp);
|
||||
vImaginaryTemp[u] = XMVectorMultiply(pImaginary[u], vRnm);
|
||||
}
|
||||
|
||||
if (uLength > 16)
|
||||
{
|
||||
for (size_t uChannel=0; uChannel < uChannelCount; ++uChannel)
|
||||
{
|
||||
FFT(&vRealTemp[uChannel*(uLength>>2)], &vImaginaryTemp[uChannel*(uLength>>2)], pUnityTable, uLength);
|
||||
}
|
||||
}
|
||||
else if (uLength == 16)
|
||||
{
|
||||
for (size_t uChannel=0; uChannel < uChannelCount; ++uChannel)
|
||||
{
|
||||
FFT16(&vRealTemp[uChannel*(uLength>>2)], &vImaginaryTemp[uChannel*(uLength>>2)]);
|
||||
}
|
||||
}
|
||||
else if (uLength == 8)
|
||||
{
|
||||
for (size_t uChannel=0; uChannel < uChannelCount; ++uChannel)
|
||||
{
|
||||
FFT8(&vRealTemp[uChannel*(uLength>>2)], &vImaginaryTemp[uChannel*(uLength>>2)]);
|
||||
}
|
||||
}
|
||||
else if (uLength == 4)
|
||||
{
|
||||
for (size_t uChannel=0; uChannel < uChannelCount; ++uChannel)
|
||||
{
|
||||
FFT4(&vRealTemp[uChannel*(uLength>>2)], &vImaginaryTemp[uChannel*(uLength>>2)]);
|
||||
}
|
||||
}
|
||||
|
||||
for (size_t uChannel=0; uChannel < uChannelCount; ++uChannel)
|
||||
{
|
||||
FFTUnswizzle(&vImaginaryTemp[uChannel*(uLength>>2)], &vRealTemp[uChannel*(uLength>>2)], uLog2Length);
|
||||
}
|
||||
|
||||
if (uChannelCount > 1)
|
||||
{
|
||||
Interleave(pReal, vImaginaryTemp, uChannelCount, uLength);
|
||||
}
|
||||
else
|
||||
{
|
||||
memcpy_s(pReal, uLength*uChannelCount*sizeof(float), vImaginaryTemp, (uLength>>2)*sizeof(XMVECTOR));
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace XDSP
|
||||
|
||||
#pragma warning(pop)
|
9
Sdk/External/DirectXTK/.editorconfig
vendored
Normal file
9
Sdk/External/DirectXTK/.editorconfig
vendored
Normal file
@ -0,0 +1,9 @@
|
||||
root = true
|
||||
|
||||
[*.{cpp,h,inl,fx,fxh,hlsl,hlsli}]
|
||||
indent_size = 4
|
||||
indent_style = space
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
||||
end_of_line = crlf
|
||||
charset = latin1
|
78
Sdk/External/DirectXTK/.nuget/directxtk_desktop_2017.nuspec
vendored
Normal file
78
Sdk/External/DirectXTK/.nuget/directxtk_desktop_2017.nuspec
vendored
Normal file
@ -0,0 +1,78 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
|
||||
<metadata minClientVersion="2.8.6">
|
||||
<id>directxtk_desktop_2017</id>
|
||||
<version>0.0.0-SpecifyVersionOnCommandline</version>
|
||||
<title>DirectX Tool Kit (VS 2017/2019 Win32)</title>
|
||||
<authors>Microsoft</authors>
|
||||
<owners>microsoft,directxtk</owners>
|
||||
<summary>The DirectX Tool Kit (aka DirectXTK) is a collection of helper classes for writing Direct3D 11.x code in C++.</summary>
|
||||
<description>This version is for Windows desktop applications using Visual Studio 2017 or Visual Studio 2019.
|
||||
|
||||
Features:
|
||||
Audio - low-level audio API using XAudio2
|
||||
BufferHelpers - C++ helpers for creating D3D resources from CPU data
|
||||
CommonStates - factory providing commonly used D3D state objects
|
||||
DirectXHelpers - misc C++ helpers for D3D programming
|
||||
DDSTextureLoader - light-weight DDS file texture loader
|
||||
Effects - set of built-in shaders for common rendering tasks
|
||||
GamePad - gamepad controller helper using XInput
|
||||
GeometricPrimitive - draws basic shapes such as cubes and spheres
|
||||
GraphicsMemory - helper for managing dynamic graphics memory allocation
|
||||
Keyboard - keyboard state tracking helper
|
||||
Model - draws meshes loaded from .CMO, .SDKMESH, or .VBO files
|
||||
Mouse - mouse helper
|
||||
PostProcess - set of built-in shaders for common post-processing operations
|
||||
PrimitiveBatch - simple and efficient way to draw user primitives
|
||||
ScreenGrab - light-weight screen shot saver
|
||||
SimpleMath - simplified C++ wrapper for DirectXMath
|
||||
SpriteBatch - simple & efficient 2D sprite rendering
|
||||
SpriteFont - bitmap based text rendering
|
||||
VertexTypes - structures for commonly used vertex data formats
|
||||
WICTextureLoader - WIC-based image file texture loader</description>
|
||||
<releaseNotes>Matches the September 30, 2020 release on GitHub.
|
||||
|
||||
DirectX Tool Kit for Audio in this package uses XAudio2Redist NuGet package to support Windows 7 or later.</releaseNotes>
|
||||
<projectUrl>http://go.microsoft.com/fwlink/?LinkId=248929</projectUrl>
|
||||
<icon>images\icon.jpg</icon>
|
||||
<license type="expression">MIT</license>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<copyright>© Microsoft Corporation. All rights reserved.</copyright>
|
||||
<tags>DirectX DirectXTK native nativepackage</tags>
|
||||
<dependencies>
|
||||
<dependency id="Microsoft.XAudio2.Redist" version="1.2.4" />
|
||||
</dependencies>
|
||||
</metadata>
|
||||
|
||||
<files>
|
||||
|
||||
<file target="docs" src="Readme.*" />
|
||||
|
||||
<file target="include" src="Inc\*" exclude="Inc\XboxDDSTextureLoader.h" />
|
||||
|
||||
<file target="native\lib\Win32\Debug" src="Bin\Desktop_2017\Win32\Debug\*.lib" />
|
||||
<file target="native\lib\Win32\Debug" src="Bin\Desktop_2017\Win32\Debug\*.pdb" />
|
||||
<file target="native\lib\Win32\Debug" src="Audio\Bin\Desktop_2017_Win7\Win32\Debug\*.lib" />
|
||||
<file target="native\lib\Win32\Debug" src="Audio\Bin\Desktop_2017_Win7\Win32\Debug\*.pdb" />
|
||||
|
||||
<file target="native\lib\Win32\Release" src="Bin\Desktop_2017\Win32\Release\*.lib" />
|
||||
<file target="native\lib\Win32\Release" src="Bin\Desktop_2017\Win32\Release\*.pdb" />
|
||||
<file target="native\lib\Win32\Release" src="Audio\Bin\Desktop_2017_Win7\Win32\Release\*.lib" />
|
||||
<file target="native\lib\Win32\Release" src="Audio\Bin\Desktop_2017_Win7\Win32\Release\*.pdb" />
|
||||
|
||||
<file target="native\lib\x64\Debug" src="Bin\Desktop_2017\x64\Debug\*.lib" />
|
||||
<file target="native\lib\x64\Debug" src="Bin\Desktop_2017\x64\Debug\*.pdb" />
|
||||
<file target="native\lib\x64\Debug" src="Audio\Bin\Desktop_2017_Win7\x64\Debug\*.lib" />
|
||||
<file target="native\lib\x64\Debug" src="Audio\Bin\Desktop_2017_Win7\x64\Debug\*.pdb" />
|
||||
|
||||
<file target="native\lib\x64\Release" src="Bin\Desktop_2017\x64\Release\*.lib" />
|
||||
<file target="native\lib\x64\Release" src="Bin\Desktop_2017\x64\Release\*.pdb" />
|
||||
<file target="native\lib\x64\Release" src="Audio\Bin\Desktop_2017_Win7\x64\Release\*.lib" />
|
||||
<file target="native\lib\x64\Release" src="Audio\Bin\Desktop_2017_Win7\x64\Release\*.pdb" />
|
||||
|
||||
<file src=".nuget/directxtk_desktop_2017.targets" target="build\native" />
|
||||
|
||||
<file src=".nuget/icon.jpg" target="images\" />
|
||||
|
||||
</files>
|
||||
</package>
|
29
Sdk/External/DirectXTK/.nuget/directxtk_desktop_2017.targets
vendored
Normal file
29
Sdk/External/DirectXTK/.nuget/directxtk_desktop_2017.targets
vendored
Normal file
@ -0,0 +1,29 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
|
||||
<PropertyGroup Label="Debug" Condition="'$(Configuration.ToLower())' == 'debug'">
|
||||
<NuGetConfiguration>Debug</NuGetConfiguration>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Label="Non_Debug" Condition="'$(Configuration.ToLower())' != 'debug'">
|
||||
<NuGetConfiguration>Release</NuGetConfiguration>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup>
|
||||
<directxtk-LibPath>$(MSBuildThisFileDirectory)..\..\native\lib\$(Platform)\$(NuGetConfiguration)</directxtk-LibPath>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemDefinitionGroup>
|
||||
<Link>
|
||||
<AdditionalLibraryDirectories>$(directxtk-LibPath);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>DirectXTK.lib;DirectXTKAudioWin7.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
<PreprocessorDefinitions>HAS_DIRECTXTK;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>$(MSBuildThisFileDirectory)..\..\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
||||
</Project>
|
73
Sdk/External/DirectXTK/.nuget/directxtk_desktop_win10.nuspec
vendored
Normal file
73
Sdk/External/DirectXTK/.nuget/directxtk_desktop_win10.nuspec
vendored
Normal file
@ -0,0 +1,73 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
|
||||
<metadata minClientVersion="2.8.6">
|
||||
<id>directxtk_desktop_win10</id>
|
||||
<version>0.0.0-SpecifyVersionOnCommandline</version>
|
||||
<title>DirectX Tool Kit (VS 2017/2019 Win32 for Windows 10)</title>
|
||||
<authors>Microsoft</authors>
|
||||
<owners>microsoft,directxtk</owners>
|
||||
<summary>The DirectX Tool Kit (aka DirectXTK) is a collection of helper classes for writing Direct3D 11.x code in C++.</summary>
|
||||
<description>This version is for Windows desktop applications using Visual Studio 2017 or Visual Studio 2019 on Windows 10.
|
||||
|
||||
Features:
|
||||
Audio - low-level audio API using XAudio2
|
||||
BufferHelpers - C++ helpers for creating D3D resources from CPU data
|
||||
CommonStates - factory providing commonly used D3D state objects
|
||||
DirectXHelpers - misc C++ helpers for D3D programming
|
||||
DDSTextureLoader - light-weight DDS file texture loader
|
||||
Effects - set of built-in shaders for common rendering tasks
|
||||
GamePad - gamepad controller helper using XInput
|
||||
GeometricPrimitive - draws basic shapes such as cubes and spheres
|
||||
GraphicsMemory - helper for managing dynamic graphics memory allocation
|
||||
Keyboard - keyboard state tracking helper
|
||||
Model - draws meshes loaded from .CMO, .SDKMESH, or .VBO files
|
||||
Mouse - mouse helper
|
||||
PostProcess - set of built-in shaders for common post-processing operations
|
||||
PrimitiveBatch - simple and efficient way to draw user primitives
|
||||
ScreenGrab - light-weight screen shot saver
|
||||
SimpleMath - simplified C++ wrapper for DirectXMath
|
||||
SpriteBatch - simple & efficient 2D sprite rendering
|
||||
SpriteFont - bitmap based text rendering
|
||||
VertexTypes - structures for commonly used vertex data formats
|
||||
WICTextureLoader - WIC-based image file texture loader</description>
|
||||
<releaseNotes>Matches the September 30, 2020 release on GitHub.
|
||||
|
||||
DirectX Tool Kit for Audio in this package uses XAudio 2.9 which requires Windows 10.</releaseNotes>
|
||||
<projectUrl>http://go.microsoft.com/fwlink/?LinkId=248929</projectUrl>
|
||||
<icon>images\icon.jpg</icon>
|
||||
<license type="expression">MIT</license>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<copyright>© Microsoft Corporation. All rights reserved.</copyright>
|
||||
<tags>DirectX DirectXTK native nativepackage</tags>
|
||||
</metadata>
|
||||
|
||||
<files>
|
||||
|
||||
<file target="docs" src="Readme.*" />
|
||||
|
||||
<file target="include" src="Inc\*" exclude="Inc\XboxDDSTextureLoader.h" />
|
||||
|
||||
<file target="native\lib\Win32\Debug" src="Bin\Desktop_2017_Win10\Win32\Debug\*.lib" />
|
||||
<file target="native\lib\Win32\Debug" src="Bin\Desktop_2017_Win10\Win32\Debug\*.pdb" />
|
||||
|
||||
<file target="native\lib\Win32\Release" src="Bin\Desktop_2017_Win10\Win32\Release\*.lib" />
|
||||
<file target="native\lib\Win32\Release" src="Bin\Desktop_2017_Win10\Win32\Release\*.pdb" />
|
||||
|
||||
<file target="native\lib\x64\Debug" src="Bin\Desktop_2017_Win10\x64\Debug\*.lib" />
|
||||
<file target="native\lib\x64\Debug" src="Bin\Desktop_2017_Win10\x64\Debug\*.pdb" />
|
||||
|
||||
<file target="native\lib\x64\Release" src="Bin\Desktop_2017_Win10\x64\Release\*.lib" />
|
||||
<file target="native\lib\x64\Release" src="Bin\Desktop_2017_Win10\x64\Release\*.pdb" />
|
||||
|
||||
<file target="native\lib\ARM64\Debug" src="Bin\Desktop_2017_Win10\ARM64\Debug\*.lib" />
|
||||
<file target="native\lib\ARM64\Debug" src="Bin\Desktop_2017_Win10\ARM64\Debug\*.pdb" />
|
||||
|
||||
<file target="native\lib\ARM64\Release" src="Bin\Desktop_2017_Win10\ARM64\Release\*.lib" />
|
||||
<file target="native\lib\ARM64\Release" src="Bin\Desktop_2017_Win10\ARM64\Release\*.pdb" />
|
||||
|
||||
<file src=".nuget/directxtk_desktop_win10.targets" target="build\native" />
|
||||
|
||||
<file src=".nuget/icon.jpg" target="images\" />
|
||||
|
||||
</files>
|
||||
</package>
|
29
Sdk/External/DirectXTK/.nuget/directxtk_desktop_win10.targets
vendored
Normal file
29
Sdk/External/DirectXTK/.nuget/directxtk_desktop_win10.targets
vendored
Normal file
@ -0,0 +1,29 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
|
||||
<PropertyGroup Label="Debug" Condition="'$(Configuration.ToLower())' == 'debug'">
|
||||
<NuGetConfiguration>Debug</NuGetConfiguration>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Label="Non_Debug" Condition="'$(Configuration.ToLower())' != 'debug'">
|
||||
<NuGetConfiguration>Release</NuGetConfiguration>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup>
|
||||
<directxtk-LibPath>$(MSBuildThisFileDirectory)..\..\native\lib\$(Platform)\$(NuGetConfiguration)</directxtk-LibPath>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemDefinitionGroup>
|
||||
<Link>
|
||||
<AdditionalLibraryDirectories>$(directxtk-LibPath);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>DirectXTK.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
<PreprocessorDefinitions>HAS_DIRECTXTK;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>$(MSBuildThisFileDirectory)..\..\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
||||
</Project>
|
77
Sdk/External/DirectXTK/.nuget/directxtk_uwp.nuspec
vendored
Normal file
77
Sdk/External/DirectXTK/.nuget/directxtk_uwp.nuspec
vendored
Normal file
@ -0,0 +1,77 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
|
||||
<metadata minClientVersion="2.8.6">
|
||||
<id>directxtk_uwp</id>
|
||||
<version>0.0.0-SpecifyVersionOnCommandline</version>
|
||||
<title>DirectX Tool Kit (UWP)</title>
|
||||
<authors>Microsoft</authors>
|
||||
<owners>microsoft,directxtk</owners>
|
||||
<summary>The DirectX Tool Kit (aka DirectXTK) is a collection of helper classes for writing Direct3D 11.x code in C++.</summary>
|
||||
<description>This version is for Universal Windows Platform apps on Windows 10 using Visual Studio 2017 or Visual Studio 2019.
|
||||
|
||||
Features:
|
||||
Audio - low-level audio API using XAudio2
|
||||
BufferHelpers - C++ helpers for creating D3D resources from CPU data
|
||||
CommonStates - factory providing commonly used D3D state objects
|
||||
DirectXHelpers - misc C++ helpers for D3D programming
|
||||
DDSTextureLoader - light-weight DDS file texture loader
|
||||
Effects - set of built-in shaders for common rendering tasks
|
||||
GamePad - gamepad controller helper using XInput
|
||||
GeometricPrimitive - draws basic shapes such as cubes and spheres
|
||||
GraphicsMemory - helper for managing dynamic graphics memory allocation
|
||||
Keyboard - keyboard state tracking helper
|
||||
Model - draws meshes loaded from .CMO, .SDKMESH, or .VBO files
|
||||
Mouse - mouse helper
|
||||
PostProcess - set of built-in shaders for common post-processing operations
|
||||
PrimitiveBatch - simple and efficient way to draw user primitives
|
||||
ScreenGrab - light-weight screen shot saver
|
||||
SimpleMath - simplified C++ wrapper for DirectXMath
|
||||
SpriteBatch - simple & efficient 2D sprite rendering
|
||||
SpriteFont - bitmap based text rendering
|
||||
VertexTypes - structures for commonly used vertex data formats
|
||||
WICTextureLoader - WIC-based image file texture loader</description>
|
||||
<releaseNotes>Matches the September 30, 2020 release on GitHub.</releaseNotes>
|
||||
<projectUrl>http://go.microsoft.com/fwlink/?LinkId=248929</projectUrl>
|
||||
<icon>images\icon.jpg</icon>
|
||||
<license type="expression">MIT</license>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<copyright>© Microsoft Corporation. All rights reserved.</copyright>
|
||||
<tags>DirectX DirectXTK native nativepackage</tags>
|
||||
</metadata>
|
||||
|
||||
<files>
|
||||
|
||||
<file target="docs" src="Readme.*" />
|
||||
|
||||
<file target="include" src="Inc\*" exclude="Inc\XboxDDSTextureLoader.h" />
|
||||
|
||||
<file target="native\lib\ARM\Debug" src="Bin\Windows10_2017\ARM\Debug\*.lib" />
|
||||
<file target="native\lib\ARM\Debug" src="Bin\Windows10_2017\ARM\Debug\*.pdb" />
|
||||
|
||||
<file target="native\lib\ARM\Release" src="Bin\Windows10_2017\ARM\Release\*.lib" />
|
||||
<file target="native\lib\ARM\Release" src="Bin\Windows10_2017\ARM\Release\*.pdb" />
|
||||
|
||||
<file target="native\lib\ARM64\Debug" src="Bin\Windows10_2017\ARM64\Debug\*.lib" />
|
||||
<file target="native\lib\ARM64\Debug" src="Bin\Windows10_2017\ARM64\Debug\*.pdb" />
|
||||
|
||||
<file target="native\lib\ARM64\Release" src="Bin\Windows10_2017\ARM64\Release\*.lib" />
|
||||
<file target="native\lib\ARM64\Release" src="Bin\Windows10_2017\ARM64\Release\*.pdb" />
|
||||
|
||||
<file target="native\lib\Win32\Debug" src="Bin\Windows10_2017\Win32\Debug\*.lib" />
|
||||
<file target="native\lib\Win32\Debug" src="Bin\Windows10_2017\Win32\Debug\*.pdb" />
|
||||
|
||||
<file target="native\lib\Win32\Release" src="Bin\Windows10_2017\Win32\Release\*.lib" />
|
||||
<file target="native\lib\Win32\Release" src="Bin\Windows10_2017\Win32\Release\*.pdb" />
|
||||
|
||||
<file target="native\lib\x64\Debug" src="Bin\Windows10_2017\x64\Debug\*.lib" />
|
||||
<file target="native\lib\x64\Debug" src="Bin\Windows10_2017\x64\Debug\*.pdb" />
|
||||
|
||||
<file target="native\lib\x64\Release" src="Bin\Windows10_2017\x64\Release\*.lib" />
|
||||
<file target="native\lib\x64\Release" src="Bin\Windows10_2017\x64\Release\*.pdb" />
|
||||
|
||||
<file src=".nuget/directxtk_uwp.targets" target="build\native" />
|
||||
|
||||
<file src=".nuget/icon.jpg" target="images\" />
|
||||
|
||||
</files>
|
||||
</package>
|
29
Sdk/External/DirectXTK/.nuget/directxtk_uwp.targets
vendored
Normal file
29
Sdk/External/DirectXTK/.nuget/directxtk_uwp.targets
vendored
Normal file
@ -0,0 +1,29 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
|
||||
<PropertyGroup Label="Debug" Condition="'$(Configuration.ToLower())' == 'debug'">
|
||||
<NuGetConfiguration>Debug</NuGetConfiguration>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Label="Non_Debug" Condition="'$(Configuration.ToLower())' != 'debug'">
|
||||
<NuGetConfiguration>Release</NuGetConfiguration>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup>
|
||||
<directxtk-LibPath>$(MSBuildThisFileDirectory)..\..\native\lib\$(Platform)\$(NuGetConfiguration)</directxtk-LibPath>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemDefinitionGroup>
|
||||
<Link>
|
||||
<AdditionalLibraryDirectories>$(directxtk-LibPath);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>DirectXTK.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
<PreprocessorDefinitions>HAS_DIRECTXTK;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>$(MSBuildThisFileDirectory)..\..\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
||||
</Project>
|
BIN
Sdk/External/DirectXTK/.nuget/icon.jpg
vendored
Normal file
BIN
Sdk/External/DirectXTK/.nuget/icon.jpg
vendored
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.4 KiB |
11
Sdk/External/DirectXTK/.nuget/signconfig_desktop.xml
vendored
Normal file
11
Sdk/External/DirectXTK/.nuget/signconfig_desktop.xml
vendored
Normal file
@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<SignConfigXML>
|
||||
<job dest="__OUTPATHROOT__" certSubject="NuGet" jobname="NugetSigningTest">
|
||||
<file src="__INPATHROOT__\directxtk_desktop_2017*.nupkg" signType="CP-401405" dest="__OUTPATHROOT__\directxtk_desktop_2017*.nupkg" />
|
||||
<file src="__INPATHROOT__\directxtk_desktop_win10*.nupkg" signType="CP-401405" dest="__OUTPATHROOT__\directxtk_desktop_win10*.nupkg" />
|
||||
</job>
|
||||
<job certSubject="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US" dest="__OUTPATHROOT__" jobname="ISS EngFun" approvers="">
|
||||
<file src="__INPATHROOT__\MakeSpriteFont.exe" signType="135020002" dest="__OUTPATHROOT__\MakeSpriteFont.exe" />
|
||||
<file src="__INPATHROOT__\xwbtool.exe" signType="135020002" dest="__OUTPATHROOT__\xwbtool.exe" />
|
||||
</job>
|
||||
</SignConfigXML>
|
6
Sdk/External/DirectXTK/.nuget/signconfig_uwp.xml
vendored
Normal file
6
Sdk/External/DirectXTK/.nuget/signconfig_uwp.xml
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<SignConfigXML>
|
||||
<job dest="__OUTPATHROOT__" certSubject="NuGet" jobname="NugetSigningTest">
|
||||
<file src="__INPATHROOT__\directxtk_uwp*.nupkg" signType="CP-401405" dest="__OUTPATHROOT__\directxtk_uwp*.nupkg" />
|
||||
</job>
|
||||
</SignConfigXML>
|
6
Sdk/External/DirectXTK/.nuget/versioninfo.ps1
vendored
Normal file
6
Sdk/External/DirectXTK/.nuget/versioninfo.ps1
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
param(
|
||||
[string]$version
|
||||
)
|
||||
$versionComma = $version.Replace(".", ",")
|
||||
$files = 'XWBTool\xwbtool.rc', 'MakeSpriteFont\Properties\AssemblyInfo.cs'
|
||||
foreach ($file in $files) { (Get-Content $file).replace('1,0,0,0', $versionComma).replace('1.0.0.0', $version) | Set-Content $file }
|
1653
Sdk/External/DirectXTK/Audio/AudioEngine.cpp
vendored
Normal file
1653
Sdk/External/DirectXTK/Audio/AudioEngine.cpp
vendored
Normal file
File diff suppressed because it is too large
Load Diff
207
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2017_Win7.vcxproj
vendored
Normal file
207
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2017_Win7.vcxproj
vendored
Normal file
@ -0,0 +1,207 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\Inc\Audio.h" />
|
||||
<ClInclude Include="SoundCommon.h" />
|
||||
<ClInclude Include="WaveBankReader.h" />
|
||||
<ClInclude Include="WAVFileReader.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="AudioEngine.cpp">
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
|
||||
</ClCompile>
|
||||
<ClCompile Include="DynamicSoundEffectInstance.cpp" />
|
||||
<ClCompile Include="SoundCommon.cpp" />
|
||||
<ClCompile Include="SoundEffect.cpp" />
|
||||
<ClCompile Include="SoundEffectInstance.cpp" />
|
||||
<ClCompile Include="SoundStreamInstance.cpp" />
|
||||
<ClCompile Include="WaveBank.cpp" />
|
||||
<ClCompile Include="WaveBankReader.cpp" />
|
||||
<ClCompile Include="WAVFileReader.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{4F150A30-CECB-49D1-8283-6A3F57438CF5}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>DirectXTKAudioWin7</RootNamespace>
|
||||
<WindowsTargetPlatformVersion>10.0.17763.0</WindowsTargetPlatformVersion>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>Bin\Desktop_2017_Win7\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017_Win7\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin7</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<OutDir>Bin\Desktop_2017_Win7\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017_Win7\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin7</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>Bin\Desktop_2017_Win7\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017_Win7\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin7</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<OutDir>Bin\Desktop_2017_Win7\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017_Win7\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin7</TargetName>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
<Import Project="..\packages\Microsoft.XAudio2.Redist.1.2.4\build\native\Microsoft.XAudio2.Redist.targets" Condition="Exists('..\packages\Microsoft.XAudio2.Redist.1.2.4\build\native\Microsoft.XAudio2.Redist.targets')" />
|
||||
</ImportGroup>
|
||||
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
||||
<PropertyGroup>
|
||||
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
|
||||
</PropertyGroup>
|
||||
<Error Condition="!Exists('..\packages\Microsoft.XAudio2.Redist.1.2.4\build\native\Microsoft.XAudio2.Redist.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Microsoft.XAudio2.Redist.1.2.4\build\native\Microsoft.XAudio2.Redist.targets'))" />
|
||||
</Target>
|
||||
</Project>
|
59
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2017_Win7.vcxproj.filters
vendored
Normal file
59
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2017_Win7.vcxproj.filters
vendored
Normal file
@ -0,0 +1,59 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Inc">
|
||||
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
|
||||
<Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Src">
|
||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="WaveBankReader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="WAVFileReader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\Inc\Audio.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="SoundCommon.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="AudioEngine.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="WaveBankReader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="WAVFileReader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="WaveBank.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundEffectInstance.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundCommon.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="DynamicSoundEffectInstance.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundStreamInstance.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
</Project>
|
197
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2017_Win8.vcxproj
vendored
Normal file
197
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2017_Win8.vcxproj
vendored
Normal file
@ -0,0 +1,197 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\Inc\Audio.h" />
|
||||
<ClInclude Include="SoundCommon.h" />
|
||||
<ClInclude Include="WaveBankReader.h" />
|
||||
<ClInclude Include="WAVFileReader.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="AudioEngine.cpp">
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
|
||||
</ClCompile>
|
||||
<ClCompile Include="DynamicSoundEffectInstance.cpp" />
|
||||
<ClCompile Include="SoundCommon.cpp" />
|
||||
<ClCompile Include="SoundEffect.cpp" />
|
||||
<ClCompile Include="SoundEffectInstance.cpp" />
|
||||
<ClCompile Include="SoundStreamInstance.cpp" />
|
||||
<ClCompile Include="WaveBank.cpp" />
|
||||
<ClCompile Include="WaveBankReader.cpp" />
|
||||
<ClCompile Include="WAVFileReader.cpp" />
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{4F150A30-CECB-49D1-8283-6A3F57438CF5}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>DirectXTKAudio</RootNamespace>
|
||||
<WindowsTargetPlatformVersion>10.0.17763.0</WindowsTargetPlatformVersion>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin8</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<OutDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin8</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin8</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<OutDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin8</TargetName>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0602;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0602;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0602;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0602;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
56
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2017_Win8.vcxproj.filters
vendored
Normal file
56
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2017_Win8.vcxproj.filters
vendored
Normal file
@ -0,0 +1,56 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Inc">
|
||||
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
|
||||
<Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Src">
|
||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="WaveBankReader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="WAVFileReader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\Inc\Audio.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="SoundCommon.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="AudioEngine.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="WaveBankReader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="WAVFileReader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="WaveBank.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundEffectInstance.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundCommon.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="DynamicSoundEffectInstance.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundStreamInstance.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
</Project>
|
211
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2019_Win7.vcxproj
vendored
Normal file
211
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2019_Win7.vcxproj
vendored
Normal file
@ -0,0 +1,211 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\Inc\Audio.h" />
|
||||
<ClInclude Include="SoundCommon.h" />
|
||||
<ClInclude Include="WaveBankReader.h" />
|
||||
<ClInclude Include="WAVFileReader.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="AudioEngine.cpp">
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
|
||||
</ClCompile>
|
||||
<ClCompile Include="DynamicSoundEffectInstance.cpp" />
|
||||
<ClCompile Include="SoundCommon.cpp" />
|
||||
<ClCompile Include="SoundEffect.cpp" />
|
||||
<ClCompile Include="SoundEffectInstance.cpp" />
|
||||
<ClCompile Include="SoundStreamInstance.cpp" />
|
||||
<ClCompile Include="WaveBank.cpp" />
|
||||
<ClCompile Include="WaveBankReader.cpp" />
|
||||
<ClCompile Include="WAVFileReader.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{4F150A30-CECB-49D1-8283-6A3F57438CF5}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>DirectXTKAudioWin7</RootNamespace>
|
||||
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>Bin\Desktop_2019_Win7\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019_Win7\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin7</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<OutDir>Bin\Desktop_2019_Win7\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019_Win7\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin7</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>Bin\Desktop_2019_Win7\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019_Win7\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin7</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<OutDir>Bin\Desktop_2019_Win7\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019_Win7\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin7</TargetName>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
<Import Project="..\packages\Microsoft.XAudio2.Redist.1.2.4\build\native\Microsoft.XAudio2.Redist.targets" Condition="Exists('..\packages\Microsoft.XAudio2.Redist.1.2.4\build\native\Microsoft.XAudio2.Redist.targets')" />
|
||||
</ImportGroup>
|
||||
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
||||
<PropertyGroup>
|
||||
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
|
||||
</PropertyGroup>
|
||||
<Error Condition="!Exists('..\packages\Microsoft.XAudio2.Redist.1.2.4\build\native\Microsoft.XAudio2.Redist.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Microsoft.XAudio2.Redist.1.2.4\build\native\Microsoft.XAudio2.Redist.targets'))" />
|
||||
</Target>
|
||||
</Project>
|
59
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2019_Win7.vcxproj.filters
vendored
Normal file
59
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2019_Win7.vcxproj.filters
vendored
Normal file
@ -0,0 +1,59 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Inc">
|
||||
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
|
||||
<Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Src">
|
||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="WaveBankReader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="WAVFileReader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\Inc\Audio.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="SoundCommon.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="AudioEngine.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="WaveBankReader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="WAVFileReader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="WaveBank.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundEffectInstance.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundCommon.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="DynamicSoundEffectInstance.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundStreamInstance.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
</Project>
|
201
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2019_Win8.vcxproj
vendored
Normal file
201
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2019_Win8.vcxproj
vendored
Normal file
@ -0,0 +1,201 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\Inc\Audio.h" />
|
||||
<ClInclude Include="SoundCommon.h" />
|
||||
<ClInclude Include="WaveBankReader.h" />
|
||||
<ClInclude Include="WAVFileReader.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="AudioEngine.cpp">
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
|
||||
</ClCompile>
|
||||
<ClCompile Include="DynamicSoundEffectInstance.cpp" />
|
||||
<ClCompile Include="SoundCommon.cpp" />
|
||||
<ClCompile Include="SoundEffect.cpp" />
|
||||
<ClCompile Include="SoundEffectInstance.cpp" />
|
||||
<ClCompile Include="SoundStreamInstance.cpp" />
|
||||
<ClCompile Include="WaveBank.cpp" />
|
||||
<ClCompile Include="WaveBankReader.cpp" />
|
||||
<ClCompile Include="WAVFileReader.cpp" />
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{4F150A30-CECB-49D1-8283-6A3F57438CF5}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>DirectXTKAudio</RootNamespace>
|
||||
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin8</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<OutDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin8</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin8</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<OutDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTKAudioWin8</TargetName>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0602;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0602;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0602;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0602;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>..\Inc;..\Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
56
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2019_Win8.vcxproj.filters
vendored
Normal file
56
Sdk/External/DirectXTK/Audio/DirectXTKAudio_Desktop_2019_Win8.vcxproj.filters
vendored
Normal file
@ -0,0 +1,56 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Inc">
|
||||
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
|
||||
<Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Src">
|
||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="WaveBankReader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="WAVFileReader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\Inc\Audio.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="SoundCommon.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="AudioEngine.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="WaveBankReader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="WAVFileReader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="WaveBank.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundEffectInstance.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundCommon.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="DynamicSoundEffectInstance.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SoundStreamInstance.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
</Project>
|
387
Sdk/External/DirectXTK/Audio/DynamicSoundEffectInstance.cpp
vendored
Normal file
387
Sdk/External/DirectXTK/Audio/DynamicSoundEffectInstance.cpp
vendored
Normal file
@ -0,0 +1,387 @@
|
||||
//--------------------------------------------------------------------------------------
|
||||
// File: DynamicSoundEffectInstance.cpp
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkId=248929
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615561
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
#include "pch.h"
|
||||
#include "SoundCommon.h"
|
||||
|
||||
using namespace DirectX;
|
||||
|
||||
|
||||
//======================================================================================
|
||||
// DynamicSoundEffectInstance
|
||||
//======================================================================================
|
||||
|
||||
// Internal object implementation class.
|
||||
class DynamicSoundEffectInstance::Impl : public IVoiceNotify
|
||||
{
|
||||
public:
|
||||
Impl(_In_ AudioEngine* engine,
|
||||
_In_ DynamicSoundEffectInstance* object,
|
||||
std::function<void(DynamicSoundEffectInstance*)>& bufferNeeded,
|
||||
int sampleRate, int channels, int sampleBits,
|
||||
SOUND_EFFECT_INSTANCE_FLAGS flags) :
|
||||
mBase(),
|
||||
mBufferNeeded(nullptr),
|
||||
mObject(object)
|
||||
{
|
||||
if ((sampleRate < XAUDIO2_MIN_SAMPLE_RATE)
|
||||
|| (sampleRate > XAUDIO2_MAX_SAMPLE_RATE))
|
||||
{
|
||||
DebugTrace("DynamicSoundEffectInstance sampleRate must be in range %u...%u\n", XAUDIO2_MIN_SAMPLE_RATE, XAUDIO2_MAX_SAMPLE_RATE);
|
||||
throw std::invalid_argument("DynamicSoundEffectInstance");
|
||||
}
|
||||
|
||||
if (!channels || (channels > 8))
|
||||
{
|
||||
DebugTrace("DynamicSoundEffectInstance channels must be in range 1...8\n");
|
||||
throw std::invalid_argument("DynamicSoundEffectInstance");
|
||||
}
|
||||
|
||||
switch (sampleBits)
|
||||
{
|
||||
case 8:
|
||||
case 16:
|
||||
break;
|
||||
|
||||
default:
|
||||
DebugTrace("DynamicSoundEffectInstance sampleBits must be 8-bit or 16-bit\n");
|
||||
throw std::invalid_argument("DynamicSoundEffectInstance");
|
||||
}
|
||||
|
||||
mBufferEvent.reset(CreateEventEx(nullptr, nullptr, 0, EVENT_MODIFY_STATE | SYNCHRONIZE));
|
||||
if (!mBufferEvent)
|
||||
{
|
||||
throw std::exception("CreateEvent");
|
||||
}
|
||||
|
||||
CreateIntegerPCM(&mWaveFormat, sampleRate, channels, sampleBits);
|
||||
|
||||
assert(engine != nullptr);
|
||||
engine->RegisterNotify(this, true);
|
||||
|
||||
mBase.Initialize(engine, &mWaveFormat, flags);
|
||||
|
||||
mBufferNeeded = bufferNeeded;
|
||||
}
|
||||
|
||||
Impl(Impl&&) = default;
|
||||
Impl& operator= (Impl&&) = default;
|
||||
|
||||
Impl(Impl const&) = delete;
|
||||
Impl& operator= (Impl const&) = delete;
|
||||
|
||||
~Impl() override
|
||||
{
|
||||
mBase.DestroyVoice();
|
||||
|
||||
if (mBase.engine)
|
||||
{
|
||||
mBase.engine->UnregisterNotify(this, false, true);
|
||||
mBase.engine = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
void Play();
|
||||
|
||||
void Resume();
|
||||
|
||||
void SubmitBuffer(_In_reads_bytes_(audioBytes) const uint8_t* pAudioData, uint32_t offset, size_t audioBytes);
|
||||
|
||||
const WAVEFORMATEX* GetFormat() const noexcept { return &mWaveFormat; }
|
||||
|
||||
// IVoiceNotify
|
||||
void __cdecl OnBufferEnd() override
|
||||
{
|
||||
SetEvent(mBufferEvent.get());
|
||||
}
|
||||
|
||||
void __cdecl OnCriticalError() override
|
||||
{
|
||||
mBase.OnCriticalError();
|
||||
}
|
||||
|
||||
void __cdecl OnReset() override
|
||||
{
|
||||
mBase.OnReset();
|
||||
}
|
||||
|
||||
void __cdecl OnUpdate() override;
|
||||
|
||||
void __cdecl OnDestroyEngine() noexcept override
|
||||
{
|
||||
mBase.OnDestroy();
|
||||
}
|
||||
|
||||
void __cdecl OnTrim() override
|
||||
{
|
||||
mBase.OnTrim();
|
||||
}
|
||||
|
||||
void __cdecl GatherStatistics(AudioStatistics& stats) const noexcept override
|
||||
{
|
||||
mBase.GatherStatistics(stats);
|
||||
}
|
||||
|
||||
void __cdecl OnDestroyParent() noexcept override
|
||||
{
|
||||
}
|
||||
|
||||
SoundEffectInstanceBase mBase;
|
||||
|
||||
private:
|
||||
ScopedHandle mBufferEvent;
|
||||
std::function<void(DynamicSoundEffectInstance*)> mBufferNeeded;
|
||||
DynamicSoundEffectInstance* mObject;
|
||||
WAVEFORMATEX mWaveFormat;
|
||||
};
|
||||
|
||||
|
||||
void DynamicSoundEffectInstance::Impl::Play()
|
||||
{
|
||||
if (!mBase.voice)
|
||||
{
|
||||
mBase.AllocateVoice(&mWaveFormat);
|
||||
}
|
||||
|
||||
(void)mBase.Play();
|
||||
|
||||
if (mBase.voice && (mBase.state == PLAYING) && (mBase.GetPendingBufferCount() <= 2))
|
||||
{
|
||||
SetEvent(mBufferEvent.get());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void DynamicSoundEffectInstance::Impl::Resume()
|
||||
{
|
||||
if (mBase.voice && (mBase.state == PAUSED))
|
||||
{
|
||||
mBase.Resume();
|
||||
|
||||
if ((mBase.state == PLAYING) && (mBase.GetPendingBufferCount() <= 2))
|
||||
{
|
||||
SetEvent(mBufferEvent.get());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
void DynamicSoundEffectInstance::Impl::SubmitBuffer(const uint8_t* pAudioData, uint32_t offset, size_t audioBytes)
|
||||
{
|
||||
if (!pAudioData || !audioBytes)
|
||||
throw std::exception("Invalid audio data buffer");
|
||||
|
||||
if (audioBytes > UINT32_MAX)
|
||||
throw std::out_of_range("SubmitBuffer");
|
||||
|
||||
XAUDIO2_BUFFER buffer = {};
|
||||
buffer.AudioBytes = static_cast<UINT32>(audioBytes);
|
||||
buffer.pAudioData = pAudioData;
|
||||
|
||||
if (offset)
|
||||
{
|
||||
assert(mWaveFormat.wFormatTag == WAVE_FORMAT_PCM);
|
||||
buffer.PlayBegin = offset / mWaveFormat.nBlockAlign;
|
||||
buffer.PlayLength = static_cast<UINT32>((audioBytes - offset) / mWaveFormat.nBlockAlign);
|
||||
}
|
||||
|
||||
buffer.pContext = this;
|
||||
|
||||
HRESULT hr = mBase.voice->SubmitSourceBuffer(&buffer, nullptr);
|
||||
if (FAILED(hr))
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
DebugTrace("ERROR: DynamicSoundEffectInstance failed (%08X) when submitting buffer:\n", static_cast<unsigned int>(hr));
|
||||
|
||||
DebugTrace("\tFormat Tag %u, %u channels, %u-bit, %u Hz, %zu bytes [%u offset)\n",
|
||||
mWaveFormat.wFormatTag, mWaveFormat.nChannels, mWaveFormat.wBitsPerSample, mWaveFormat.nSamplesPerSec, audioBytes, offset);
|
||||
#endif
|
||||
throw std::exception("SubmitSourceBuffer");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void DynamicSoundEffectInstance::Impl::OnUpdate()
|
||||
{
|
||||
DWORD result = WaitForSingleObjectEx(mBufferEvent.get(), 0, FALSE);
|
||||
switch (result)
|
||||
{
|
||||
case WAIT_TIMEOUT:
|
||||
break;
|
||||
|
||||
case WAIT_OBJECT_0:
|
||||
if (mBufferNeeded)
|
||||
{
|
||||
// This callback happens on the same thread that called AudioEngine::Update()
|
||||
mBufferNeeded(mObject);
|
||||
}
|
||||
break;
|
||||
|
||||
case WAIT_FAILED:
|
||||
throw std::exception("WaitForSingleObjectEx");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
//--------------------------------------------------------------------------------------
|
||||
// DynamicSoundEffectInstance
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
#pragma warning( disable : 4355 )
|
||||
|
||||
// Public constructors
|
||||
_Use_decl_annotations_
|
||||
DynamicSoundEffectInstance::DynamicSoundEffectInstance(
|
||||
AudioEngine* engine,
|
||||
std::function<void(DynamicSoundEffectInstance*)> bufferNeeded,
|
||||
int sampleRate,
|
||||
int channels,
|
||||
int sampleBits,
|
||||
SOUND_EFFECT_INSTANCE_FLAGS flags) :
|
||||
pImpl(std::make_unique<Impl>(engine, this, bufferNeeded, sampleRate, channels, sampleBits, flags))
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
// Move constructor.
|
||||
DynamicSoundEffectInstance::DynamicSoundEffectInstance(DynamicSoundEffectInstance&& moveFrom) noexcept
|
||||
: pImpl(std::move(moveFrom.pImpl))
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
// Move assignment.
|
||||
DynamicSoundEffectInstance& DynamicSoundEffectInstance::operator= (DynamicSoundEffectInstance&& moveFrom) noexcept
|
||||
{
|
||||
pImpl = std::move(moveFrom.pImpl);
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
// Public destructor.
|
||||
DynamicSoundEffectInstance::~DynamicSoundEffectInstance()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
// Public methods.
|
||||
void DynamicSoundEffectInstance::Play()
|
||||
{
|
||||
pImpl->Play();
|
||||
}
|
||||
|
||||
|
||||
void DynamicSoundEffectInstance::Stop(bool immediate) noexcept
|
||||
{
|
||||
bool looped = false;
|
||||
pImpl->mBase.Stop(immediate, looped);
|
||||
}
|
||||
|
||||
|
||||
void DynamicSoundEffectInstance::Pause() noexcept
|
||||
{
|
||||
pImpl->mBase.Pause();
|
||||
}
|
||||
|
||||
|
||||
void DynamicSoundEffectInstance::Resume()
|
||||
{
|
||||
pImpl->Resume();
|
||||
}
|
||||
|
||||
|
||||
void DynamicSoundEffectInstance::SetVolume(float volume)
|
||||
{
|
||||
pImpl->mBase.SetVolume(volume);
|
||||
}
|
||||
|
||||
|
||||
void DynamicSoundEffectInstance::SetPitch(float pitch)
|
||||
{
|
||||
pImpl->mBase.SetPitch(pitch);
|
||||
}
|
||||
|
||||
|
||||
void DynamicSoundEffectInstance::SetPan(float pan)
|
||||
{
|
||||
pImpl->mBase.SetPan(pan);
|
||||
}
|
||||
|
||||
|
||||
void DynamicSoundEffectInstance::Apply3D(const AudioListener& listener, const AudioEmitter& emitter, bool rhcoords)
|
||||
{
|
||||
pImpl->mBase.Apply3D(listener, emitter, rhcoords);
|
||||
}
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
void DynamicSoundEffectInstance::SubmitBuffer(const uint8_t* pAudioData, size_t audioBytes)
|
||||
{
|
||||
pImpl->SubmitBuffer(pAudioData, 0, audioBytes);
|
||||
}
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
void DynamicSoundEffectInstance::SubmitBuffer(const uint8_t* pAudioData, uint32_t offset, size_t audioBytes)
|
||||
{
|
||||
pImpl->SubmitBuffer(pAudioData, offset, audioBytes);
|
||||
}
|
||||
|
||||
|
||||
// Public accessors.
|
||||
SoundState DynamicSoundEffectInstance::GetState() noexcept
|
||||
{
|
||||
return pImpl->mBase.GetState(false);
|
||||
}
|
||||
|
||||
|
||||
size_t DynamicSoundEffectInstance::GetSampleDuration(size_t bytes) const noexcept
|
||||
{
|
||||
auto wfx = pImpl->GetFormat();
|
||||
if (!wfx || !wfx->wBitsPerSample || !wfx->nChannels)
|
||||
return 0;
|
||||
|
||||
return static_cast<size_t>((uint64_t(bytes) * 8)
|
||||
/ (uint64_t(wfx->wBitsPerSample) * uint64_t(wfx->nChannels)));
|
||||
}
|
||||
|
||||
|
||||
size_t DynamicSoundEffectInstance::GetSampleDurationMS(size_t bytes) const noexcept
|
||||
{
|
||||
auto wfx = pImpl->GetFormat();
|
||||
if (!wfx || !wfx->nAvgBytesPerSec)
|
||||
return 0;
|
||||
|
||||
return static_cast<size_t>((uint64_t(bytes) * 1000) / wfx->nAvgBytesPerSec);
|
||||
}
|
||||
|
||||
|
||||
size_t DynamicSoundEffectInstance::GetSampleSizeInBytes(uint64_t duration) const noexcept
|
||||
{
|
||||
auto wfx = pImpl->GetFormat();
|
||||
if (!wfx || !wfx->nSamplesPerSec)
|
||||
return 0;
|
||||
|
||||
return static_cast<size_t>(((duration * wfx->nSamplesPerSec) / 1000) * wfx->nBlockAlign);
|
||||
}
|
||||
|
||||
|
||||
int DynamicSoundEffectInstance::GetPendingBufferCount() const noexcept
|
||||
{
|
||||
return pImpl->mBase.GetPendingBufferCount();
|
||||
}
|
||||
|
||||
|
||||
const WAVEFORMATEX* DynamicSoundEffectInstance::GetFormat() const noexcept
|
||||
{
|
||||
return pImpl->GetFormat();
|
||||
}
|
798
Sdk/External/DirectXTK/Audio/SoundCommon.cpp
vendored
Normal file
798
Sdk/External/DirectXTK/Audio/SoundCommon.cpp
vendored
Normal file
@ -0,0 +1,798 @@
|
||||
//--------------------------------------------------------------------------------------
|
||||
// File: SoundCommon.cpp
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkId=248929
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615561
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
#include "pch.h"
|
||||
#include "SoundCommon.h"
|
||||
|
||||
using namespace DirectX;
|
||||
|
||||
|
||||
namespace
|
||||
{
|
||||
template <typename T> WORD ChannelsSpecifiedInMask(T x) noexcept
|
||||
{
|
||||
WORD bitCount = 0;
|
||||
while (x) { ++bitCount; x &= (x - 1); }
|
||||
return bitCount;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//======================================================================================
|
||||
// Wave format utilities
|
||||
//======================================================================================
|
||||
|
||||
bool DirectX::IsValid(_In_ const WAVEFORMATEX* wfx) noexcept
|
||||
{
|
||||
if (!wfx)
|
||||
return false;
|
||||
|
||||
if (!wfx->nChannels)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format must have at least 1 channel\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfx->nChannels > XAUDIO2_MAX_AUDIO_CHANNELS)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format must have less than %u channels (%u)\n", XAUDIO2_MAX_AUDIO_CHANNELS, wfx->nChannels);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!wfx->nSamplesPerSec)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format cannot have a sample rate of 0\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
if ((wfx->nSamplesPerSec < XAUDIO2_MIN_SAMPLE_RATE)
|
||||
|| (wfx->nSamplesPerSec > XAUDIO2_MAX_SAMPLE_RATE))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format channel count must be in range %u..%u (%u)\n",
|
||||
XAUDIO2_MIN_SAMPLE_RATE, XAUDIO2_MAX_SAMPLE_RATE, wfx->nSamplesPerSec);
|
||||
return false;
|
||||
}
|
||||
|
||||
switch (wfx->wFormatTag)
|
||||
{
|
||||
case WAVE_FORMAT_PCM:
|
||||
|
||||
switch (wfx->wBitsPerSample)
|
||||
{
|
||||
case 8:
|
||||
case 16:
|
||||
case 24:
|
||||
case 32:
|
||||
break;
|
||||
|
||||
default:
|
||||
DebugTrace("ERROR: Wave format integer PCM must have 8, 16, 24, or 32 bits per sample (%u)\n", wfx->wBitsPerSample);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfx->nBlockAlign != (wfx->nChannels * wfx->wBitsPerSample / 8))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format integer PCM - nBlockAlign (%u) != nChannels (%u) * wBitsPerSample (%u) / 8\n",
|
||||
wfx->nBlockAlign, wfx->nChannels, wfx->wBitsPerSample);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfx->nAvgBytesPerSec != (wfx->nSamplesPerSec * wfx->nBlockAlign))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format integer PCM - nAvgBytesPerSec (%lu) != nSamplesPerSec (%lu) * nBlockAlign (%u)\n",
|
||||
wfx->nAvgBytesPerSec, wfx->nSamplesPerSec, wfx->nBlockAlign);
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
|
||||
case WAVE_FORMAT_IEEE_FLOAT:
|
||||
|
||||
if (wfx->wBitsPerSample != 32)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format float PCM must have 32-bits per sample (%u)\n", wfx->wBitsPerSample);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfx->nBlockAlign != (wfx->nChannels * wfx->wBitsPerSample / 8))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format float PCM - nBlockAlign (%u) != nChannels (%u) * wBitsPerSample (%u) / 8\n",
|
||||
wfx->nBlockAlign, wfx->nChannels, wfx->wBitsPerSample);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfx->nAvgBytesPerSec != (wfx->nSamplesPerSec * wfx->nBlockAlign))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format float PCM - nAvgBytesPerSec (%lu) != nSamplesPerSec (%lu) * nBlockAlign (%u)\n",
|
||||
wfx->nAvgBytesPerSec, wfx->nSamplesPerSec, wfx->nBlockAlign);
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
|
||||
case WAVE_FORMAT_ADPCM:
|
||||
|
||||
if ((wfx->nChannels != 1) && (wfx->nChannels != 2))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format ADPCM must have 1 or 2 channels (%u)\n", wfx->nChannels);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfx->wBitsPerSample != 4 /*MSADPCM_BITS_PER_SAMPLE*/)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format ADPCM must have 4 bits per sample (%u)\n", wfx->wBitsPerSample);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfx->cbSize != 32 /*MSADPCM_FORMAT_EXTRA_BYTES*/)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format ADPCM must have cbSize = 32 (%u)\n", wfx->cbSize);
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
auto wfadpcm = reinterpret_cast<const ADPCMWAVEFORMAT*>(wfx);
|
||||
|
||||
if (wfadpcm->wNumCoef != 7 /*MSADPCM_NUM_COEFFICIENTS*/)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format ADPCM must have 7 coefficients (%u)\n", wfadpcm->wNumCoef);
|
||||
return false;
|
||||
}
|
||||
|
||||
bool valid = true;
|
||||
for (int j = 0; j < 7 /*MSADPCM_NUM_COEFFICIENTS*/; ++j)
|
||||
{
|
||||
// Microsoft ADPCM standard encoding coefficients
|
||||
static const short g_pAdpcmCoefficients1[] = { 256, 512, 0, 192, 240, 460, 392 };
|
||||
static const short g_pAdpcmCoefficients2[] = { 0, -256, 0, 64, 0, -208, -232 };
|
||||
|
||||
if (wfadpcm->aCoef[j].iCoef1 != g_pAdpcmCoefficients1[j]
|
||||
|| wfadpcm->aCoef[j].iCoef2 != g_pAdpcmCoefficients2[j])
|
||||
{
|
||||
valid = false;
|
||||
}
|
||||
}
|
||||
|
||||
if (!valid)
|
||||
{
|
||||
DebugTrace("ERROR: Wave formt ADPCM found non-standard coefficients\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
if ((wfadpcm->wSamplesPerBlock < 4 /*MSADPCM_MIN_SAMPLES_PER_BLOCK*/)
|
||||
|| (wfadpcm->wSamplesPerBlock > 64000 /*MSADPCM_MAX_SAMPLES_PER_BLOCK*/))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format ADPCM wSamplesPerBlock must be 4..64000 (%u)\n", wfadpcm->wSamplesPerBlock);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfadpcm->wfx.nChannels == 1 && (wfadpcm->wSamplesPerBlock % 2))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format ADPCM mono files must have even wSamplesPerBlock\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
int nHeaderBytes = 7 /*MSADPCM_HEADER_LENGTH*/ * wfx->nChannels;
|
||||
int nBitsPerFrame = 4 /*MSADPCM_BITS_PER_SAMPLE*/ * wfx->nChannels;
|
||||
int nPcmFramesPerBlock = (wfx->nBlockAlign - nHeaderBytes) * 8 / nBitsPerFrame + 2;
|
||||
|
||||
if (wfadpcm->wSamplesPerBlock != nPcmFramesPerBlock)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format ADPCM %u-channel with nBlockAlign = %u must have wSamplesPerBlock = %d (%u)\n",
|
||||
wfx->nChannels, wfx->nBlockAlign, nPcmFramesPerBlock, wfadpcm->wSamplesPerBlock);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
||||
case WAVE_FORMAT_WMAUDIO2:
|
||||
case WAVE_FORMAT_WMAUDIO3:
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
|
||||
if (wfx->wBitsPerSample != 16)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format xWMA only supports 16-bit data\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!wfx->nBlockAlign)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format xWMA must have a non-zero nBlockAlign\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!wfx->nAvgBytesPerSec)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format xWMA must have a non-zero nAvgBytesPerSec\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
|
||||
#else
|
||||
DebugTrace("ERROR: Wave format xWMA not supported by this version of DirectXTK for Audio\n");
|
||||
return false;
|
||||
#endif
|
||||
|
||||
case 0x166 /* WAVE_FORMAT_XMA2 */:
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
|
||||
static_assert(WAVE_FORMAT_XMA2 == 0x166, "Unrecognized XMA2 tag");
|
||||
|
||||
if (wfx->nBlockAlign != wfx->nChannels * XMA_OUTPUT_SAMPLE_BYTES)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format XMA2 - nBlockAlign (%u) != nChannels(%u) * %u\n", wfx->nBlockAlign, wfx->nChannels, XMA_OUTPUT_SAMPLE_BYTES);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfx->wBitsPerSample != XMA_OUTPUT_SAMPLE_BITS)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format XMA2 wBitsPerSample (%u) should be %u\n", wfx->wBitsPerSample, XMA_OUTPUT_SAMPLE_BITS);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfx->cbSize != (sizeof(XMA2WAVEFORMATEX) - sizeof(WAVEFORMATEX)))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format XMA2 - cbSize must be %zu (%u)\n", (sizeof(XMA2WAVEFORMATEX) - sizeof(WAVEFORMATEX)), wfx->cbSize);
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
auto xmaFmt = reinterpret_cast<const XMA2WAVEFORMATEX*>(wfx);
|
||||
|
||||
if (xmaFmt->EncoderVersion < 3)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format XMA2 encoder version (%u) - 3 or higher is required\n", xmaFmt->EncoderVersion);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!xmaFmt->BlockCount)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format XMA2 BlockCount must be non-zero\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!xmaFmt->BytesPerBlock || (xmaFmt->BytesPerBlock > XMA_READBUFFER_MAX_BYTES))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format XMA2 BytesPerBlock (%u) is invalid\n", xmaFmt->BytesPerBlock);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (xmaFmt->ChannelMask)
|
||||
{
|
||||
auto channelBits = ChannelsSpecifiedInMask(xmaFmt->ChannelMask);
|
||||
if (channelBits != wfx->nChannels)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format XMA2 - nChannels=%u but ChannelMask (%08X) has %u bits set\n",
|
||||
xmaFmt->ChannelMask, wfx->nChannels, channelBits);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (xmaFmt->NumStreams != ((wfx->nChannels + 1) / 2))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format XMA2 - NumStreams (%u) != ( nChannels(%u) + 1 ) / 2\n",
|
||||
xmaFmt->NumStreams, wfx->nChannels);
|
||||
return false;
|
||||
}
|
||||
|
||||
if ((xmaFmt->PlayBegin + xmaFmt->PlayLength) > xmaFmt->SamplesEncoded)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format XMA2 play region too large (%u + %u > %u)\n",
|
||||
xmaFmt->PlayBegin, xmaFmt->PlayLength, xmaFmt->SamplesEncoded);
|
||||
return false;
|
||||
}
|
||||
|
||||
if ((xmaFmt->LoopBegin + xmaFmt->LoopLength) > xmaFmt->SamplesEncoded)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format XMA2 loop region too large (%u + %u > %u)\n",
|
||||
xmaFmt->LoopBegin, xmaFmt->LoopLength, xmaFmt->SamplesEncoded);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
||||
#else
|
||||
DebugTrace("ERROR: Wave format XMA2 not supported by this version of DirectXTK for Audio\n");
|
||||
return false;
|
||||
#endif
|
||||
|
||||
case WAVE_FORMAT_EXTENSIBLE:
|
||||
if (wfx->cbSize < (sizeof(WAVEFORMATEXTENSIBLE) - sizeof(WAVEFORMATEX)))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format WAVE_FORMAT_EXTENSIBLE - cbSize must be %zu (%u)\n",
|
||||
(sizeof(WAVEFORMATEXTENSIBLE) - sizeof(WAVEFORMATEX)), wfx->cbSize);
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
static const GUID s_wfexBase = { 0x00000000, 0x0000, 0x0010, { 0x80, 0x00, 0x00, 0xAA, 0x00, 0x38, 0x9B, 0x71 } };
|
||||
|
||||
auto wfex = reinterpret_cast<const WAVEFORMATEXTENSIBLE*>(wfx);
|
||||
|
||||
if (memcmp(reinterpret_cast<const BYTE*>(&wfex->SubFormat) + sizeof(DWORD),
|
||||
reinterpret_cast<const BYTE*>(&s_wfexBase) + sizeof(DWORD), sizeof(GUID) - sizeof(DWORD)) != 0)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format WAVEFORMATEXTENSIBLE encountered with unknown GUID ({%8.8lX-%4.4X-%4.4X-%2.2X%2.2X-%2.2X%2.2X%2.2X%2.2X%2.2X%2.2X})\n",
|
||||
wfex->SubFormat.Data1, wfex->SubFormat.Data2, wfex->SubFormat.Data3,
|
||||
wfex->SubFormat.Data4[0], wfex->SubFormat.Data4[1], wfex->SubFormat.Data4[2], wfex->SubFormat.Data4[3],
|
||||
wfex->SubFormat.Data4[4], wfex->SubFormat.Data4[5], wfex->SubFormat.Data4[6], wfex->SubFormat.Data4[7]);
|
||||
return false;
|
||||
}
|
||||
|
||||
switch (wfex->SubFormat.Data1)
|
||||
{
|
||||
case WAVE_FORMAT_PCM:
|
||||
|
||||
switch (wfx->wBitsPerSample)
|
||||
{
|
||||
case 8:
|
||||
case 16:
|
||||
case 24:
|
||||
case 32:
|
||||
break;
|
||||
|
||||
default:
|
||||
DebugTrace("ERROR: Wave format integer PCM must have 8, 16, 24, or 32 bits per sample (%u)\n",
|
||||
wfx->wBitsPerSample);
|
||||
return false;
|
||||
}
|
||||
|
||||
switch (wfex->Samples.wValidBitsPerSample)
|
||||
{
|
||||
case 0:
|
||||
case 8:
|
||||
case 16:
|
||||
case 20:
|
||||
case 24:
|
||||
case 32:
|
||||
break;
|
||||
|
||||
default:
|
||||
DebugTrace("ERROR: Wave format integer PCM must have 8, 16, 20, 24, or 32 valid bits per sample (%u)\n",
|
||||
wfex->Samples.wValidBitsPerSample);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfex->Samples.wValidBitsPerSample
|
||||
&& (wfex->Samples.wValidBitsPerSample > wfx->wBitsPerSample))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format ingter PCM wValidBitsPerSample (%u) is greater than wBitsPerSample (%u)\n",
|
||||
wfex->Samples.wValidBitsPerSample, wfx->wBitsPerSample);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfx->nBlockAlign != (wfx->nChannels * wfx->wBitsPerSample / 8))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format integer PCM - nBlockAlign (%u) != nChannels (%u) * wBitsPerSample (%u) / 8\n",
|
||||
wfx->nBlockAlign, wfx->nChannels, wfx->wBitsPerSample);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfx->nAvgBytesPerSec != (wfx->nSamplesPerSec * wfx->nBlockAlign))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format integer PCM - nAvgBytesPerSec (%lu) != nSamplesPerSec (%lu) * nBlockAlign (%u)\n",
|
||||
wfx->nAvgBytesPerSec, wfx->nSamplesPerSec, wfx->nBlockAlign);
|
||||
return false;
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case WAVE_FORMAT_IEEE_FLOAT:
|
||||
|
||||
if (wfx->wBitsPerSample != 32)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format float PCM must have 32-bits per sample (%u)\n", wfx->wBitsPerSample);
|
||||
return false;
|
||||
}
|
||||
|
||||
switch (wfex->Samples.wValidBitsPerSample)
|
||||
{
|
||||
case 0:
|
||||
case 32:
|
||||
break;
|
||||
|
||||
default:
|
||||
DebugTrace("ERROR: Wave format float PCM must have 32 valid bits per sample (%u)\n",
|
||||
wfex->Samples.wValidBitsPerSample);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfx->nBlockAlign != (wfx->nChannels * wfx->wBitsPerSample / 8))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format float PCM - nBlockAlign (%u) != nChannels (%u) * wBitsPerSample (%u) / 8\n",
|
||||
wfx->nBlockAlign, wfx->nChannels, wfx->wBitsPerSample);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfx->nAvgBytesPerSec != (wfx->nSamplesPerSec * wfx->nBlockAlign))
|
||||
{
|
||||
DebugTrace("ERROR: Wave format float PCM - nAvgBytesPerSec (%lu) != nSamplesPerSec (%lu) * nBlockAlign (%u)\n",
|
||||
wfx->nAvgBytesPerSec, wfx->nSamplesPerSec, wfx->nBlockAlign);
|
||||
return false;
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case WAVE_FORMAT_ADPCM:
|
||||
DebugTrace("ERROR: Wave format ADPCM is not supported as a WAVEFORMATEXTENSIBLE\n");
|
||||
return false;
|
||||
|
||||
case WAVE_FORMAT_WMAUDIO2:
|
||||
case WAVE_FORMAT_WMAUDIO3:
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
|
||||
if (wfx->wBitsPerSample != 16)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format xWMA only supports 16-bit data\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!wfx->nBlockAlign)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format xWMA must have a non-zero nBlockAlign\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!wfx->nAvgBytesPerSec)
|
||||
{
|
||||
DebugTrace("ERROR: Wave format xWMA must have a non-zero nAvgBytesPerSec\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
#else
|
||||
DebugTrace("ERROR: Wave format xWMA not supported by this version of DirectXTK for Audio\n");
|
||||
return false;
|
||||
#endif
|
||||
|
||||
case 0x166 /* WAVE_FORMAT_XMA2 */:
|
||||
DebugTrace("ERROR: Wave format XMA2 is not supported as a WAVEFORMATEXTENSIBLE\n");
|
||||
return false;
|
||||
|
||||
default:
|
||||
DebugTrace("ERROR: Unknown WAVEFORMATEXTENSIBLE format tag (%u)\n", wfex->SubFormat.Data1);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (wfex->dwChannelMask)
|
||||
{
|
||||
auto channelBits = ChannelsSpecifiedInMask(wfex->dwChannelMask);
|
||||
if (channelBits != wfx->nChannels)
|
||||
{
|
||||
DebugTrace("ERROR: WAVEFORMATEXTENSIBLE: nChannels=%u but ChannelMask has %u bits set\n",
|
||||
wfx->nChannels, channelBits);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
default:
|
||||
DebugTrace("ERROR: Unknown WAVEFORMATEX format tag (%u)\n", wfx->wFormatTag);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
uint32_t DirectX::GetDefaultChannelMask(int channels) noexcept
|
||||
{
|
||||
switch (channels)
|
||||
{
|
||||
case 1: return SPEAKER_MONO;
|
||||
case 2: return SPEAKER_STEREO;
|
||||
case 3: return SPEAKER_2POINT1;
|
||||
case 4: return SPEAKER_QUAD;
|
||||
case 5: return SPEAKER_4POINT1;
|
||||
case 6: return SPEAKER_5POINT1;
|
||||
case 7: return SPEAKER_5POINT1 | SPEAKER_BACK_CENTER;
|
||||
case 8: return SPEAKER_7POINT1;
|
||||
default: return 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
void DirectX::CreateIntegerPCM(WAVEFORMATEX* wfx, int sampleRate, int channels, int sampleBits) noexcept
|
||||
{
|
||||
int blockAlign = channels * sampleBits / 8;
|
||||
|
||||
wfx->wFormatTag = WAVE_FORMAT_PCM;
|
||||
wfx->nChannels = static_cast<WORD>(channels);
|
||||
wfx->nSamplesPerSec = static_cast<DWORD>(sampleRate);
|
||||
wfx->nAvgBytesPerSec = static_cast<DWORD>(blockAlign * sampleRate);
|
||||
wfx->nBlockAlign = static_cast<WORD>(blockAlign);
|
||||
wfx->wBitsPerSample = static_cast<WORD>(sampleBits);
|
||||
wfx->cbSize = 0;
|
||||
|
||||
assert(IsValid(wfx));
|
||||
}
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
void DirectX::CreateFloatPCM(WAVEFORMATEX* wfx, int sampleRate, int channels) noexcept
|
||||
{
|
||||
int blockAlign = channels * 4;
|
||||
|
||||
wfx->wFormatTag = WAVE_FORMAT_IEEE_FLOAT;
|
||||
wfx->nChannels = static_cast<WORD>(channels);
|
||||
wfx->nSamplesPerSec = static_cast<DWORD>(sampleRate);
|
||||
wfx->nAvgBytesPerSec = static_cast<DWORD>(blockAlign * sampleRate);
|
||||
wfx->nBlockAlign = static_cast<WORD>(blockAlign);
|
||||
wfx->wBitsPerSample = 32;
|
||||
wfx->cbSize = 0;
|
||||
|
||||
assert(IsValid(wfx));
|
||||
}
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
void DirectX::CreateADPCM(WAVEFORMATEX* wfx, size_t wfxSize, int sampleRate, int channels, int samplesPerBlock) noexcept(false)
|
||||
{
|
||||
if (wfxSize < (sizeof(WAVEFORMATEX) + 32 /*MSADPCM_FORMAT_EXTRA_BYTES*/))
|
||||
{
|
||||
DebugTrace("CreateADPCM needs at least %zu bytes for the result\n",
|
||||
(sizeof(WAVEFORMATEX) + 32 /*MSADPCM_FORMAT_EXTRA_BYTES*/));
|
||||
throw std::invalid_argument("ADPCMWAVEFORMAT");
|
||||
}
|
||||
|
||||
if (!samplesPerBlock)
|
||||
{
|
||||
DebugTrace("CreateADPCM needs a non-zero samples per block count\n");
|
||||
throw std::invalid_argument("ADPCMWAVEFORMAT");
|
||||
}
|
||||
|
||||
int blockAlign = (7 /*MSADPCM_HEADER_LENGTH*/) * channels
|
||||
+ (samplesPerBlock - 2) * (4 /* MSADPCM_BITS_PER_SAMPLE */) * channels / 8;
|
||||
|
||||
wfx->wFormatTag = WAVE_FORMAT_ADPCM;
|
||||
wfx->nChannels = static_cast<WORD>(channels);
|
||||
wfx->nSamplesPerSec = static_cast<DWORD>(sampleRate);
|
||||
wfx->nAvgBytesPerSec = static_cast<DWORD>(blockAlign * sampleRate / samplesPerBlock);
|
||||
wfx->nBlockAlign = static_cast<WORD>(blockAlign);
|
||||
wfx->wBitsPerSample = 4 /* MSADPCM_BITS_PER_SAMPLE */;
|
||||
wfx->cbSize = 32 /*MSADPCM_FORMAT_EXTRA_BYTES*/;
|
||||
|
||||
auto adpcm = reinterpret_cast<ADPCMWAVEFORMAT*>(wfx);
|
||||
adpcm->wSamplesPerBlock = static_cast<WORD>(samplesPerBlock);
|
||||
adpcm->wNumCoef = 7 /* MSADPCM_NUM_COEFFICIENTS */;
|
||||
|
||||
static ADPCMCOEFSET aCoef[7] = { { 256, 0}, {512, -256}, {0,0}, {192,64}, {240,0}, {460, -208}, {392,-232} };
|
||||
memcpy(&adpcm->aCoef, aCoef, sizeof(aCoef));
|
||||
|
||||
assert(IsValid(wfx));
|
||||
}
|
||||
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
_Use_decl_annotations_
|
||||
void DirectX::CreateXWMA(WAVEFORMATEX* wfx, int sampleRate, int channels, int blockAlign, int avgBytes, bool wma3) noexcept
|
||||
{
|
||||
wfx->wFormatTag = static_cast<WORD>((wma3) ? WAVE_FORMAT_WMAUDIO3 : WAVE_FORMAT_WMAUDIO2);
|
||||
wfx->nChannels = static_cast<WORD>(channels);
|
||||
wfx->nSamplesPerSec = static_cast<DWORD>(sampleRate);
|
||||
wfx->nAvgBytesPerSec = static_cast<DWORD>(avgBytes);
|
||||
wfx->nBlockAlign = static_cast<WORD>(blockAlign);
|
||||
wfx->wBitsPerSample = 16;
|
||||
wfx->cbSize = 0;
|
||||
|
||||
assert(IsValid(wfx));
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
_Use_decl_annotations_
|
||||
void DirectX::CreateXMA2(WAVEFORMATEX* wfx, size_t wfxSize, int sampleRate, int channels, int bytesPerBlock, int blockCount, int samplesEncoded) noexcept(false)
|
||||
{
|
||||
if (wfxSize < sizeof(XMA2WAVEFORMATEX))
|
||||
{
|
||||
DebugTrace("XMA2 needs at least %zu bytes for the result\n", sizeof(XMA2WAVEFORMATEX));
|
||||
throw std::invalid_argument("XMA2WAVEFORMATEX");
|
||||
}
|
||||
|
||||
if ((bytesPerBlock < 1) || (bytesPerBlock > int(XMA_READBUFFER_MAX_BYTES)))
|
||||
{
|
||||
DebugTrace("XMA2 needs a valid bytes per block\n");
|
||||
throw std::invalid_argument("XMA2WAVEFORMATEX");
|
||||
}
|
||||
|
||||
int blockAlign = (channels * (16 /*XMA_OUTPUT_SAMPLE_BITS*/) / 8);
|
||||
|
||||
wfx->wFormatTag = WAVE_FORMAT_XMA2;
|
||||
wfx->nChannels = static_cast<WORD>(channels);
|
||||
wfx->nSamplesPerSec = static_cast<WORD>(sampleRate);
|
||||
wfx->nAvgBytesPerSec = static_cast<DWORD>(blockAlign * sampleRate);
|
||||
wfx->nBlockAlign = static_cast<WORD>(blockAlign);
|
||||
wfx->wBitsPerSample = 16 /* XMA_OUTPUT_SAMPLE_BITS */;
|
||||
wfx->cbSize = sizeof(XMA2WAVEFORMATEX) - sizeof(WAVEFORMATEX);
|
||||
|
||||
auto xmaFmt = reinterpret_cast<XMA2WAVEFORMATEX*>(wfx);
|
||||
|
||||
xmaFmt->NumStreams = static_cast<WORD>((channels + 1) / 2);
|
||||
|
||||
xmaFmt->ChannelMask = GetDefaultChannelMask(channels);
|
||||
|
||||
xmaFmt->SamplesEncoded = static_cast<DWORD>(samplesEncoded);
|
||||
xmaFmt->BytesPerBlock = static_cast<DWORD>(bytesPerBlock);
|
||||
xmaFmt->PlayBegin = xmaFmt->PlayLength =
|
||||
xmaFmt->LoopBegin = xmaFmt->LoopLength = xmaFmt->LoopCount = 0;
|
||||
xmaFmt->EncoderVersion = 4 /* XMAENCODER_VERSION_XMA2 */;
|
||||
xmaFmt->BlockCount = static_cast<WORD>(blockCount);
|
||||
|
||||
assert(IsValid(wfx));
|
||||
}
|
||||
#endif // XMA2
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
bool DirectX::ComputePan(float pan, unsigned int channels, float* matrix) noexcept
|
||||
{
|
||||
memset(matrix, 0, sizeof(float) * 16);
|
||||
|
||||
if (channels == 1)
|
||||
{
|
||||
// Mono panning
|
||||
float left = (pan >= 0) ? (1.f - pan) : 1.f;
|
||||
left = std::min<float>(1.f, left);
|
||||
left = std::max<float>(-1.f, left);
|
||||
|
||||
float right = (pan <= 0) ? (-pan - 1.f) : 1.f;
|
||||
right = std::min<float>(1.f, right);
|
||||
right = std::max<float>(-1.f, right);
|
||||
|
||||
matrix[0] = left;
|
||||
matrix[1] = right;
|
||||
}
|
||||
else if (channels == 2)
|
||||
{
|
||||
// Stereo panning
|
||||
if (-1.f <= pan && pan <= 0.f)
|
||||
{
|
||||
matrix[0] = .5f * pan + 1.f; // .5 when pan is -1, 1 when pan is 0
|
||||
matrix[1] = .5f * -pan; // .5 when pan is -1, 0 when pan is 0
|
||||
matrix[2] = 0.f; // 0 when pan is -1, 0 when pan is 0
|
||||
matrix[3] = pan + 1.f; // 0 when pan is -1, 1 when pan is 0
|
||||
}
|
||||
else
|
||||
{
|
||||
matrix[0] = -pan + 1.f; // 1 when pan is 0, 0 when pan is 1
|
||||
matrix[1] = 0.f; // 0 when pan is 0, 0 when pan is 1
|
||||
matrix[2] = .5f * pan; // 0 when pan is 0, .5f when pan is 1
|
||||
matrix[3] = .5f * -pan + 1.f; // 1 when pan is 0. .5f when pan is 1
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (pan != 0.f)
|
||||
{
|
||||
DebugTrace("WARNING: Only supports panning on mono or stereo source data, ignored\n");
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
//======================================================================================
|
||||
// SoundEffectInstanceBase
|
||||
//======================================================================================
|
||||
|
||||
void SoundEffectInstanceBase::SetPan(float pan)
|
||||
{
|
||||
assert(pan >= -1.f && pan <= 1.f);
|
||||
|
||||
mPan = pan;
|
||||
|
||||
if (!voice)
|
||||
return;
|
||||
|
||||
float matrix[16];
|
||||
if (ComputePan(pan, mDSPSettings.SrcChannelCount, matrix))
|
||||
{
|
||||
HRESULT hr = voice->SetOutputMatrix(nullptr, mDSPSettings.SrcChannelCount, mDSPSettings.DstChannelCount, matrix);
|
||||
ThrowIfFailed(hr);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void SoundEffectInstanceBase::Apply3D(const AudioListener& listener, const AudioEmitter& emitter, bool rhcoords)
|
||||
{
|
||||
if (!voice)
|
||||
return;
|
||||
|
||||
if (!(mFlags & SoundEffectInstance_Use3D))
|
||||
{
|
||||
DebugTrace("ERROR: Apply3D called for an instance created without SoundEffectInstance_Use3D set\n");
|
||||
throw std::exception("Apply3D");
|
||||
}
|
||||
|
||||
DWORD dwCalcFlags = X3DAUDIO_CALCULATE_MATRIX | X3DAUDIO_CALCULATE_DOPPLER | X3DAUDIO_CALCULATE_LPF_DIRECT;
|
||||
|
||||
if (mFlags & SoundEffectInstance_UseRedirectLFE)
|
||||
{
|
||||
// On devices with an LFE channel, allow the mono source data to be routed to the LFE destination channel.
|
||||
dwCalcFlags |= X3DAUDIO_CALCULATE_REDIRECT_TO_LFE;
|
||||
}
|
||||
|
||||
auto reverb = mReverbVoice;
|
||||
if (reverb)
|
||||
{
|
||||
dwCalcFlags |= X3DAUDIO_CALCULATE_LPF_REVERB | X3DAUDIO_CALCULATE_REVERB;
|
||||
}
|
||||
|
||||
float matrix[XAUDIO2_MAX_AUDIO_CHANNELS * 8] = {};
|
||||
assert(mDSPSettings.SrcChannelCount <= XAUDIO2_MAX_AUDIO_CHANNELS);
|
||||
assert(mDSPSettings.DstChannelCount <= 8);
|
||||
mDSPSettings.pMatrixCoefficients = matrix;
|
||||
|
||||
assert(engine != nullptr);
|
||||
if (rhcoords)
|
||||
{
|
||||
X3DAUDIO_EMITTER lhEmitter;
|
||||
memcpy(&lhEmitter, &emitter, sizeof(X3DAUDIO_EMITTER));
|
||||
lhEmitter.OrientFront.z = -emitter.OrientFront.z;
|
||||
lhEmitter.OrientTop.z = -emitter.OrientTop.z;
|
||||
lhEmitter.Position.z = -emitter.Position.z;
|
||||
lhEmitter.Velocity.z = -emitter.Velocity.z;
|
||||
|
||||
X3DAUDIO_LISTENER lhListener;
|
||||
memcpy(&lhListener, &listener, sizeof(X3DAUDIO_LISTENER));
|
||||
lhListener.OrientFront.z = -listener.OrientFront.z;
|
||||
lhListener.OrientTop.z = -listener.OrientTop.z;
|
||||
lhListener.Position.z = -listener.Position.z;
|
||||
lhListener.Velocity.z = -listener.Velocity.z;
|
||||
|
||||
X3DAudioCalculate(engine->Get3DHandle(), &lhListener, &lhEmitter, dwCalcFlags, &mDSPSettings);
|
||||
}
|
||||
else
|
||||
{
|
||||
X3DAudioCalculate(engine->Get3DHandle(), &listener, &emitter, dwCalcFlags, &mDSPSettings);
|
||||
}
|
||||
|
||||
mDSPSettings.pMatrixCoefficients = nullptr;
|
||||
|
||||
(void)voice->SetFrequencyRatio(mFreqRatio * mDSPSettings.DopplerFactor);
|
||||
|
||||
auto direct = mDirectVoice;
|
||||
assert(direct != nullptr);
|
||||
(void)voice->SetOutputMatrix(direct, mDSPSettings.SrcChannelCount, mDSPSettings.DstChannelCount, matrix);
|
||||
|
||||
if (reverb)
|
||||
{
|
||||
for (size_t j = 0; (j < mDSPSettings.SrcChannelCount) && (j < XAUDIO2_MAX_AUDIO_CHANNELS); ++j)
|
||||
{
|
||||
matrix[j] = mDSPSettings.ReverbLevel;
|
||||
}
|
||||
(void)voice->SetOutputMatrix(reverb, mDSPSettings.SrcChannelCount, 1, matrix);
|
||||
}
|
||||
|
||||
if (mFlags & SoundEffectInstance_ReverbUseFilters)
|
||||
{
|
||||
XAUDIO2_FILTER_PARAMETERS filterDirect = { LowPassFilter, 2.0f * sinf(X3DAUDIO_PI / 6.0f * mDSPSettings.LPFDirectCoefficient), 1.0f };
|
||||
// see XAudio2CutoffFrequencyToRadians() in XAudio2.h for more information on the formula used here
|
||||
(void)voice->SetOutputFilterParameters(direct, &filterDirect);
|
||||
|
||||
if (reverb)
|
||||
{
|
||||
XAUDIO2_FILTER_PARAMETERS filterReverb = { LowPassFilter, 2.0f * sinf(X3DAUDIO_PI / 6.0f * mDSPSettings.LPFReverbCoefficient), 1.0f };
|
||||
// see XAudio2CutoffFrequencyToRadians() in XAudio2.h for more information on the formula used here
|
||||
(void)voice->SetOutputFilterParameters(reverb, &filterReverb);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
383
Sdk/External/DirectXTK/Audio/SoundCommon.h
vendored
Normal file
383
Sdk/External/DirectXTK/Audio/SoundCommon.h
vendored
Normal file
@ -0,0 +1,383 @@
|
||||
//--------------------------------------------------------------------------------------
|
||||
// File: SoundCommon.h
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkId=248929
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615561
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "Audio.h"
|
||||
#include "PlatformHelpers.h"
|
||||
|
||||
#ifdef USING_XAUDIO2_9
|
||||
#define DIRECTX_ENABLE_XWMA
|
||||
#endif
|
||||
|
||||
#if (defined(_XBOX_ONE) && defined(_TITLE)) || defined(_GAMING_XBOX)
|
||||
#define DIRECTX_ENABLE_XMA2
|
||||
#endif
|
||||
|
||||
#if defined(DIRECTX_ENABLE_XWMA) || defined(DIRECTX_ENABLE_XMA2)
|
||||
#define DIRECTX_ENABLE_SEEK_TABLES
|
||||
#endif
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
// Helper for getting a format tag from a WAVEFORMATEX
|
||||
inline uint32_t GetFormatTag(const WAVEFORMATEX* wfx) noexcept
|
||||
{
|
||||
if (wfx->wFormatTag == WAVE_FORMAT_EXTENSIBLE)
|
||||
{
|
||||
if (wfx->cbSize < (sizeof(WAVEFORMATEXTENSIBLE) - sizeof(WAVEFORMATEX)))
|
||||
return 0;
|
||||
|
||||
static const GUID s_wfexBase = { 0x00000000, 0x0000, 0x0010, { 0x80, 0x00, 0x00, 0xAA, 0x00, 0x38, 0x9B, 0x71 } };
|
||||
|
||||
auto wfex = reinterpret_cast<const WAVEFORMATEXTENSIBLE*>(wfx);
|
||||
|
||||
if (memcmp(reinterpret_cast<const BYTE*>(&wfex->SubFormat) + sizeof(DWORD),
|
||||
reinterpret_cast<const BYTE*>(&s_wfexBase) + sizeof(DWORD), sizeof(GUID) - sizeof(DWORD)) != 0)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
return wfex->SubFormat.Data1;
|
||||
}
|
||||
else
|
||||
{
|
||||
return wfx->wFormatTag;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Helper for validating wave format structure
|
||||
bool IsValid(_In_ const WAVEFORMATEX* wfx) noexcept;
|
||||
|
||||
|
||||
// Helper for getting a default channel mask from channels
|
||||
uint32_t GetDefaultChannelMask(int channels) noexcept;
|
||||
|
||||
|
||||
// Helpers for creating various wave format structures
|
||||
void CreateIntegerPCM(_Out_ WAVEFORMATEX* wfx, int sampleRate, int channels, int sampleBits) noexcept;
|
||||
void CreateFloatPCM(_Out_ WAVEFORMATEX* wfx, int sampleRate, int channels) noexcept;
|
||||
void CreateADPCM(_Out_writes_bytes_(wfxSize) WAVEFORMATEX* wfx, size_t wfxSize, int sampleRate, int channels, int samplesPerBlock) noexcept(false);
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
void CreateXWMA(_Out_ WAVEFORMATEX* wfx, int sampleRate, int channels, int blockAlign, int avgBytes, bool wma3) noexcept;
|
||||
#endif
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
void CreateXMA2(_Out_writes_bytes_(wfxSize) WAVEFORMATEX* wfx, size_t wfxSize, int sampleRate, int channels, int bytesPerBlock, int blockCount, int samplesEncoded) noexcept(false);
|
||||
#endif
|
||||
|
||||
// Helper for computing pan volume matrix
|
||||
bool ComputePan(float pan, unsigned int channels, _Out_writes_(16) float* matrix) noexcept;
|
||||
|
||||
// Helper class for implementing SoundEffectInstance
|
||||
class SoundEffectInstanceBase
|
||||
{
|
||||
public:
|
||||
SoundEffectInstanceBase() noexcept :
|
||||
voice(nullptr),
|
||||
state(STOPPED),
|
||||
engine(nullptr),
|
||||
mVolume(1.f),
|
||||
mPitch(0.f),
|
||||
mFreqRatio(1.f),
|
||||
mPan(0.f),
|
||||
mFlags(SoundEffectInstance_Default),
|
||||
mDirectVoice(nullptr),
|
||||
mReverbVoice(nullptr),
|
||||
mDSPSettings{}
|
||||
{
|
||||
}
|
||||
|
||||
SoundEffectInstanceBase(SoundEffectInstanceBase&&) = default;
|
||||
SoundEffectInstanceBase& operator= (SoundEffectInstanceBase&&) = default;
|
||||
|
||||
SoundEffectInstanceBase(SoundEffectInstanceBase const&) = delete;
|
||||
SoundEffectInstanceBase& operator= (SoundEffectInstanceBase const&) = delete;
|
||||
|
||||
~SoundEffectInstanceBase()
|
||||
{
|
||||
assert(voice == nullptr);
|
||||
}
|
||||
|
||||
void Initialize(_In_ AudioEngine* eng, _In_ const WAVEFORMATEX* wfx, SOUND_EFFECT_INSTANCE_FLAGS flags) noexcept
|
||||
{
|
||||
assert(eng != nullptr);
|
||||
engine = eng;
|
||||
mDirectVoice = eng->GetMasterVoice();
|
||||
mReverbVoice = eng->GetReverbVoice();
|
||||
|
||||
if (eng->GetChannelMask() & SPEAKER_LOW_FREQUENCY)
|
||||
mFlags = flags | SoundEffectInstance_UseRedirectLFE;
|
||||
else
|
||||
mFlags = flags & ~SoundEffectInstance_UseRedirectLFE;
|
||||
|
||||
memset(&mDSPSettings, 0, sizeof(X3DAUDIO_DSP_SETTINGS));
|
||||
assert(wfx != nullptr);
|
||||
mDSPSettings.SrcChannelCount = wfx->nChannels;
|
||||
mDSPSettings.DstChannelCount = eng->GetOutputChannels();
|
||||
}
|
||||
|
||||
void AllocateVoice(_In_ const WAVEFORMATEX* wfx)
|
||||
{
|
||||
if (voice)
|
||||
return;
|
||||
|
||||
assert(engine != nullptr);
|
||||
engine->AllocateVoice(wfx, mFlags, false, &voice);
|
||||
}
|
||||
|
||||
void DestroyVoice() noexcept
|
||||
{
|
||||
if (voice)
|
||||
{
|
||||
assert(engine != nullptr);
|
||||
engine->DestroyVoice(voice);
|
||||
voice = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
bool Play() // Returns true if STOPPED -> PLAYING
|
||||
{
|
||||
if (voice)
|
||||
{
|
||||
if (state == PAUSED)
|
||||
{
|
||||
HRESULT hr = voice->Start(0);
|
||||
ThrowIfFailed(hr);
|
||||
state = PLAYING;
|
||||
}
|
||||
else if (state != PLAYING)
|
||||
{
|
||||
if (mVolume != 1.f)
|
||||
{
|
||||
HRESULT hr = voice->SetVolume(mVolume);
|
||||
ThrowIfFailed(hr);
|
||||
}
|
||||
|
||||
if (mPitch != 0.f)
|
||||
{
|
||||
mFreqRatio = XAudio2SemitonesToFrequencyRatio(mPitch * 12.f);
|
||||
|
||||
HRESULT hr = voice->SetFrequencyRatio(mFreqRatio);
|
||||
ThrowIfFailed(hr);
|
||||
}
|
||||
|
||||
if (mPan != 0.f)
|
||||
{
|
||||
SetPan(mPan);
|
||||
}
|
||||
|
||||
HRESULT hr = voice->Start(0);
|
||||
ThrowIfFailed(hr);
|
||||
state = PLAYING;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
void Stop(bool immediate, bool& looped) noexcept
|
||||
{
|
||||
if (!voice)
|
||||
{
|
||||
state = STOPPED;
|
||||
return;
|
||||
}
|
||||
|
||||
if (immediate)
|
||||
{
|
||||
state = STOPPED;
|
||||
(void)voice->Stop(0);
|
||||
(void)voice->FlushSourceBuffers();
|
||||
}
|
||||
else if (looped)
|
||||
{
|
||||
looped = false;
|
||||
(void)voice->ExitLoop();
|
||||
}
|
||||
else
|
||||
{
|
||||
(void)voice->Stop(XAUDIO2_PLAY_TAILS);
|
||||
}
|
||||
}
|
||||
|
||||
void Pause() noexcept
|
||||
{
|
||||
if (voice && state == PLAYING)
|
||||
{
|
||||
state = PAUSED;
|
||||
|
||||
(void)voice->Stop(0);
|
||||
}
|
||||
}
|
||||
|
||||
void Resume()
|
||||
{
|
||||
if (voice && state == PAUSED)
|
||||
{
|
||||
HRESULT hr = voice->Start(0);
|
||||
ThrowIfFailed(hr);
|
||||
state = PLAYING;
|
||||
}
|
||||
}
|
||||
|
||||
void SetVolume(float volume)
|
||||
{
|
||||
assert(volume >= -XAUDIO2_MAX_VOLUME_LEVEL && volume <= XAUDIO2_MAX_VOLUME_LEVEL);
|
||||
|
||||
mVolume = volume;
|
||||
|
||||
if (voice)
|
||||
{
|
||||
HRESULT hr = voice->SetVolume(volume);
|
||||
ThrowIfFailed(hr);
|
||||
}
|
||||
}
|
||||
|
||||
void SetPitch(float pitch)
|
||||
{
|
||||
assert(pitch >= -1.f && pitch <= 1.f);
|
||||
|
||||
if ((mFlags & SoundEffectInstance_NoSetPitch) && pitch != 0.f)
|
||||
{
|
||||
DebugTrace("ERROR: Sound effect instance was created with the NoSetPitch flag\n");
|
||||
throw std::exception("SetPitch");
|
||||
}
|
||||
|
||||
mPitch = pitch;
|
||||
|
||||
if (voice)
|
||||
{
|
||||
mFreqRatio = XAudio2SemitonesToFrequencyRatio(mPitch * 12.f);
|
||||
|
||||
HRESULT hr = voice->SetFrequencyRatio(mFreqRatio);
|
||||
ThrowIfFailed(hr);
|
||||
}
|
||||
}
|
||||
|
||||
void SetPan(float pan);
|
||||
|
||||
void Apply3D(const AudioListener& listener, const AudioEmitter& emitter, bool rhcoords);
|
||||
|
||||
SoundState GetState(bool autostop) noexcept
|
||||
{
|
||||
if (autostop && voice && (state == PLAYING))
|
||||
{
|
||||
XAUDIO2_VOICE_STATE xstate;
|
||||
voice->GetState(&xstate, XAUDIO2_VOICE_NOSAMPLESPLAYED);
|
||||
|
||||
if (!xstate.BuffersQueued)
|
||||
{
|
||||
// Automatic stop if the buffer has finished playing
|
||||
(void)voice->Stop();
|
||||
state = STOPPED;
|
||||
}
|
||||
}
|
||||
|
||||
return state;
|
||||
}
|
||||
|
||||
int GetPendingBufferCount() const noexcept
|
||||
{
|
||||
if (!voice)
|
||||
return 0;
|
||||
|
||||
XAUDIO2_VOICE_STATE xstate;
|
||||
voice->GetState(&xstate, XAUDIO2_VOICE_NOSAMPLESPLAYED);
|
||||
return static_cast<int>(xstate.BuffersQueued);
|
||||
}
|
||||
|
||||
void OnCriticalError() noexcept
|
||||
{
|
||||
if (voice)
|
||||
{
|
||||
voice->DestroyVoice();
|
||||
voice = nullptr;
|
||||
}
|
||||
state = STOPPED;
|
||||
mDirectVoice = nullptr;
|
||||
mReverbVoice = nullptr;
|
||||
}
|
||||
|
||||
void OnReset() noexcept
|
||||
{
|
||||
assert(engine != nullptr);
|
||||
mDirectVoice = engine->GetMasterVoice();
|
||||
mReverbVoice = engine->GetReverbVoice();
|
||||
|
||||
if (engine->GetChannelMask() & SPEAKER_LOW_FREQUENCY)
|
||||
mFlags = mFlags | SoundEffectInstance_UseRedirectLFE;
|
||||
else
|
||||
mFlags = mFlags & ~SoundEffectInstance_UseRedirectLFE;
|
||||
|
||||
mDSPSettings.DstChannelCount = engine->GetOutputChannels();
|
||||
}
|
||||
|
||||
void OnDestroy() noexcept
|
||||
{
|
||||
if (voice)
|
||||
{
|
||||
(void)voice->Stop(0);
|
||||
(void)voice->FlushSourceBuffers();
|
||||
voice->DestroyVoice();
|
||||
voice = nullptr;
|
||||
}
|
||||
state = STOPPED;
|
||||
engine = nullptr;
|
||||
mDirectVoice = nullptr;
|
||||
mReverbVoice = nullptr;
|
||||
}
|
||||
|
||||
void OnTrim()
|
||||
{
|
||||
if (voice && (state == STOPPED))
|
||||
{
|
||||
engine->DestroyVoice(voice);
|
||||
voice = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
void GatherStatistics(AudioStatistics& stats) const noexcept
|
||||
{
|
||||
++stats.allocatedInstances;
|
||||
if (voice)
|
||||
{
|
||||
++stats.allocatedVoices;
|
||||
|
||||
if (mFlags & SoundEffectInstance_Use3D)
|
||||
++stats.allocatedVoices3d;
|
||||
|
||||
if (state == PLAYING)
|
||||
++stats.playingInstances;
|
||||
}
|
||||
}
|
||||
|
||||
IXAudio2SourceVoice* voice;
|
||||
SoundState state;
|
||||
AudioEngine* engine;
|
||||
|
||||
private:
|
||||
float mVolume;
|
||||
float mPitch;
|
||||
float mFreqRatio;
|
||||
float mPan;
|
||||
SOUND_EFFECT_INSTANCE_FLAGS mFlags;
|
||||
IXAudio2Voice* mDirectVoice;
|
||||
IXAudio2Voice* mReverbVoice;
|
||||
X3DAUDIO_DSP_SETTINGS mDSPSettings;
|
||||
};
|
||||
|
||||
struct WaveBankSeekData
|
||||
{
|
||||
uint32_t seekCount;
|
||||
const uint32_t* seekTable;
|
||||
uint32_t tag;
|
||||
};
|
||||
}
|
622
Sdk/External/DirectXTK/Audio/SoundEffect.cpp
vendored
Normal file
622
Sdk/External/DirectXTK/Audio/SoundEffect.cpp
vendored
Normal file
@ -0,0 +1,622 @@
|
||||
//--------------------------------------------------------------------------------------
|
||||
// File: SoundEffect.cpp
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkId=248929
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615561
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
#include "pch.h"
|
||||
#include "WAVFileReader.h"
|
||||
#include "SoundCommon.h"
|
||||
|
||||
#include <list>
|
||||
|
||||
#if (defined(_XBOX_ONE) && defined(_TITLE)) || defined(_GAMING_XBOX)
|
||||
#include <apu.h>
|
||||
#include <shapexmacontext.h>
|
||||
#endif
|
||||
|
||||
using namespace DirectX;
|
||||
|
||||
|
||||
//======================================================================================
|
||||
// SoundEffect
|
||||
//======================================================================================
|
||||
|
||||
// Internal object implementation class.
|
||||
class SoundEffect::Impl : public IVoiceNotify
|
||||
{
|
||||
public:
|
||||
explicit Impl(_In_ AudioEngine* engine) :
|
||||
mWaveFormat(nullptr),
|
||||
mStartAudio(nullptr),
|
||||
mAudioBytes(0),
|
||||
mLoopStart(0),
|
||||
mLoopLength(0),
|
||||
mEngine(engine),
|
||||
mOneShots(0)
|
||||
#ifdef DIRECTX_ENABLE_SEEK_TABLES
|
||||
, mSeekCount(0)
|
||||
, mSeekTable(nullptr)
|
||||
#endif
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
, mXMAMemory(nullptr)
|
||||
#endif
|
||||
{
|
||||
assert(mEngine != nullptr);
|
||||
mEngine->RegisterNotify(this, false);
|
||||
}
|
||||
|
||||
Impl(Impl&&) = default;
|
||||
Impl& operator= (Impl&&) = default;
|
||||
|
||||
Impl(Impl const&) = delete;
|
||||
Impl& operator= (Impl const&) = delete;
|
||||
|
||||
~Impl() override
|
||||
{
|
||||
if (!mInstances.empty())
|
||||
{
|
||||
DebugTrace("WARNING: Destroying SoundEffect with %zu outstanding SoundEffectInstances\n", mInstances.size());
|
||||
|
||||
for (auto it = mInstances.begin(); it != mInstances.end(); ++it)
|
||||
{
|
||||
assert(*it != nullptr);
|
||||
(*it)->OnDestroyParent();
|
||||
}
|
||||
|
||||
mInstances.clear();
|
||||
}
|
||||
|
||||
if (mOneShots > 0)
|
||||
{
|
||||
DebugTrace("WARNING: Destroying SoundEffect with %u outstanding one shot effects\n", mOneShots);
|
||||
}
|
||||
|
||||
if (mEngine)
|
||||
{
|
||||
mEngine->UnregisterNotify(this, true, false);
|
||||
mEngine = nullptr;
|
||||
}
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
if (mXMAMemory)
|
||||
{
|
||||
ApuFree(mXMAMemory);
|
||||
mXMAMemory = nullptr;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
HRESULT Initialize(_In_ AudioEngine* engine, _Inout_ std::unique_ptr<uint8_t[]>& wavData,
|
||||
_In_ const WAVEFORMATEX* wfx, _In_reads_bytes_(audioBytes) const uint8_t* startAudio, size_t audioBytes,
|
||||
#ifdef DIRECTX_ENABLE_SEEK_TABLES
|
||||
_In_reads_opt_(seekCount) const uint32_t* seekTable, size_t seekCount,
|
||||
#endif
|
||||
uint32_t loopStart, uint32_t loopLength) noexcept;
|
||||
|
||||
void Play(float volume, float pitch, float pan);
|
||||
|
||||
// IVoiceNotify
|
||||
void __cdecl OnBufferEnd() override
|
||||
{
|
||||
InterlockedDecrement(&mOneShots);
|
||||
}
|
||||
|
||||
void __cdecl OnCriticalError() override
|
||||
{
|
||||
mOneShots = 0;
|
||||
}
|
||||
|
||||
void __cdecl OnReset() override
|
||||
{
|
||||
// No action required
|
||||
}
|
||||
|
||||
void __cdecl OnUpdate() override
|
||||
{
|
||||
// We do not register for update notification
|
||||
assert(false);
|
||||
}
|
||||
|
||||
void __cdecl OnDestroyEngine() noexcept override
|
||||
{
|
||||
mEngine = nullptr;
|
||||
mOneShots = 0;
|
||||
}
|
||||
|
||||
void __cdecl OnTrim() override
|
||||
{
|
||||
// No action required
|
||||
}
|
||||
|
||||
void __cdecl GatherStatistics(AudioStatistics& stats) const noexcept override
|
||||
{
|
||||
stats.playingOneShots += mOneShots;
|
||||
stats.audioBytes += mAudioBytes;
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
if (mXMAMemory)
|
||||
stats.xmaAudioBytes += mAudioBytes;
|
||||
#endif
|
||||
}
|
||||
|
||||
void __cdecl OnDestroyParent() noexcept override
|
||||
{
|
||||
}
|
||||
|
||||
const WAVEFORMATEX* mWaveFormat;
|
||||
const uint8_t* mStartAudio;
|
||||
uint32_t mAudioBytes;
|
||||
uint32_t mLoopStart;
|
||||
uint32_t mLoopLength;
|
||||
AudioEngine* mEngine;
|
||||
std::list<IVoiceNotify*> mInstances;
|
||||
uint32_t mOneShots;
|
||||
|
||||
#ifdef DIRECTX_ENABLE_SEEK_TABLES
|
||||
uint32_t mSeekCount;
|
||||
const uint32_t* mSeekTable;
|
||||
#endif
|
||||
|
||||
private:
|
||||
std::unique_ptr<uint8_t[]> mWavData;
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
void* mXMAMemory;
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
HRESULT SoundEffect::Impl::Initialize(AudioEngine* engine, std::unique_ptr<uint8_t[]>& wavData,
|
||||
const WAVEFORMATEX* wfx, const uint8_t* startAudio, size_t audioBytes,
|
||||
#ifdef DIRECTX_ENABLE_SEEK_TABLES
|
||||
const uint32_t* seekTable, size_t seekCount,
|
||||
#endif
|
||||
uint32_t loopStart, uint32_t loopLength) noexcept
|
||||
{
|
||||
if (!engine || !IsValid(wfx) || !startAudio || !audioBytes || !wavData)
|
||||
return E_INVALIDARG;
|
||||
|
||||
if (audioBytes > UINT32_MAX)
|
||||
return E_INVALIDARG;
|
||||
|
||||
switch (GetFormatTag(wfx))
|
||||
{
|
||||
case WAVE_FORMAT_PCM:
|
||||
case WAVE_FORMAT_IEEE_FLOAT:
|
||||
case WAVE_FORMAT_ADPCM:
|
||||
// Take ownership of the buffer
|
||||
mWavData.reset(wavData.release());
|
||||
|
||||
// WARNING: We assume the wfx and startAudio parameters are pointers into the wavData memory buffer
|
||||
mWaveFormat = wfx;
|
||||
mStartAudio = startAudio;
|
||||
break;
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
|
||||
case WAVE_FORMAT_WMAUDIO2:
|
||||
case WAVE_FORMAT_WMAUDIO3:
|
||||
if (!seekCount || !seekTable)
|
||||
{
|
||||
DebugTrace("ERROR: SoundEffect format xWMA requires seek table\n");
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (seekCount > UINT32_MAX)
|
||||
return E_INVALIDARG;
|
||||
|
||||
// Take ownership of the buffer
|
||||
mWavData.reset(wavData.release());
|
||||
|
||||
// WARNING: We assume the wfx, startAudio, and mSeekTable parameters are pointers into the wavData memory buffer
|
||||
mWaveFormat = wfx;
|
||||
mStartAudio = startAudio;
|
||||
mSeekCount = static_cast<uint32_t>(seekCount);
|
||||
mSeekTable = seekTable;
|
||||
break;
|
||||
|
||||
#endif // xWMA
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
|
||||
case WAVE_FORMAT_XMA2:
|
||||
if (!seekCount || !seekTable)
|
||||
{
|
||||
DebugTrace("ERROR: SoundEffect format XMA2 requires seek table\n");
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (seekCount > UINT32_MAX)
|
||||
return E_INVALIDARG;
|
||||
|
||||
{
|
||||
HRESULT hr = ApuAlloc(&mXMAMemory, nullptr,
|
||||
static_cast<UINT32>(audioBytes), SHAPE_XMA_INPUT_BUFFER_ALIGNMENT);
|
||||
if (FAILED(hr))
|
||||
{
|
||||
DebugTrace("ERROR: ApuAlloc failed. Did you allocate a large enough heap with ApuCreateHeap for all your XMA wave data?\n");
|
||||
return hr;
|
||||
}
|
||||
}
|
||||
|
||||
memcpy(mXMAMemory, startAudio, audioBytes);
|
||||
mStartAudio = reinterpret_cast<const uint8_t*>(mXMAMemory);
|
||||
|
||||
mWavData.reset(new (std::nothrow) uint8_t[sizeof(XMA2WAVEFORMATEX) + (seekCount * sizeof(uint32_t))]);
|
||||
if (!mWavData)
|
||||
return E_OUTOFMEMORY;
|
||||
|
||||
memcpy(mWavData.get(), wfx, sizeof(XMA2WAVEFORMATEX));
|
||||
mWaveFormat = reinterpret_cast<WAVEFORMATEX*>(mWavData.get());
|
||||
|
||||
// XMA seek table is Big-Endian
|
||||
{
|
||||
auto dest = reinterpret_cast<uint32_t*>(mWavData.get() + sizeof(XMA2WAVEFORMATEX));
|
||||
for (size_t k = 0; k < seekCount; ++k)
|
||||
{
|
||||
dest[k] = _byteswap_ulong(seekTable[k]);
|
||||
}
|
||||
}
|
||||
|
||||
mSeekCount = static_cast<uint32_t>(seekCount);
|
||||
mSeekTable = reinterpret_cast<const uint32_t*>(mWavData.get() + sizeof(XMA2WAVEFORMATEX));
|
||||
|
||||
wavData.reset();
|
||||
break;
|
||||
|
||||
#endif // XMA2
|
||||
|
||||
default:
|
||||
{
|
||||
DebugTrace("ERROR: SoundEffect encountered an unsupported format tag (%u)\n", wfx->wFormatTag);
|
||||
return HRESULT_FROM_WIN32(ERROR_NOT_SUPPORTED);
|
||||
}
|
||||
}
|
||||
|
||||
mAudioBytes = static_cast<uint32_t>(audioBytes);
|
||||
mLoopStart = loopStart;
|
||||
mLoopLength = loopLength;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
void SoundEffect::Impl::Play(float volume, float pitch, float pan)
|
||||
{
|
||||
assert(volume >= -XAUDIO2_MAX_VOLUME_LEVEL && volume <= XAUDIO2_MAX_VOLUME_LEVEL);
|
||||
assert(pitch >= -1.f && pitch <= 1.f);
|
||||
assert(pan >= -1.f && pan <= 1.f);
|
||||
|
||||
IXAudio2SourceVoice* voice = nullptr;
|
||||
mEngine->AllocateVoice(mWaveFormat, SoundEffectInstance_Default, true, &voice);
|
||||
|
||||
if (!voice)
|
||||
return;
|
||||
|
||||
if (volume != 1.f)
|
||||
{
|
||||
HRESULT hr = voice->SetVolume(volume);
|
||||
ThrowIfFailed(hr);
|
||||
}
|
||||
|
||||
if (pitch != 0.f)
|
||||
{
|
||||
float fr = XAudio2SemitonesToFrequencyRatio(pitch * 12.f);
|
||||
|
||||
HRESULT hr = voice->SetFrequencyRatio(fr);
|
||||
ThrowIfFailed(hr);
|
||||
}
|
||||
|
||||
if (pan != 0.f)
|
||||
{
|
||||
float matrix[16];
|
||||
if (ComputePan(pan, mWaveFormat->nChannels, matrix))
|
||||
{
|
||||
HRESULT hr = voice->SetOutputMatrix(nullptr, mWaveFormat->nChannels, mEngine->GetOutputChannels(), matrix);
|
||||
ThrowIfFailed(hr);
|
||||
}
|
||||
}
|
||||
|
||||
HRESULT hr = voice->Start(0);
|
||||
ThrowIfFailed(hr);
|
||||
|
||||
XAUDIO2_BUFFER buffer = {};
|
||||
buffer.AudioBytes = mAudioBytes;
|
||||
buffer.pAudioData = mStartAudio;
|
||||
buffer.Flags = XAUDIO2_END_OF_STREAM;
|
||||
buffer.pContext = this;
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
uint32_t tag = GetFormatTag(mWaveFormat);
|
||||
if (tag == WAVE_FORMAT_WMAUDIO2 || tag == WAVE_FORMAT_WMAUDIO3)
|
||||
{
|
||||
XAUDIO2_BUFFER_WMA wmaBuffer = {};
|
||||
wmaBuffer.PacketCount = mSeekCount;
|
||||
wmaBuffer.pDecodedPacketCumulativeBytes = mSeekTable;
|
||||
|
||||
hr = voice->SubmitSourceBuffer(&buffer, &wmaBuffer);
|
||||
}
|
||||
else
|
||||
#endif // xWMA
|
||||
{
|
||||
hr = voice->SubmitSourceBuffer(&buffer, nullptr);
|
||||
}
|
||||
if (FAILED(hr))
|
||||
{
|
||||
DebugTrace("ERROR: SoundEffect failed (%08X) when submitting buffer:\n", static_cast<unsigned int>(hr));
|
||||
DebugTrace("\tFormat Tag %u, %u channels, %u-bit, %u Hz, %u bytes\n",
|
||||
mWaveFormat->wFormatTag, mWaveFormat->nChannels, mWaveFormat->wBitsPerSample, mWaveFormat->nSamplesPerSec, mAudioBytes);
|
||||
throw std::exception("SubmitSourceBuffer");
|
||||
}
|
||||
|
||||
InterlockedIncrement(&mOneShots);
|
||||
}
|
||||
|
||||
|
||||
//--------------------------------------------------------------------------------------
|
||||
// SoundEffect
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
// Public constructors.
|
||||
_Use_decl_annotations_
|
||||
SoundEffect::SoundEffect(AudioEngine* engine, const wchar_t* waveFileName)
|
||||
: pImpl(std::make_unique<Impl>(engine))
|
||||
{
|
||||
WAVData wavInfo;
|
||||
std::unique_ptr<uint8_t[]> wavData;
|
||||
HRESULT hr = LoadWAVAudioFromFileEx(waveFileName, wavData, wavInfo);
|
||||
if (FAILED(hr))
|
||||
{
|
||||
DebugTrace("ERROR: SoundEffect failed (%08X) to load from .wav file \"%ls\"\n",
|
||||
static_cast<unsigned int>(hr), waveFileName);
|
||||
throw std::exception("SoundEffect");
|
||||
}
|
||||
|
||||
#ifdef DIRECTX_ENABLE_SEEK_TABLES
|
||||
hr = pImpl->Initialize(engine, wavData, wavInfo.wfx, wavInfo.startAudio, wavInfo.audioBytes,
|
||||
wavInfo.seek, wavInfo.seekCount,
|
||||
wavInfo.loopStart, wavInfo.loopLength);
|
||||
#else
|
||||
hr = pImpl->Initialize(engine, wavData, wavInfo.wfx, wavInfo.startAudio, wavInfo.audioBytes,
|
||||
wavInfo.loopStart, wavInfo.loopLength);
|
||||
#endif
|
||||
|
||||
if (FAILED(hr))
|
||||
{
|
||||
DebugTrace("ERROR: SoundEffect failed (%08X) to intialize from .wav file \"%ls\"\n",
|
||||
static_cast<unsigned int>(hr), waveFileName);
|
||||
throw std::exception("SoundEffect");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
SoundEffect::SoundEffect(AudioEngine* engine, std::unique_ptr<uint8_t[]>& wavData,
|
||||
const WAVEFORMATEX* wfx, const uint8_t* startAudio, size_t audioBytes)
|
||||
: pImpl(std::make_unique<Impl>(engine))
|
||||
{
|
||||
#ifdef DIRECTX_ENABLE_SEEK_TABLES
|
||||
HRESULT hr = pImpl->Initialize(engine, wavData, wfx, startAudio, audioBytes, nullptr, 0, 0, 0);
|
||||
#else
|
||||
HRESULT hr = pImpl->Initialize(engine, wavData, wfx, startAudio, audioBytes, 0, 0);
|
||||
#endif
|
||||
if (FAILED(hr))
|
||||
{
|
||||
DebugTrace("ERROR: SoundEffect failed (%08X) to intialize\n", static_cast<unsigned int>(hr));
|
||||
throw std::exception("SoundEffect");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
SoundEffect::SoundEffect(AudioEngine* engine, std::unique_ptr<uint8_t[]>& wavData,
|
||||
const WAVEFORMATEX* wfx, const uint8_t* startAudio, size_t audioBytes,
|
||||
uint32_t loopStart, uint32_t loopLength)
|
||||
: pImpl(std::make_unique<Impl>(engine))
|
||||
{
|
||||
#ifdef DIRECTX_ENABLE_SEEK_TABLES
|
||||
HRESULT hr = pImpl->Initialize(engine, wavData, wfx, startAudio, audioBytes, nullptr, 0, loopStart, loopLength);
|
||||
#else
|
||||
HRESULT hr = pImpl->Initialize(engine, wavData, wfx, startAudio, audioBytes, loopStart, loopLength);
|
||||
#endif
|
||||
if (FAILED(hr))
|
||||
{
|
||||
DebugTrace("ERROR: SoundEffect failed (%08X) to intialize\n", static_cast<unsigned int>(hr));
|
||||
throw std::exception("SoundEffect");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#ifdef DIRECTX_ENABLE_SEEK_TABLES
|
||||
|
||||
_Use_decl_annotations_
|
||||
SoundEffect::SoundEffect(AudioEngine* engine, std::unique_ptr<uint8_t[]>& wavData,
|
||||
const WAVEFORMATEX* wfx, const uint8_t* startAudio, size_t audioBytes,
|
||||
const uint32_t* seekTable, size_t seekCount)
|
||||
{
|
||||
HRESULT hr = pImpl->Initialize(engine, wavData, wfx, startAudio, audioBytes, seekTable, seekCount, 0, 0);
|
||||
if (FAILED(hr))
|
||||
{
|
||||
DebugTrace("ERROR: SoundEffect failed (%08X) to intialize\n", static_cast<unsigned int>(hr));
|
||||
throw std::exception("SoundEffect");
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
// Move constructor.
|
||||
SoundEffect::SoundEffect(SoundEffect&& moveFrom) noexcept
|
||||
: pImpl(std::move(moveFrom.pImpl))
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
// Move assignment.
|
||||
SoundEffect& SoundEffect::operator= (SoundEffect&& moveFrom) noexcept
|
||||
{
|
||||
pImpl = std::move(moveFrom.pImpl);
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
// Public destructor.
|
||||
SoundEffect::~SoundEffect()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
// Public methods.
|
||||
void SoundEffect::Play()
|
||||
{
|
||||
pImpl->Play(1.f, 0.f, 0.f);
|
||||
}
|
||||
|
||||
|
||||
void SoundEffect::Play(float volume, float pitch, float pan)
|
||||
{
|
||||
pImpl->Play(volume, pitch, pan);
|
||||
}
|
||||
|
||||
|
||||
std::unique_ptr<SoundEffectInstance> SoundEffect::CreateInstance(SOUND_EFFECT_INSTANCE_FLAGS flags)
|
||||
{
|
||||
auto effect = new SoundEffectInstance(pImpl->mEngine, this, flags);
|
||||
assert(effect != nullptr);
|
||||
pImpl->mInstances.emplace_back(effect->GetVoiceNotify());
|
||||
return std::unique_ptr<SoundEffectInstance>(effect);
|
||||
}
|
||||
|
||||
|
||||
void SoundEffect::UnregisterInstance(_In_ IVoiceNotify* instance)
|
||||
{
|
||||
auto it = std::find(pImpl->mInstances.begin(), pImpl->mInstances.end(), instance);
|
||||
if (it == pImpl->mInstances.end())
|
||||
return;
|
||||
|
||||
pImpl->mInstances.erase(it);
|
||||
}
|
||||
|
||||
|
||||
// Public accessors.
|
||||
bool SoundEffect::IsInUse() const noexcept
|
||||
{
|
||||
return (pImpl->mOneShots > 0) || !pImpl->mInstances.empty();
|
||||
}
|
||||
|
||||
|
||||
size_t SoundEffect::GetSampleSizeInBytes() const noexcept
|
||||
{
|
||||
return pImpl->mAudioBytes;
|
||||
}
|
||||
|
||||
|
||||
size_t SoundEffect::GetSampleDuration() const noexcept
|
||||
{
|
||||
if (!pImpl->mWaveFormat || !pImpl->mWaveFormat->nChannels)
|
||||
return 0;
|
||||
|
||||
switch (GetFormatTag(pImpl->mWaveFormat))
|
||||
{
|
||||
case WAVE_FORMAT_ADPCM:
|
||||
{
|
||||
auto adpcmFmt = reinterpret_cast<const ADPCMWAVEFORMAT*>(pImpl->mWaveFormat);
|
||||
|
||||
uint64_t duration = uint64_t(pImpl->mAudioBytes / adpcmFmt->wfx.nBlockAlign) * adpcmFmt->wSamplesPerBlock;
|
||||
unsigned int partial = pImpl->mAudioBytes % adpcmFmt->wfx.nBlockAlign;
|
||||
if (partial)
|
||||
{
|
||||
if (partial >= (7u * adpcmFmt->wfx.nChannels))
|
||||
duration += (uint64_t(partial) * 2 / uint64_t(adpcmFmt->wfx.nChannels - 12));
|
||||
}
|
||||
return static_cast<size_t>(duration);
|
||||
}
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
|
||||
case WAVE_FORMAT_WMAUDIO2:
|
||||
case WAVE_FORMAT_WMAUDIO3:
|
||||
if (pImpl->mSeekTable && pImpl->mSeekCount > 0)
|
||||
{
|
||||
return pImpl->mSeekTable[pImpl->mSeekCount - 1] / uint32_t(2 * pImpl->mWaveFormat->nChannels);
|
||||
}
|
||||
break;
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
|
||||
case WAVE_FORMAT_XMA2:
|
||||
return reinterpret_cast<const XMA2WAVEFORMATEX*>(pImpl->mWaveFormat)->SamplesEncoded;
|
||||
|
||||
#endif
|
||||
|
||||
default:
|
||||
if (pImpl->mWaveFormat->wBitsPerSample > 0)
|
||||
{
|
||||
return static_cast<size_t>((uint64_t(pImpl->mAudioBytes) * 8)
|
||||
/ (uint64_t(pImpl->mWaveFormat->wBitsPerSample) * uint64_t(pImpl->mWaveFormat->nChannels)));
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
size_t SoundEffect::GetSampleDurationMS() const noexcept
|
||||
{
|
||||
if (!pImpl->mWaveFormat || !pImpl->mWaveFormat->nSamplesPerSec)
|
||||
return 0;
|
||||
|
||||
uint64_t samples = GetSampleDuration();
|
||||
return static_cast<size_t>((samples * 1000) / pImpl->mWaveFormat->nSamplesPerSec);
|
||||
}
|
||||
|
||||
|
||||
const WAVEFORMATEX* SoundEffect::GetFormat() const noexcept
|
||||
{
|
||||
return pImpl->mWaveFormat;
|
||||
}
|
||||
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
|
||||
bool SoundEffect::FillSubmitBuffer(_Out_ XAUDIO2_BUFFER& buffer, _Out_ XAUDIO2_BUFFER_WMA& wmaBuffer) const
|
||||
{
|
||||
memset(&buffer, 0, sizeof(buffer));
|
||||
memset(&wmaBuffer, 0, sizeof(wmaBuffer));
|
||||
|
||||
buffer.AudioBytes = pImpl->mAudioBytes;
|
||||
buffer.pAudioData = pImpl->mStartAudio;
|
||||
buffer.LoopBegin = pImpl->mLoopStart;
|
||||
buffer.LoopLength = pImpl->mLoopLength;
|
||||
|
||||
uint32_t tag = GetFormatTag(pImpl->mWaveFormat);
|
||||
if (tag == WAVE_FORMAT_WMAUDIO2 || tag == WAVE_FORMAT_WMAUDIO3)
|
||||
{
|
||||
wmaBuffer.PacketCount = pImpl->mSeekCount;
|
||||
wmaBuffer.pDecodedPacketCumulativeBytes = pImpl->mSeekTable;
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
#else // !xWMA
|
||||
|
||||
void SoundEffect::FillSubmitBuffer(_Out_ XAUDIO2_BUFFER& buffer) const
|
||||
{
|
||||
memset(&buffer, 0, sizeof(buffer));
|
||||
buffer.AudioBytes = pImpl->mAudioBytes;
|
||||
buffer.pAudioData = pImpl->mStartAudio;
|
||||
buffer.LoopBegin = pImpl->mLoopStart;
|
||||
buffer.LoopLength = pImpl->mLoopLength;
|
||||
}
|
||||
|
||||
#endif
|
341
Sdk/External/DirectXTK/Audio/SoundEffectInstance.cpp
vendored
Normal file
341
Sdk/External/DirectXTK/Audio/SoundEffectInstance.cpp
vendored
Normal file
@ -0,0 +1,341 @@
|
||||
//--------------------------------------------------------------------------------------
|
||||
// File: SoundEffectInstance.cpp
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkId=248929
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615561
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
#include "pch.h"
|
||||
#include "SoundCommon.h"
|
||||
|
||||
using namespace DirectX;
|
||||
|
||||
|
||||
//======================================================================================
|
||||
// SoundEffectInstance
|
||||
//======================================================================================
|
||||
|
||||
// Internal object implementation class.
|
||||
class SoundEffectInstance::Impl : public IVoiceNotify
|
||||
{
|
||||
public:
|
||||
Impl(_In_ AudioEngine* engine, _In_ SoundEffect* effect, SOUND_EFFECT_INSTANCE_FLAGS flags) :
|
||||
mBase(),
|
||||
mEffect(effect),
|
||||
mWaveBank(nullptr),
|
||||
mIndex(0),
|
||||
mLooped(false)
|
||||
{
|
||||
assert(engine != nullptr);
|
||||
engine->RegisterNotify(this, false);
|
||||
|
||||
assert(mEffect != nullptr);
|
||||
mBase.Initialize(engine, effect->GetFormat(), flags);
|
||||
}
|
||||
|
||||
Impl(_In_ AudioEngine* engine, _In_ WaveBank* waveBank, uint32_t index, SOUND_EFFECT_INSTANCE_FLAGS flags) :
|
||||
mBase(),
|
||||
mEffect(nullptr),
|
||||
mWaveBank(waveBank),
|
||||
mIndex(index),
|
||||
mLooped(false)
|
||||
{
|
||||
assert(engine != nullptr);
|
||||
engine->RegisterNotify(this, false);
|
||||
|
||||
char buff[64] = {};
|
||||
auto wfx = reinterpret_cast<WAVEFORMATEX*>(buff);
|
||||
assert(mWaveBank != nullptr);
|
||||
mBase.Initialize(engine, mWaveBank->GetFormat(index, wfx, sizeof(buff)), flags);
|
||||
}
|
||||
|
||||
Impl(Impl&&) = default;
|
||||
Impl& operator= (Impl&&) = default;
|
||||
|
||||
Impl(Impl const&) = delete;
|
||||
Impl& operator= (Impl const&) = delete;
|
||||
|
||||
~Impl() override
|
||||
{
|
||||
mBase.DestroyVoice();
|
||||
|
||||
if (mBase.engine)
|
||||
{
|
||||
mBase.engine->UnregisterNotify(this, false, false);
|
||||
mBase.engine = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
void Play(bool loop);
|
||||
|
||||
// IVoiceNotify
|
||||
void __cdecl OnBufferEnd() override
|
||||
{
|
||||
// We don't register for this notification for SoundEffectInstances, so this should not be invoked
|
||||
assert(false);
|
||||
}
|
||||
|
||||
void __cdecl OnCriticalError() override
|
||||
{
|
||||
mBase.OnCriticalError();
|
||||
}
|
||||
|
||||
void __cdecl OnReset() override
|
||||
{
|
||||
mBase.OnReset();
|
||||
}
|
||||
|
||||
void __cdecl OnUpdate() override
|
||||
{
|
||||
// We do not register for update notification
|
||||
assert(false);
|
||||
}
|
||||
|
||||
void __cdecl OnDestroyEngine() noexcept override
|
||||
{
|
||||
mBase.OnDestroy();
|
||||
}
|
||||
|
||||
void __cdecl OnTrim() override
|
||||
{
|
||||
mBase.OnTrim();
|
||||
}
|
||||
|
||||
void __cdecl GatherStatistics(AudioStatistics& stats) const noexcept override
|
||||
{
|
||||
mBase.GatherStatistics(stats);
|
||||
}
|
||||
|
||||
void __cdecl OnDestroyParent() noexcept override
|
||||
{
|
||||
mBase.OnDestroy();
|
||||
mWaveBank = nullptr;
|
||||
mEffect = nullptr;
|
||||
}
|
||||
|
||||
SoundEffectInstanceBase mBase;
|
||||
SoundEffect* mEffect;
|
||||
WaveBank* mWaveBank;
|
||||
uint32_t mIndex;
|
||||
bool mLooped;
|
||||
};
|
||||
|
||||
|
||||
void SoundEffectInstance::Impl::Play(bool loop)
|
||||
{
|
||||
if (!mBase.voice)
|
||||
{
|
||||
if (mWaveBank)
|
||||
{
|
||||
char buff[64] = {};
|
||||
auto wfx = reinterpret_cast<WAVEFORMATEX*>(buff);
|
||||
mBase.AllocateVoice(mWaveBank->GetFormat(mIndex, wfx, sizeof(buff)));
|
||||
}
|
||||
else
|
||||
{
|
||||
assert(mEffect != nullptr);
|
||||
mBase.AllocateVoice(mEffect->GetFormat());
|
||||
}
|
||||
}
|
||||
|
||||
if (!mBase.Play())
|
||||
return;
|
||||
|
||||
// Submit audio data for STOPPED -> PLAYING state transition
|
||||
XAUDIO2_BUFFER buffer = {};
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
|
||||
bool iswma = false;
|
||||
XAUDIO2_BUFFER_WMA wmaBuffer = {};
|
||||
if (mWaveBank)
|
||||
{
|
||||
iswma = mWaveBank->FillSubmitBuffer(mIndex, buffer, wmaBuffer);
|
||||
}
|
||||
else
|
||||
{
|
||||
assert(mEffect != nullptr);
|
||||
iswma = mEffect->FillSubmitBuffer(buffer, wmaBuffer);
|
||||
}
|
||||
|
||||
#else // !xWMA
|
||||
|
||||
if (mWaveBank)
|
||||
{
|
||||
mWaveBank->FillSubmitBuffer(mIndex, buffer);
|
||||
}
|
||||
else
|
||||
{
|
||||
assert(mEffect != nullptr);
|
||||
mEffect->FillSubmitBuffer(buffer);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
buffer.Flags = XAUDIO2_END_OF_STREAM;
|
||||
if (loop)
|
||||
{
|
||||
mLooped = true;
|
||||
buffer.LoopCount = XAUDIO2_LOOP_INFINITE;
|
||||
}
|
||||
else
|
||||
{
|
||||
mLooped = false;
|
||||
buffer.LoopCount = buffer.LoopBegin = buffer.LoopLength = 0;
|
||||
}
|
||||
buffer.pContext = nullptr;
|
||||
|
||||
HRESULT hr;
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
if (iswma)
|
||||
{
|
||||
hr = mBase.voice->SubmitSourceBuffer(&buffer, &wmaBuffer);
|
||||
}
|
||||
else
|
||||
#endif
|
||||
{
|
||||
hr = mBase.voice->SubmitSourceBuffer(&buffer, nullptr);
|
||||
}
|
||||
|
||||
if (FAILED(hr))
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
DebugTrace("ERROR: SoundEffectInstance failed (%08X) when submitting buffer:\n", static_cast<unsigned int>(hr));
|
||||
|
||||
char buff[64] = {};
|
||||
auto wfx = (mWaveBank) ? mWaveBank->GetFormat(mIndex, reinterpret_cast<WAVEFORMATEX*>(buff), sizeof(buff))
|
||||
: mEffect->GetFormat();
|
||||
|
||||
size_t length = (mWaveBank) ? mWaveBank->GetSampleSizeInBytes(mIndex) : mEffect->GetSampleSizeInBytes();
|
||||
|
||||
DebugTrace("\tFormat Tag %u, %u channels, %u-bit, %u Hz, %zu bytes\n",
|
||||
wfx->wFormatTag, wfx->nChannels, wfx->wBitsPerSample, wfx->nSamplesPerSec, length);
|
||||
#endif
|
||||
mBase.Stop(true, mLooped);
|
||||
throw std::exception("SubmitSourceBuffer");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//--------------------------------------------------------------------------------------
|
||||
// SoundEffectInstance
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
// Private constructors
|
||||
_Use_decl_annotations_
|
||||
SoundEffectInstance::SoundEffectInstance(AudioEngine* engine, SoundEffect* effect, SOUND_EFFECT_INSTANCE_FLAGS flags) :
|
||||
pImpl(std::make_unique<Impl>(engine, effect, flags))
|
||||
{
|
||||
}
|
||||
|
||||
_Use_decl_annotations_
|
||||
SoundEffectInstance::SoundEffectInstance(AudioEngine* engine, WaveBank* waveBank, unsigned int index, SOUND_EFFECT_INSTANCE_FLAGS flags) :
|
||||
pImpl(std::make_unique<Impl>(engine, waveBank, index, flags))
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
// Move constructor.
|
||||
SoundEffectInstance::SoundEffectInstance(SoundEffectInstance&& moveFrom) noexcept
|
||||
: pImpl(std::move(moveFrom.pImpl))
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
// Move assignment.
|
||||
SoundEffectInstance& SoundEffectInstance::operator= (SoundEffectInstance&& moveFrom) noexcept
|
||||
{
|
||||
pImpl = std::move(moveFrom.pImpl);
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
// Public destructor.
|
||||
SoundEffectInstance::~SoundEffectInstance()
|
||||
{
|
||||
if (pImpl)
|
||||
{
|
||||
if (pImpl->mWaveBank)
|
||||
{
|
||||
pImpl->mWaveBank->UnregisterInstance(pImpl.get());
|
||||
pImpl->mWaveBank = nullptr;
|
||||
}
|
||||
|
||||
if (pImpl->mEffect)
|
||||
{
|
||||
pImpl->mEffect->UnregisterInstance(pImpl.get());
|
||||
pImpl->mEffect = nullptr;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Public methods.
|
||||
void SoundEffectInstance::Play(bool loop)
|
||||
{
|
||||
pImpl->Play(loop);
|
||||
}
|
||||
|
||||
|
||||
void SoundEffectInstance::Stop(bool immediate) noexcept
|
||||
{
|
||||
pImpl->mBase.Stop(immediate, pImpl->mLooped);
|
||||
}
|
||||
|
||||
|
||||
void SoundEffectInstance::Pause() noexcept
|
||||
{
|
||||
pImpl->mBase.Pause();
|
||||
}
|
||||
|
||||
|
||||
void SoundEffectInstance::Resume()
|
||||
{
|
||||
pImpl->mBase.Resume();
|
||||
}
|
||||
|
||||
|
||||
void SoundEffectInstance::SetVolume(float volume)
|
||||
{
|
||||
pImpl->mBase.SetVolume(volume);
|
||||
}
|
||||
|
||||
|
||||
void SoundEffectInstance::SetPitch(float pitch)
|
||||
{
|
||||
pImpl->mBase.SetPitch(pitch);
|
||||
}
|
||||
|
||||
|
||||
void SoundEffectInstance::SetPan(float pan)
|
||||
{
|
||||
pImpl->mBase.SetPan(pan);
|
||||
}
|
||||
|
||||
|
||||
void SoundEffectInstance::Apply3D(const AudioListener& listener, const AudioEmitter& emitter, bool rhcoords)
|
||||
{
|
||||
pImpl->mBase.Apply3D(listener, emitter, rhcoords);
|
||||
}
|
||||
|
||||
|
||||
// Public accessors.
|
||||
bool SoundEffectInstance::IsLooped() const noexcept
|
||||
{
|
||||
return pImpl->mLooped;
|
||||
}
|
||||
|
||||
|
||||
SoundState SoundEffectInstance::GetState() noexcept
|
||||
{
|
||||
return pImpl->mBase.GetState(true);
|
||||
}
|
||||
|
||||
|
||||
IVoiceNotify* SoundEffectInstance::GetVoiceNotify() const noexcept
|
||||
{
|
||||
return pImpl.get();
|
||||
}
|
849
Sdk/External/DirectXTK/Audio/SoundStreamInstance.cpp
vendored
Normal file
849
Sdk/External/DirectXTK/Audio/SoundStreamInstance.cpp
vendored
Normal file
@ -0,0 +1,849 @@
|
||||
//--------------------------------------------------------------------------------------
|
||||
// File: SoundStreamInstance.cpp
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkId=248929
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615561
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
#include "pch.h"
|
||||
#include "DirectXHelpers.h"
|
||||
#include "WaveBankReader.h"
|
||||
#include "PlatformHelpers.h"
|
||||
#include "SoundCommon.h"
|
||||
|
||||
#if (defined(_XBOX_ONE) && defined(_TITLE)) || defined(_GAMING_XBOX)
|
||||
#include <apu.h>
|
||||
#include <shapexmacontext.h>
|
||||
#endif
|
||||
|
||||
using namespace DirectX;
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic ignored "-Wcovered-switch-default"
|
||||
#endif
|
||||
|
||||
#pragma warning(disable : 4061 4062)
|
||||
|
||||
//#define VERBOSE_TRACE
|
||||
|
||||
#ifdef VERBOSE_TRACE
|
||||
#pragma message("NOTE: Verbose tracing enabled")
|
||||
#endif
|
||||
|
||||
namespace
|
||||
{
|
||||
const size_t DVD_SECTOR_SIZE = 2048;
|
||||
const size_t MEMORY_ALLOC_SIZE = 4096;
|
||||
const size_t MAX_BUFFER_COUNT = 3;
|
||||
|
||||
#ifdef DIRECTX_ENABLE_SEEK_TABLES
|
||||
const size_t MAX_STREAMING_SEEK_PACKETS = 2048;
|
||||
#endif
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
const size_t XMA2_64KBLOCKINBYTES = 65536;
|
||||
|
||||
struct apu_deleter { void operator()(void* p) noexcept { if (p) ApuFree(p); } };
|
||||
#endif
|
||||
|
||||
size_t ComputeAsyncPacketSize(_In_ const WAVEFORMATEX* wfx, uint32_t tag)
|
||||
{
|
||||
if (!wfx)
|
||||
return 0;
|
||||
|
||||
size_t buffer = size_t(wfx->nAvgBytesPerSec) * 2u;
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
if (tag == WAVE_FORMAT_XMA2)
|
||||
{
|
||||
buffer = AlignUp(buffer, XMA2_64KBLOCKINBYTES);
|
||||
buffer = std::max<size_t>(XMA2_64KBLOCKINBYTES, buffer);
|
||||
return buffer;
|
||||
}
|
||||
#else
|
||||
UNREFERENCED_PARAMETER(tag);
|
||||
#endif
|
||||
|
||||
buffer = AlignUp(buffer, MEMORY_ALLOC_SIZE);
|
||||
buffer = std::max<size_t>(65536u, buffer);
|
||||
return buffer;
|
||||
}
|
||||
|
||||
static_assert(MEMORY_ALLOC_SIZE >= DVD_SECTOR_SIZE, "Memory size should be larger than sector size");
|
||||
static_assert(MEMORY_ALLOC_SIZE >= DVD_SECTOR_SIZE || (MEMORY_ALLOC_SIZE% DVD_SECTOR_SIZE) == 0, "Memory size should be multiples of sector size");
|
||||
}
|
||||
|
||||
|
||||
//======================================================================================
|
||||
// SoundStreamInstance
|
||||
//======================================================================================
|
||||
|
||||
// Internal object implementation class.
|
||||
class SoundStreamInstance::Impl : public IVoiceNotify
|
||||
{
|
||||
public:
|
||||
Impl(_In_ AudioEngine* engine,
|
||||
WaveBank* waveBank,
|
||||
uint32_t index,
|
||||
SOUND_EFFECT_INSTANCE_FLAGS flags) noexcept(false) :
|
||||
mBase(),
|
||||
mWaveBank(waveBank),
|
||||
mIndex(index),
|
||||
mPlaying(false),
|
||||
mLooped(false),
|
||||
mEndStream(false),
|
||||
mPrefetch(false),
|
||||
mSitching(false),
|
||||
mPackets{},
|
||||
mCurrentDiskReadBuffer(0),
|
||||
mCurrentPlayBuffer(0),
|
||||
mBlockAlign(0),
|
||||
mCurrentPosition(0),
|
||||
mOffsetBytes(0),
|
||||
mLengthInBytes(0),
|
||||
mPacketSize(0),
|
||||
mTotalSize(0)
|
||||
#ifdef DIRECTX_ENABLE_SEEK_TABLES
|
||||
, mSeekCount(0),
|
||||
mSeekTable(nullptr),
|
||||
mSeekTableCopy{}
|
||||
#endif
|
||||
{
|
||||
assert(engine != nullptr);
|
||||
engine->RegisterNotify(this, true);
|
||||
|
||||
char buff[64] = {};
|
||||
auto wfx = reinterpret_cast<WAVEFORMATEX*>(buff);
|
||||
assert(mWaveBank != nullptr);
|
||||
mBase.Initialize(engine, mWaveBank->GetFormat(index, wfx, sizeof(buff)), flags);
|
||||
|
||||
WaveBankReader::Metadata metadata = {};
|
||||
(void)mWaveBank->GetPrivateData(index, &metadata, sizeof(metadata));
|
||||
|
||||
mOffsetBytes = metadata.offsetBytes;
|
||||
mLengthInBytes = metadata.lengthBytes;
|
||||
|
||||
#ifdef DIRECTX_ENABLE_SEEK_TABLES
|
||||
WaveBankSeekData seekData = {};
|
||||
(void)mWaveBank->GetPrivateData(index, &seekData, sizeof(seekData));
|
||||
if (seekData.tag == WAVE_FORMAT_WMAUDIO2 || seekData.tag == WAVE_FORMAT_WMAUDIO3)
|
||||
{
|
||||
mSeekCount = seekData.seekCount;
|
||||
mSeekTable = seekData.seekTable;
|
||||
}
|
||||
#endif
|
||||
|
||||
mBufferEnd.reset(CreateEventEx(nullptr, nullptr, 0, EVENT_MODIFY_STATE | SYNCHRONIZE));
|
||||
mBufferRead.reset(CreateEventEx(nullptr, nullptr, 0, EVENT_MODIFY_STATE | SYNCHRONIZE));
|
||||
if (!mBufferEnd || !mBufferRead)
|
||||
{
|
||||
throw std::exception("CreateEvent");
|
||||
}
|
||||
|
||||
ThrowIfFailed(AllocateStreamingBuffers(wfx));
|
||||
|
||||
#ifdef VERBOSE_TRACE
|
||||
DebugTrace("INFO (Streaming): packet size %zu, play length %zu\n", mPacketSize, mLengthInBytes);
|
||||
#endif
|
||||
|
||||
mPrefetch = true;
|
||||
ThrowIfFailed(ReadBuffers());
|
||||
}
|
||||
|
||||
virtual ~Impl() override
|
||||
{
|
||||
mBase.DestroyVoice();
|
||||
|
||||
if (mWaveBank && mWaveBank->GetAsyncHandle())
|
||||
{
|
||||
for (size_t j = 0; j < MAX_BUFFER_COUNT; ++j)
|
||||
{
|
||||
(void)CancelIoEx(mWaveBank->GetAsyncHandle(), &mPackets[j].request);
|
||||
}
|
||||
}
|
||||
|
||||
if (mBase.engine)
|
||||
{
|
||||
mBase.engine->UnregisterNotify(this, false, true);
|
||||
mBase.engine = nullptr;
|
||||
}
|
||||
|
||||
for (size_t j = 0; j < MAX_BUFFER_COUNT; ++j)
|
||||
{
|
||||
mPackets[j] = {};
|
||||
}
|
||||
mPacketSize = 0;
|
||||
}
|
||||
|
||||
Impl(Impl&&) = default;
|
||||
Impl& operator= (Impl&&) = default;
|
||||
|
||||
Impl(Impl const&) = delete;
|
||||
Impl& operator= (Impl const&) = delete;
|
||||
|
||||
void Play(bool loop)
|
||||
{
|
||||
if (!mBase.voice)
|
||||
{
|
||||
if (!mWaveBank)
|
||||
return;
|
||||
|
||||
char buff[64] = {};
|
||||
auto wfx = reinterpret_cast<WAVEFORMATEX*>(buff);
|
||||
mBase.AllocateVoice(mWaveBank->GetFormat(mIndex, wfx, sizeof(buff)));
|
||||
}
|
||||
|
||||
if (!mBase.Play())
|
||||
return;
|
||||
|
||||
mLooped = loop;
|
||||
mEndStream = false;
|
||||
|
||||
if (!mPrefetch)
|
||||
{
|
||||
mCurrentPosition = 0;
|
||||
}
|
||||
|
||||
ThrowIfFailed(PlayBuffers());
|
||||
}
|
||||
|
||||
// IVoiceNotify
|
||||
virtual void __cdecl OnBufferEnd() override
|
||||
{
|
||||
// Not used
|
||||
}
|
||||
|
||||
virtual void __cdecl OnCriticalError() override
|
||||
{
|
||||
mBase.OnCriticalError();
|
||||
}
|
||||
|
||||
virtual void __cdecl OnReset() override
|
||||
{
|
||||
mBase.OnReset();
|
||||
}
|
||||
|
||||
virtual void __cdecl OnUpdate() override
|
||||
{
|
||||
if (!mPlaying)
|
||||
return;
|
||||
|
||||
HANDLE events[] = { mBufferRead.get(), mBufferEnd.get() };
|
||||
switch (WaitForMultipleObjectsEx(_countof(events), events, FALSE, 0, FALSE))
|
||||
{
|
||||
case WAIT_TIMEOUT:
|
||||
break;
|
||||
|
||||
case WAIT_OBJECT_0: // Read completed
|
||||
#ifdef VERBOSE_TRACE
|
||||
DebugTrace("INFO (Streaming): Playing... (readpos %zu) [", mCurrentPosition);
|
||||
for (uint32_t k = 0; k < MAX_BUFFER_COUNT; ++k)
|
||||
{
|
||||
DebugTrace("%ls ", s_debugState[static_cast<int>(mPackets[k].state)]);
|
||||
}
|
||||
DebugTrace("]\n");
|
||||
#endif
|
||||
mPrefetch = false;
|
||||
ThrowIfFailed(PlayBuffers());
|
||||
break;
|
||||
|
||||
case (WAIT_OBJECT_0 + 1): // Play completed
|
||||
#ifdef VERBOSE_TRACE
|
||||
DebugTrace("INFO (Streaming): Reading... (readpos %zu) [", mCurrentPosition);
|
||||
for (uint32_t k = 0; k < MAX_BUFFER_COUNT; ++k)
|
||||
{
|
||||
DebugTrace("%ls ", s_debugState[static_cast<int>(mPackets[k].state)]);
|
||||
}
|
||||
DebugTrace("]\n");
|
||||
#endif
|
||||
ThrowIfFailed(ReadBuffers());
|
||||
break;
|
||||
|
||||
case WAIT_FAILED:
|
||||
throw std::exception("WaitForMultipleObjects");
|
||||
}
|
||||
}
|
||||
|
||||
virtual void __cdecl OnDestroyEngine() noexcept override
|
||||
{
|
||||
mBase.OnDestroy();
|
||||
}
|
||||
|
||||
virtual void __cdecl OnTrim() override
|
||||
{
|
||||
mBase.OnTrim();
|
||||
}
|
||||
|
||||
virtual void __cdecl GatherStatistics(AudioStatistics& stats) const noexcept override
|
||||
{
|
||||
mBase.GatherStatistics(stats);
|
||||
|
||||
stats.streamingBytes += mPacketSize * MAX_BUFFER_COUNT;
|
||||
}
|
||||
|
||||
virtual void __cdecl OnDestroyParent() noexcept override
|
||||
{
|
||||
mBase.OnDestroy();
|
||||
mWaveBank = nullptr;
|
||||
}
|
||||
|
||||
SoundEffectInstanceBase mBase;
|
||||
WaveBank* mWaveBank;
|
||||
uint32_t mIndex;
|
||||
bool mPlaying;
|
||||
bool mLooped;
|
||||
bool mEndStream;
|
||||
bool mPrefetch;
|
||||
bool mSitching;
|
||||
|
||||
ScopedHandle mBufferEnd;
|
||||
ScopedHandle mBufferRead;
|
||||
|
||||
enum class State : uint32_t
|
||||
{
|
||||
FREE = 0,
|
||||
PENDING,
|
||||
READY,
|
||||
PLAYING,
|
||||
};
|
||||
|
||||
#ifdef VERBOSE_TRACE
|
||||
static const wchar_t* s_debugState[4];
|
||||
#endif
|
||||
|
||||
struct BufferNotify : public IVoiceNotify
|
||||
{
|
||||
BufferNotify() : mParent(nullptr), mIndex(0) {}
|
||||
|
||||
void Set(SoundStreamInstance::Impl* parent, size_t index) noexcept(true) { mParent = parent; mIndex = index; }
|
||||
|
||||
void __cdecl OnBufferEnd() override
|
||||
{
|
||||
assert(mParent != nullptr);
|
||||
mParent->mPackets[mIndex].state = State::FREE;
|
||||
SetEvent(mParent->mBufferEnd.get());
|
||||
}
|
||||
|
||||
void __cdecl OnCriticalError() override { assert(mParent != nullptr); mParent->OnCriticalError(); }
|
||||
void __cdecl OnReset() override { assert(mParent != nullptr); mParent->OnReset(); }
|
||||
void __cdecl OnUpdate() override { assert(mParent != nullptr); mParent->OnUpdate(); }
|
||||
void __cdecl OnDestroyEngine() noexcept override { assert(mParent != nullptr); mParent->OnDestroyEngine(); }
|
||||
void __cdecl OnTrim() override { assert(mParent != nullptr); mParent->OnTrim(); }
|
||||
void __cdecl GatherStatistics(AudioStatistics& stats) const override { assert(mParent != nullptr); mParent->GatherStatistics(stats); }
|
||||
void __cdecl OnDestroyParent() noexcept override { assert(mParent != nullptr); mParent->OnDestroyParent(); }
|
||||
|
||||
private:
|
||||
SoundStreamInstance::Impl* mParent;
|
||||
size_t mIndex;
|
||||
};
|
||||
|
||||
struct Packets
|
||||
{
|
||||
State state;
|
||||
uint8_t* buffer;
|
||||
uint8_t* stitchBuffer;
|
||||
uint32_t valid;
|
||||
uint32_t audioBytes;
|
||||
uint32_t startPosition;
|
||||
OVERLAPPED request;
|
||||
BufferNotify notify;
|
||||
|
||||
Packets() :
|
||||
state(State::FREE),
|
||||
buffer(nullptr),
|
||||
stitchBuffer(nullptr),
|
||||
valid(0),
|
||||
audioBytes(0),
|
||||
startPosition(0),
|
||||
request{},
|
||||
notify{} {}
|
||||
};
|
||||
|
||||
Packets mPackets[MAX_BUFFER_COUNT];
|
||||
|
||||
private:
|
||||
uint32_t mCurrentDiskReadBuffer;
|
||||
uint32_t mCurrentPlayBuffer;
|
||||
uint32_t mBlockAlign;
|
||||
size_t mCurrentPosition;
|
||||
size_t mOffsetBytes;
|
||||
size_t mLengthInBytes;
|
||||
|
||||
size_t mPacketSize;
|
||||
size_t mTotalSize;
|
||||
std::unique_ptr<uint8_t[], virtual_deleter> mStreamBuffer;
|
||||
|
||||
#ifdef DIRECTX_ENABLE_SEEK_TABLES
|
||||
uint32_t mSeekCount;
|
||||
const uint32_t* mSeekTable;
|
||||
uint32_t mSeekTableCopy[MAX_STREAMING_SEEK_PACKETS];
|
||||
#endif
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
std::unique_ptr<uint8_t[], apu_deleter> mXMAMemory;
|
||||
#endif
|
||||
|
||||
HRESULT AllocateStreamingBuffers(const WAVEFORMATEX* wfx) noexcept;
|
||||
HRESULT ReadBuffers() noexcept;
|
||||
HRESULT PlayBuffers() noexcept;
|
||||
};
|
||||
|
||||
|
||||
HRESULT SoundStreamInstance::Impl::AllocateStreamingBuffers(const WAVEFORMATEX* wfx) noexcept
|
||||
{
|
||||
if (!wfx)
|
||||
return E_INVALIDARG;
|
||||
|
||||
uint32_t tag = GetFormatTag(wfx);
|
||||
|
||||
size_t packetSize = ComputeAsyncPacketSize(wfx, tag);
|
||||
if (!packetSize)
|
||||
return E_UNEXPECTED;
|
||||
|
||||
uint64_t totalSize = uint64_t(packetSize) * uint64_t(MAX_BUFFER_COUNT);
|
||||
if (totalSize > UINT32_MAX)
|
||||
return HRESULT_FROM_WIN32(ERROR_ARITHMETIC_OVERFLOW);
|
||||
|
||||
mPacketSize = packetSize;
|
||||
mBlockAlign = wfx->nBlockAlign;
|
||||
mSitching = false;
|
||||
|
||||
size_t stitchSize = 0;
|
||||
if ((packetSize % wfx->nBlockAlign) != 0)
|
||||
{
|
||||
mSitching = true;
|
||||
|
||||
stitchSize = AlignUp<size_t>(wfx->nBlockAlign, DVD_SECTOR_SIZE);
|
||||
totalSize += uint64_t(stitchSize) * uint64_t(MAX_BUFFER_COUNT);
|
||||
if (totalSize > UINT32_MAX)
|
||||
return HRESULT_FROM_WIN32(ERROR_ARITHMETIC_OVERFLOW);
|
||||
}
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
if ((mTotalSize < totalSize) || (tag == WAVE_FORMAT_XMA2 && !mXMAMemory) || (tag != WAVE_FORMAT_XMA2 && !mStreamBuffer))
|
||||
#else
|
||||
if (mTotalSize < totalSize)
|
||||
#endif
|
||||
{
|
||||
mStreamBuffer.reset();
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
mXMAMemory.reset();
|
||||
if (tag == WAVE_FORMAT_XMA2)
|
||||
{
|
||||
void* xmaMemory = nullptr;
|
||||
HRESULT hr = ApuAlloc(&xmaMemory, nullptr, static_cast<UINT32>(totalSize), SHAPE_XMA_INPUT_BUFFER_ALIGNMENT);
|
||||
if (FAILED(hr))
|
||||
{
|
||||
DebugTrace("ERROR: ApuAlloc failed (%llu bytes). Did you allocate a large enough heap with ApuCreateHeap for all your XMA wave data?\n", totalSize);
|
||||
return hr;
|
||||
}
|
||||
mXMAMemory.reset(static_cast<uint8_t*>(xmaMemory));
|
||||
}
|
||||
else
|
||||
#endif
|
||||
{
|
||||
mStreamBuffer.reset(reinterpret_cast<uint8_t*>(
|
||||
VirtualAlloc(nullptr, static_cast<SIZE_T>(totalSize), MEM_COMMIT, PAGE_READWRITE)
|
||||
));
|
||||
|
||||
if (!mStreamBuffer)
|
||||
{
|
||||
DebugTrace("ERROR: Failed allocating %llu bytes for SoundStreamInstance\n", totalSize);
|
||||
mPacketSize = 0;
|
||||
totalSize = 0;
|
||||
return E_OUTOFMEMORY;
|
||||
}
|
||||
}
|
||||
|
||||
mTotalSize = static_cast<size_t>(totalSize);
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
uint8_t* ptr = (tag == WAVE_FORMAT_XMA2) ? mXMAMemory.get() : mStreamBuffer.get();
|
||||
#else
|
||||
uint8_t* ptr = mStreamBuffer.get();
|
||||
#endif
|
||||
for (size_t j = 0; j < MAX_BUFFER_COUNT; ++j)
|
||||
{
|
||||
mPackets[j].buffer = ptr;
|
||||
mPackets[j].stitchBuffer = nullptr;
|
||||
mPackets[j].request.hEvent = mBufferRead.get();
|
||||
mPackets[j].notify.Set(this, j);
|
||||
ptr += packetSize;
|
||||
}
|
||||
|
||||
if (stitchSize > 0)
|
||||
{
|
||||
for (size_t j = 0; j < MAX_BUFFER_COUNT; ++j)
|
||||
{
|
||||
mPackets[j].stitchBuffer = ptr;
|
||||
ptr += stitchSize;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
HRESULT SoundStreamInstance::Impl::ReadBuffers() noexcept
|
||||
{
|
||||
if (mCurrentPosition >= mLengthInBytes)
|
||||
{
|
||||
if (!mLooped)
|
||||
{
|
||||
mEndStream = true;
|
||||
return S_FALSE;
|
||||
}
|
||||
|
||||
#ifdef VERBOSE_TRACE
|
||||
DebugTrace("INFO (Streaming): Loop restart\n");
|
||||
#endif
|
||||
|
||||
mCurrentPosition = 0;
|
||||
}
|
||||
|
||||
HANDLE async = mWaveBank->GetAsyncHandle();
|
||||
|
||||
uint32_t readBuffer = mCurrentDiskReadBuffer;
|
||||
for (uint32_t j = 0; j < MAX_BUFFER_COUNT; ++j)
|
||||
{
|
||||
uint32_t entry = (j + readBuffer) % uint32_t(MAX_BUFFER_COUNT);
|
||||
if (mPackets[entry].state == State::FREE)
|
||||
{
|
||||
if (mCurrentPosition < mLengthInBytes)
|
||||
{
|
||||
auto cbValid = static_cast<uint32_t>(std::min(mPacketSize, mLengthInBytes - mCurrentPosition));
|
||||
|
||||
mPackets[entry].valid = cbValid;
|
||||
mPackets[entry].audioBytes = 0;
|
||||
mPackets[entry].startPosition = static_cast<uint32_t>(mCurrentPosition);
|
||||
mPackets[entry].request.Offset = static_cast<DWORD>(mOffsetBytes + mCurrentPosition);
|
||||
|
||||
if (!ReadFile(async, mPackets[entry].buffer, uint32_t(mPacketSize), nullptr, &mPackets[entry].request))
|
||||
{
|
||||
DWORD error = GetLastError();
|
||||
if (error != ERROR_IO_PENDING)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(error);
|
||||
}
|
||||
}
|
||||
|
||||
mCurrentPosition += cbValid;
|
||||
|
||||
mCurrentDiskReadBuffer = (entry + 1) % uint32_t(MAX_BUFFER_COUNT);
|
||||
|
||||
mPackets[entry].state = State::PENDING;
|
||||
|
||||
if ((cbValid < mPacketSize) && mLooped)
|
||||
{
|
||||
#ifdef VERBOSE_TRACE
|
||||
DebugTrace("INFO (Streaming): Loop restart\n");
|
||||
#endif
|
||||
mCurrentPosition = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
HRESULT SoundStreamInstance::Impl::PlayBuffers() noexcept
|
||||
{
|
||||
HANDLE async = mWaveBank->GetAsyncHandle();
|
||||
|
||||
for (uint32_t j = 0; j < MAX_BUFFER_COUNT; ++j)
|
||||
{
|
||||
if (mPackets[j].state == State::PENDING)
|
||||
{
|
||||
DWORD cb = 0;
|
||||
#if (_WIN32_WINNT >= _WIN32_WINNT_WIN8)
|
||||
BOOL result = GetOverlappedResultEx(async, &mPackets[j].request, &cb, 0, FALSE);
|
||||
#else
|
||||
BOOL result = GetOverlappedResult(async, &mPackets[j].request, &cb, FALSE);
|
||||
#endif
|
||||
if (result)
|
||||
{
|
||||
mPackets[j].state = State::READY;
|
||||
}
|
||||
else
|
||||
{
|
||||
DWORD error = GetLastError();
|
||||
if (error != ERROR_IO_INCOMPLETE)
|
||||
{
|
||||
ThrowIfFailed(HRESULT_FROM_WIN32(error));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!mBase.voice || !mPlaying)
|
||||
return S_FALSE;
|
||||
|
||||
for (uint32_t j = 0; j < MAX_BUFFER_COUNT; ++j)
|
||||
{
|
||||
if (mPackets[mCurrentPlayBuffer].state != State::READY)
|
||||
break;
|
||||
|
||||
const uint8_t* ptr = mPackets[mCurrentPlayBuffer].buffer;
|
||||
uint32_t valid = mPackets[mCurrentPlayBuffer].valid;
|
||||
|
||||
bool endstream = false;
|
||||
if (valid < mPacketSize)
|
||||
{
|
||||
endstream = true;
|
||||
#ifdef VERBOSE_TRACE
|
||||
DebugTrace("INFO (Streaming): End of stream (%u of %zu bytes)\n", mPackets[mCurrentPlayBuffer].valid, mPacketSize);
|
||||
#endif
|
||||
}
|
||||
|
||||
uint32_t thisFrameStitch = 0;
|
||||
if (mSitching)
|
||||
{
|
||||
// Compute how many left-over bytes at the end of the previous packet (if any, they form the head of a partial block).
|
||||
uint32_t prevFrameStitch = (mPackets[mCurrentPlayBuffer].startPosition % mBlockAlign);
|
||||
|
||||
if (prevFrameStitch > 0)
|
||||
{
|
||||
auto buffer = mPackets[mCurrentPlayBuffer].stitchBuffer;
|
||||
|
||||
// Compute how many bytes at the start of our current packet are the tail of the partial block.
|
||||
thisFrameStitch = mBlockAlign - prevFrameStitch;
|
||||
|
||||
uint32_t k = (mCurrentPlayBuffer + MAX_BUFFER_COUNT - 1) % MAX_BUFFER_COUNT;
|
||||
if (mPackets[k].state == State::READY || mPackets[k].state == State::PLAYING)
|
||||
{
|
||||
// Compute how many bytes at the start of the previous packet were the tail of the previous stitch block.
|
||||
uint32_t prevFrameStitchOffset = (mPackets[k].startPosition % mBlockAlign);
|
||||
prevFrameStitchOffset = (prevFrameStitchOffset > 0) ? (mBlockAlign - prevFrameStitchOffset) : 0u;
|
||||
|
||||
// Point to the start of the partial block's head in the previous packet.
|
||||
auto prevBuffer = mPackets[k].buffer + prevFrameStitchOffset + mPackets[k].audioBytes;
|
||||
|
||||
// Merge the the head partial block in the previous packet with the tail partial block at the start of our packet.
|
||||
memcpy(buffer, prevBuffer, prevFrameStitch);
|
||||
memcpy(buffer + prevFrameStitch, ptr, thisFrameStitch);
|
||||
|
||||
// Submit stitch packet (only need to get notified if we aren't submitting another packet for this buffer).
|
||||
XAUDIO2_BUFFER buf = {};
|
||||
buf.AudioBytes = mBlockAlign;
|
||||
buf.pAudioData = buffer;
|
||||
|
||||
if (endstream && (valid <= thisFrameStitch))
|
||||
{
|
||||
buf.Flags = XAUDIO2_END_OF_STREAM;
|
||||
buf.pContext = &mPackets[mCurrentPlayBuffer].notify;
|
||||
}
|
||||
#ifdef VERBOSE_TRACE
|
||||
DebugTrace("INFO (Streaming): Stitch packet (%u + %u = %u)\n", prevFrameStitch, thisFrameStitch, mBlockAlign);
|
||||
#endif
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
if (mSeekCount > 0)
|
||||
{
|
||||
XAUDIO2_BUFFER_WMA wmaBuf = {};
|
||||
wmaBuf.pDecodedPacketCumulativeBytes = mSeekTableCopy;
|
||||
wmaBuf.PacketCount = 1;
|
||||
|
||||
uint32_t seekOffset = (mPackets[k].startPosition + prevFrameStitchOffset + mPackets[k].audioBytes) / mBlockAlign;
|
||||
assert(seekOffset > 0);
|
||||
mSeekTableCopy[0] = mSeekTable[seekOffset] - mSeekTable[seekOffset - 1];
|
||||
|
||||
ThrowIfFailed(mBase.voice->SubmitSourceBuffer(&buf, &wmaBuf));
|
||||
}
|
||||
else
|
||||
#endif // XWMA
|
||||
{
|
||||
ThrowIfFailed(mBase.voice->SubmitSourceBuffer(&buf));
|
||||
}
|
||||
}
|
||||
|
||||
ptr += thisFrameStitch;
|
||||
}
|
||||
|
||||
// Compute valid audio bytes in our current packet.
|
||||
valid = ((valid - thisFrameStitch) / mBlockAlign) * mBlockAlign;
|
||||
}
|
||||
|
||||
if (valid > 0)
|
||||
{
|
||||
// Record the audioBytes we actually submitted...
|
||||
mPackets[mCurrentPlayBuffer].audioBytes = valid;
|
||||
|
||||
XAUDIO2_BUFFER buf = {};
|
||||
buf.Flags = (endstream) ? XAUDIO2_END_OF_STREAM : 0;
|
||||
buf.AudioBytes = valid;
|
||||
buf.pAudioData = ptr;
|
||||
buf.pContext = &mPackets[mCurrentPlayBuffer].notify;
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
if (mSeekCount > 0)
|
||||
{
|
||||
XAUDIO2_BUFFER_WMA wmaBuf = {};
|
||||
|
||||
wmaBuf.PacketCount = valid / mBlockAlign;
|
||||
|
||||
uint32_t seekOffset = mPackets[mCurrentPlayBuffer].startPosition / mBlockAlign;
|
||||
if (seekOffset > MAX_STREAMING_SEEK_PACKETS)
|
||||
{
|
||||
DebugTrace("ERROR: xWMA packet seek count exceeds %zu\n", MAX_STREAMING_SEEK_PACKETS);
|
||||
return E_FAIL;
|
||||
}
|
||||
else if (seekOffset > 0)
|
||||
{
|
||||
for (uint32_t i = 0; i < wmaBuf.PacketCount; ++i)
|
||||
{
|
||||
mSeekTableCopy[i] = mSeekTable[i + seekOffset] - mSeekTable[seekOffset - 1];
|
||||
}
|
||||
|
||||
wmaBuf.pDecodedPacketCumulativeBytes = mSeekTableCopy;
|
||||
}
|
||||
else
|
||||
{
|
||||
wmaBuf.pDecodedPacketCumulativeBytes = mSeekTable;
|
||||
}
|
||||
|
||||
ThrowIfFailed(mBase.voice->SubmitSourceBuffer(&buf, &wmaBuf));
|
||||
}
|
||||
else
|
||||
#endif // xWMA
|
||||
{
|
||||
ThrowIfFailed(mBase.voice->SubmitSourceBuffer(&buf));
|
||||
}
|
||||
}
|
||||
|
||||
mPackets[mCurrentPlayBuffer].state = State::PLAYING;
|
||||
mCurrentPlayBuffer = (mCurrentPlayBuffer + 1) % uint32_t(MAX_BUFFER_COUNT);
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
#ifdef VERBOSE_TRACE
|
||||
const wchar_t* SoundStreamInstance::Impl::s_debugState[4] =
|
||||
{
|
||||
L"FREE",
|
||||
L"PENDING",
|
||||
L"READY",
|
||||
L"PLAYING"
|
||||
};
|
||||
#endif
|
||||
|
||||
|
||||
//--------------------------------------------------------------------------------------
|
||||
// SoundStreamInstance
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
// Private constructors
|
||||
_Use_decl_annotations_
|
||||
SoundStreamInstance::SoundStreamInstance(AudioEngine* engine, WaveBank* waveBank, unsigned int index, SOUND_EFFECT_INSTANCE_FLAGS flags) :
|
||||
pImpl(std::make_unique<Impl>(engine, waveBank, index, flags))
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
// Move constructor.
|
||||
SoundStreamInstance::SoundStreamInstance(SoundStreamInstance&& moveFrom) noexcept
|
||||
: pImpl(std::move(moveFrom.pImpl))
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
// Move assignment.
|
||||
SoundStreamInstance& SoundStreamInstance::operator= (SoundStreamInstance&& moveFrom) noexcept
|
||||
{
|
||||
pImpl = std::move(moveFrom.pImpl);
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
// Public destructor.
|
||||
SoundStreamInstance::~SoundStreamInstance()
|
||||
{
|
||||
if (pImpl)
|
||||
{
|
||||
if (pImpl->mWaveBank)
|
||||
{
|
||||
pImpl->mWaveBank->UnregisterInstance(pImpl.get());
|
||||
pImpl->mWaveBank = nullptr;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Public methods.
|
||||
void SoundStreamInstance::Play(bool loop)
|
||||
{
|
||||
pImpl->Play(loop);
|
||||
pImpl->mPlaying = true;
|
||||
}
|
||||
|
||||
|
||||
void SoundStreamInstance::Stop(bool immediate) noexcept
|
||||
{
|
||||
pImpl->mBase.Stop(immediate, pImpl->mLooped);
|
||||
pImpl->mPlaying = !immediate;
|
||||
}
|
||||
|
||||
|
||||
void SoundStreamInstance::Pause() noexcept
|
||||
{
|
||||
pImpl->mBase.Pause();
|
||||
}
|
||||
|
||||
|
||||
void SoundStreamInstance::Resume()
|
||||
{
|
||||
pImpl->mBase.Resume();
|
||||
}
|
||||
|
||||
|
||||
void SoundStreamInstance::SetVolume(float volume)
|
||||
{
|
||||
pImpl->mBase.SetVolume(volume);
|
||||
}
|
||||
|
||||
|
||||
void SoundStreamInstance::SetPitch(float pitch)
|
||||
{
|
||||
pImpl->mBase.SetPitch(pitch);
|
||||
}
|
||||
|
||||
|
||||
void SoundStreamInstance::SetPan(float pan)
|
||||
{
|
||||
pImpl->mBase.SetPan(pan);
|
||||
}
|
||||
|
||||
|
||||
void SoundStreamInstance::Apply3D(const AudioListener& listener, const AudioEmitter& emitter, bool rhcoords)
|
||||
{
|
||||
pImpl->mBase.Apply3D(listener, emitter, rhcoords);
|
||||
}
|
||||
|
||||
|
||||
// Public accessors.
|
||||
bool SoundStreamInstance::IsLooped() const noexcept
|
||||
{
|
||||
return pImpl->mLooped;
|
||||
}
|
||||
|
||||
|
||||
SoundState SoundStreamInstance::GetState() noexcept
|
||||
{
|
||||
SoundState state = pImpl->mBase.GetState(pImpl->mEndStream);
|
||||
if (state == STOPPED)
|
||||
{
|
||||
pImpl->mPlaying = false;
|
||||
}
|
||||
return state;
|
||||
}
|
||||
|
||||
|
||||
IVoiceNotify* SoundStreamInstance::GetVoiceNotify() const noexcept
|
||||
{
|
||||
return pImpl.get();
|
||||
}
|
700
Sdk/External/DirectXTK/Audio/WAVFileReader.cpp
vendored
Normal file
700
Sdk/External/DirectXTK/Audio/WAVFileReader.cpp
vendored
Normal file
@ -0,0 +1,700 @@
|
||||
//--------------------------------------------------------------------------------------
|
||||
// File: WAVFileReader.cpp
|
||||
//
|
||||
// Functions for loading WAV audio files
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkId=248929
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615561
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#include "pch.h"
|
||||
#include "PlatformHelpers.h"
|
||||
#include "WAVFileReader.h"
|
||||
|
||||
using namespace DirectX;
|
||||
|
||||
|
||||
namespace
|
||||
{
|
||||
//---------------------------------------------------------------------------------
|
||||
// .WAV files
|
||||
//---------------------------------------------------------------------------------
|
||||
constexpr uint32_t FOURCC_RIFF_TAG = MAKEFOURCC('R', 'I', 'F', 'F');
|
||||
constexpr uint32_t FOURCC_FORMAT_TAG = MAKEFOURCC('f', 'm', 't', ' ');
|
||||
constexpr uint32_t FOURCC_DATA_TAG = MAKEFOURCC('d', 'a', 't', 'a');
|
||||
constexpr uint32_t FOURCC_WAVE_FILE_TAG = MAKEFOURCC('W', 'A', 'V', 'E');
|
||||
constexpr uint32_t FOURCC_XWMA_FILE_TAG = MAKEFOURCC('X', 'W', 'M', 'A');
|
||||
constexpr uint32_t FOURCC_DLS_SAMPLE = MAKEFOURCC('w', 's', 'm', 'p');
|
||||
constexpr uint32_t FOURCC_MIDI_SAMPLE = MAKEFOURCC('s', 'm', 'p', 'l');
|
||||
constexpr uint32_t FOURCC_XWMA_DPDS = MAKEFOURCC('d', 'p', 'd', 's');
|
||||
constexpr uint32_t FOURCC_XMA_SEEK = MAKEFOURCC('s', 'e', 'e', 'k');
|
||||
|
||||
#pragma pack(push,1)
|
||||
struct RIFFChunk
|
||||
{
|
||||
uint32_t tag;
|
||||
uint32_t size;
|
||||
};
|
||||
|
||||
struct RIFFChunkHeader
|
||||
{
|
||||
uint32_t tag;
|
||||
uint32_t size;
|
||||
uint32_t riff;
|
||||
};
|
||||
|
||||
struct DLSLoop
|
||||
{
|
||||
static const uint32_t LOOP_TYPE_FORWARD = 0x00000000;
|
||||
static const uint32_t LOOP_TYPE_RELEASE = 0x00000001;
|
||||
|
||||
uint32_t size;
|
||||
uint32_t loopType;
|
||||
uint32_t loopStart;
|
||||
uint32_t loopLength;
|
||||
};
|
||||
|
||||
struct RIFFDLSSample
|
||||
{
|
||||
static const uint32_t OPTIONS_NOTRUNCATION = 0x00000001;
|
||||
static const uint32_t OPTIONS_NOCOMPRESSION = 0x00000002;
|
||||
|
||||
uint32_t size;
|
||||
uint16_t unityNote;
|
||||
int16_t fineTune;
|
||||
int32_t gain;
|
||||
uint32_t options;
|
||||
uint32_t loopCount;
|
||||
};
|
||||
|
||||
struct MIDILoop
|
||||
{
|
||||
static const uint32_t LOOP_TYPE_FORWARD = 0x00000000;
|
||||
static const uint32_t LOOP_TYPE_ALTERNATING = 0x00000001;
|
||||
static const uint32_t LOOP_TYPE_BACKWARD = 0x00000002;
|
||||
|
||||
uint32_t cuePointId;
|
||||
uint32_t type;
|
||||
uint32_t start;
|
||||
uint32_t end;
|
||||
uint32_t fraction;
|
||||
uint32_t playCount;
|
||||
};
|
||||
|
||||
struct RIFFMIDISample
|
||||
{
|
||||
uint32_t manufacturerId;
|
||||
uint32_t productId;
|
||||
uint32_t samplePeriod;
|
||||
uint32_t unityNode;
|
||||
uint32_t pitchFraction;
|
||||
uint32_t SMPTEFormat;
|
||||
uint32_t SMPTEOffset;
|
||||
uint32_t loopCount;
|
||||
uint32_t samplerData;
|
||||
};
|
||||
#pragma pack(pop)
|
||||
|
||||
static_assert(sizeof(RIFFChunk) == 8, "structure size mismatch");
|
||||
static_assert(sizeof(RIFFChunkHeader) == 12, "structure size mismatch");
|
||||
static_assert(sizeof(DLSLoop) == 16, "structure size mismatch");
|
||||
static_assert(sizeof(RIFFDLSSample) == 20, "structure size mismatch");
|
||||
static_assert(sizeof(MIDILoop) == 24, "structure size mismatch");
|
||||
static_assert(sizeof(RIFFMIDISample) == 36, "structure size mismatch");
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
const RIFFChunk* FindChunk(
|
||||
_In_reads_bytes_(sizeBytes) const uint8_t* data,
|
||||
_In_ size_t sizeBytes,
|
||||
_In_ uint32_t tag) noexcept
|
||||
{
|
||||
if (!data)
|
||||
return nullptr;
|
||||
|
||||
const uint8_t* ptr = data;
|
||||
const uint8_t* end = data + sizeBytes;
|
||||
|
||||
while (end > (ptr + sizeof(RIFFChunk)))
|
||||
{
|
||||
auto header = reinterpret_cast<const RIFFChunk*>(ptr);
|
||||
if (header->tag == tag)
|
||||
return header;
|
||||
|
||||
auto offset = header->size + sizeof(RIFFChunk);
|
||||
ptr += offset;
|
||||
}
|
||||
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
HRESULT WaveFindFormatAndData(
|
||||
_In_reads_bytes_(wavDataSize) const uint8_t* wavData,
|
||||
_In_ size_t wavDataSize,
|
||||
_Outptr_ const WAVEFORMATEX** pwfx,
|
||||
_Outptr_ const uint8_t** pdata,
|
||||
_Out_ uint32_t* dataSize,
|
||||
_Out_ bool& dpds,
|
||||
_Out_ bool& seek) noexcept
|
||||
{
|
||||
if (!wavData || !pwfx)
|
||||
return E_POINTER;
|
||||
|
||||
dpds = seek = false;
|
||||
|
||||
if (wavDataSize < (sizeof(RIFFChunk) * 2 + sizeof(uint32_t) + sizeof(WAVEFORMAT)))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
const uint8_t* wavEnd = wavData + wavDataSize;
|
||||
|
||||
// Locate RIFF 'WAVE'
|
||||
auto riffChunk = FindChunk(wavData, wavDataSize, FOURCC_RIFF_TAG);
|
||||
if (!riffChunk || riffChunk->size < 4)
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
auto riffHeader = reinterpret_cast<const RIFFChunkHeader*>(riffChunk);
|
||||
if (riffHeader->riff != FOURCC_WAVE_FILE_TAG && riffHeader->riff != FOURCC_XWMA_FILE_TAG)
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
// Locate 'fmt '
|
||||
auto ptr = reinterpret_cast<const uint8_t*>(riffHeader) + sizeof(RIFFChunkHeader);
|
||||
if ((ptr + sizeof(RIFFChunk)) > wavEnd)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_HANDLE_EOF);
|
||||
}
|
||||
|
||||
auto fmtChunk = FindChunk(ptr, riffHeader->size, FOURCC_FORMAT_TAG);
|
||||
if (!fmtChunk || fmtChunk->size < sizeof(PCMWAVEFORMAT))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
ptr = reinterpret_cast<const uint8_t*>(fmtChunk) + sizeof(RIFFChunk);
|
||||
if (ptr + fmtChunk->size > wavEnd)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_HANDLE_EOF);
|
||||
}
|
||||
|
||||
auto wf = reinterpret_cast<const WAVEFORMAT*>(ptr);
|
||||
|
||||
// Validate WAVEFORMAT (focused on chunk size and format tag, not other data that XAUDIO2 will validate)
|
||||
switch (wf->wFormatTag)
|
||||
{
|
||||
case WAVE_FORMAT_PCM:
|
||||
case WAVE_FORMAT_IEEE_FLOAT:
|
||||
// Can be a PCMWAVEFORMAT (16 bytes) or WAVEFORMATEX (18 bytes)
|
||||
// We validiated chunk as at least sizeof(PCMWAVEFORMAT) above
|
||||
break;
|
||||
|
||||
default:
|
||||
{
|
||||
if (fmtChunk->size < sizeof(WAVEFORMATEX))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
auto wfx = reinterpret_cast<const WAVEFORMATEX*>(ptr);
|
||||
|
||||
if (fmtChunk->size < (sizeof(WAVEFORMATEX) + wfx->cbSize))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
switch (wfx->wFormatTag)
|
||||
{
|
||||
case WAVE_FORMAT_WMAUDIO2:
|
||||
case WAVE_FORMAT_WMAUDIO3:
|
||||
dpds = true;
|
||||
break;
|
||||
|
||||
case 0x166 /*WAVE_FORMAT_XMA2*/: // XMA2 is supported by Xbox One
|
||||
if ((fmtChunk->size < 52 /*sizeof(XMA2WAVEFORMATEX)*/) || (wfx->cbSize < 34 /*( sizeof(XMA2WAVEFORMATEX) - sizeof(WAVEFORMATEX) )*/))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
seek = true;
|
||||
break;
|
||||
|
||||
case WAVE_FORMAT_ADPCM:
|
||||
if ((fmtChunk->size < (sizeof(WAVEFORMATEX) + 32)) || (wfx->cbSize < 32 /*MSADPCM_FORMAT_EXTRA_BYTES*/))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
break;
|
||||
|
||||
case WAVE_FORMAT_EXTENSIBLE:
|
||||
if ((fmtChunk->size < sizeof(WAVEFORMATEXTENSIBLE)) || (wfx->cbSize < (sizeof(WAVEFORMATEXTENSIBLE) - sizeof(WAVEFORMATEX))))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
else
|
||||
{
|
||||
static const GUID s_wfexBase = { 0x00000000, 0x0000, 0x0010, { 0x80, 0x00, 0x00, 0xAA, 0x00, 0x38, 0x9B, 0x71 } };
|
||||
|
||||
auto wfex = reinterpret_cast<const WAVEFORMATEXTENSIBLE*>(ptr);
|
||||
|
||||
if (memcmp(reinterpret_cast<const BYTE*>(&wfex->SubFormat) + sizeof(DWORD),
|
||||
reinterpret_cast<const BYTE*>(&s_wfexBase) + sizeof(DWORD), sizeof(GUID) - sizeof(DWORD)) != 0)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_NOT_SUPPORTED);
|
||||
}
|
||||
|
||||
switch (wfex->SubFormat.Data1)
|
||||
{
|
||||
case WAVE_FORMAT_PCM:
|
||||
case WAVE_FORMAT_IEEE_FLOAT:
|
||||
break;
|
||||
|
||||
// MS-ADPCM and XMA2 are not supported as WAVEFORMATEXTENSIBLE
|
||||
|
||||
case WAVE_FORMAT_WMAUDIO2:
|
||||
case WAVE_FORMAT_WMAUDIO3:
|
||||
dpds = true;
|
||||
break;
|
||||
|
||||
default:
|
||||
return HRESULT_FROM_WIN32(ERROR_NOT_SUPPORTED);
|
||||
}
|
||||
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
return HRESULT_FROM_WIN32(ERROR_NOT_SUPPORTED);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Locate 'data'
|
||||
ptr = reinterpret_cast<const uint8_t*>(riffHeader) + sizeof(RIFFChunkHeader);
|
||||
if ((ptr + sizeof(RIFFChunk)) > wavEnd)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_HANDLE_EOF);
|
||||
}
|
||||
|
||||
auto dataChunk = FindChunk(ptr, riffChunk->size, FOURCC_DATA_TAG);
|
||||
if (!dataChunk || !dataChunk->size)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_INVALID_DATA);
|
||||
}
|
||||
|
||||
ptr = reinterpret_cast<const uint8_t*>(dataChunk) + sizeof(RIFFChunk);
|
||||
if (ptr + dataChunk->size > wavEnd)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_HANDLE_EOF);
|
||||
}
|
||||
|
||||
*pwfx = reinterpret_cast<const WAVEFORMATEX*>(wf);
|
||||
*pdata = ptr;
|
||||
*dataSize = dataChunk->size;
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
HRESULT WaveFindLoopInfo(
|
||||
_In_reads_bytes_(wavDataSize) const uint8_t* wavData,
|
||||
_In_ size_t wavDataSize,
|
||||
_Out_ uint32_t* pLoopStart,
|
||||
_Out_ uint32_t* pLoopLength) noexcept
|
||||
{
|
||||
if (!wavData || !pLoopStart || !pLoopLength)
|
||||
return E_POINTER;
|
||||
|
||||
if (wavDataSize < (sizeof(RIFFChunk) + sizeof(uint32_t)))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
*pLoopStart = 0;
|
||||
*pLoopLength = 0;
|
||||
|
||||
const uint8_t* wavEnd = wavData + wavDataSize;
|
||||
|
||||
// Locate RIFF 'WAVE'
|
||||
auto riffChunk = FindChunk(wavData, wavDataSize, FOURCC_RIFF_TAG);
|
||||
if (!riffChunk || riffChunk->size < 4)
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
auto riffHeader = reinterpret_cast<const RIFFChunkHeader*>(riffChunk);
|
||||
if (riffHeader->riff == FOURCC_XWMA_FILE_TAG)
|
||||
{
|
||||
// xWMA files do not contain loop information
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
if (riffHeader->riff != FOURCC_WAVE_FILE_TAG)
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
// Locate 'wsmp' (DLS Chunk)
|
||||
auto ptr = reinterpret_cast<const uint8_t*>(riffHeader) + sizeof(RIFFChunkHeader);
|
||||
if ((ptr + sizeof(RIFFChunk)) > wavEnd)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_HANDLE_EOF);
|
||||
}
|
||||
|
||||
auto dlsChunk = FindChunk(ptr, riffChunk->size, FOURCC_DLS_SAMPLE);
|
||||
if (dlsChunk)
|
||||
{
|
||||
ptr = reinterpret_cast<const uint8_t*>(dlsChunk) + sizeof(RIFFChunk);
|
||||
if (ptr + dlsChunk->size > wavEnd)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_HANDLE_EOF);
|
||||
}
|
||||
|
||||
if (dlsChunk->size >= sizeof(RIFFDLSSample))
|
||||
{
|
||||
auto dlsSample = reinterpret_cast<const RIFFDLSSample*>(ptr);
|
||||
|
||||
if (dlsChunk->size >= (dlsSample->size + dlsSample->loopCount * sizeof(DLSLoop)))
|
||||
{
|
||||
auto loops = reinterpret_cast<const DLSLoop*>(ptr + dlsSample->size);
|
||||
for (uint32_t j = 0; j < dlsSample->loopCount; ++j)
|
||||
{
|
||||
if ((loops[j].loopType == DLSLoop::LOOP_TYPE_FORWARD || loops[j].loopType == DLSLoop::LOOP_TYPE_RELEASE))
|
||||
{
|
||||
// Return 'forward' loop
|
||||
*pLoopStart = loops[j].loopStart;
|
||||
*pLoopLength = loops[j].loopLength;
|
||||
return S_OK;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Locate 'smpl' (Sample Chunk)
|
||||
auto midiChunk = FindChunk(ptr, riffChunk->size, FOURCC_MIDI_SAMPLE);
|
||||
if (midiChunk)
|
||||
{
|
||||
ptr = reinterpret_cast<const uint8_t*>(midiChunk) + sizeof(RIFFChunk);
|
||||
if (ptr + midiChunk->size > wavEnd)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_HANDLE_EOF);
|
||||
}
|
||||
|
||||
if (midiChunk->size >= sizeof(RIFFMIDISample))
|
||||
{
|
||||
auto midiSample = reinterpret_cast<const RIFFMIDISample*>(ptr);
|
||||
|
||||
if (midiChunk->size >= (sizeof(RIFFMIDISample) + midiSample->loopCount * sizeof(MIDILoop)))
|
||||
{
|
||||
auto loops = reinterpret_cast<const MIDILoop*>(ptr + sizeof(RIFFMIDISample));
|
||||
for (uint32_t j = 0; j < midiSample->loopCount; ++j)
|
||||
{
|
||||
if (loops[j].type == MIDILoop::LOOP_TYPE_FORWARD)
|
||||
{
|
||||
// Return 'forward' loop
|
||||
*pLoopStart = loops[j].start;
|
||||
*pLoopLength = loops[j].end - loops[j].start + 1;
|
||||
return S_OK;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
HRESULT WaveFindTable(
|
||||
_In_reads_bytes_(wavDataSize) const uint8_t* wavData,
|
||||
_In_ size_t wavDataSize,
|
||||
_In_ uint32_t tag,
|
||||
_Outptr_result_maybenull_ const uint32_t** pData,
|
||||
_Out_ uint32_t* dataCount) noexcept
|
||||
{
|
||||
if (!wavData || !pData || !dataCount)
|
||||
return E_POINTER;
|
||||
|
||||
if (wavDataSize < (sizeof(RIFFChunk) + sizeof(uint32_t)))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
*pData = nullptr;
|
||||
*dataCount = 0;
|
||||
|
||||
const uint8_t* wavEnd = wavData + wavDataSize;
|
||||
|
||||
// Locate RIFF 'WAVE'
|
||||
auto riffChunk = FindChunk(wavData, wavDataSize, FOURCC_RIFF_TAG);
|
||||
if (!riffChunk || riffChunk->size < 4)
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
auto riffHeader = reinterpret_cast<const RIFFChunkHeader*>(riffChunk);
|
||||
if (riffHeader->riff != FOURCC_WAVE_FILE_TAG && riffHeader->riff != FOURCC_XWMA_FILE_TAG)
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
// Locate tag
|
||||
auto ptr = reinterpret_cast<const uint8_t*>(riffHeader) + sizeof(RIFFChunkHeader);
|
||||
if ((ptr + sizeof(RIFFChunk)) > wavEnd)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_HANDLE_EOF);
|
||||
}
|
||||
|
||||
auto tableChunk = FindChunk(ptr, riffChunk->size, tag);
|
||||
if (tableChunk)
|
||||
{
|
||||
ptr = reinterpret_cast<const uint8_t*>(tableChunk) + sizeof(RIFFChunk);
|
||||
if (ptr + tableChunk->size > wavEnd)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_HANDLE_EOF);
|
||||
}
|
||||
|
||||
if ((tableChunk->size % sizeof(uint32_t)) != 0)
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
*pData = reinterpret_cast<const uint32_t*>(ptr);
|
||||
*dataCount = tableChunk->size / 4;
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
HRESULT LoadAudioFromFile(
|
||||
_In_z_ const wchar_t* szFileName,
|
||||
_Inout_ std::unique_ptr<uint8_t[]>& wavData,
|
||||
_Out_ DWORD* bytesRead) noexcept
|
||||
{
|
||||
if (!szFileName)
|
||||
return E_INVALIDARG;
|
||||
|
||||
// open the file
|
||||
#if (_WIN32_WINNT >= _WIN32_WINNT_WIN8)
|
||||
ScopedHandle hFile(safe_handle(CreateFile2(szFileName,
|
||||
GENERIC_READ,
|
||||
FILE_SHARE_READ,
|
||||
OPEN_EXISTING,
|
||||
nullptr)));
|
||||
#else
|
||||
ScopedHandle hFile(safe_handle(CreateFileW(szFileName,
|
||||
GENERIC_READ,
|
||||
FILE_SHARE_READ,
|
||||
nullptr,
|
||||
OPEN_EXISTING,
|
||||
FILE_ATTRIBUTE_NORMAL,
|
||||
nullptr)));
|
||||
#endif
|
||||
|
||||
if (!hFile)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
}
|
||||
|
||||
// Get the file size
|
||||
FILE_STANDARD_INFO fileInfo;
|
||||
if (!GetFileInformationByHandleEx(hFile.get(), FileStandardInfo, &fileInfo, sizeof(fileInfo)))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
}
|
||||
|
||||
// File is too big for 32-bit allocation, so reject read
|
||||
if (fileInfo.EndOfFile.HighPart > 0)
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
// Need at least enough data to have a valid minimal WAV file
|
||||
if (fileInfo.EndOfFile.LowPart < (sizeof(RIFFChunk) * 2 + sizeof(DWORD) + sizeof(WAVEFORMAT)))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
// create enough space for the file data
|
||||
wavData.reset(new (std::nothrow) uint8_t[fileInfo.EndOfFile.LowPart]);
|
||||
if (!wavData)
|
||||
{
|
||||
return E_OUTOFMEMORY;
|
||||
}
|
||||
|
||||
// read the data in
|
||||
if (!ReadFile(hFile.get(),
|
||||
wavData.get(),
|
||||
fileInfo.EndOfFile.LowPart,
|
||||
bytesRead,
|
||||
nullptr
|
||||
))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
}
|
||||
|
||||
return (*bytesRead < fileInfo.EndOfFile.LowPart) ? E_FAIL : S_OK;
|
||||
}
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
_Use_decl_annotations_
|
||||
HRESULT DirectX::LoadWAVAudioInMemory(
|
||||
const uint8_t* wavData,
|
||||
size_t wavDataSize,
|
||||
const WAVEFORMATEX** wfx,
|
||||
const uint8_t** startAudio,
|
||||
uint32_t* audioBytes) noexcept
|
||||
{
|
||||
if (!wavData || !wfx || !startAudio || !audioBytes)
|
||||
return E_INVALIDARG;
|
||||
|
||||
*wfx = nullptr;
|
||||
*startAudio = nullptr;
|
||||
*audioBytes = 0;
|
||||
|
||||
// Need at least enough data to have a valid minimal WAV file
|
||||
if (wavDataSize < (sizeof(RIFFChunk) * 2 + sizeof(DWORD) + sizeof(WAVEFORMAT)))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
bool dpds, seek;
|
||||
HRESULT hr = WaveFindFormatAndData(wavData, wavDataSize, wfx, startAudio, audioBytes, dpds, seek);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
return (dpds || seek) ? E_FAIL : S_OK;
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
_Use_decl_annotations_
|
||||
HRESULT DirectX::LoadWAVAudioFromFile(
|
||||
const wchar_t* szFileName,
|
||||
std::unique_ptr<uint8_t[]>& wavData,
|
||||
const WAVEFORMATEX** wfx,
|
||||
const uint8_t** startAudio,
|
||||
uint32_t* audioBytes) noexcept
|
||||
{
|
||||
if (!szFileName || !wfx || !startAudio || !audioBytes)
|
||||
return E_INVALIDARG;
|
||||
|
||||
*wfx = nullptr;
|
||||
*startAudio = nullptr;
|
||||
*audioBytes = 0;
|
||||
|
||||
DWORD bytesRead = 0;
|
||||
HRESULT hr = LoadAudioFromFile(szFileName, wavData, &bytesRead);
|
||||
if (FAILED(hr))
|
||||
{
|
||||
return hr;
|
||||
}
|
||||
|
||||
bool dpds, seek;
|
||||
hr = WaveFindFormatAndData(wavData.get(), bytesRead, wfx, startAudio, audioBytes, dpds, seek);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
return (dpds || seek) ? E_FAIL : S_OK;
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
_Use_decl_annotations_
|
||||
HRESULT DirectX::LoadWAVAudioInMemoryEx(
|
||||
const uint8_t* wavData,
|
||||
size_t wavDataSize,
|
||||
DirectX::WAVData& result) noexcept
|
||||
{
|
||||
if (!wavData)
|
||||
return E_INVALIDARG;
|
||||
|
||||
memset(&result, 0, sizeof(result));
|
||||
|
||||
// Need at least enough data to have a valid minimal WAV file
|
||||
if (wavDataSize < (sizeof(RIFFChunk) * 2 + sizeof(DWORD) + sizeof(WAVEFORMAT)))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
bool dpds, seek;
|
||||
HRESULT hr = WaveFindFormatAndData(wavData, wavDataSize, &result.wfx, &result.startAudio, &result.audioBytes, dpds, seek);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
hr = WaveFindLoopInfo(wavData, wavDataSize, &result.loopStart, &result.loopLength);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
if (dpds)
|
||||
{
|
||||
hr = WaveFindTable(wavData, wavDataSize, FOURCC_XWMA_DPDS, &result.seek, &result.seekCount);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
}
|
||||
else if (seek)
|
||||
{
|
||||
hr = WaveFindTable(wavData, wavDataSize, FOURCC_XMA_SEEK, &result.seek, &result.seekCount);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
_Use_decl_annotations_
|
||||
HRESULT DirectX::LoadWAVAudioFromFileEx(
|
||||
const wchar_t* szFileName,
|
||||
std::unique_ptr<uint8_t[]>& wavData,
|
||||
DirectX::WAVData& result) noexcept
|
||||
{
|
||||
if (!szFileName)
|
||||
return E_INVALIDARG;
|
||||
|
||||
memset(&result, 0, sizeof(result));
|
||||
|
||||
DWORD bytesRead = 0;
|
||||
HRESULT hr = LoadAudioFromFile(szFileName, wavData, &bytesRead);
|
||||
if (FAILED(hr))
|
||||
{
|
||||
return hr;
|
||||
}
|
||||
|
||||
bool dpds, seek;
|
||||
hr = WaveFindFormatAndData(wavData.get(), bytesRead, &result.wfx, &result.startAudio, &result.audioBytes, dpds, seek);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
hr = WaveFindLoopInfo(wavData.get(), bytesRead, &result.loopStart, &result.loopLength);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
if (dpds)
|
||||
{
|
||||
hr = WaveFindTable(wavData.get(), bytesRead, FOURCC_XWMA_DPDS, &result.seek, &result.seekCount);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
}
|
||||
else if (seek)
|
||||
{
|
||||
hr = WaveFindTable(wavData.get(), bytesRead, FOURCC_XMA_SEEK, &result.seek, &result.seekCount);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
58
Sdk/External/DirectXTK/Audio/WAVFileReader.h
vendored
Normal file
58
Sdk/External/DirectXTK/Audio/WAVFileReader.h
vendored
Normal file
@ -0,0 +1,58 @@
|
||||
//--------------------------------------------------------------------------------------
|
||||
// File: WAVFileReader.h
|
||||
//
|
||||
// Functions for loading WAV audio files
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkId=248929
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615561
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <objbase.h>
|
||||
|
||||
#include <cstdint>
|
||||
#include <memory>
|
||||
#include <mmreg.h>
|
||||
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
HRESULT LoadWAVAudioInMemory(
|
||||
_In_reads_bytes_(wavDataSize) const uint8_t* wavData,
|
||||
_In_ size_t wavDataSize,
|
||||
_Outptr_ const WAVEFORMATEX** wfx,
|
||||
_Outptr_ const uint8_t** startAudio,
|
||||
_Out_ uint32_t* audioBytes) noexcept;
|
||||
|
||||
HRESULT LoadWAVAudioFromFile(
|
||||
_In_z_ const wchar_t* szFileName,
|
||||
_Inout_ std::unique_ptr<uint8_t[]>& wavData,
|
||||
_Outptr_ const WAVEFORMATEX** wfx,
|
||||
_Outptr_ const uint8_t** startAudio,
|
||||
_Out_ uint32_t* audioBytes) noexcept;
|
||||
|
||||
struct WAVData
|
||||
{
|
||||
const WAVEFORMATEX* wfx;
|
||||
const uint8_t* startAudio;
|
||||
uint32_t audioBytes;
|
||||
uint32_t loopStart;
|
||||
uint32_t loopLength;
|
||||
const uint32_t* seek; // Note: XMA Seek data is Big-Endian
|
||||
uint32_t seekCount;
|
||||
};
|
||||
|
||||
HRESULT LoadWAVAudioInMemoryEx(
|
||||
_In_reads_bytes_(wavDataSize) const uint8_t* wavData,
|
||||
_In_ size_t wavDataSize,
|
||||
_Out_ WAVData& result) noexcept;
|
||||
|
||||
HRESULT LoadWAVAudioFromFileEx(
|
||||
_In_z_ const wchar_t* szFileName,
|
||||
_Inout_ std::unique_ptr<uint8_t[]>& wavData,
|
||||
_Out_ WAVData& result) noexcept;
|
||||
}
|
615
Sdk/External/DirectXTK/Audio/WaveBank.cpp
vendored
Normal file
615
Sdk/External/DirectXTK/Audio/WaveBank.cpp
vendored
Normal file
@ -0,0 +1,615 @@
|
||||
//--------------------------------------------------------------------------------------
|
||||
// File: WaveBank.cpp
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkId=248929
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615561
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
#include "pch.h"
|
||||
#include "Audio.h"
|
||||
#include "WaveBankReader.h"
|
||||
#include "SoundCommon.h"
|
||||
#include "PlatformHelpers.h"
|
||||
|
||||
#include <list>
|
||||
|
||||
using namespace DirectX;
|
||||
|
||||
|
||||
//======================================================================================
|
||||
// WaveBank
|
||||
//======================================================================================
|
||||
|
||||
// Internal object implementation class.
|
||||
class WaveBank::Impl : public IVoiceNotify
|
||||
{
|
||||
public:
|
||||
explicit Impl(_In_ AudioEngine* engine) :
|
||||
mEngine(engine),
|
||||
mOneShots(0),
|
||||
mPrepared(false),
|
||||
mStreaming(false)
|
||||
{
|
||||
assert(mEngine != nullptr);
|
||||
mEngine->RegisterNotify(this, false);
|
||||
}
|
||||
|
||||
Impl(Impl&&) = default;
|
||||
Impl& operator= (Impl&&) = default;
|
||||
|
||||
Impl(Impl const&) = delete;
|
||||
Impl& operator= (Impl const&) = delete;
|
||||
|
||||
~Impl() override
|
||||
{
|
||||
if (!mInstances.empty())
|
||||
{
|
||||
DebugTrace("WARNING: Destroying WaveBank \"%hs\" with %zu outstanding instances\n",
|
||||
mReader.BankName(), mInstances.size());
|
||||
|
||||
for (auto it = mInstances.begin(); it != mInstances.end(); ++it)
|
||||
{
|
||||
assert(*it != nullptr);
|
||||
(*it)->OnDestroyParent();
|
||||
}
|
||||
|
||||
mInstances.clear();
|
||||
}
|
||||
|
||||
if (mOneShots > 0)
|
||||
{
|
||||
DebugTrace("WARNING: Destroying WaveBank \"%hs\" with %u outstanding one shot effects\n",
|
||||
mReader.BankName(), mOneShots);
|
||||
}
|
||||
|
||||
if (mEngine)
|
||||
{
|
||||
mEngine->UnregisterNotify(this, true, false);
|
||||
mEngine = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
HRESULT Initialize(_In_ AudioEngine* engine, _In_z_ const wchar_t* wbFileName) noexcept;
|
||||
|
||||
void Play(unsigned int index, float volume, float pitch, float pan);
|
||||
|
||||
// IVoiceNotify
|
||||
void __cdecl OnBufferEnd() override
|
||||
{
|
||||
InterlockedDecrement(&mOneShots);
|
||||
}
|
||||
|
||||
void __cdecl OnCriticalError() override
|
||||
{
|
||||
mOneShots = 0;
|
||||
}
|
||||
|
||||
void __cdecl OnReset() override
|
||||
{
|
||||
// No action required
|
||||
}
|
||||
|
||||
void __cdecl OnUpdate() override
|
||||
{
|
||||
// We do not register for update notification
|
||||
assert(false);
|
||||
}
|
||||
|
||||
void __cdecl OnDestroyEngine() noexcept override
|
||||
{
|
||||
mEngine = nullptr;
|
||||
mOneShots = 0;
|
||||
}
|
||||
|
||||
void __cdecl OnTrim() override
|
||||
{
|
||||
// No action required
|
||||
}
|
||||
|
||||
void __cdecl GatherStatistics(AudioStatistics& stats) const noexcept override
|
||||
{
|
||||
stats.playingOneShots += mOneShots;
|
||||
|
||||
if (!mStreaming)
|
||||
{
|
||||
stats.audioBytes += mReader.BankAudioSize();
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XMA2
|
||||
if (mReader.HasXMA())
|
||||
stats.xmaAudioBytes += mReader.BankAudioSize();
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
void __cdecl OnDestroyParent() noexcept override
|
||||
{
|
||||
}
|
||||
|
||||
AudioEngine* mEngine;
|
||||
std::list<IVoiceNotify*> mInstances;
|
||||
WaveBankReader mReader;
|
||||
uint32_t mOneShots;
|
||||
bool mPrepared;
|
||||
bool mStreaming;
|
||||
};
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
HRESULT WaveBank::Impl::Initialize(AudioEngine* engine, const wchar_t* wbFileName) noexcept
|
||||
{
|
||||
if (!engine || !wbFileName)
|
||||
return E_INVALIDARG;
|
||||
|
||||
HRESULT hr = mReader.Open(wbFileName);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
mStreaming = mReader.IsStreamingBank();
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
void WaveBank::Impl::Play(unsigned int index, float volume, float pitch, float pan)
|
||||
{
|
||||
assert(volume >= -XAUDIO2_MAX_VOLUME_LEVEL && volume <= XAUDIO2_MAX_VOLUME_LEVEL);
|
||||
assert(pitch >= -1.f && pitch <= 1.f);
|
||||
assert(pan >= -1.f && pan <= 1.f);
|
||||
|
||||
if (mStreaming)
|
||||
{
|
||||
DebugTrace("ERROR: One-shots can only be created from an in-memory wave bank\n");
|
||||
throw std::exception("WaveBank::Play");
|
||||
}
|
||||
|
||||
if (index >= mReader.Count())
|
||||
{
|
||||
DebugTrace("WARNING: Index %u not found in wave bank with only %u entries, one-shot not triggered\n",
|
||||
index, mReader.Count());
|
||||
return;
|
||||
}
|
||||
|
||||
if (!mPrepared)
|
||||
{
|
||||
mReader.WaitOnPrepare();
|
||||
mPrepared = true;
|
||||
}
|
||||
|
||||
char wfxbuff[64] = {};
|
||||
auto wfx = reinterpret_cast<WAVEFORMATEX*>(wfxbuff);
|
||||
HRESULT hr = mReader.GetFormat(index, wfx, sizeof(wfxbuff));
|
||||
ThrowIfFailed(hr);
|
||||
|
||||
IXAudio2SourceVoice* voice = nullptr;
|
||||
mEngine->AllocateVoice(wfx, SoundEffectInstance_Default, true, &voice);
|
||||
|
||||
if (!voice)
|
||||
return;
|
||||
|
||||
if (volume != 1.f)
|
||||
{
|
||||
hr = voice->SetVolume(volume);
|
||||
ThrowIfFailed(hr);
|
||||
}
|
||||
|
||||
if (pitch != 0.f)
|
||||
{
|
||||
float fr = XAudio2SemitonesToFrequencyRatio(pitch * 12.f);
|
||||
|
||||
hr = voice->SetFrequencyRatio(fr);
|
||||
ThrowIfFailed(hr);
|
||||
}
|
||||
|
||||
if (pan != 0.f)
|
||||
{
|
||||
float matrix[16];
|
||||
if (ComputePan(pan, wfx->nChannels, matrix))
|
||||
{
|
||||
hr = voice->SetOutputMatrix(nullptr, wfx->nChannels, mEngine->GetOutputChannels(), matrix);
|
||||
ThrowIfFailed(hr);
|
||||
}
|
||||
}
|
||||
|
||||
hr = voice->Start(0);
|
||||
ThrowIfFailed(hr);
|
||||
|
||||
XAUDIO2_BUFFER buffer = {};
|
||||
hr = mReader.GetWaveData(index, &buffer.pAudioData, buffer.AudioBytes);
|
||||
ThrowIfFailed(hr);
|
||||
|
||||
WaveBankReader::Metadata metadata;
|
||||
hr = mReader.GetMetadata(index, metadata);
|
||||
ThrowIfFailed(hr);
|
||||
|
||||
buffer.Flags = XAUDIO2_END_OF_STREAM;
|
||||
buffer.pContext = this;
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
|
||||
XAUDIO2_BUFFER_WMA wmaBuffer = {};
|
||||
|
||||
uint32_t tag;
|
||||
hr = mReader.GetSeekTable(index, &wmaBuffer.pDecodedPacketCumulativeBytes, wmaBuffer.PacketCount, tag);
|
||||
ThrowIfFailed(hr);
|
||||
|
||||
if (tag == WAVE_FORMAT_WMAUDIO2 || tag == WAVE_FORMAT_WMAUDIO3)
|
||||
{
|
||||
hr = voice->SubmitSourceBuffer(&buffer, &wmaBuffer);
|
||||
}
|
||||
else
|
||||
#endif // xWMA
|
||||
{
|
||||
hr = voice->SubmitSourceBuffer(&buffer, nullptr);
|
||||
}
|
||||
if (FAILED(hr))
|
||||
{
|
||||
DebugTrace("ERROR: WaveBank failed (%08X) when submitting buffer:\n", static_cast<unsigned int>(hr));
|
||||
DebugTrace("\tFormat Tag %u, %u channels, %u-bit, %u Hz, %u bytes\n",
|
||||
wfx->wFormatTag, wfx->nChannels, wfx->wBitsPerSample, wfx->nSamplesPerSec, metadata.lengthBytes);
|
||||
throw std::exception("SubmitSourceBuffer");
|
||||
}
|
||||
|
||||
InterlockedIncrement(&mOneShots);
|
||||
}
|
||||
|
||||
|
||||
//--------------------------------------------------------------------------------------
|
||||
// WaveBank
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
// Public constructors.
|
||||
_Use_decl_annotations_
|
||||
WaveBank::WaveBank(AudioEngine* engine, const wchar_t* wbFileName)
|
||||
: pImpl(std::make_unique<Impl>(engine))
|
||||
{
|
||||
HRESULT hr = pImpl->Initialize(engine, wbFileName);
|
||||
if (FAILED(hr))
|
||||
{
|
||||
DebugTrace("ERROR: WaveBank failed (%08X) to intialize from .xwb file \"%ls\"\n",
|
||||
static_cast<unsigned int>(hr), wbFileName);
|
||||
throw std::exception("WaveBank");
|
||||
}
|
||||
|
||||
DebugTrace("INFO: WaveBank \"%hs\" with %u entries loaded from .xwb file \"%ls\"\n",
|
||||
pImpl->mReader.BankName(), pImpl->mReader.Count(), wbFileName);
|
||||
}
|
||||
|
||||
|
||||
// Move constructor.
|
||||
WaveBank::WaveBank(WaveBank&& moveFrom) noexcept
|
||||
: pImpl(std::move(moveFrom.pImpl))
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
// Move assignment.
|
||||
WaveBank& WaveBank::operator= (WaveBank&& moveFrom) noexcept
|
||||
{
|
||||
pImpl = std::move(moveFrom.pImpl);
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
// Public destructor.
|
||||
WaveBank::~WaveBank()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
// Public methods (one-shots)
|
||||
void WaveBank::Play(unsigned int index)
|
||||
{
|
||||
pImpl->Play(index, 1.f, 0.f, 0.f);
|
||||
}
|
||||
|
||||
|
||||
void WaveBank::Play(unsigned int index, float volume, float pitch, float pan)
|
||||
{
|
||||
pImpl->Play(index, volume, pitch, pan);
|
||||
}
|
||||
|
||||
|
||||
void WaveBank::Play(_In_z_ const char* name)
|
||||
{
|
||||
unsigned int index = pImpl->mReader.Find(name);
|
||||
if (index == unsigned(-1))
|
||||
{
|
||||
DebugTrace("WARNING: Name '%hs' not found in wave bank, one-shot not triggered\n", name);
|
||||
return;
|
||||
}
|
||||
|
||||
pImpl->Play(index, 1.f, 0.f, 0.f);
|
||||
}
|
||||
|
||||
|
||||
void WaveBank::Play(_In_z_ const char* name, float volume, float pitch, float pan)
|
||||
{
|
||||
unsigned int index = pImpl->mReader.Find(name);
|
||||
if (index == unsigned(-1))
|
||||
{
|
||||
DebugTrace("WARNING: Name '%hs' not found in wave bank, one-shot not triggered\n", name);
|
||||
return;
|
||||
}
|
||||
|
||||
pImpl->Play(index, volume, pitch, pan);
|
||||
}
|
||||
|
||||
|
||||
// Public methods (sound effect instance)
|
||||
std::unique_ptr<SoundEffectInstance> WaveBank::CreateInstance(unsigned int index, SOUND_EFFECT_INSTANCE_FLAGS flags)
|
||||
{
|
||||
auto& wb = pImpl->mReader;
|
||||
|
||||
if (pImpl->mStreaming)
|
||||
{
|
||||
DebugTrace("ERROR: SoundEffectInstances can only be created from an in-memory wave bank\n");
|
||||
throw std::exception("WaveBank::CreateInstance");
|
||||
}
|
||||
|
||||
if (index >= wb.Count())
|
||||
{
|
||||
// We don't throw an exception here as titles often simply ignore missing assets rather than fail
|
||||
return std::unique_ptr<SoundEffectInstance>();
|
||||
}
|
||||
|
||||
if (!pImpl->mPrepared)
|
||||
{
|
||||
wb.WaitOnPrepare();
|
||||
pImpl->mPrepared = true;
|
||||
}
|
||||
|
||||
auto effect = new SoundEffectInstance(pImpl->mEngine, this, index, flags);
|
||||
assert(effect != nullptr);
|
||||
pImpl->mInstances.emplace_back(effect->GetVoiceNotify());
|
||||
return std::unique_ptr<SoundEffectInstance>(effect);
|
||||
}
|
||||
|
||||
|
||||
std::unique_ptr<SoundEffectInstance> WaveBank::CreateInstance(_In_z_ const char* name, SOUND_EFFECT_INSTANCE_FLAGS flags)
|
||||
{
|
||||
unsigned int index = pImpl->mReader.Find(name);
|
||||
if (index == unsigned(-1))
|
||||
{
|
||||
// We don't throw an exception here as titles often simply ignore missing assets rather than fail
|
||||
return std::unique_ptr<SoundEffectInstance>();
|
||||
}
|
||||
|
||||
return CreateInstance(index, flags);
|
||||
}
|
||||
|
||||
|
||||
// Public methods (sound stream instance)
|
||||
std::unique_ptr<SoundStreamInstance> WaveBank::CreateStreamInstance(unsigned int index, SOUND_EFFECT_INSTANCE_FLAGS flags)
|
||||
{
|
||||
auto& wb = pImpl->mReader;
|
||||
|
||||
if (!pImpl->mStreaming)
|
||||
{
|
||||
DebugTrace("ERROR: SoundStreamInstances can only be created from a streaming wave bank\n");
|
||||
throw std::exception("WaveBank::CreateStreamInstance");
|
||||
}
|
||||
|
||||
if (index >= wb.Count())
|
||||
{
|
||||
// We don't throw an exception here as titles often simply ignore missing assets rather than fail
|
||||
return std::unique_ptr<SoundStreamInstance>();
|
||||
}
|
||||
|
||||
if (!pImpl->mPrepared)
|
||||
{
|
||||
wb.WaitOnPrepare();
|
||||
pImpl->mPrepared = true;
|
||||
}
|
||||
|
||||
auto effect = new SoundStreamInstance(pImpl->mEngine, this, index, flags);
|
||||
assert(effect != nullptr);
|
||||
pImpl->mInstances.emplace_back(effect->GetVoiceNotify());
|
||||
return std::unique_ptr<SoundStreamInstance>(effect);
|
||||
}
|
||||
|
||||
|
||||
std::unique_ptr<SoundStreamInstance> WaveBank::CreateStreamInstance(_In_z_ const char* name, SOUND_EFFECT_INSTANCE_FLAGS flags)
|
||||
{
|
||||
unsigned int index = pImpl->mReader.Find(name);
|
||||
if (index == unsigned(-1))
|
||||
{
|
||||
// We don't throw an exception here as titles often simply ignore missing assets rather than fail
|
||||
return std::unique_ptr<SoundStreamInstance>();
|
||||
}
|
||||
|
||||
return CreateStreamInstance(index, flags);
|
||||
}
|
||||
|
||||
|
||||
void WaveBank::UnregisterInstance(_In_ IVoiceNotify* instance)
|
||||
{
|
||||
auto it = std::find(pImpl->mInstances.begin(), pImpl->mInstances.end(), instance);
|
||||
if (it == pImpl->mInstances.end())
|
||||
return;
|
||||
|
||||
pImpl->mInstances.erase(it);
|
||||
}
|
||||
|
||||
|
||||
// Public accessors.
|
||||
bool WaveBank::IsPrepared() const noexcept
|
||||
{
|
||||
if (pImpl->mPrepared)
|
||||
return true;
|
||||
|
||||
if (!pImpl->mReader.IsPrepared())
|
||||
return false;
|
||||
|
||||
pImpl->mPrepared = true;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
bool WaveBank::IsInUse() const noexcept
|
||||
{
|
||||
return (pImpl->mOneShots > 0) || !pImpl->mInstances.empty();
|
||||
}
|
||||
|
||||
|
||||
bool WaveBank::IsStreamingBank() const noexcept
|
||||
{
|
||||
return pImpl->mReader.IsStreamingBank();
|
||||
}
|
||||
|
||||
|
||||
size_t WaveBank::GetSampleSizeInBytes(unsigned int index) const noexcept
|
||||
{
|
||||
if (index >= pImpl->mReader.Count())
|
||||
return 0;
|
||||
|
||||
WaveBankReader::Metadata metadata;
|
||||
HRESULT hr = pImpl->mReader.GetMetadata(index, metadata);
|
||||
if (FAILED(hr))
|
||||
return 0;
|
||||
|
||||
return metadata.lengthBytes;
|
||||
}
|
||||
|
||||
|
||||
size_t WaveBank::GetSampleDuration(unsigned int index) const noexcept
|
||||
{
|
||||
if (index >= pImpl->mReader.Count())
|
||||
return 0;
|
||||
|
||||
WaveBankReader::Metadata metadata;
|
||||
HRESULT hr = pImpl->mReader.GetMetadata(index, metadata);
|
||||
if (FAILED(hr))
|
||||
return 0;
|
||||
|
||||
return metadata.duration;
|
||||
}
|
||||
|
||||
|
||||
size_t WaveBank::GetSampleDurationMS(unsigned int index) const noexcept
|
||||
{
|
||||
if (index >= pImpl->mReader.Count())
|
||||
return 0;
|
||||
|
||||
char buff[64] = {};
|
||||
auto wfx = reinterpret_cast<WAVEFORMATEX*>(buff);
|
||||
HRESULT hr = pImpl->mReader.GetFormat(index, wfx, sizeof(buff));
|
||||
if (FAILED(hr))
|
||||
return 0;
|
||||
|
||||
WaveBankReader::Metadata metadata;
|
||||
hr = pImpl->mReader.GetMetadata(index, metadata);
|
||||
if (FAILED(hr))
|
||||
return 0;
|
||||
|
||||
return static_cast<size_t>((uint64_t(metadata.duration) * 1000) / wfx->nSamplesPerSec);
|
||||
}
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
const WAVEFORMATEX* WaveBank::GetFormat(unsigned int index, WAVEFORMATEX* wfx, size_t maxsize) const noexcept
|
||||
{
|
||||
if (index >= pImpl->mReader.Count())
|
||||
return nullptr;
|
||||
|
||||
HRESULT hr = pImpl->mReader.GetFormat(index, wfx, maxsize);
|
||||
if (FAILED(hr))
|
||||
return nullptr;
|
||||
|
||||
return wfx;
|
||||
}
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
int WaveBank::Find(const char* name) const
|
||||
{
|
||||
return static_cast<int>(pImpl->mReader.Find(name));
|
||||
}
|
||||
|
||||
|
||||
#ifdef DIRECTX_ENABLE_XWMA
|
||||
|
||||
_Use_decl_annotations_
|
||||
bool WaveBank::FillSubmitBuffer(unsigned int index, XAUDIO2_BUFFER& buffer, XAUDIO2_BUFFER_WMA& wmaBuffer) const
|
||||
{
|
||||
memset(&buffer, 0, sizeof(buffer));
|
||||
memset(&wmaBuffer, 0, sizeof(wmaBuffer));
|
||||
|
||||
HRESULT hr = pImpl->mReader.GetWaveData(index, &buffer.pAudioData, buffer.AudioBytes);
|
||||
ThrowIfFailed(hr);
|
||||
|
||||
WaveBankReader::Metadata metadata;
|
||||
hr = pImpl->mReader.GetMetadata(index, metadata);
|
||||
ThrowIfFailed(hr);
|
||||
|
||||
buffer.LoopBegin = metadata.loopStart;
|
||||
buffer.LoopLength = metadata.loopLength;
|
||||
|
||||
uint32_t tag;
|
||||
hr = pImpl->mReader.GetSeekTable(index, &wmaBuffer.pDecodedPacketCumulativeBytes, wmaBuffer.PacketCount, tag);
|
||||
ThrowIfFailed(hr);
|
||||
|
||||
return (tag == WAVE_FORMAT_WMAUDIO2 || tag == WAVE_FORMAT_WMAUDIO3);
|
||||
}
|
||||
|
||||
#else // !xWMA
|
||||
|
||||
_Use_decl_annotations_
|
||||
void WaveBank::FillSubmitBuffer(unsigned int index, XAUDIO2_BUFFER& buffer) const
|
||||
{
|
||||
memset(&buffer, 0, sizeof(buffer));
|
||||
|
||||
HRESULT hr = pImpl->mReader.GetWaveData(index, &buffer.pAudioData, buffer.AudioBytes);
|
||||
ThrowIfFailed(hr);
|
||||
|
||||
WaveBankReader::Metadata metadata;
|
||||
hr = pImpl->mReader.GetMetadata(index, metadata);
|
||||
ThrowIfFailed(hr);
|
||||
|
||||
buffer.LoopBegin = metadata.loopStart;
|
||||
buffer.LoopLength = metadata.loopLength;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
HANDLE WaveBank::GetAsyncHandle() const noexcept
|
||||
{
|
||||
if (pImpl)
|
||||
{
|
||||
return pImpl->mReader.GetAsyncHandle();
|
||||
}
|
||||
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
||||
_Use_decl_annotations_
|
||||
bool WaveBank::GetPrivateData(unsigned int index, void* data, size_t datasize)
|
||||
{
|
||||
if (index >= pImpl->mReader.Count())
|
||||
return false;
|
||||
|
||||
if (!data)
|
||||
return false;
|
||||
|
||||
switch (datasize)
|
||||
{
|
||||
case sizeof(WaveBankReader::Metadata):
|
||||
{
|
||||
auto ptr = reinterpret_cast<WaveBankReader::Metadata*>(data);
|
||||
return SUCCEEDED(pImpl->mReader.GetMetadata(index, *ptr));
|
||||
}
|
||||
|
||||
case sizeof(WaveBankSeekData):
|
||||
{
|
||||
auto ptr = reinterpret_cast<WaveBankSeekData*>(data);
|
||||
return SUCCEEDED(pImpl->mReader.GetSeekTable(index, &ptr->seekTable, ptr->seekCount, ptr->tag));
|
||||
}
|
||||
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
1386
Sdk/External/DirectXTK/Audio/WaveBankReader.cpp
vendored
Normal file
1386
Sdk/External/DirectXTK/Audio/WaveBankReader.cpp
vendored
Normal file
File diff suppressed because it is too large
Load Diff
81
Sdk/External/DirectXTK/Audio/WaveBankReader.h
vendored
Normal file
81
Sdk/External/DirectXTK/Audio/WaveBankReader.h
vendored
Normal file
@ -0,0 +1,81 @@
|
||||
//--------------------------------------------------------------------------------------
|
||||
// File: WaveBankReader.h
|
||||
//
|
||||
// Functions for loading audio data from Wave Banks
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkId=248929
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615561
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <objbase.h>
|
||||
#include <mmreg.h>
|
||||
|
||||
#include <cstdint>
|
||||
#include <memory>
|
||||
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
class WaveBankReader
|
||||
{
|
||||
public:
|
||||
WaveBankReader() noexcept(false);
|
||||
|
||||
WaveBankReader(WaveBankReader&&) = default;
|
||||
WaveBankReader& operator= (WaveBankReader&&) = default;
|
||||
|
||||
WaveBankReader(WaveBankReader const&) = delete;
|
||||
WaveBankReader& operator= (WaveBankReader const&) = delete;
|
||||
|
||||
~WaveBankReader();
|
||||
|
||||
HRESULT Open(_In_z_ const wchar_t* szFileName) noexcept;
|
||||
|
||||
uint32_t Find(_In_z_ const char* name) const;
|
||||
|
||||
bool IsPrepared() noexcept;
|
||||
void WaitOnPrepare() noexcept;
|
||||
|
||||
bool HasNames() const noexcept;
|
||||
bool IsStreamingBank() const noexcept;
|
||||
|
||||
#if (defined(_XBOX_ONE) && defined(_TITLE)) || defined(_GAMING_XBOX)
|
||||
bool HasXMA() const noexcept;
|
||||
#endif
|
||||
|
||||
const char* BankName() const noexcept;
|
||||
|
||||
uint32_t Count() const noexcept;
|
||||
|
||||
uint32_t BankAudioSize() const noexcept;
|
||||
|
||||
HRESULT GetFormat(_In_ uint32_t index, _Out_writes_bytes_(maxsize) WAVEFORMATEX* pFormat, _In_ size_t maxsize) const noexcept;
|
||||
|
||||
HRESULT GetWaveData(_In_ uint32_t index, _Outptr_ const uint8_t** pData, _Out_ uint32_t& dataSize) const noexcept;
|
||||
|
||||
HRESULT GetSeekTable(_In_ uint32_t index, _Out_ const uint32_t** pData, _Out_ uint32_t& dataCount, _Out_ uint32_t& tag) const noexcept;
|
||||
|
||||
HANDLE GetAsyncHandle() const noexcept;
|
||||
|
||||
struct Metadata
|
||||
{
|
||||
uint32_t duration;
|
||||
uint32_t loopStart;
|
||||
uint32_t loopLength;
|
||||
uint32_t offsetBytes;
|
||||
uint32_t lengthBytes;
|
||||
};
|
||||
HRESULT GetMetadata(_In_ uint32_t index, _Out_ Metadata& metadata) const noexcept;
|
||||
|
||||
private:
|
||||
// Private implementation.
|
||||
class Impl;
|
||||
|
||||
std::unique_ptr<Impl> pImpl;
|
||||
};
|
||||
}
|
4
Sdk/External/DirectXTK/Audio/packages.config
vendored
Normal file
4
Sdk/External/DirectXTK/Audio/packages.config
vendored
Normal file
@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="Microsoft.XAudio2.Redist" version="1.2.4" targetFramework="native" />
|
||||
</packages>
|
234
Sdk/External/DirectXTK/CMakeLists.txt
vendored
Normal file
234
Sdk/External/DirectXTK/CMakeLists.txt
vendored
Normal file
@ -0,0 +1,234 @@
|
||||
# DirectX Tool Kit for DirectX 11
|
||||
#
|
||||
# Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
# Licensed under the MIT License.
|
||||
#
|
||||
# http://go.microsoft.com/fwlink/?LinkId=248929
|
||||
|
||||
cmake_minimum_required (VERSION 3.11)
|
||||
|
||||
project (DirectXTK LANGUAGES CXX)
|
||||
|
||||
option(BUILD_XAUDIO_WIN10 "Build for XAudio 2.9" OFF)
|
||||
option(BUILD_XAUDIO_WIN8 "Build for XAudio 2.8" ON)
|
||||
|
||||
option(ENABLE_CODE_ANALYSIS "Use Static Code Analysis on build" OFF)
|
||||
|
||||
set(CMAKE_CXX_STANDARD 14)
|
||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||
set(CMAKE_CXX_EXTENSIONS OFF)
|
||||
|
||||
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/CMake")
|
||||
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/CMake")
|
||||
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/CMake")
|
||||
|
||||
set(LIBRARY_SOURCES
|
||||
Inc/BufferHelpers.h
|
||||
Inc/CommonStates.h
|
||||
Inc/DDSTextureLoader.h
|
||||
Inc/DirectXHelpers.h
|
||||
Inc/Effects.h
|
||||
Inc/GamePad.h
|
||||
Inc/GeometricPrimitive.h
|
||||
Inc/GraphicsMemory.h
|
||||
Inc/Keyboard.h
|
||||
Inc/Model.h
|
||||
Inc/Mouse.h
|
||||
Inc/PostProcess.h
|
||||
Inc/PrimitiveBatch.h
|
||||
Inc/ScreenGrab.h
|
||||
Inc/SimpleMath.h
|
||||
Inc/SimpleMath.inl
|
||||
Inc/SpriteBatch.h
|
||||
Inc/SpriteFont.h
|
||||
Inc/VertexTypes.h
|
||||
Inc/WICTextureLoader.h
|
||||
Src/AlignedNew.h
|
||||
Src/AlphaTestEffect.cpp
|
||||
Src/BasicEffect.cpp
|
||||
Src/BasicPostProcess.cpp
|
||||
Src/Bezier.h
|
||||
Src/BinaryReader.cpp
|
||||
Src/BinaryReader.h
|
||||
Src/BufferHelpers.cpp
|
||||
Src/CommonStates.cpp
|
||||
Src/dds.h
|
||||
Src/DDSTextureLoader.cpp
|
||||
Src/DebugEffect.cpp
|
||||
Src/DemandCreate.h
|
||||
Src/DGSLEffect.cpp
|
||||
Src/DGSLEffectFactory.cpp
|
||||
Src/DirectXHelpers.cpp
|
||||
Src/DualPostProcess.cpp
|
||||
Src/DualTextureEffect.cpp
|
||||
Src/EffectCommon.cpp
|
||||
Src/EffectCommon.h
|
||||
Src/EffectFactory.cpp
|
||||
Src/EnvironmentMapEffect.cpp
|
||||
Src/GamePad.cpp
|
||||
Src/GeometricPrimitive.cpp
|
||||
Src/Geometry.h
|
||||
Src/Geometry.cpp
|
||||
Src/GraphicsMemory.cpp
|
||||
Src/Keyboard.cpp
|
||||
Src/LoaderHelpers.h
|
||||
Src/Model.cpp
|
||||
Src/ModelLoadCMO.cpp
|
||||
Src/ModelLoadSDKMESH.cpp
|
||||
Src/ModelLoadVBO.cpp
|
||||
Src/Mouse.cpp
|
||||
Src/NormalMapEffect.cpp
|
||||
Src/PBREffect.cpp
|
||||
Src/PBREffectFactory.cpp
|
||||
Src/pch.h
|
||||
Src/PlatformHelpers.h
|
||||
Src/PrimitiveBatch.cpp
|
||||
Src/ScreenGrab.cpp
|
||||
Src/SDKMesh.h
|
||||
Src/SharedResourcePool.h
|
||||
Src/SimpleMath.cpp
|
||||
Src/SkinnedEffect.cpp
|
||||
Src/SpriteBatch.cpp
|
||||
Src/SpriteFont.cpp
|
||||
Src/TeapotData.inc
|
||||
Src/ToneMapPostProcess.cpp
|
||||
Src/vbo.h
|
||||
Src/VertexTypes.cpp
|
||||
Src/WICTextureLoader.cpp)
|
||||
|
||||
set(SHADER_SOURCES
|
||||
Src/Shaders/AlphaTestEffect.fx
|
||||
Src/Shaders/BasicEffect.fx
|
||||
Src/Shaders/Common.fxh
|
||||
Src/Shaders/DebugEffect.fx
|
||||
Src/Shaders/DGSLEffect.fx
|
||||
Src/Shaders/DGSLLambert.hlsl
|
||||
Src/Shaders/DGSLPhong.hlsl
|
||||
Src/Shaders/DGSLUnlit.hlsl
|
||||
Src/Shaders/DualTextureEffect.fx
|
||||
Src/Shaders/EnvironmentMapEffect.fx
|
||||
Src/Shaders/Lighting.fxh
|
||||
Src/Shaders/NormalMapEffect.fx
|
||||
Src/Shaders/PBRCommon.fxh
|
||||
Src/Shaders/PBREffect.fx
|
||||
Src/Shaders/PixelPacking_Velocity.hlsli
|
||||
Src/Shaders/PostProcess.fx
|
||||
Src/Shaders/SkinnedEffect.fx
|
||||
Src/Shaders/SpriteEffect.fx
|
||||
Src/Shaders/Structures.fxh
|
||||
Src/Shaders/ToneMap.fx
|
||||
Src/Shaders/Utilities.fxh)
|
||||
|
||||
if((BUILD_XAUDIO_WIN10) OR (BUILD_XAUDIO_WIN8))
|
||||
set(LIBRARY_SOURCES ${LIBRARY_SOURCES}
|
||||
Inc/Audio.h
|
||||
Audio/AudioEngine.cpp
|
||||
Audio/DynamicSoundEffectInstance.cpp
|
||||
Audio/SoundCommon.cpp
|
||||
Audio/SoundCommon.h
|
||||
Audio/SoundEffect.cpp
|
||||
Audio/SoundEffectInstance.cpp
|
||||
Audio/SoundStreamInstance.cpp
|
||||
Audio/WaveBank.cpp
|
||||
Audio/WaveBankReader.cpp
|
||||
Audio/WaveBankReader.h
|
||||
Audio/WAVFileReader.cpp
|
||||
Audio/WAVFileReader.h)
|
||||
endif()
|
||||
|
||||
add_library(${PROJECT_NAME} STATIC ${LIBRARY_SOURCES} Src/Shaders/Compiled/SpriteEffect_SpriteVertexShader.inc)
|
||||
|
||||
if (${CMAKE_VERSION} VERSION_GREATER_EQUAL "3.16")
|
||||
target_precompile_headers(${PROJECT_NAME} PRIVATE Src/pch.h)
|
||||
endif()
|
||||
|
||||
add_custom_command(
|
||||
OUTPUT "${PROJECT_SOURCE_DIR}/Src/Shaders/Compiled/SpriteEffect_SpriteVertexShader.inc"
|
||||
MAIN_DEPENDENCY "${PROJECT_SOURCE_DIR}/Src/Shaders/CompileShaders.cmd"
|
||||
DEPENDS ${SHADER_SOURCES}
|
||||
COMMENT "Generating HLSL shaders..."
|
||||
COMMAND "CompileShaders.cmd"
|
||||
WORKING_DIRECTORY "${PROJECT_SOURCE_DIR}/Src/Shaders"
|
||||
USES_TERMINAL)
|
||||
|
||||
source_group(Audio REGULAR_EXPRESSION Audio/*.*)
|
||||
source_group(Inc REGULAR_EXPRESSION Inc/*.*)
|
||||
source_group(Src REGULAR_EXPRESSION Src/*.*)
|
||||
|
||||
target_include_directories(${PROJECT_NAME} PUBLIC Inc)
|
||||
target_include_directories(${PROJECT_NAME} PRIVATE Src)
|
||||
|
||||
if((BUILD_XAUDIO_WIN10) OR (BUILD_XAUDIO_WIN8))
|
||||
target_include_directories(${PROJECT_NAME} PRIVATE Audio)
|
||||
endif()
|
||||
|
||||
if(MSVC)
|
||||
# Use max Warning Level
|
||||
string(REPLACE "/W3 " "/Wall " CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
|
||||
string(REPLACE "/W3 " "/Wall " CMAKE_CXX_FLAGS_DEBUG ${CMAKE_CXX_FLAGS_DEBUG})
|
||||
string(REPLACE "/W3 " "/Wall " CMAKE_CXX_FLAGS_RELEASE ${CMAKE_CXX_FLAGS_RELEASE})
|
||||
|
||||
# Model uses dynamic_cast, so we need /GR (Enable RTTI)
|
||||
|
||||
# Library needs /EHsc (Enable C++ exceptions)
|
||||
endif()
|
||||
|
||||
add_executable(xwbtool
|
||||
xwbtool/xwbtool.cpp
|
||||
Audio/WAVFileReader.cpp
|
||||
Audio/WAVFileReader.h)
|
||||
target_include_directories(xwbtool PRIVATE Audio Src)
|
||||
target_link_libraries(xwbtool version.lib)
|
||||
source_group(xwbtool REGULAR_EXPRESSION XWBTool/*.*)
|
||||
|
||||
if(MSVC)
|
||||
target_compile_options(${PROJECT_NAME} PRIVATE /fp:fast)
|
||||
target_compile_options(xwbtool PRIVATE /fp:fast)
|
||||
|
||||
if(ENABLE_CODE_ANALYSIS)
|
||||
target_compile_options(${PROJECT_NAME} PRIVATE /analyze)
|
||||
target_compile_options(xwbtool PRIVATE /analyze)
|
||||
endif()
|
||||
|
||||
if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 19.26)
|
||||
target_compile_options(${PROJECT_NAME} PRIVATE /Zc:preprocessor /wd5104 /wd5105)
|
||||
target_compile_options(xwbtool PRIVATE /Zc:preprocessor /wd5104 /wd5105)
|
||||
endif()
|
||||
|
||||
if (${CMAKE_SIZEOF_VOID_P} EQUAL "4")
|
||||
target_compile_options(${PROJECT_NAME} PRIVATE /arch:SSE2)
|
||||
target_compile_options(xwbtool PRIVATE /arch:SSE2)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if ( CMAKE_CXX_COMPILER_ID MATCHES "Clang" )
|
||||
set(WarningsLib "-Wpedantic" "-Wextra")
|
||||
target_compile_options(${PROJECT_NAME} PRIVATE ${WarningsLib})
|
||||
|
||||
set(WarningsEXE ${WarningsLib} "-Wno-c++98-compat" "-Wno-c++98-compat-pedantic"
|
||||
"-Wno-double-promotion" "-Wno-exit-time-destructors" "-Wno-gnu-anonymous-struct"
|
||||
"-Wno-missing-prototypes" "-Wno-nested-anon-types" "-Wno-unused-const-variable")
|
||||
target_compile_options(xwbtool PRIVATE ${WarningsEXE})
|
||||
endif()
|
||||
if ( CMAKE_CXX_COMPILER_ID MATCHES "MSVC" )
|
||||
target_compile_options(${PROJECT_NAME} PRIVATE /permissive- /JMC- /Zc:__cplusplus)
|
||||
target_compile_options(xwbtool PRIVATE /permissive- /Zc:__cplusplus)
|
||||
|
||||
set(WarningsEXE "/wd4365" "/wd4710" "/wd4820" "/wd5039" "/wd5045")
|
||||
target_compile_options(xwbtool PRIVATE ${WarningsEXE})
|
||||
endif()
|
||||
|
||||
if(WIN32)
|
||||
target_compile_definitions(${PROJECT_NAME} PRIVATE _UNICODE UNICODE)
|
||||
target_compile_definitions(xwbtool PRIVATE _UNICODE UNICODE _WIN32_WINNT=0x0601)
|
||||
|
||||
if(BUILD_XAUDIO_WIN10)
|
||||
target_compile_definitions(${PROJECT_NAME} PRIVATE _WIN32_WINNT=0x0A00)
|
||||
elseif(BUILD_XAUDIO_WIN8)
|
||||
target_compile_definitions(${PROJECT_NAME} PRIVATE _WIN32_WINNT=0x0602)
|
||||
else()
|
||||
target_compile_definitions(${PROJECT_NAME} PRIVATE _WIN32_WINNT=0x0601)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
set_property(DIRECTORY PROPERTY VS_STARTUP_PROJECT xwbtool)
|
64
Sdk/External/DirectXTK/CMakeSettings.json
vendored
Normal file
64
Sdk/External/DirectXTK/CMakeSettings.json
vendored
Normal file
@ -0,0 +1,64 @@
|
||||
{
|
||||
"configurations": [
|
||||
{
|
||||
"name": "x86-Clang-Debug",
|
||||
"generator": "Ninja",
|
||||
"configurationType": "Debug",
|
||||
"buildRoot": "${projectDir}\\out\\build\\${name}",
|
||||
"installRoot": "${projectDir}\\out\\install\\${name}",
|
||||
"cmakeCommandArgs": "",
|
||||
"buildCommandArgs": "-v",
|
||||
"ctestCommandArgs": "",
|
||||
"inheritEnvironments": [ "clang_cl_x86" ],
|
||||
"variables": []
|
||||
},
|
||||
{
|
||||
"name": "x86-Clang-Release",
|
||||
"generator": "Ninja",
|
||||
"configurationType": "RelWithDebInfo",
|
||||
"buildRoot": "${projectDir}\\out\\build\\${name}",
|
||||
"installRoot": "${projectDir}\\out\\install\\${name}",
|
||||
"cmakeCommandArgs": "",
|
||||
"buildCommandArgs": "-v",
|
||||
"ctestCommandArgs": "",
|
||||
"inheritEnvironments": [ "clang_cl_x86" ],
|
||||
"variables": []
|
||||
},
|
||||
{
|
||||
"name": "x64-Clang-Debug",
|
||||
"generator": "Ninja",
|
||||
"configurationType": "Debug",
|
||||
"buildRoot": "${projectDir}\\out\\build\\${name}",
|
||||
"installRoot": "${projectDir}\\out\\install\\${name}",
|
||||
"cmakeCommandArgs": "",
|
||||
"buildCommandArgs": "-v",
|
||||
"ctestCommandArgs": "",
|
||||
"inheritEnvironments": [ "clang_cl_x64" ],
|
||||
"variables": []
|
||||
},
|
||||
{
|
||||
"name": "x64-Clang-Release",
|
||||
"generator": "Ninja",
|
||||
"configurationType": "RelWithDebInfo",
|
||||
"buildRoot": "${projectDir}\\out\\build\\${name}",
|
||||
"installRoot": "${projectDir}\\out\\install\\${name}",
|
||||
"cmakeCommandArgs": "",
|
||||
"buildCommandArgs": "-v",
|
||||
"ctestCommandArgs": "",
|
||||
"inheritEnvironments": [ "clang_cl_x64" ],
|
||||
"variables": []
|
||||
},
|
||||
{
|
||||
"name": "x64-Debug",
|
||||
"generator": "Ninja",
|
||||
"configurationType": "Debug",
|
||||
"buildRoot": "${projectDir}\\out\\build\\${name}",
|
||||
"installRoot": "${projectDir}\\out\\install\\${name}",
|
||||
"cmakeCommandArgs": "",
|
||||
"buildCommandArgs": "-v",
|
||||
"ctestCommandArgs": "",
|
||||
"inheritEnvironments": [ "msvc_x64_x64" ],
|
||||
"variables": []
|
||||
}
|
||||
]
|
||||
}
|
84
Sdk/External/DirectXTK/DirectXTK_Desktop_2017.sln
vendored
Normal file
84
Sdk/External/DirectXTK/DirectXTK_Desktop_2017.sln
vendored
Normal file
@ -0,0 +1,84 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio 15
|
||||
VisualStudioVersion = 15.0.27703.2000
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTK_Desktop_2017", "DirectXTK_Desktop_2017.vcxproj", "{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MakeSpriteFont", "MakeSpriteFont\MakeSpriteFont.csproj", "{7329B02D-C504-482A-A156-181D48CE493C}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTKAudio_Desktop_2017_Win8", "Audio\DirectXTKAudio_Desktop_2017_Win8.vcxproj", "{4F150A30-CECB-49D1-8283-6A3F57438CF5}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "XWBTool_Desktop_2017", "XWBTool\XWBTool_Desktop_2017.vcxproj", "{C7AB4186-54B2-4244-A533-77494763EA1D}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{0317D9F7-1BFB-4422-8B2F-670E7956F12D}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
.editorconfig = .editorconfig
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Mixed Platforms = Debug|Mixed Platforms
|
||||
Debug|x86 = Debug|x86
|
||||
Debug|x64 = Debug|x64
|
||||
Release|Mixed Platforms = Release|Mixed Platforms
|
||||
Release|x86 = Release|x86
|
||||
Release|x64 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|Mixed Platforms.Build.0 = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x86.Build.0 = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x64.Build.0 = Debug|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|Mixed Platforms.ActiveCfg = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|Mixed Platforms.Build.0 = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x86.ActiveCfg = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x86.Build.0 = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x64.ActiveCfg = Release|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x64.Build.0 = Release|x64
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|Mixed Platforms.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x86.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x64.Build.0 = Release|Any CPU
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|Mixed Platforms.Build.0 = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x86.Build.0 = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x64.Build.0 = Debug|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|Mixed Platforms.ActiveCfg = Release|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|Mixed Platforms.Build.0 = Release|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x86.ActiveCfg = Release|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x86.Build.0 = Release|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x64.ActiveCfg = Release|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x64.Build.0 = Release|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|Mixed Platforms.Build.0 = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x86.Build.0 = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x64.Build.0 = Debug|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|Mixed Platforms.ActiveCfg = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|Mixed Platforms.Build.0 = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x86.ActiveCfg = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x86.Build.0 = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x64.ActiveCfg = Release|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x64.Build.0 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {A26A07B7-AF41-47A4-B21F-8C772153EAA4}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
342
Sdk/External/DirectXTK/DirectXTK_Desktop_2017.vcxproj
vendored
Normal file
342
Sdk/External/DirectXTK/DirectXTK_Desktop_2017.vcxproj
vendored
Normal file
@ -0,0 +1,342 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Inc\BufferHelpers.h" />
|
||||
<ClInclude Include="Inc\CommonStates.h" />
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h" />
|
||||
<ClInclude Include="Inc\DirectXHelpers.h" />
|
||||
<ClInclude Include="Inc\Effects.h" />
|
||||
<ClInclude Include="Inc\GamePad.h" />
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h" />
|
||||
<ClInclude Include="Inc\GraphicsMemory.h" />
|
||||
<ClInclude Include="Inc\Keyboard.h" />
|
||||
<ClInclude Include="Inc\Model.h" />
|
||||
<ClInclude Include="Inc\Mouse.h" />
|
||||
<ClInclude Include="Inc\PostProcess.h" />
|
||||
<ClInclude Include="Inc\SimpleMath.h" />
|
||||
<ClInclude Include="Inc\SimpleMath.inl" />
|
||||
<ClInclude Include="Inc\ScreenGrab.h" />
|
||||
<ClInclude Include="Inc\SpriteBatch.h" />
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h" />
|
||||
<ClInclude Include="Inc\SpriteFont.h" />
|
||||
<ClInclude Include="Inc\VertexTypes.h" />
|
||||
<ClInclude Include="Inc\WICTextureLoader.h" />
|
||||
<ClInclude Include="Src\AlignedNew.h" />
|
||||
<ClInclude Include="Src\Bezier.h" />
|
||||
<ClInclude Include="Src\BinaryReader.h" />
|
||||
<ClInclude Include="Src\DemandCreate.h" />
|
||||
<ClInclude Include="Src\EffectCommon.h" />
|
||||
<ClInclude Include="Src\Geometry.h" />
|
||||
<ClInclude Include="Src\LoaderHelpers.h" />
|
||||
<ClInclude Include="Src\pch.h" />
|
||||
<ClInclude Include="Src\PlatformHelpers.h" />
|
||||
<ClInclude Include="Src\SDKMesh.h" />
|
||||
<ClInclude Include="Src\SharedResourcePool.h" />
|
||||
<ClInclude Include="Src\DDS.h" />
|
||||
<ClInclude Include="Src\vbo.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp" />
|
||||
<ClCompile Include="Src\BufferHelpers.cpp" />
|
||||
<ClCompile Include="Src\CommonStates.cpp" />
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp" />
|
||||
<ClCompile Include="Src\DebugEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp" />
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp" />
|
||||
<ClCompile Include="Src\DualPostProcess.cpp" />
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp" />
|
||||
<ClCompile Include="Src\BinaryReader.cpp" />
|
||||
<ClCompile Include="Src\EffectCommon.cpp" />
|
||||
<ClCompile Include="Src\EffectFactory.cpp" />
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp" />
|
||||
<ClCompile Include="Src\GamePad.cpp" />
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp" />
|
||||
<ClCompile Include="Src\Geometry.cpp" />
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp" />
|
||||
<ClCompile Include="Src\Keyboard.cpp" />
|
||||
<ClCompile Include="Src\Model.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp" />
|
||||
<ClCompile Include="Src\Mouse.cpp" />
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp" />
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ScreenGrab.cpp" />
|
||||
<ClCompile Include="Src\SimpleMath.cpp" />
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp" />
|
||||
<ClCompile Include="Src\SpriteBatch.cpp" />
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp" />
|
||||
<ClCompile Include="Src\SpriteFont.cpp" />
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp" />
|
||||
<ClCompile Include="Src\VertexTypes.cpp" />
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="README.md" />
|
||||
<None Include="Src\Shaders\Common.fxh" />
|
||||
<None Include="Src\Shaders\CompileShaders.cmd" />
|
||||
<None Include="Src\Shaders\Lighting.fxh" />
|
||||
<None Include="Src\Shaders\PBRCommon.fxh" />
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli" />
|
||||
<None Include="Src\Shaders\SpriteEffect.fx" />
|
||||
<None Include="Src\Shaders\Structures.fxh" />
|
||||
<None Include="Src\Shaders\Utilities.fxh" />
|
||||
<None Include="Src\TeapotData.inc" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>DirectXTK</RootNamespace>
|
||||
<WindowsTargetPlatformVersion>10.0.17763.0</WindowsTargetPlatformVersion>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<OutDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<OutDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;_WIN7_PLATFORM_UPDATE;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;_WIN7_PLATFORM_UPDATE;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;_WIN7_PLATFORM_UPDATE;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;_WIN7_PLATFORM_UPDATE;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
<Target Name="ATGEnsureShaders" BeforeTargets="PrepareForBuild">
|
||||
<PropertyGroup>
|
||||
<_ATGFXCPath>$(WindowsSDK_ExecutablePath_x64.Split(';')[0])</_ATGFXCPath>
|
||||
<_ATGFXCPath>$(_ATGFXCPath.Replace("x64",""))</_ATGFXCPath>
|
||||
<_ATGFXCPath Condition="'$(_ATGFXCPath)' != '' and !HasTrailingSlash('$(_ATGFXCPath)')">$(_ATGFXCPath)\</_ATGFXCPath>
|
||||
</PropertyGroup>
|
||||
<Exec Condition="!Exists('src/Shaders/Compiled/SpriteEffect_SpriteVertexShader.inc')" WorkingDirectory="$(ProjectDir)src/Shaders" Command="CompileShaders" EnvironmentVariables="WindowsSdkVerBinPath=$(_ATGFXCPath)" />
|
||||
<PropertyGroup>
|
||||
<_ATGFXCPath />
|
||||
</PropertyGroup>
|
||||
</Target>
|
||||
<Target Name="ATGDeleteShaders" AfterTargets="Clean">
|
||||
<ItemGroup>
|
||||
<_ATGShaderHeaders Include="$(ProjectDir)src/Shaders/Compiled/*.inc" Exclude="$(ProjectDir)src/Shaders/Compiled/*Xbox*.inc" />
|
||||
<_ATGShaderSymbols Include="$(ProjectDir)src/Shaders/Compiled/*.pdb" Exclude="$(ProjectDir)src/Shaders/Compiled/*Xbox*.pdb" />
|
||||
</ItemGroup>
|
||||
<Delete Files="@(_ATGShaderHeaders)" />
|
||||
<Delete Files="@(_ATGShaderSymbols)" />
|
||||
</Target>
|
||||
</Project>
|
315
Sdk/External/DirectXTK/DirectXTK_Desktop_2017.vcxproj.filters
vendored
Normal file
315
Sdk/External/DirectXTK/DirectXTK_Desktop_2017.vcxproj.filters
vendored
Normal file
@ -0,0 +1,315 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Inc">
|
||||
<UniqueIdentifier>{771f5f80-d173-49c3-8afb-790e8f7cb0ce}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src">
|
||||
<UniqueIdentifier>{c52e19b6-8703-49a1-9b36-101a05b4745d}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Inc\Shared">
|
||||
<UniqueIdentifier>{e07ba3bc-b69f-4ded-9ffa-3b47427e9fef}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shared">
|
||||
<UniqueIdentifier>{28e934ed-a6d7-4c30-b064-c72c50c99626}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders">
|
||||
<UniqueIdentifier>{28d5fa16-99e2-471c-8cd8-2020e81f0024}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders\Shared">
|
||||
<UniqueIdentifier>{34676173-31f5-4435-b90d-a0ad4f7d163c}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Inc\CommonStates.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\ScreenGrab.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteFont.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\VertexTypes.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\pch.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\EffectCommon.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Effects.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\WICTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Model.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DirectXHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GamePad.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Keyboard.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Mouse.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SimpleMath.inl">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SimpleMath.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\AlignedNew.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Bezier.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\BinaryReader.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DDS.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DemandCreate.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\PlatformHelpers.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GraphicsMemory.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SDKMesh.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SharedResourcePool.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\vbo.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Geometry.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\LoaderHelpers.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PostProcess.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\BufferHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Src\CommonStates.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteFont.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\VertexTypes.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectCommon.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ScreenGrab.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Model.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BinaryReader.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GamePad.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Keyboard.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Mouse.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SimpleMath.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Geometry.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DebugEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BufferHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\CompileShaders.cmd">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SpriteEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\TeapotData.inc">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Common.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Lighting.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Structures.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Utilities.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBRCommon.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="README.md" />
|
||||
</ItemGroup>
|
||||
</Project>
|
84
Sdk/External/DirectXTK/DirectXTK_Desktop_2017_Win10.sln
vendored
Normal file
84
Sdk/External/DirectXTK/DirectXTK_Desktop_2017_Win10.sln
vendored
Normal file
@ -0,0 +1,84 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio 15
|
||||
VisualStudioVersion = 15.0.27703.2000
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTK_Desktop_2017_Win10", "DirectXTK_Desktop_2017_Win10.vcxproj", "{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MakeSpriteFont", "MakeSpriteFont\MakeSpriteFont.csproj", "{7329B02D-C504-482A-A156-181D48CE493C}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "XWBTool_Desktop_2017", "XWBTool\XWBTool_Desktop_2017.vcxproj", "{C7AB4186-54B2-4244-A533-77494763EA1D}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{BD5A62C9-FE7B-4491-82C2-BD46EA64D1C8}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
.editorconfig = .editorconfig
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|ARM64 = Debug|ARM64
|
||||
Debug|Mixed Platforms = Debug|Mixed Platforms
|
||||
Debug|x64 = Debug|x64
|
||||
Debug|x86 = Debug|x86
|
||||
Release|ARM64 = Release|ARM64
|
||||
Release|Mixed Platforms = Release|Mixed Platforms
|
||||
Release|x64 = Release|x64
|
||||
Release|x86 = Release|x86
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|ARM64.ActiveCfg = Debug|ARM64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|ARM64.Build.0 = Debug|ARM64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|Mixed Platforms.Build.0 = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x64.Build.0 = Debug|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x86.Build.0 = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|ARM64.ActiveCfg = Release|ARM64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|ARM64.Build.0 = Release|ARM64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|Mixed Platforms.ActiveCfg = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|Mixed Platforms.Build.0 = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x64.ActiveCfg = Release|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x64.Build.0 = Release|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x86.ActiveCfg = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x86.Build.0 = Release|Win32
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|ARM64.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|ARM64.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|ARM64.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|ARM64.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|Mixed Platforms.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x64.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x86.Build.0 = Release|Any CPU
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|ARM64.ActiveCfg = Debug|ARM64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|ARM64.Build.0 = Debug|ARM64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|Mixed Platforms.Build.0 = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x64.Build.0 = Debug|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x86.Build.0 = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|ARM64.ActiveCfg = Release|ARM64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|ARM64.Build.0 = Release|ARM64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|Mixed Platforms.ActiveCfg = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|Mixed Platforms.Build.0 = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x64.ActiveCfg = Release|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x64.Build.0 = Release|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x86.ActiveCfg = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x86.Build.0 = Release|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {0F7A0290-0AF9-47AB-A91D-1346B9433995}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
434
Sdk/External/DirectXTK/DirectXTK_Desktop_2017_Win10.vcxproj
vendored
Normal file
434
Sdk/External/DirectXTK/DirectXTK_Desktop_2017_Win10.vcxproj
vendored
Normal file
@ -0,0 +1,434 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|ARM64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>ARM64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|ARM64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>ARM64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Audio\SoundCommon.h" />
|
||||
<ClInclude Include="Audio\WaveBankReader.h" />
|
||||
<ClInclude Include="Audio\WAVFileReader.h" />
|
||||
<ClInclude Include="Inc\Audio.h" />
|
||||
<ClInclude Include="Inc\BufferHelpers.h" />
|
||||
<ClInclude Include="Inc\CommonStates.h" />
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h" />
|
||||
<ClInclude Include="Inc\DirectXHelpers.h" />
|
||||
<ClInclude Include="Inc\Effects.h" />
|
||||
<ClInclude Include="Inc\GamePad.h" />
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h" />
|
||||
<ClInclude Include="Inc\GraphicsMemory.h" />
|
||||
<ClInclude Include="Inc\Keyboard.h" />
|
||||
<ClInclude Include="Inc\Model.h" />
|
||||
<ClInclude Include="Inc\Mouse.h" />
|
||||
<ClInclude Include="Inc\PostProcess.h" />
|
||||
<ClInclude Include="Inc\SimpleMath.h" />
|
||||
<ClInclude Include="Inc\SimpleMath.inl" />
|
||||
<ClInclude Include="Inc\ScreenGrab.h" />
|
||||
<ClInclude Include="Inc\SpriteBatch.h" />
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h" />
|
||||
<ClInclude Include="Inc\SpriteFont.h" />
|
||||
<ClInclude Include="Inc\VertexTypes.h" />
|
||||
<ClInclude Include="Inc\WICTextureLoader.h" />
|
||||
<ClInclude Include="Src\AlignedNew.h" />
|
||||
<ClInclude Include="Src\Bezier.h" />
|
||||
<ClInclude Include="Src\BinaryReader.h" />
|
||||
<ClInclude Include="Src\DemandCreate.h" />
|
||||
<ClInclude Include="Src\EffectCommon.h" />
|
||||
<ClInclude Include="Src\Geometry.h" />
|
||||
<ClInclude Include="Src\LoaderHelpers.h" />
|
||||
<ClInclude Include="Src\pch.h" />
|
||||
<ClInclude Include="Src\PlatformHelpers.h" />
|
||||
<ClInclude Include="Src\SDKMesh.h" />
|
||||
<ClInclude Include="Src\SharedResourcePool.h" />
|
||||
<ClInclude Include="Src\DDS.h" />
|
||||
<ClInclude Include="Src\vbo.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Audio\AudioEngine.cpp" />
|
||||
<ClCompile Include="Audio\DynamicSoundEffectInstance.cpp" />
|
||||
<ClCompile Include="Audio\SoundCommon.cpp" />
|
||||
<ClCompile Include="Audio\SoundEffect.cpp" />
|
||||
<ClCompile Include="Audio\SoundEffectInstance.cpp" />
|
||||
<ClCompile Include="Audio\SoundStreamInstance.cpp" />
|
||||
<ClCompile Include="Audio\WaveBank.cpp" />
|
||||
<ClCompile Include="Audio\WaveBankReader.cpp" />
|
||||
<ClCompile Include="Audio\WAVFileReader.cpp" />
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp" />
|
||||
<ClCompile Include="Src\BufferHelpers.cpp" />
|
||||
<ClCompile Include="Src\CommonStates.cpp" />
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp" />
|
||||
<ClCompile Include="Src\DebugEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp" />
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp" />
|
||||
<ClCompile Include="Src\DualPostProcess.cpp" />
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp" />
|
||||
<ClCompile Include="Src\BinaryReader.cpp" />
|
||||
<ClCompile Include="Src\EffectCommon.cpp" />
|
||||
<ClCompile Include="Src\EffectFactory.cpp" />
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp" />
|
||||
<ClCompile Include="Src\GamePad.cpp" />
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp" />
|
||||
<ClCompile Include="Src\Geometry.cpp" />
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp" />
|
||||
<ClCompile Include="Src\Keyboard.cpp" />
|
||||
<ClCompile Include="Src\Model.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp" />
|
||||
<ClCompile Include="Src\Mouse.cpp" />
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp" />
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">Create</PrecompiledHeader>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ScreenGrab.cpp" />
|
||||
<ClCompile Include="Src\SimpleMath.cpp" />
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp" />
|
||||
<ClCompile Include="Src\SpriteBatch.cpp" />
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp" />
|
||||
<ClCompile Include="Src\SpriteFont.cpp" />
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp" />
|
||||
<ClCompile Include="Src\VertexTypes.cpp" />
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="README.md" />
|
||||
<None Include="Src\Shaders\Common.fxh" />
|
||||
<None Include="Src\Shaders\CompileShaders.cmd" />
|
||||
<None Include="Src\Shaders\Lighting.fxh" />
|
||||
<None Include="Src\Shaders\PBRCommon.fxh" />
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli" />
|
||||
<None Include="Src\Shaders\SpriteEffect.fx" />
|
||||
<None Include="Src\Shaders\Structures.fxh" />
|
||||
<None Include="Src\Shaders\Utilities.fxh" />
|
||||
<None Include="Src\TeapotData.inc" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>DirectXTK</RootNamespace>
|
||||
<WindowsTargetPlatformVersion>10.0.17763.0</WindowsTargetPlatformVersion>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>Bin\Desktop_2017_Win10\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017_Win10\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>Bin\Desktop_2017_Win10\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017_Win10\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<OutDir>Bin\Desktop_2017_Win10\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017_Win10\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
|
||||
<OutDir>Bin\Desktop_2017_Win10\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017_Win10\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<OutDir>Bin\Desktop_2017_Win10\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017_Win10\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
|
||||
<OutDir>Bin\Desktop_2017_Win10\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2017_Win10\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0A00;_WIN7_PLATFORM_UPDATE;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0A00;_WIN7_PLATFORM_UPDATE;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0A00;_WIN7_PLATFORM_UPDATE;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0A00;_WIN7_PLATFORM_UPDATE;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0A00;_WIN7_PLATFORM_UPDATE;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0A00;_WIN7_PLATFORM_UPDATE;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus /Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
<Target Name="ATGEnsureShaders" BeforeTargets="PrepareForBuild">
|
||||
<PropertyGroup>
|
||||
<_ATGFXCPath>$(WindowsSDK_ExecutablePath_x64.Split(';')[0])</_ATGFXCPath>
|
||||
<_ATGFXCPath>$(_ATGFXCPath.Replace("x64",""))</_ATGFXCPath>
|
||||
<_ATGFXCPath Condition="'$(_ATGFXCPath)' != '' and !HasTrailingSlash('$(_ATGFXCPath)')">$(_ATGFXCPath)\</_ATGFXCPath>
|
||||
</PropertyGroup>
|
||||
<Exec Condition="!Exists('src/Shaders/Compiled/SpriteEffect_SpriteVertexShader.inc')" WorkingDirectory="$(ProjectDir)src/Shaders" Command="CompileShaders" EnvironmentVariables="WindowsSdkVerBinPath=$(_ATGFXCPath)" />
|
||||
<PropertyGroup>
|
||||
<_ATGFXCPath />
|
||||
</PropertyGroup>
|
||||
</Target>
|
||||
<Target Name="ATGDeleteShaders" AfterTargets="Clean">
|
||||
<ItemGroup>
|
||||
<_ATGShaderHeaders Include="$(ProjectDir)src/Shaders/Compiled/*.inc" Exclude="$(ProjectDir)src/Shaders/Compiled/*Xbox*.inc" />
|
||||
<_ATGShaderSymbols Include="$(ProjectDir)src/Shaders/Compiled/*.pdb" Exclude="$(ProjectDir)src/Shaders/Compiled/*Xbox*.pdb" />
|
||||
</ItemGroup>
|
||||
<Delete Files="@(_ATGShaderHeaders)" />
|
||||
<Delete Files="@(_ATGShaderSymbols)" />
|
||||
</Target>
|
||||
</Project>
|
357
Sdk/External/DirectXTK/DirectXTK_Desktop_2017_Win10.vcxproj.filters
vendored
Normal file
357
Sdk/External/DirectXTK/DirectXTK_Desktop_2017_Win10.vcxproj.filters
vendored
Normal file
@ -0,0 +1,357 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Inc">
|
||||
<UniqueIdentifier>{771f5f80-d173-49c3-8afb-790e8f7cb0ce}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src">
|
||||
<UniqueIdentifier>{c52e19b6-8703-49a1-9b36-101a05b4745d}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Inc\Shared">
|
||||
<UniqueIdentifier>{e07ba3bc-b69f-4ded-9ffa-3b47427e9fef}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shared">
|
||||
<UniqueIdentifier>{28e934ed-a6d7-4c30-b064-c72c50c99626}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders">
|
||||
<UniqueIdentifier>{28d5fa16-99e2-471c-8cd8-2020e81f0024}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders\Shared">
|
||||
<UniqueIdentifier>{34676173-31f5-4435-b90d-a0ad4f7d163c}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Audio">
|
||||
<UniqueIdentifier>{5d47b946-09b9-4477-934f-ca45fba9845d}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Inc\CommonStates.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\ScreenGrab.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteFont.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\VertexTypes.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\pch.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\PlatformHelpers.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\EffectCommon.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Effects.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\WICTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Model.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DirectXHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GraphicsMemory.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Audio.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\SoundCommon.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\WAVFileReader.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\WaveBankReader.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GamePad.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Keyboard.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Mouse.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SimpleMath.inl">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SimpleMath.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\AlignedNew.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Bezier.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\BinaryReader.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DDS.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DemandCreate.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Geometry.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\LoaderHelpers.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SharedResourcePool.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\vbo.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SDKMesh.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PostProcess.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\BufferHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Src\CommonStates.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteFont.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\VertexTypes.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectCommon.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ScreenGrab.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Model.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\AudioEngine.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\DynamicSoundEffectInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundCommon.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WAVFileReader.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WaveBankReader.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WaveBank.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundEffectInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundEffect.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BinaryReader.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GamePad.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Geometry.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Keyboard.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Mouse.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SimpleMath.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DebugEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundStreamInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BufferHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\CompileShaders.cmd">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SpriteEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Lighting.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Common.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Structures.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\TeapotData.inc">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Utilities.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBRCommon.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="README.md" />
|
||||
</ItemGroup>
|
||||
</Project>
|
73
Sdk/External/DirectXTK/DirectXTK_Desktop_2017_Win7.sln
vendored
Normal file
73
Sdk/External/DirectXTK/DirectXTK_Desktop_2017_Win7.sln
vendored
Normal file
@ -0,0 +1,73 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio 15
|
||||
VisualStudioVersion = 15.0.28307.1000
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTK_Desktop_2017", "DirectXTK_Desktop_2017.vcxproj", "{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTKAudio_Desktop_2017_Win7", "Audio\DirectXTKAudio_Desktop_2017_Win7.vcxproj", "{4F150A30-CECB-49D1-8283-6A3F57438CF5}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MakeSpriteFont", "MakeSpriteFont\MakeSpriteFont.csproj", "{7329B02D-C504-482A-A156-181D48CE493C}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xwbtool_Desktop_2017", "XWBTool\xwbtool_Desktop_2017.vcxproj", "{C7AB4186-54B2-4244-A533-77494763EA1D}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
Debug|x64 = Debug|x64
|
||||
Debug|x86 = Debug|x86
|
||||
Release|Any CPU = Release|Any CPU
|
||||
Release|x64 = Release|x64
|
||||
Release|x86 = Release|x86
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|Any CPU.ActiveCfg = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x64.Build.0 = Debug|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x86.Build.0 = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|Any CPU.ActiveCfg = Release|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x64.ActiveCfg = Release|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x64.Build.0 = Release|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x86.ActiveCfg = Release|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x86.Build.0 = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|Any CPU.ActiveCfg = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x64.Build.0 = Debug|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x86.Build.0 = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|Any CPU.ActiveCfg = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x64.ActiveCfg = Release|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x64.Build.0 = Release|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x86.ActiveCfg = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x86.Build.0 = Release|Win32
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x64.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x86.Build.0 = Release|Any CPU
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|Any CPU.ActiveCfg = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x64.Build.0 = Debug|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x86.Build.0 = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|Any CPU.ActiveCfg = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x64.ActiveCfg = Release|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x64.Build.0 = Release|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x86.ActiveCfg = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x86.Build.0 = Release|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {3B774DEE-1D2A-4EEF-B8FA-75BDC1DA64DE}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
84
Sdk/External/DirectXTK/DirectXTK_Desktop_2019.sln
vendored
Normal file
84
Sdk/External/DirectXTK/DirectXTK_Desktop_2019.sln
vendored
Normal file
@ -0,0 +1,84 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio Version 16
|
||||
VisualStudioVersion = 15.0.27703.2000
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTK_Desktop_2019", "DirectXTK_Desktop_2019.vcxproj", "{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MakeSpriteFont", "MakeSpriteFont\MakeSpriteFont.csproj", "{7329B02D-C504-482A-A156-181D48CE493C}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTKAudio_Desktop_2019_Win8", "Audio\DirectXTKAudio_Desktop_2019_Win8.vcxproj", "{4F150A30-CECB-49D1-8283-6A3F57438CF5}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "XWBTool_Desktop_2019", "XWBTool\XWBTool_Desktop_2019.vcxproj", "{C7AB4186-54B2-4244-A533-77494763EA1D}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{0317D9F7-1BFB-4422-8B2F-670E7956F12D}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
.editorconfig = .editorconfig
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Mixed Platforms = Debug|Mixed Platforms
|
||||
Debug|x86 = Debug|x86
|
||||
Debug|x64 = Debug|x64
|
||||
Release|Mixed Platforms = Release|Mixed Platforms
|
||||
Release|x86 = Release|x86
|
||||
Release|x64 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|Mixed Platforms.Build.0 = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x86.Build.0 = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x64.Build.0 = Debug|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|Mixed Platforms.ActiveCfg = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|Mixed Platforms.Build.0 = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x86.ActiveCfg = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x86.Build.0 = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x64.ActiveCfg = Release|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x64.Build.0 = Release|x64
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|Mixed Platforms.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x86.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x64.Build.0 = Release|Any CPU
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|Mixed Platforms.Build.0 = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x86.Build.0 = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x64.Build.0 = Debug|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|Mixed Platforms.ActiveCfg = Release|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|Mixed Platforms.Build.0 = Release|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x86.ActiveCfg = Release|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x86.Build.0 = Release|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x64.ActiveCfg = Release|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x64.Build.0 = Release|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|Mixed Platforms.Build.0 = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x86.Build.0 = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x64.Build.0 = Debug|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|Mixed Platforms.ActiveCfg = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|Mixed Platforms.Build.0 = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x86.ActiveCfg = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x86.Build.0 = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x64.ActiveCfg = Release|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x64.Build.0 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {A26A07B7-AF41-47A4-B21F-8C772153EAA4}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
346
Sdk/External/DirectXTK/DirectXTK_Desktop_2019.vcxproj
vendored
Normal file
346
Sdk/External/DirectXTK/DirectXTK_Desktop_2019.vcxproj
vendored
Normal file
@ -0,0 +1,346 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Inc\BufferHelpers.h" />
|
||||
<ClInclude Include="Inc\CommonStates.h" />
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h" />
|
||||
<ClInclude Include="Inc\DirectXHelpers.h" />
|
||||
<ClInclude Include="Inc\Effects.h" />
|
||||
<ClInclude Include="Inc\GamePad.h" />
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h" />
|
||||
<ClInclude Include="Inc\GraphicsMemory.h" />
|
||||
<ClInclude Include="Inc\Keyboard.h" />
|
||||
<ClInclude Include="Inc\Model.h" />
|
||||
<ClInclude Include="Inc\Mouse.h" />
|
||||
<ClInclude Include="Inc\PostProcess.h" />
|
||||
<ClInclude Include="Inc\SimpleMath.h" />
|
||||
<ClInclude Include="Inc\SimpleMath.inl" />
|
||||
<ClInclude Include="Inc\ScreenGrab.h" />
|
||||
<ClInclude Include="Inc\SpriteBatch.h" />
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h" />
|
||||
<ClInclude Include="Inc\SpriteFont.h" />
|
||||
<ClInclude Include="Inc\VertexTypes.h" />
|
||||
<ClInclude Include="Inc\WICTextureLoader.h" />
|
||||
<ClInclude Include="Src\AlignedNew.h" />
|
||||
<ClInclude Include="Src\Bezier.h" />
|
||||
<ClInclude Include="Src\BinaryReader.h" />
|
||||
<ClInclude Include="Src\DemandCreate.h" />
|
||||
<ClInclude Include="Src\EffectCommon.h" />
|
||||
<ClInclude Include="Src\Geometry.h" />
|
||||
<ClInclude Include="Src\LoaderHelpers.h" />
|
||||
<ClInclude Include="Src\pch.h" />
|
||||
<ClInclude Include="Src\PlatformHelpers.h" />
|
||||
<ClInclude Include="Src\SDKMesh.h" />
|
||||
<ClInclude Include="Src\SharedResourcePool.h" />
|
||||
<ClInclude Include="Src\DDS.h" />
|
||||
<ClInclude Include="Src\vbo.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp" />
|
||||
<ClCompile Include="Src\BufferHelpers.cpp" />
|
||||
<ClCompile Include="Src\CommonStates.cpp" />
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp" />
|
||||
<ClCompile Include="Src\DebugEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp" />
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp" />
|
||||
<ClCompile Include="Src\DualPostProcess.cpp" />
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp" />
|
||||
<ClCompile Include="Src\BinaryReader.cpp" />
|
||||
<ClCompile Include="Src\EffectCommon.cpp" />
|
||||
<ClCompile Include="Src\EffectFactory.cpp" />
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp" />
|
||||
<ClCompile Include="Src\GamePad.cpp" />
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp" />
|
||||
<ClCompile Include="Src\Geometry.cpp" />
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp" />
|
||||
<ClCompile Include="Src\Keyboard.cpp" />
|
||||
<ClCompile Include="Src\Model.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp" />
|
||||
<ClCompile Include="Src\Mouse.cpp" />
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp" />
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ScreenGrab.cpp" />
|
||||
<ClCompile Include="Src\SimpleMath.cpp" />
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp" />
|
||||
<ClCompile Include="Src\SpriteBatch.cpp" />
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp" />
|
||||
<ClCompile Include="Src\SpriteFont.cpp" />
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp" />
|
||||
<ClCompile Include="Src\VertexTypes.cpp" />
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="README.md" />
|
||||
<None Include="Src\Shaders\Common.fxh" />
|
||||
<None Include="Src\Shaders\CompileShaders.cmd" />
|
||||
<None Include="Src\Shaders\Lighting.fxh" />
|
||||
<None Include="Src\Shaders\PBRCommon.fxh" />
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli" />
|
||||
<None Include="Src\Shaders\SpriteEffect.fx" />
|
||||
<None Include="Src\Shaders\Structures.fxh" />
|
||||
<None Include="Src\Shaders\Utilities.fxh" />
|
||||
<None Include="Src\TeapotData.inc" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>DirectXTK</RootNamespace>
|
||||
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<OutDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<OutDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;_WIN7_PLATFORM_UPDATE;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;_WIN7_PLATFORM_UPDATE;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;_WIN7_PLATFORM_UPDATE;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0601;_WIN7_PLATFORM_UPDATE;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
<Target Name="ATGEnsureShaders" BeforeTargets="PrepareForBuild">
|
||||
<PropertyGroup>
|
||||
<_ATGFXCPath>$(WindowsSDK_ExecutablePath_x64.Split(';')[0])</_ATGFXCPath>
|
||||
<_ATGFXCPath>$(_ATGFXCPath.Replace("x64",""))</_ATGFXCPath>
|
||||
<_ATGFXCPath Condition="'$(_ATGFXCPath)' != '' and !HasTrailingSlash('$(_ATGFXCPath)')">$(_ATGFXCPath)\</_ATGFXCPath>
|
||||
</PropertyGroup>
|
||||
<Exec Condition="!Exists('src/Shaders/Compiled/SpriteEffect_SpriteVertexShader.inc')" WorkingDirectory="$(ProjectDir)src/Shaders" Command="CompileShaders" EnvironmentVariables="WindowsSdkVerBinPath=$(_ATGFXCPath)" />
|
||||
<PropertyGroup>
|
||||
<_ATGFXCPath />
|
||||
</PropertyGroup>
|
||||
</Target>
|
||||
<Target Name="ATGDeleteShaders" AfterTargets="Clean">
|
||||
<ItemGroup>
|
||||
<_ATGShaderHeaders Include="$(ProjectDir)src/Shaders/Compiled/*.inc" Exclude="$(ProjectDir)src/Shaders/Compiled/*Xbox*.inc" />
|
||||
<_ATGShaderSymbols Include="$(ProjectDir)src/Shaders/Compiled/*.pdb" Exclude="$(ProjectDir)src/Shaders/Compiled/*Xbox*.pdb" />
|
||||
</ItemGroup>
|
||||
<Delete Files="@(_ATGShaderHeaders)" />
|
||||
<Delete Files="@(_ATGShaderSymbols)" />
|
||||
</Target>
|
||||
</Project>
|
315
Sdk/External/DirectXTK/DirectXTK_Desktop_2019.vcxproj.filters
vendored
Normal file
315
Sdk/External/DirectXTK/DirectXTK_Desktop_2019.vcxproj.filters
vendored
Normal file
@ -0,0 +1,315 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Inc">
|
||||
<UniqueIdentifier>{771f5f80-d173-49c3-8afb-790e8f7cb0ce}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src">
|
||||
<UniqueIdentifier>{c52e19b6-8703-49a1-9b36-101a05b4745d}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Inc\Shared">
|
||||
<UniqueIdentifier>{e07ba3bc-b69f-4ded-9ffa-3b47427e9fef}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shared">
|
||||
<UniqueIdentifier>{28e934ed-a6d7-4c30-b064-c72c50c99626}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders">
|
||||
<UniqueIdentifier>{28d5fa16-99e2-471c-8cd8-2020e81f0024}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders\Shared">
|
||||
<UniqueIdentifier>{34676173-31f5-4435-b90d-a0ad4f7d163c}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Inc\CommonStates.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\ScreenGrab.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteFont.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\VertexTypes.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\pch.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\EffectCommon.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Effects.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\WICTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Model.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DirectXHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GamePad.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Keyboard.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Mouse.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SimpleMath.inl">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SimpleMath.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\AlignedNew.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Bezier.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\BinaryReader.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DDS.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DemandCreate.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\PlatformHelpers.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GraphicsMemory.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SDKMesh.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SharedResourcePool.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\vbo.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Geometry.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\LoaderHelpers.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PostProcess.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\BufferHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Src\CommonStates.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteFont.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\VertexTypes.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectCommon.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ScreenGrab.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Model.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BinaryReader.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GamePad.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Keyboard.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Mouse.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SimpleMath.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Geometry.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DebugEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BufferHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\CompileShaders.cmd">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SpriteEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\TeapotData.inc">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Common.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Lighting.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Structures.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Utilities.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBRCommon.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="README.md" />
|
||||
</ItemGroup>
|
||||
</Project>
|
84
Sdk/External/DirectXTK/DirectXTK_Desktop_2019_Win10.sln
vendored
Normal file
84
Sdk/External/DirectXTK/DirectXTK_Desktop_2019_Win10.sln
vendored
Normal file
@ -0,0 +1,84 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio Version 16
|
||||
VisualStudioVersion = 16.0.29609.76
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTK_Desktop_2019_Win10", "DirectXTK_Desktop_2019_Win10.vcxproj", "{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MakeSpriteFont", "MakeSpriteFont\MakeSpriteFont.csproj", "{7329B02D-C504-482A-A156-181D48CE493C}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "XWBTool_Desktop_2019", "XWBTool\XWBTool_Desktop_2019.vcxproj", "{C7AB4186-54B2-4244-A533-77494763EA1D}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{BD5A62C9-FE7B-4491-82C2-BD46EA64D1C8}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
.editorconfig = .editorconfig
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|ARM64 = Debug|ARM64
|
||||
Debug|Mixed Platforms = Debug|Mixed Platforms
|
||||
Debug|x86 = Debug|x86
|
||||
Debug|x64 = Debug|x64
|
||||
Release|ARM64 = Release|ARM64
|
||||
Release|Mixed Platforms = Release|Mixed Platforms
|
||||
Release|x86 = Release|x86
|
||||
Release|x64 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|ARM64.ActiveCfg = Debug|ARM64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|ARM64.Build.0 = Debug|ARM64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|Mixed Platforms.Build.0 = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x86.Build.0 = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x64.Build.0 = Debug|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|ARM64.ActiveCfg = Release|ARM64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|ARM64.Build.0 = Release|ARM64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|Mixed Platforms.ActiveCfg = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|Mixed Platforms.Build.0 = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x86.ActiveCfg = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x86.Build.0 = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x64.ActiveCfg = Release|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x64.Build.0 = Release|x64
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|ARM64.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|ARM64.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|ARM64.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|ARM64.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|Mixed Platforms.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x86.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x64.Build.0 = Release|Any CPU
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|ARM64.ActiveCfg = Debug|ARM64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|ARM64.Build.0 = Debug|ARM64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|Mixed Platforms.Build.0 = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x86.Build.0 = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x64.Build.0 = Debug|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|ARM64.ActiveCfg = Release|ARM64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|ARM64.Build.0 = Release|ARM64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|Mixed Platforms.ActiveCfg = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|Mixed Platforms.Build.0 = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x86.ActiveCfg = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x86.Build.0 = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x64.ActiveCfg = Release|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x64.Build.0 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {0F7A0290-0AF9-47AB-A91D-1346B9433995}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
440
Sdk/External/DirectXTK/DirectXTK_Desktop_2019_Win10.vcxproj
vendored
Normal file
440
Sdk/External/DirectXTK/DirectXTK_Desktop_2019_Win10.vcxproj
vendored
Normal file
@ -0,0 +1,440 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|ARM64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>ARM64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|ARM64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>ARM64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Audio\SoundCommon.h" />
|
||||
<ClInclude Include="Audio\WaveBankReader.h" />
|
||||
<ClInclude Include="Audio\WAVFileReader.h" />
|
||||
<ClInclude Include="Inc\Audio.h" />
|
||||
<ClInclude Include="Inc\BufferHelpers.h" />
|
||||
<ClInclude Include="Inc\CommonStates.h" />
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h" />
|
||||
<ClInclude Include="Inc\DirectXHelpers.h" />
|
||||
<ClInclude Include="Inc\Effects.h" />
|
||||
<ClInclude Include="Inc\GamePad.h" />
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h" />
|
||||
<ClInclude Include="Inc\GraphicsMemory.h" />
|
||||
<ClInclude Include="Inc\Keyboard.h" />
|
||||
<ClInclude Include="Inc\Model.h" />
|
||||
<ClInclude Include="Inc\Mouse.h" />
|
||||
<ClInclude Include="Inc\PostProcess.h" />
|
||||
<ClInclude Include="Inc\SimpleMath.h" />
|
||||
<ClInclude Include="Inc\SimpleMath.inl" />
|
||||
<ClInclude Include="Inc\ScreenGrab.h" />
|
||||
<ClInclude Include="Inc\SpriteBatch.h" />
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h" />
|
||||
<ClInclude Include="Inc\SpriteFont.h" />
|
||||
<ClInclude Include="Inc\VertexTypes.h" />
|
||||
<ClInclude Include="Inc\WICTextureLoader.h" />
|
||||
<ClInclude Include="Src\AlignedNew.h" />
|
||||
<ClInclude Include="Src\Bezier.h" />
|
||||
<ClInclude Include="Src\BinaryReader.h" />
|
||||
<ClInclude Include="Src\DemandCreate.h" />
|
||||
<ClInclude Include="Src\EffectCommon.h" />
|
||||
<ClInclude Include="Src\Geometry.h" />
|
||||
<ClInclude Include="Src\LoaderHelpers.h" />
|
||||
<ClInclude Include="Src\pch.h" />
|
||||
<ClInclude Include="Src\PlatformHelpers.h" />
|
||||
<ClInclude Include="Src\SDKMesh.h" />
|
||||
<ClInclude Include="Src\SharedResourcePool.h" />
|
||||
<ClInclude Include="Src\DDS.h" />
|
||||
<ClInclude Include="Src\vbo.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Audio\AudioEngine.cpp" />
|
||||
<ClCompile Include="Audio\DynamicSoundEffectInstance.cpp" />
|
||||
<ClCompile Include="Audio\SoundCommon.cpp" />
|
||||
<ClCompile Include="Audio\SoundEffect.cpp" />
|
||||
<ClCompile Include="Audio\SoundEffectInstance.cpp" />
|
||||
<ClCompile Include="Audio\SoundStreamInstance.cpp" />
|
||||
<ClCompile Include="Audio\WaveBank.cpp" />
|
||||
<ClCompile Include="Audio\WaveBankReader.cpp" />
|
||||
<ClCompile Include="Audio\WAVFileReader.cpp" />
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp" />
|
||||
<ClCompile Include="Src\BufferHelpers.cpp" />
|
||||
<ClCompile Include="Src\CommonStates.cpp" />
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp" />
|
||||
<ClCompile Include="Src\DebugEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp" />
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp" />
|
||||
<ClCompile Include="Src\DualPostProcess.cpp" />
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp" />
|
||||
<ClCompile Include="Src\BinaryReader.cpp" />
|
||||
<ClCompile Include="Src\EffectCommon.cpp" />
|
||||
<ClCompile Include="Src\EffectFactory.cpp" />
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp" />
|
||||
<ClCompile Include="Src\GamePad.cpp" />
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp" />
|
||||
<ClCompile Include="Src\Geometry.cpp" />
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp" />
|
||||
<ClCompile Include="Src\Keyboard.cpp" />
|
||||
<ClCompile Include="Src\Model.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp" />
|
||||
<ClCompile Include="Src\Mouse.cpp" />
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp" />
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">Create</PrecompiledHeader>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ScreenGrab.cpp" />
|
||||
<ClCompile Include="Src\SimpleMath.cpp" />
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp" />
|
||||
<ClCompile Include="Src\SpriteBatch.cpp" />
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp" />
|
||||
<ClCompile Include="Src\SpriteFont.cpp" />
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp" />
|
||||
<ClCompile Include="Src\VertexTypes.cpp" />
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="README.md" />
|
||||
<None Include="Src\Shaders\Common.fxh" />
|
||||
<None Include="Src\Shaders\CompileShaders.cmd" />
|
||||
<None Include="Src\Shaders\Lighting.fxh" />
|
||||
<None Include="Src\Shaders\PBRCommon.fxh" />
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli" />
|
||||
<None Include="Src\Shaders\SpriteEffect.fx" />
|
||||
<None Include="Src\Shaders\Structures.fxh" />
|
||||
<None Include="Src\Shaders\Utilities.fxh" />
|
||||
<None Include="Src\TeapotData.inc" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>DirectXTK</RootNamespace>
|
||||
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>Bin\Desktop_2019_Win10\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019_Win10\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>Bin\Desktop_2019_Win10\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019_Win10\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<OutDir>Bin\Desktop_2019_Win10\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019_Win10\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
|
||||
<OutDir>Bin\Desktop_2019_Win10\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019_Win10\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<OutDir>Bin\Desktop_2019_Win10\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019_Win10\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
|
||||
<OutDir>Bin\Desktop_2019_Win10\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Desktop_2019_Win10\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0A00;_WIN7_PLATFORM_UPDATE;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0A00;_WIN7_PLATFORM_UPDATE;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0A00;_WIN7_PLATFORM_UPDATE;WIN32;_DEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0A00;_WIN7_PLATFORM_UPDATE;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0A00;_WIN7_PLATFORM_UPDATE;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<PreprocessorDefinitions>_WIN32_WINNT=0x0A00;_WIN7_PLATFORM_UPDATE;WIN32;NDEBUG;_LIB;_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
<Target Name="ATGEnsureShaders" BeforeTargets="PrepareForBuild">
|
||||
<PropertyGroup>
|
||||
<_ATGFXCPath>$(WindowsSDK_ExecutablePath_x64.Split(';')[0])</_ATGFXCPath>
|
||||
<_ATGFXCPath>$(_ATGFXCPath.Replace("x64",""))</_ATGFXCPath>
|
||||
<_ATGFXCPath Condition="'$(_ATGFXCPath)' != '' and !HasTrailingSlash('$(_ATGFXCPath)')">$(_ATGFXCPath)\</_ATGFXCPath>
|
||||
</PropertyGroup>
|
||||
<Exec Condition="!Exists('src/Shaders/Compiled/SpriteEffect_SpriteVertexShader.inc')" WorkingDirectory="$(ProjectDir)src/Shaders" Command="CompileShaders" EnvironmentVariables="WindowsSdkVerBinPath=$(_ATGFXCPath)" />
|
||||
<PropertyGroup>
|
||||
<_ATGFXCPath />
|
||||
</PropertyGroup>
|
||||
</Target>
|
||||
<Target Name="ATGDeleteShaders" AfterTargets="Clean">
|
||||
<ItemGroup>
|
||||
<_ATGShaderHeaders Include="$(ProjectDir)src/Shaders/Compiled/*.inc" Exclude="$(ProjectDir)src/Shaders/Compiled/*Xbox*.inc" />
|
||||
<_ATGShaderSymbols Include="$(ProjectDir)src/Shaders/Compiled/*.pdb" Exclude="$(ProjectDir)src/Shaders/Compiled/*Xbox*.pdb" />
|
||||
</ItemGroup>
|
||||
<Delete Files="@(_ATGShaderHeaders)" />
|
||||
<Delete Files="@(_ATGShaderSymbols)" />
|
||||
</Target>
|
||||
</Project>
|
357
Sdk/External/DirectXTK/DirectXTK_Desktop_2019_Win10.vcxproj.filters
vendored
Normal file
357
Sdk/External/DirectXTK/DirectXTK_Desktop_2019_Win10.vcxproj.filters
vendored
Normal file
@ -0,0 +1,357 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Inc">
|
||||
<UniqueIdentifier>{771f5f80-d173-49c3-8afb-790e8f7cb0ce}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src">
|
||||
<UniqueIdentifier>{c52e19b6-8703-49a1-9b36-101a05b4745d}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Inc\Shared">
|
||||
<UniqueIdentifier>{e07ba3bc-b69f-4ded-9ffa-3b47427e9fef}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shared">
|
||||
<UniqueIdentifier>{28e934ed-a6d7-4c30-b064-c72c50c99626}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders">
|
||||
<UniqueIdentifier>{28d5fa16-99e2-471c-8cd8-2020e81f0024}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders\Shared">
|
||||
<UniqueIdentifier>{34676173-31f5-4435-b90d-a0ad4f7d163c}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Audio">
|
||||
<UniqueIdentifier>{5d47b946-09b9-4477-934f-ca45fba9845d}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Inc\CommonStates.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\ScreenGrab.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteFont.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\VertexTypes.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\pch.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\PlatformHelpers.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\EffectCommon.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Effects.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\WICTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Model.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DirectXHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GraphicsMemory.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Audio.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\SoundCommon.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\WAVFileReader.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\WaveBankReader.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GamePad.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Keyboard.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Mouse.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SimpleMath.inl">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SimpleMath.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\AlignedNew.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Bezier.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\BinaryReader.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DDS.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DemandCreate.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Geometry.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\LoaderHelpers.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SharedResourcePool.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\vbo.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SDKMesh.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PostProcess.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\BufferHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Src\CommonStates.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteFont.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\VertexTypes.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectCommon.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ScreenGrab.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Model.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\AudioEngine.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\DynamicSoundEffectInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundCommon.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WAVFileReader.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WaveBankReader.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WaveBank.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundEffectInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundEffect.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BinaryReader.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GamePad.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Geometry.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Keyboard.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Mouse.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SimpleMath.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DebugEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundStreamInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BufferHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\CompileShaders.cmd">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SpriteEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Lighting.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Common.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Structures.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\TeapotData.inc">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Utilities.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBRCommon.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="README.md" />
|
||||
</ItemGroup>
|
||||
</Project>
|
73
Sdk/External/DirectXTK/DirectXTK_Desktop_2019_Win7.sln
vendored
Normal file
73
Sdk/External/DirectXTK/DirectXTK_Desktop_2019_Win7.sln
vendored
Normal file
@ -0,0 +1,73 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio Version 16
|
||||
VisualStudioVersion = 15.0.28307.1000
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTK_Desktop_2019", "DirectXTK_Desktop_2019.vcxproj", "{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTKAudio_Desktop_2019_Win7", "Audio\DirectXTKAudio_Desktop_2019_Win7.vcxproj", "{4F150A30-CECB-49D1-8283-6A3F57438CF5}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MakeSpriteFont", "MakeSpriteFont\MakeSpriteFont.csproj", "{7329B02D-C504-482A-A156-181D48CE493C}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xwbtool_Desktop_2019", "XWBTool\xwbtool_Desktop_2019.vcxproj", "{C7AB4186-54B2-4244-A533-77494763EA1D}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
Debug|x64 = Debug|x64
|
||||
Debug|x86 = Debug|x86
|
||||
Release|Any CPU = Release|Any CPU
|
||||
Release|x64 = Release|x64
|
||||
Release|x86 = Release|x86
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|Any CPU.ActiveCfg = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x64.Build.0 = Debug|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Debug|x86.Build.0 = Debug|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|Any CPU.ActiveCfg = Release|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x64.ActiveCfg = Release|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x64.Build.0 = Release|x64
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x86.ActiveCfg = Release|Win32
|
||||
{4F150A30-CECB-49D1-8283-6A3F57438CF5}.Release|x86.Build.0 = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|Any CPU.ActiveCfg = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x64.Build.0 = Debug|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Debug|x86.Build.0 = Debug|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|Any CPU.ActiveCfg = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x64.ActiveCfg = Release|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x64.Build.0 = Release|x64
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x86.ActiveCfg = Release|Win32
|
||||
{E0B52AE7-E160-4D32-BF3F-910B785E5A8E}.Release|x86.Build.0 = Release|Win32
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x64.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Debug|x86.Build.0 = Debug|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x64.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x64.Build.0 = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{7329B02D-C504-482A-A156-181D48CE493C}.Release|x86.Build.0 = Release|Any CPU
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|Any CPU.ActiveCfg = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x64.Build.0 = Debug|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Debug|x86.Build.0 = Debug|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|Any CPU.ActiveCfg = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x64.ActiveCfg = Release|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x64.Build.0 = Release|x64
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x86.ActiveCfg = Release|Win32
|
||||
{C7AB4186-54B2-4244-A533-77494763EA1D}.Release|x86.Build.0 = Release|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {3B774DEE-1D2A-4EEF-B8FA-75BDC1DA64DE}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
48
Sdk/External/DirectXTK/DirectXTK_Windows10_2017.sln
vendored
Normal file
48
Sdk/External/DirectXTK/DirectXTK_Windows10_2017.sln
vendored
Normal file
@ -0,0 +1,48 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio 15
|
||||
VisualStudioVersion = 15.0.27703.2000
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTK", "DirectXTK_Windows10_2017.vcxproj", "{F4776924-619C-42C7-88B2-82C947CCC9E7}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{88140C29-E1F8-41E0-9126-6912B6A713BA}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
.editorconfig = .editorconfig
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|ARM = Debug|ARM
|
||||
Debug|ARM64 = Debug|ARM64
|
||||
Debug|x64 = Debug|x64
|
||||
Debug|x86 = Debug|x86
|
||||
Release|ARM = Release|ARM
|
||||
Release|ARM64 = Release|ARM64
|
||||
Release|x64 = Release|x64
|
||||
Release|x86 = Release|x86
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|ARM.ActiveCfg = Debug|ARM
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|ARM.Build.0 = Debug|ARM
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|ARM64.ActiveCfg = Debug|ARM64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|ARM64.Build.0 = Debug|ARM64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|x64.Build.0 = Debug|x64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|x86.Build.0 = Debug|Win32
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|ARM.ActiveCfg = Release|ARM
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|ARM.Build.0 = Release|ARM
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|ARM64.ActiveCfg = Release|ARM64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|ARM64.Build.0 = Release|ARM64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|x64.ActiveCfg = Release|x64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|x64.Build.0 = Release|x64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|x86.ActiveCfg = Release|Win32
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|x86.Build.0 = Release|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {FFD89A12-8620-47B9-A00E-6FD1824BFAC5}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
527
Sdk/External/DirectXTK/DirectXTK_Windows10_2017.vcxproj
vendored
Normal file
527
Sdk/External/DirectXTK/DirectXTK_Windows10_2017.vcxproj
vendored
Normal file
@ -0,0 +1,527 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|ARM">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>ARM</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|ARM64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>ARM64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|ARM">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>ARM</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|ARM64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>ARM64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Audio\SoundCommon.h" />
|
||||
<ClInclude Include="Audio\WaveBankReader.h" />
|
||||
<ClInclude Include="Audio\WAVFileReader.h" />
|
||||
<ClInclude Include="Inc\Audio.h" />
|
||||
<ClInclude Include="Inc\BufferHelpers.h" />
|
||||
<ClInclude Include="Inc\CommonStates.h" />
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h" />
|
||||
<ClInclude Include="Inc\DirectXHelpers.h" />
|
||||
<ClInclude Include="Inc\Effects.h" />
|
||||
<ClInclude Include="Inc\GamePad.h" />
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h" />
|
||||
<ClInclude Include="Inc\GraphicsMemory.h" />
|
||||
<ClInclude Include="Inc\Keyboard.h" />
|
||||
<ClInclude Include="Inc\Model.h" />
|
||||
<ClInclude Include="Inc\Mouse.h" />
|
||||
<ClInclude Include="Inc\PostProcess.h" />
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h" />
|
||||
<ClInclude Include="Inc\ScreenGrab.h" />
|
||||
<ClInclude Include="Inc\SimpleMath.h" />
|
||||
<ClInclude Include="Inc\SpriteBatch.h" />
|
||||
<ClInclude Include="Inc\SpriteFont.h" />
|
||||
<ClInclude Include="Inc\VertexTypes.h" />
|
||||
<ClInclude Include="Inc\WICTextureLoader.h" />
|
||||
<ClInclude Include="Src\AlignedNew.h" />
|
||||
<ClInclude Include="Src\Bezier.h" />
|
||||
<ClInclude Include="Src\BinaryReader.h" />
|
||||
<ClInclude Include="Src\DDS.h" />
|
||||
<ClInclude Include="Src\DemandCreate.h" />
|
||||
<ClInclude Include="Src\EffectCommon.h" />
|
||||
<ClInclude Include="Src\Geometry.h" />
|
||||
<ClInclude Include="Src\LoaderHelpers.h" />
|
||||
<ClInclude Include="Src\pch.h" />
|
||||
<ClInclude Include="Src\PlatformHelpers.h" />
|
||||
<ClInclude Include="Src\SDKMesh.h" />
|
||||
<ClInclude Include="Src\SharedResourcePool.h" />
|
||||
<ClInclude Include="Src\vbo.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Inc\SimpleMath.inl" />
|
||||
<None Include="README.md" />
|
||||
<None Include="Src\Shaders\Common.fxh" />
|
||||
<None Include="Src\Shaders\CompileShaders.cmd" />
|
||||
<None Include="Src\Shaders\Lighting.fxh" />
|
||||
<None Include="Src\Shaders\PBRCommon.fxh" />
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli" />
|
||||
<None Include="Src\Shaders\Structures.fxh" />
|
||||
<None Include="Src\Shaders\Utilities.fxh" />
|
||||
<None Include="Src\TeapotData.inc" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Audio\AudioEngine.cpp" />
|
||||
<ClCompile Include="Audio\DynamicSoundEffectInstance.cpp" />
|
||||
<ClCompile Include="Audio\SoundCommon.cpp" />
|
||||
<ClCompile Include="Audio\SoundEffect.cpp" />
|
||||
<ClCompile Include="Audio\SoundEffectInstance.cpp" />
|
||||
<ClCompile Include="Audio\SoundStreamInstance.cpp" />
|
||||
<ClCompile Include="Audio\WaveBank.cpp" />
|
||||
<ClCompile Include="Audio\WaveBankReader.cpp" />
|
||||
<ClCompile Include="Audio\WAVFileReader.cpp" />
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp" />
|
||||
<ClCompile Include="Src\BinaryReader.cpp" />
|
||||
<ClCompile Include="Src\BufferHelpers.cpp" />
|
||||
<ClCompile Include="Src\CommonStates.cpp" />
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp" />
|
||||
<ClCompile Include="Src\DebugEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp" />
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp" />
|
||||
<ClCompile Include="Src\DualPostProcess.cpp" />
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp" />
|
||||
<ClCompile Include="Src\EffectCommon.cpp" />
|
||||
<ClCompile Include="Src\EffectFactory.cpp" />
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp" />
|
||||
<ClCompile Include="Src\GamePad.cpp" />
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp" />
|
||||
<ClCompile Include="Src\Geometry.cpp" />
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp" />
|
||||
<ClCompile Include="Src\Keyboard.cpp" />
|
||||
<ClCompile Include="Src\Model.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp" />
|
||||
<ClCompile Include="Src\Mouse.cpp" />
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp" />
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|ARM'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|ARM'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp" />
|
||||
<ClCompile Include="Src\ScreenGrab.cpp" />
|
||||
<ClCompile Include="Src\SimpleMath.cpp" />
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp" />
|
||||
<ClCompile Include="Src\SpriteBatch.cpp" />
|
||||
<ClCompile Include="Src\SpriteFont.cpp" />
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp" />
|
||||
<ClCompile Include="Src\VertexTypes.cpp" />
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SpriteEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{f4776924-619c-42c7-88b2-82c947ccc9e7}</ProjectGuid>
|
||||
<Keyword>StaticLibrary</Keyword>
|
||||
<ProjectName>DirectXTK</ProjectName>
|
||||
<RootNamespace>DirectXTK</RootNamespace>
|
||||
<DefaultLanguage>en-US</DefaultLanguage>
|
||||
<MinimumVisualStudioVersion>14.0</MinimumVisualStudioVersion>
|
||||
<AppContainerApplication>true</AppContainerApplication>
|
||||
<ApplicationType>Windows Store</ApplicationType>
|
||||
<WindowsTargetPlatformVersion>10.0.17763.0</WindowsTargetPlatformVersion>
|
||||
<WindowsTargetPlatformMinVersion>10.0.14393.0</WindowsTargetPlatformMinVersion>
|
||||
<ApplicationTypeRevision>10.0</ApplicationTypeRevision>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="Shared">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|ARM'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|ARM'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM'">
|
||||
<OutDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
|
||||
<OutDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM'">
|
||||
<OutDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
|
||||
<OutDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<OutDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<OutDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles />
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles />
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles />
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles>
|
||||
</ForcedUsingFiles>
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles />
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles>
|
||||
</ForcedUsingFiles>
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles />
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles />
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
<Target Name="ATGEnsureShaders" BeforeTargets="PrepareForBuild">
|
||||
<PropertyGroup>
|
||||
<_ATGFXCPath>$(WindowsSDK_ExecutablePath_x64.Split(';')[0])</_ATGFXCPath>
|
||||
<_ATGFXCPath>$(_ATGFXCPath.Replace("x64",""))</_ATGFXCPath>
|
||||
<_ATGFXCPath Condition="'$(_ATGFXCPath)' != '' and !HasTrailingSlash('$(_ATGFXCPath)')">$(_ATGFXCPath)\</_ATGFXCPath>
|
||||
</PropertyGroup>
|
||||
<Exec Condition="!Exists('src/Shaders/Compiled/SpriteEffect_SpriteVertexShader.inc')" WorkingDirectory="$(ProjectDir)src/Shaders" Command="CompileShaders" EnvironmentVariables="WindowsSdkVerBinPath=$(_ATGFXCPath)" />
|
||||
<PropertyGroup>
|
||||
<_ATGFXCPath />
|
||||
</PropertyGroup>
|
||||
</Target>
|
||||
<Target Name="ATGDeleteShaders" AfterTargets="Clean">
|
||||
<ItemGroup>
|
||||
<_ATGShaderHeaders Include="$(ProjectDir)src/Shaders/Compiled/*.inc" Exclude="$(ProjectDir)src/Shaders/Compiled/*Xbox*.inc" />
|
||||
<_ATGShaderSymbols Include="$(ProjectDir)src/Shaders/Compiled/*.pdb" Exclude="$(ProjectDir)src/Shaders/Compiled/*Xbox*.pdb" />
|
||||
</ItemGroup>
|
||||
<Delete Files="@(_ATGShaderHeaders)" />
|
||||
<Delete Files="@(_ATGShaderSymbols)" />
|
||||
</Target>
|
||||
</Project>
|
357
Sdk/External/DirectXTK/DirectXTK_Windows10_2017.vcxproj.filters
vendored
Normal file
357
Sdk/External/DirectXTK/DirectXTK_Windows10_2017.vcxproj.filters
vendored
Normal file
@ -0,0 +1,357 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Inc">
|
||||
<UniqueIdentifier>{a77af43b-f2ab-4dcc-b84e-70909b198d8a}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src">
|
||||
<UniqueIdentifier>{4a81ebd8-dd1a-46fb-ad14-8b57d8e92774}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Audio">
|
||||
<UniqueIdentifier>{a872f54e-e97f-4e14-a946-da034ce61f99}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders">
|
||||
<UniqueIdentifier>{e536bb5b-5908-4d5a-b629-6a73cf2fc9ca}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Inc\Shared">
|
||||
<UniqueIdentifier>{68d47991-3b63-4a17-a705-680374a426f2}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shared">
|
||||
<UniqueIdentifier>{b5728d91-918a-4481-8e6f-8e793da9ee2c}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders\Shared">
|
||||
<UniqueIdentifier>{020af8ad-d3a0-41bc-bc05-b1d0a5d2a85f}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Inc\CommonStates.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DirectXHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Effects.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Model.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\ScreenGrab.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteFont.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\VertexTypes.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\WICTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\EffectCommon.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\pch.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Audio.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\SoundCommon.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\WaveBankReader.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\WAVFileReader.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GraphicsMemory.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GamePad.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Keyboard.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Mouse.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SimpleMath.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\AlignedNew.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Bezier.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\BinaryReader.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DDS.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DemandCreate.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\PlatformHelpers.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SDKMesh.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SharedResourcePool.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\vbo.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Geometry.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\LoaderHelpers.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PostProcess.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\BufferHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\CompileShaders.cmd">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SpriteEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Inc\SimpleMath.inl">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\TeapotData.inc">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Common.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Lighting.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Structures.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Utilities.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBRCommon.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="README.md" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\CommonStates.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectCommon.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Model.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ScreenGrab.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteFont.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\VertexTypes.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\AudioEngine.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\DynamicSoundEffectInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundCommon.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundEffect.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundEffectInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WaveBank.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WaveBankReader.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WAVFileReader.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BinaryReader.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GamePad.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Keyboard.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Mouse.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SimpleMath.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Geometry.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DebugEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundStreamInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BufferHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
</Project>
|
48
Sdk/External/DirectXTK/DirectXTK_Windows10_2019.sln
vendored
Normal file
48
Sdk/External/DirectXTK/DirectXTK_Windows10_2019.sln
vendored
Normal file
@ -0,0 +1,48 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio Version 16
|
||||
VisualStudioVersion = 15.0.27703.2000
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTK", "DirectXTK_Windows10_2019.vcxproj", "{F4776924-619C-42C7-88B2-82C947CCC9E7}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{88140C29-E1F8-41E0-9126-6912B6A713BA}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
.editorconfig = .editorconfig
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|ARM = Debug|ARM
|
||||
Debug|ARM64 = Debug|ARM64
|
||||
Debug|x64 = Debug|x64
|
||||
Debug|x86 = Debug|x86
|
||||
Release|ARM = Release|ARM
|
||||
Release|ARM64 = Release|ARM64
|
||||
Release|x64 = Release|x64
|
||||
Release|x86 = Release|x86
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|ARM.ActiveCfg = Debug|ARM
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|ARM.Build.0 = Debug|ARM
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|ARM64.ActiveCfg = Debug|ARM64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|ARM64.Build.0 = Debug|ARM64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|x64.Build.0 = Debug|x64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Debug|x86.Build.0 = Debug|Win32
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|ARM.ActiveCfg = Release|ARM
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|ARM.Build.0 = Release|ARM
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|ARM64.ActiveCfg = Release|ARM64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|ARM64.Build.0 = Release|ARM64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|x64.ActiveCfg = Release|x64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|x64.Build.0 = Release|x64
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|x86.ActiveCfg = Release|Win32
|
||||
{F4776924-619C-42C7-88B2-82C947CCC9E7}.Release|x86.Build.0 = Release|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {FFD89A12-8620-47B9-A00E-6FD1824BFAC5}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
535
Sdk/External/DirectXTK/DirectXTK_Windows10_2019.vcxproj
vendored
Normal file
535
Sdk/External/DirectXTK/DirectXTK_Windows10_2019.vcxproj
vendored
Normal file
@ -0,0 +1,535 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|ARM">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>ARM</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|ARM64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>ARM64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|ARM">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>ARM</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|ARM64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>ARM64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Audio\SoundCommon.h" />
|
||||
<ClInclude Include="Audio\WaveBankReader.h" />
|
||||
<ClInclude Include="Audio\WAVFileReader.h" />
|
||||
<ClInclude Include="Inc\Audio.h" />
|
||||
<ClInclude Include="Inc\BufferHelpers.h" />
|
||||
<ClInclude Include="Inc\CommonStates.h" />
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h" />
|
||||
<ClInclude Include="Inc\DirectXHelpers.h" />
|
||||
<ClInclude Include="Inc\Effects.h" />
|
||||
<ClInclude Include="Inc\GamePad.h" />
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h" />
|
||||
<ClInclude Include="Inc\GraphicsMemory.h" />
|
||||
<ClInclude Include="Inc\Keyboard.h" />
|
||||
<ClInclude Include="Inc\Model.h" />
|
||||
<ClInclude Include="Inc\Mouse.h" />
|
||||
<ClInclude Include="Inc\PostProcess.h" />
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h" />
|
||||
<ClInclude Include="Inc\ScreenGrab.h" />
|
||||
<ClInclude Include="Inc\SimpleMath.h" />
|
||||
<ClInclude Include="Inc\SpriteBatch.h" />
|
||||
<ClInclude Include="Inc\SpriteFont.h" />
|
||||
<ClInclude Include="Inc\VertexTypes.h" />
|
||||
<ClInclude Include="Inc\WICTextureLoader.h" />
|
||||
<ClInclude Include="Src\AlignedNew.h" />
|
||||
<ClInclude Include="Src\Bezier.h" />
|
||||
<ClInclude Include="Src\BinaryReader.h" />
|
||||
<ClInclude Include="Src\DDS.h" />
|
||||
<ClInclude Include="Src\DemandCreate.h" />
|
||||
<ClInclude Include="Src\EffectCommon.h" />
|
||||
<ClInclude Include="Src\Geometry.h" />
|
||||
<ClInclude Include="Src\LoaderHelpers.h" />
|
||||
<ClInclude Include="Src\pch.h" />
|
||||
<ClInclude Include="Src\PlatformHelpers.h" />
|
||||
<ClInclude Include="Src\SDKMesh.h" />
|
||||
<ClInclude Include="Src\SharedResourcePool.h" />
|
||||
<ClInclude Include="Src\vbo.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Inc\SimpleMath.inl" />
|
||||
<None Include="README.md" />
|
||||
<None Include="Src\Shaders\Common.fxh" />
|
||||
<None Include="Src\Shaders\CompileShaders.cmd" />
|
||||
<None Include="Src\Shaders\Lighting.fxh" />
|
||||
<None Include="Src\Shaders\PBRCommon.fxh" />
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli" />
|
||||
<None Include="Src\Shaders\Structures.fxh" />
|
||||
<None Include="Src\Shaders\Utilities.fxh" />
|
||||
<None Include="Src\TeapotData.inc" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Audio\AudioEngine.cpp" />
|
||||
<ClCompile Include="Audio\DynamicSoundEffectInstance.cpp" />
|
||||
<ClCompile Include="Audio\SoundCommon.cpp" />
|
||||
<ClCompile Include="Audio\SoundEffect.cpp" />
|
||||
<ClCompile Include="Audio\SoundEffectInstance.cpp" />
|
||||
<ClCompile Include="Audio\SoundStreamInstance.cpp" />
|
||||
<ClCompile Include="Audio\WaveBank.cpp" />
|
||||
<ClCompile Include="Audio\WaveBankReader.cpp" />
|
||||
<ClCompile Include="Audio\WAVFileReader.cpp" />
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp" />
|
||||
<ClCompile Include="Src\BinaryReader.cpp" />
|
||||
<ClCompile Include="Src\BufferHelpers.cpp" />
|
||||
<ClCompile Include="Src\CommonStates.cpp" />
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp" />
|
||||
<ClCompile Include="Src\DebugEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp" />
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp" />
|
||||
<ClCompile Include="Src\DualPostProcess.cpp" />
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp" />
|
||||
<ClCompile Include="Src\EffectCommon.cpp" />
|
||||
<ClCompile Include="Src\EffectFactory.cpp" />
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp" />
|
||||
<ClCompile Include="Src\GamePad.cpp" />
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp" />
|
||||
<ClCompile Include="Src\Geometry.cpp" />
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp" />
|
||||
<ClCompile Include="Src\Keyboard.cpp" />
|
||||
<ClCompile Include="Src\Model.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp" />
|
||||
<ClCompile Include="Src\Mouse.cpp" />
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp" />
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|ARM'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|ARM'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp" />
|
||||
<ClCompile Include="Src\ScreenGrab.cpp" />
|
||||
<ClCompile Include="Src\SimpleMath.cpp" />
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp" />
|
||||
<ClCompile Include="Src\SpriteBatch.cpp" />
|
||||
<ClCompile Include="Src\SpriteFont.cpp" />
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp" />
|
||||
<ClCompile Include="Src\VertexTypes.cpp" />
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SpriteEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{f4776924-619c-42c7-88b2-82c947ccc9e7}</ProjectGuid>
|
||||
<Keyword>StaticLibrary</Keyword>
|
||||
<ProjectName>DirectXTK</ProjectName>
|
||||
<RootNamespace>DirectXTK</RootNamespace>
|
||||
<DefaultLanguage>en-US</DefaultLanguage>
|
||||
<MinimumVisualStudioVersion>14.0</MinimumVisualStudioVersion>
|
||||
<AppContainerApplication>true</AppContainerApplication>
|
||||
<ApplicationType>Windows Store</ApplicationType>
|
||||
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
|
||||
<WindowsTargetPlatformMinVersion>10.0.14393.0</WindowsTargetPlatformMinVersion>
|
||||
<ApplicationTypeRevision>10.0</ApplicationTypeRevision>
|
||||
<PreferredToolArchitecture>x64</PreferredToolArchitecture>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v142</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="Shared">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|ARM'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|ARM'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM'">
|
||||
<OutDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
|
||||
<OutDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM'">
|
||||
<OutDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
|
||||
<OutDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<OutDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<OutDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\Windows10_2019\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles />
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles />
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles />
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles>
|
||||
</ForcedUsingFiles>
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles />
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles>
|
||||
</ForcedUsingFiles>
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles />
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<ForcedUsingFiles />
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<PreprocessorDefinitions>_CRT_STDIO_ARBITRARY_WIDE_SPECIFIERS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalOptions>/Zc:__cplusplus %(AdditionalOptions)</AdditionalOptions>
|
||||
<DisableSpecificWarnings>4711;5045;26812</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
<Target Name="ATGEnsureShaders" BeforeTargets="PrepareForBuild">
|
||||
<PropertyGroup>
|
||||
<_ATGFXCPath>$(WindowsSDK_ExecutablePath_x64.Split(';')[0])</_ATGFXCPath>
|
||||
<_ATGFXCPath>$(_ATGFXCPath.Replace("x64",""))</_ATGFXCPath>
|
||||
<_ATGFXCPath Condition="'$(_ATGFXCPath)' != '' and !HasTrailingSlash('$(_ATGFXCPath)')">$(_ATGFXCPath)\</_ATGFXCPath>
|
||||
</PropertyGroup>
|
||||
<Exec Condition="!Exists('src/Shaders/Compiled/SpriteEffect_SpriteVertexShader.inc')" WorkingDirectory="$(ProjectDir)src/Shaders" Command="CompileShaders" EnvironmentVariables="WindowsSdkVerBinPath=$(_ATGFXCPath)" />
|
||||
<PropertyGroup>
|
||||
<_ATGFXCPath />
|
||||
</PropertyGroup>
|
||||
</Target>
|
||||
<Target Name="ATGDeleteShaders" AfterTargets="Clean">
|
||||
<ItemGroup>
|
||||
<_ATGShaderHeaders Include="$(ProjectDir)src/Shaders/Compiled/*.inc" Exclude="$(ProjectDir)src/Shaders/Compiled/*Xbox*.inc" />
|
||||
<_ATGShaderSymbols Include="$(ProjectDir)src/Shaders/Compiled/*.pdb" Exclude="$(ProjectDir)src/Shaders/Compiled/*Xbox*.pdb" />
|
||||
</ItemGroup>
|
||||
<Delete Files="@(_ATGShaderHeaders)" />
|
||||
<Delete Files="@(_ATGShaderSymbols)" />
|
||||
</Target>
|
||||
</Project>
|
357
Sdk/External/DirectXTK/DirectXTK_Windows10_2019.vcxproj.filters
vendored
Normal file
357
Sdk/External/DirectXTK/DirectXTK_Windows10_2019.vcxproj.filters
vendored
Normal file
@ -0,0 +1,357 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Inc">
|
||||
<UniqueIdentifier>{a77af43b-f2ab-4dcc-b84e-70909b198d8a}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src">
|
||||
<UniqueIdentifier>{4a81ebd8-dd1a-46fb-ad14-8b57d8e92774}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Audio">
|
||||
<UniqueIdentifier>{a872f54e-e97f-4e14-a946-da034ce61f99}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders">
|
||||
<UniqueIdentifier>{e536bb5b-5908-4d5a-b629-6a73cf2fc9ca}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Inc\Shared">
|
||||
<UniqueIdentifier>{68d47991-3b63-4a17-a705-680374a426f2}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shared">
|
||||
<UniqueIdentifier>{b5728d91-918a-4481-8e6f-8e793da9ee2c}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders\Shared">
|
||||
<UniqueIdentifier>{020af8ad-d3a0-41bc-bc05-b1d0a5d2a85f}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Inc\CommonStates.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DirectXHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Effects.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Model.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\ScreenGrab.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteFont.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\VertexTypes.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\WICTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\EffectCommon.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\pch.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Audio.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\SoundCommon.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\WaveBankReader.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\WAVFileReader.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GraphicsMemory.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GamePad.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Keyboard.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Mouse.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SimpleMath.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\AlignedNew.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Bezier.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\BinaryReader.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DDS.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DemandCreate.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\PlatformHelpers.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SDKMesh.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SharedResourcePool.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\vbo.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Geometry.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\LoaderHelpers.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PostProcess.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\BufferHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\CompileShaders.cmd">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SpriteEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Inc\SimpleMath.inl">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\TeapotData.inc">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Common.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Lighting.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Structures.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Utilities.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBRCommon.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="README.md" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\CommonStates.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectCommon.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Model.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ScreenGrab.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteFont.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\VertexTypes.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\AudioEngine.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\DynamicSoundEffectInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundCommon.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundEffect.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundEffectInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WaveBank.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WaveBankReader.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WAVFileReader.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BinaryReader.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GamePad.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Keyboard.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Mouse.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SimpleMath.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Geometry.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DebugEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundStreamInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BufferHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
</Project>
|
33
Sdk/External/DirectXTK/DirectXTK_XboxOneXDK_2017.sln
vendored
Normal file
33
Sdk/External/DirectXTK/DirectXTK_XboxOneXDK_2017.sln
vendored
Normal file
@ -0,0 +1,33 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio 15
|
||||
VisualStudioVersion = 15.0.27703.2000
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTK_XboxOneXDK_2017", "DirectXTK_XboxOneXDK_2017.vcxproj", "{4FDFDCCD-EE2E-415C-B458-1E8FDB0D85F2}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{991F09BD-CC92-491D-B166-2DBEAF4C0420}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
.editorconfig = .editorconfig
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Durango = Debug|Durango
|
||||
Profile|Durango = Profile|Durango
|
||||
Release|Durango = Release|Durango
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{4FDFDCCD-EE2E-415C-B458-1E8FDB0D85F2}.Debug|Durango.ActiveCfg = Debug|Durango
|
||||
{4FDFDCCD-EE2E-415C-B458-1E8FDB0D85F2}.Debug|Durango.Build.0 = Debug|Durango
|
||||
{4FDFDCCD-EE2E-415C-B458-1E8FDB0D85F2}.Profile|Durango.ActiveCfg = Profile|Durango
|
||||
{4FDFDCCD-EE2E-415C-B458-1E8FDB0D85F2}.Profile|Durango.Build.0 = Profile|Durango
|
||||
{4FDFDCCD-EE2E-415C-B458-1E8FDB0D85F2}.Release|Durango.ActiveCfg = Release|Durango
|
||||
{4FDFDCCD-EE2E-415C-B458-1E8FDB0D85F2}.Release|Durango.Build.0 = Release|Durango
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {406725DF-706A-46B2-BCAA-47445FD39BC6}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
351
Sdk/External/DirectXTK/DirectXTK_XboxOneXDK_2017.vcxproj
vendored
Normal file
351
Sdk/External/DirectXTK/DirectXTK_XboxOneXDK_2017.vcxproj
vendored
Normal file
@ -0,0 +1,351 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Release|Durango">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Durango</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Profile|Durango">
|
||||
<Configuration>Profile</Configuration>
|
||||
<Platform>Durango</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|Durango">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Durango</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Audio\SoundCommon.h" />
|
||||
<ClInclude Include="Audio\WaveBankReader.h" />
|
||||
<ClInclude Include="Audio\WAVFileReader.h" />
|
||||
<ClInclude Include="Inc\Audio.h" />
|
||||
<ClInclude Include="Inc\BufferHelpers.h" />
|
||||
<ClInclude Include="Inc\CommonStates.h" />
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h" />
|
||||
<ClInclude Include="Inc\DirectXHelpers.h" />
|
||||
<ClInclude Include="Inc\Effects.h" />
|
||||
<ClInclude Include="Inc\GamePad.h" />
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h" />
|
||||
<ClInclude Include="Inc\GraphicsMemory.h" />
|
||||
<ClInclude Include="Inc\Keyboard.h" />
|
||||
<ClInclude Include="Inc\Model.h" />
|
||||
<ClInclude Include="Inc\Mouse.h" />
|
||||
<ClInclude Include="Inc\PostProcess.h" />
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h" />
|
||||
<ClInclude Include="Inc\ScreenGrab.h" />
|
||||
<ClInclude Include="Inc\SimpleMath.h" />
|
||||
<ClInclude Include="Inc\SpriteBatch.h" />
|
||||
<ClInclude Include="Inc\SpriteFont.h" />
|
||||
<ClInclude Include="Inc\VertexTypes.h" />
|
||||
<ClInclude Include="Inc\WICTextureLoader.h" />
|
||||
<ClInclude Include="Inc\XboxDDSTextureLoader.h" />
|
||||
<ClInclude Include="Src\AlignedNew.h" />
|
||||
<ClInclude Include="Src\Bezier.h" />
|
||||
<ClInclude Include="Src\BinaryReader.h" />
|
||||
<ClInclude Include="Src\DDS.h" />
|
||||
<ClInclude Include="Src\DemandCreate.h" />
|
||||
<ClInclude Include="Src\EffectCommon.h" />
|
||||
<ClInclude Include="Src\Geometry.h" />
|
||||
<ClInclude Include="Src\LoaderHelpers.h" />
|
||||
<ClInclude Include="Src\pch.h" />
|
||||
<ClInclude Include="Src\PlatformHelpers.h" />
|
||||
<ClInclude Include="Src\SDKMesh.h" />
|
||||
<ClInclude Include="Src\SharedResourcePool.h" />
|
||||
<ClInclude Include="Src\vbo.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Audio\AudioEngine.cpp" />
|
||||
<ClCompile Include="Audio\DynamicSoundEffectInstance.cpp" />
|
||||
<ClCompile Include="Audio\SoundCommon.cpp" />
|
||||
<ClCompile Include="Audio\SoundEffect.cpp" />
|
||||
<ClCompile Include="Audio\SoundEffectInstance.cpp" />
|
||||
<ClCompile Include="Audio\SoundStreamInstance.cpp" />
|
||||
<ClCompile Include="Audio\WaveBank.cpp" />
|
||||
<ClCompile Include="Audio\WaveBankReader.cpp" />
|
||||
<ClCompile Include="Audio\WAVFileReader.cpp" />
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicEffect.cpp" />
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp" />
|
||||
<ClCompile Include="Src\BinaryReader.cpp" />
|
||||
<ClCompile Include="Src\BufferHelpers.cpp" />
|
||||
<ClCompile Include="Src\CommonStates.cpp" />
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp" />
|
||||
<ClCompile Include="Src\DebugEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffect.cpp" />
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp" />
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp" />
|
||||
<ClCompile Include="Src\DualPostProcess.cpp" />
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp" />
|
||||
<ClCompile Include="Src\EffectCommon.cpp" />
|
||||
<ClCompile Include="Src\EffectFactory.cpp" />
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp" />
|
||||
<ClCompile Include="Src\GamePad.cpp" />
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp" />
|
||||
<ClCompile Include="Src\Geometry.cpp" />
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp" />
|
||||
<ClCompile Include="Src\Keyboard.cpp" />
|
||||
<ClCompile Include="Src\Model.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp" />
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp" />
|
||||
<ClCompile Include="Src\Mouse.cpp" />
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffect.cpp" />
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp" />
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Durango'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Durango'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Profile|Durango'">Create</PrecompiledHeader>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp" />
|
||||
<ClCompile Include="Src\ScreenGrab.cpp" />
|
||||
<ClCompile Include="Src\SimpleMath.cpp" />
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp" />
|
||||
<ClCompile Include="Src\SpriteBatch.cpp" />
|
||||
<ClCompile Include="Src\SpriteFont.cpp" />
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp" />
|
||||
<ClCompile Include="Src\VertexTypes.cpp" />
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp" />
|
||||
<ClCompile Include="Src\XboxDDSTextureLoader.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Inc\SimpleMath.inl" />
|
||||
<None Include="README.md" />
|
||||
<None Include="Src\Shaders\Common.fxh" />
|
||||
<None Include="Src\Shaders\CompileShaders.cmd" />
|
||||
<None Include="Src\Shaders\Lighting.fxh" />
|
||||
<None Include="Src\Shaders\PBRCommon.fxh" />
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli" />
|
||||
<None Include="Src\Shaders\Structures.fxh" />
|
||||
<None Include="Src\Shaders\Utilities.fxh" />
|
||||
<None Include="Src\TeapotData.inc" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SpriteEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<RootNamespace>DirectXTK</RootNamespace>
|
||||
<ProjectGuid>{4fdfdccd-ee2e-415c-b458-1e8fdb0d85f2}</ProjectGuid>
|
||||
<DefaultLanguage>en-US</DefaultLanguage>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<ApplicationEnvironment>title</ApplicationEnvironment>
|
||||
<!-- - - - -->
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<MinimumVisualStudioVersion>14.0</MinimumVisualStudioVersion>
|
||||
<TargetRuntime>Native</TargetRuntime>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Durango'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
<EmbedManifest>false</EmbedManifest>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Profile|Durango'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
<EmbedManifest>false</EmbedManifest>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Durango'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
<EmbedManifest>false</EmbedManifest>
|
||||
<GenerateManifest>false</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Durango'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Profile|Durango'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Durango'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Durango'">
|
||||
<ReferencePath>$(Console_SdkLibPath);$(Console_SdkWindowsMetadataPath)</ReferencePath>
|
||||
<LibraryPath>$(Console_SdkLibPath)</LibraryPath>
|
||||
<LibraryWPath>$(Console_SdkLibPath);$(Console_SdkWindowsMetadataPath)</LibraryWPath>
|
||||
<IncludePath>$(Console_SdkIncludeRoot)</IncludePath>
|
||||
<ExecutablePath>$(Console_SdkRoot)bin;$(VCInstallDir)bin\x86_amd64;$(VCInstallDir)bin;$(WindowsSDK_ExecutablePath_x86);$(VSInstallDir)Common7\Tools\bin;$(VSInstallDir)Common7\tools;$(VSInstallDir)Common7\ide;$(ProgramFiles)\HTML Help Workshop;$(MSBuildToolsPath32);$(FxCopDir);$(PATH);</ExecutablePath>
|
||||
<OutDir>Bin\XboxOneXDK_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\XboxOneXDK_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Profile|Durango'">
|
||||
<ReferencePath>$(Console_SdkLibPath);$(Console_SdkWindowsMetadataPath)</ReferencePath>
|
||||
<LibraryPath>$(Console_SdkLibPath)</LibraryPath>
|
||||
<LibraryWPath>$(Console_SdkLibPath);$(Console_SdkWindowsMetadataPath)</LibraryWPath>
|
||||
<IncludePath>$(Console_SdkIncludeRoot)</IncludePath>
|
||||
<ExecutablePath>$(Console_SdkRoot)bin;$(VCInstallDir)bin\x86_amd64;$(VCInstallDir)bin;$(WindowsSDK_ExecutablePath_x86);$(VSInstallDir)Common7\Tools\bin;$(VSInstallDir)Common7\tools;$(VSInstallDir)Common7\ide;$(ProgramFiles)\HTML Help Workshop;$(MSBuildToolsPath32);$(FxCopDir);$(PATH);</ExecutablePath>
|
||||
<OutDir>Bin\XboxOneXDK_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\XboxOneXDK_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Durango'">
|
||||
<ReferencePath>$(Console_SdkLibPath);$(Console_SdkWindowsMetadataPath)</ReferencePath>
|
||||
<LibraryPath>$(Console_SdkLibPath)</LibraryPath>
|
||||
<LibraryWPath>$(Console_SdkLibPath);$(Console_SdkWindowsMetadataPath)</LibraryWPath>
|
||||
<IncludePath>$(Console_SdkIncludeRoot)</IncludePath>
|
||||
<ExecutablePath>$(Console_SdkRoot)bin;$(VCInstallDir)bin\x86_amd64;$(VCInstallDir)bin;$(WindowsSDK_ExecutablePath_x86);$(VSInstallDir)Common7\Tools\bin;$(VSInstallDir)Common7\tools;$(VSInstallDir)Common7\ide;$(ProgramFiles)\HTML Help Workshop;$(MSBuildToolsPath32);$(FxCopDir);$(PATH);</ExecutablePath>
|
||||
<OutDir>Bin\XboxOneXDK_2017\$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>Bin\XboxOneXDK_2017\$(Platform)\$(Configuration)\</IntDir>
|
||||
<TargetName>DirectXTK</TargetName>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Durango'">
|
||||
<Link>
|
||||
<AdditionalDependencies>d3d11_x.lib;combase.lib;kernelx.lib;toolhelpx.lib;uuid.lib;</AdditionalDependencies>
|
||||
<EntryPointSymbol>
|
||||
</EntryPointSymbol>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalUsingDirectories />
|
||||
<ForcedUsingFiles />
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<PreprocessorDefinitions>NDEBUG;__WRL_NO_DEFAULT_LIB__;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<AdditionalOptions>/Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Profile|Durango'">
|
||||
<Link>
|
||||
<AdditionalDependencies>pixEvt.lib;d3d11_x.lib;combase.lib;kernelx.lib;toolhelpx.lib;uuid.lib;</AdditionalDependencies>
|
||||
<EntryPointSymbol>
|
||||
</EntryPointSymbol>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<AdditionalUsingDirectories />
|
||||
<ForcedUsingFiles />
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<PreprocessorDefinitions>NDEBUG;__WRL_NO_DEFAULT_LIB__;_LIB;PROFILE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<AdditionalOptions>/Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Durango'">
|
||||
<Link>
|
||||
<AdditionalDependencies>d3d11_x.lib;combase.lib;kernelx.lib;toolhelpx.lib;uuid.lib;</AdditionalDependencies>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
|
||||
</Link>
|
||||
<ClCompile>
|
||||
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
|
||||
<PrecompiledHeader>Use</PrecompiledHeader>
|
||||
<MinimalRebuild>false</MinimalRebuild>
|
||||
<AdditionalUsingDirectories />
|
||||
<ForcedUsingFiles />
|
||||
<WarningLevel>EnableAllWarnings</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<PreprocessorDefinitions>_DEBUG;__WRL_NO_DEFAULT_LIB__;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<CompileAsWinRT>false</CompileAsWinRT>
|
||||
<AdditionalIncludeDirectories>$(ProjectDir)Inc;$(ProjectDir)Src;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<ProgramDataBaseFileName>$(IntDir)$(TargetName).pdb</ProgramDataBaseFileName>
|
||||
<AdditionalOptions>/Zc:twoPhase- %(AdditionalOptions)</AdditionalOptions>
|
||||
<SupportJustMyCode>false</SupportJustMyCode>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
<Target Name="ATGEnsureShaders" BeforeTargets="PrepareForBuild">
|
||||
<Exec Condition="!Exists('src/Shaders/Compiled/XboxOneSpriteEffect_SpriteVertexShader.inc')" WorkingDirectory="$(ProjectDir)src/Shaders" Command="CompileShaders xbox" EnvironmentVariables="XboxOneXDKLatest=$(DurangoXdkInstallPath)" />
|
||||
</Target>
|
||||
<Target Name="ATGDeleteShaders" AfterTargets="Clean">
|
||||
<ItemGroup>
|
||||
<_ATGShaderHeaders Include="$(ProjectDir)src/Shaders/Compiled/XboxOne*.inc" />
|
||||
<_ATGShaderSymbols Include="$(ProjectDir)src/Shaders/Compiled/XboxOne*.pdb" />
|
||||
</ItemGroup>
|
||||
<Delete Files="@(_ATGShaderHeaders)" />
|
||||
<Delete Files="@(_ATGShaderSymbols)" />
|
||||
</Target>
|
||||
</Project>
|
365
Sdk/External/DirectXTK/DirectXTK_XboxOneXDK_2017.vcxproj.filters
vendored
Normal file
365
Sdk/External/DirectXTK/DirectXTK_XboxOneXDK_2017.vcxproj.filters
vendored
Normal file
@ -0,0 +1,365 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Audio">
|
||||
<UniqueIdentifier>{37d8d298-8ff7-4b16-9de2-1e8e5b943795}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Inc">
|
||||
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
|
||||
<Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Src">
|
||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders">
|
||||
<UniqueIdentifier>{1d7c612f-bf24-4368-a247-46d28920c4a7}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Inc\Shared">
|
||||
<UniqueIdentifier>{9fa25651-7bb5-42a1-b589-06be42c55e5b}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shared">
|
||||
<UniqueIdentifier>{bb66477f-d2e3-4eed-9c13-e86060685825}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Src\Shaders\Shared">
|
||||
<UniqueIdentifier>{a6ee428c-85f6-4fea-979a-8c22779cd9e7}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Inc\Audio.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\SoundCommon.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\WaveBankReader.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Audio\WAVFileReader.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\CommonStates.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DDSTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\DirectXHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Effects.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GeometricPrimitive.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Model.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PrimitiveBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\ScreenGrab.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteBatch.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SpriteFont.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\VertexTypes.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\WICTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\XboxDDSTextureLoader.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\EffectCommon.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\pch.h">
|
||||
<Filter>Src</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GraphicsMemory.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\AlignedNew.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Bezier.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\BinaryReader.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DDS.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\DemandCreate.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\PlatformHelpers.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\GamePad.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Mouse.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\Keyboard.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\SimpleMath.h">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SharedResourcePool.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\SDKMesh.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\vbo.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\Geometry.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Src\LoaderHelpers.h">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\PostProcess.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Inc\BufferHelpers.h">
|
||||
<Filter>Inc</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Audio\AudioEngine.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\DynamicSoundEffectInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundCommon.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundEffect.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundEffectInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WaveBank.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WaveBankReader.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\WAVFileReader.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\AlphaTestEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\CommonStates.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DDSTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DGSLEffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualTextureEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectCommon.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\EnvironmentMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GeometricPrimitive.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Model.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadCMO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadSDKMESH.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ModelLoadVBO.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\pch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PrimitiveBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ScreenGrab.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SkinnedEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteBatch.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SpriteFont.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\VertexTypes.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\WICTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\XboxDDSTextureLoader.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GraphicsMemory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BinaryReader.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\GamePad.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Keyboard.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Mouse.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SimpleMath.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\Geometry.cpp">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\NormalMapEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BasicPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DualPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\ToneMapPostProcess.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DebugEffect.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\PBREffectFactory.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Audio\SoundStreamInstance.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\BufferHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\DirectXHelpers.cpp">
|
||||
<Filter>Src</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\Shaders\CompileShaders.cmd">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SkinnedEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\SpriteEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\AlphaTestEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\BasicEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLLambert.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLPhong.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DGSLUnlit.hlsl">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DualTextureEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\EnvironmentMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\TeapotData.inc">
|
||||
<Filter>Src\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Inc\SimpleMath.inl">
|
||||
<Filter>Inc\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Common.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Lighting.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Structures.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\NormalMapEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PostProcess.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\ToneMap.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\Utilities.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBREffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PBRCommon.fxh">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\DebugEffect.fx">
|
||||
<Filter>Src\Shaders</Filter>
|
||||
</None>
|
||||
<None Include="Src\Shaders\PixelPacking_Velocity.hlsli">
|
||||
<Filter>Src\Shaders\Shared</Filter>
|
||||
</None>
|
||||
<None Include="README.md" />
|
||||
</ItemGroup>
|
||||
</Project>
|
456
Sdk/External/DirectXTK/HISTORY.md
vendored
Normal file
456
Sdk/External/DirectXTK/HISTORY.md
vendored
Normal file
@ -0,0 +1,456 @@
|
||||
# DirectX Tool Kit for DirectX 11
|
||||
|
||||
http://go.microsoft.com/fwlink/?LinkId=248929
|
||||
|
||||
Release available for download on [GitHub](https://github.com/microsoft/DirectXTK/releases)
|
||||
|
||||
## Release History
|
||||
|
||||
### September 30, 2020
|
||||
* GamePad class updated with ``c_MostRecent`` constant for ``-1`` player index special behavior
|
||||
* Fixed bug in WICTextureLoader that resulted in ``WINCODEC_ERR_INSUFFICIENTBUFFER`` for some resize requests
|
||||
* Fixed ``.wav`` file reading of MIDILoop chunk
|
||||
* Minor code cleanup
|
||||
|
||||
### August 15, 2020
|
||||
* EnvironmentMapEffect now supports cubemaps, spherical, and dual-parabola environment maps
|
||||
* Code review and project updates
|
||||
|
||||
### July 2, 2020
|
||||
* Improved SpriteFont drawing performance in Debug builds
|
||||
* Regenerated shaders using Windows 10 May 2020 Update SDK (19041)
|
||||
* Code cleanup for some new VC++ 16.7 warnings and static code analysis
|
||||
* CMake updates
|
||||
|
||||
### June 1, 2020
|
||||
* Added BufferHelpers header with functions **CreateStaticBuffer** / **CreateTextureFromMemory**, and the **ConstantBuffer** helper class
|
||||
* Added **IsPowerOf2** and **CreateInputLayoutFromEffect** helpers to DirectXHelpers
|
||||
* Converted to typed enum bitmask flags (see release notes for details on this potential *breaking change*)
|
||||
+ ``AUDIO_ENGINE_FLAGS``, ``ModelLoaderFlags``, ``SOUND_EFFECT_INSTANCE_FLAGS``, and ``WIC_LOADER_FLAGS``
|
||||
* WICTextureLoader for ``PNG`` codec now checks ``gAMA`` chunk to determine colorspace if the ``sRGB`` chunk is not found for legacy sRGB detection.
|
||||
* ``WIC_LOADER_SRGB_DEFAULT`` flag added when loading image via WIC without explicit colorspace metadata
|
||||
* Retired XAudio 2.7 for *DirectX Tool Kit for Audio*. Use XAudio 2.9, XAudio 2.8, or XAudio2Redist instead.
|
||||
* CMake project updates
|
||||
|
||||
### May 10, 2020
|
||||
* WICTextureLoader updated with new loader flags: ``FORCE_RGBA32``, ``FIT_POW2``, and ``MAKE_SQUARE``
|
||||
* SimpleMath no longer forces use of d3d11.h or d3d12.h (can be used with d3d9.h for example)
|
||||
* *DirectX Tool Kit for Audio* updated with **SoundStreamInstance** class for async I/O playback from XACT-style streaming wavebanks
|
||||
* Code cleanup
|
||||
* xwbtool: Updated with ``-l`` switch for case-sensitive file systems
|
||||
|
||||
### April 3, 2020
|
||||
* SpriteFont **MeasureString** / **MeasureDrawBounds** fixes for !ignoreWhitespace
|
||||
* Code review (``constexpr`` / ``noexcept`` usage)
|
||||
* CMake updated for PCH usage with 3.16 or later
|
||||
|
||||
### February 24, 2020
|
||||
* *breaking change* **Model::CreateFromxxx** changed to use ModelLoaderFlags instead of default bool parameters
|
||||
* DirectX Tool Kit for Audio updated to support XAudio2Redist NuGet
|
||||
* Added ``ignoreWhitespace`` defaulted parameter to SpriteFont Measure methods
|
||||
* Fixed encoding issue with Utilities.fxh
|
||||
* Code and project cleanup
|
||||
* Retired VS 2015 projects
|
||||
* xwbtool: Changed ``-n`` switch to a more safe ``-y`` switch
|
||||
|
||||
### December 17, 2019
|
||||
* Added ARM64 platform to VS 2019 Win32 desktop Win10 project
|
||||
* Added Vector ``operator/`` by float scalar to SimpleMath
|
||||
* Updated CMake project
|
||||
* Code cleaup
|
||||
|
||||
### October 17, 2019
|
||||
* Added optional ``forceSRGB`` parameter to **SaveWICTextureToFile**
|
||||
* GamePad updated to report VID/PID (when supported)
|
||||
* Minor code cleanup
|
||||
|
||||
### August 21, 2019
|
||||
* Added xwbtool to CMake project
|
||||
* Minor code cleanup
|
||||
|
||||
### June 30, 2019
|
||||
* Additional validation for Ex texture loaders
|
||||
* Clang/LLVM warning cleanup
|
||||
* Renamed ``DirectXTK_Windows10.vcxproj`` to ``_Windows10_2017.vcxproj``
|
||||
* Added VS 2019 UWP project
|
||||
|
||||
### May 30, 2019
|
||||
* PBREffect updated with additional set methods
|
||||
* Added CMake project files
|
||||
* Code cleanup
|
||||
|
||||
### April 26, 2019
|
||||
* Added VS 2019 desktop projects
|
||||
* Fixed guards w.r.t. to windows.h usage in Keyboard/Mouse headers
|
||||
* Added C++/WinRT **SetWindow** helper to Keyboard/Mouse
|
||||
* Code cleanup for texture loaders
|
||||
* Officially dropped Windows Vista support
|
||||
|
||||
### February 7, 2019
|
||||
* Model now supports loading _SDKMESH v2_ models
|
||||
* **PBREffectFactory** added to support PBR materials
|
||||
* PBREffect and NormalMapEffect shaders updated to support ``BC5_UNORM`` compressed normal maps
|
||||
* SpriteFont: **DrawString** overloads for UTF-8 chars in addition to UTF-16LE wide chars
|
||||
|
||||
### November 16, 2018
|
||||
* VS 2017 updated for Windows 10 October 2018 Update SDK (17763)
|
||||
* ARM64 platform configurations added to UWP projects
|
||||
* Minor code review
|
||||
|
||||
### October 31, 2018
|
||||
* Model loader for SDKMESH now attempts to use legacy DE3CN compressed normals
|
||||
+ This is an approximation only and emits a warning in debug builds
|
||||
|
||||
### October 25, 2018
|
||||
* Use UTF-8 instead of ANSI for narrow strings
|
||||
* Minor code review
|
||||
|
||||
### August 17, 2018
|
||||
* Improved validation for 16k textures and other large resources
|
||||
* Improved debug output for failed texture loads and screengrabs
|
||||
* Updated for VS 2017 15.8
|
||||
* Code cleanup
|
||||
|
||||
### July 3, 2018
|
||||
* ModelMeshPart **DrawInstanced** method added
|
||||
* Code and project cleanup
|
||||
|
||||
### May 31, 2018
|
||||
* VS 2017 updated for Windows 10 April 2018 Update SDK (17134)
|
||||
* Regenerated shaders using Windows 10 April 2018 Update SDK (17134)
|
||||
|
||||
### May 14, 2018
|
||||
* Updated for VS 2017 15.7 update warnings
|
||||
* Code and project cleanup
|
||||
* Retired VS 2013 projects
|
||||
|
||||
### April 23, 2018
|
||||
* ``AlignUp``, ``AlignDown`` template functions in DirectXHelpers.h
|
||||
* Mouse support for cursor visibility
|
||||
* SimpleMath and VertexTypes updated with default copy and move ctors
|
||||
* SimpleMath updates to use ``constexpr``
|
||||
* EffectFactory updated with **GetDevice** method
|
||||
* PostProcess updated with 'big triangle' optimization
|
||||
* Fix for ``CMO`` handling of skinning vertex data
|
||||
* Code and project file cleanup
|
||||
* xwbtool: Fixed Windows 7 compatibility issue
|
||||
|
||||
### February 7, 2018
|
||||
* Mouse fix for cursor behavior when using Remote Desktop for Win32
|
||||
* Updated for a few more VS 2017 warnings
|
||||
* Code cleanup
|
||||
|
||||
### December 13, 2017
|
||||
* **PBREffect** and **DebugEffect** added
|
||||
* **NormalMapEffect** no longer requires or uses explicit vertex tangents
|
||||
* *breaking change* NormalMapEffect::SetBiasedVertexNormalsAndTangents renamed to **SetBiasedVertexNormals**
|
||||
* PBREffect, DebugEffect, & NormalMapEffect all require Direct3D hardware feature level 10.0 or better
|
||||
* **VertexType** typedef added to GeometricPrimitive as alias for VertexPositionNormalTexture
|
||||
* Updated for VS 2017 15.5 update warnings
|
||||
* Code cleanup
|
||||
|
||||
### November 1, 2017
|
||||
* VS 2017 updated for Windows 10 Fall Creators Update SDK (16299)
|
||||
* Regenerated shaders using Windows 10 Fall Creators Update SDK (16299)
|
||||
|
||||
### September 22, 2017
|
||||
* Updated for VS 2017 15.3 update ``/permissive-`` changes
|
||||
* **ScreenGrab** updated to use non-sRGB metadata for PNG
|
||||
* Mouse use of ``WM_INPUT`` updated for Remote Desktop scenarios
|
||||
* Fix for ``CMO`` load issue when no materials are defined
|
||||
* xwbtool: added ``-flist`` option
|
||||
|
||||
### July 28, 2017
|
||||
* Fix for WIC writer when codec target format requires a palette
|
||||
* Code cleanup
|
||||
|
||||
### June 21, 2017
|
||||
* Post-processing support with the **BasicPostProcess**, **DualPostProcess**, and **ToneMapPostProcess** classes
|
||||
* SDKMESH loader fix when loading legacy files with all zero materials
|
||||
* DirectXTK for Audio: Minor fixes for environmental audio
|
||||
* Minor code cleanup
|
||||
|
||||
### April 24, 2017
|
||||
* VS 2017 project updates
|
||||
* Regenerated shaders using Windows 10 Creators Update SDK (15063)
|
||||
* Fixed **NormalMapEffect** shader selection for specular texture usage
|
||||
* Fixed **AudioEngine** enumeration when using Single Threaded Apartment (STA)
|
||||
* Fixed bug with **GamePad** (Windows.Gaming.Input) when no user bound
|
||||
|
||||
### April 7, 2017
|
||||
* VS 2017 updated for Windows Creators Update SDK (15063)
|
||||
* XboxDDSTextureLoader updates
|
||||
|
||||
### February 10, 2017
|
||||
* **GamePad** now supports special value of ``-1`` for 'most recently connected controller'
|
||||
* WIC format 40bppCMYKAlpha should be converted to RGBA8 rather than RGBA16
|
||||
* DDS support for L8A8 with bitcount 8 rather than 16
|
||||
* Minor code cleanup
|
||||
|
||||
### December 5, 2016
|
||||
* Mouse and Keyboard classes updated with **IsConnected** method
|
||||
* Windows10 project ``/ZW`` switch removed to support use in C++/WinRT projection apps
|
||||
* VS 2017 RC projects added
|
||||
* Minor code cleanup
|
||||
|
||||
### October 6, 2016
|
||||
* SDKMESH loader and BasicEffects support for compressed vertex normals with biasing
|
||||
* WICTextureLoader Ex bool forceSRGB parameter is now a **WIC_LOADER_FLAGS** flag
|
||||
* Minor code cleanup
|
||||
|
||||
### September 15, 2016
|
||||
* Minor code cleanup
|
||||
* xwbtool: added wildcard support for input filename and optional ``-r`` switch for recursive search
|
||||
|
||||
### September 1, 2016
|
||||
* Added ``forceSRGB`` optional parameter to SpriteFont ctor
|
||||
* EffectFactory method **EnableForceSRGB** added
|
||||
* DGSLEffect now defaults to diffuse/alpha of 1
|
||||
* Removed problematic ABI::Windows::Foundation::Rect interop for SimpleMath
|
||||
* Minor code cleanup
|
||||
|
||||
### August 4, 2016
|
||||
* Regenerated shaders using Windows 10 Anniversary Update SDK (14393)
|
||||
|
||||
### August 2, 2016
|
||||
* Updated for VS 2015 Update 3 and Windows 10 SDK (14393)
|
||||
|
||||
### August 1, 2016
|
||||
* GamePad capabilities information updated for Universal Windows and Xbox One platforms
|
||||
* Specular falloff lighting computation fix in shaders
|
||||
|
||||
### July 18, 2016
|
||||
* **NormalMapEffect** for normal-map with optional specular map rendering
|
||||
* **EnvironmentMapEffect** now supports per-pixel lighting
|
||||
* Effects updated with **SetMatrices** and **SetColorAndAlpha** methods
|
||||
* SimpleMath: improved interop with DirectXMath constants
|
||||
* Minor code cleanup
|
||||
|
||||
### June 30, 2016
|
||||
* **MeasureDrawString** added to SpriteFont; bad fix to MeasureString reverted
|
||||
* GamePad tracker updated to track emulated buttons (i.e. leftStickUp)
|
||||
* EffectFactory **SetDirectory** now checks current working directory (CWD) as well
|
||||
* *breaking change* must include <d3d11.h> before including <SimpleMath.h>
|
||||
* Code refactor for sharing some files with DirectX 12 version
|
||||
* Minor code cleanup
|
||||
|
||||
### May 31, 2016
|
||||
* Added **VertexPosition** and **VertexPositionDualTexture** to VertexTypes
|
||||
* Xbox One platform fix for PrimitiveBatch
|
||||
* CompileShader script updated to build external pdbs
|
||||
* Code cleanup
|
||||
|
||||
### April 26, 2016
|
||||
* Added **Rectangle** class to SimpleMath
|
||||
* Fix for SDKMESH loader when loading models with 'extra' texture coordinate sets
|
||||
* Made SimpleMath's Viewport **ComputeTitleSafeArea** less conservative
|
||||
* Added view/menu aliases to GamePad::ButtonStateTracker for Xbox One Controller naming
|
||||
* Retired Windows phone 8.0 projects and obsolete adapter code
|
||||
* Minor code and project file cleanup
|
||||
|
||||
### February 23, 2016
|
||||
* Fixed width computation bug in **SpriteFont::MeasureString**
|
||||
* Fix to clean up partial or zero-length image files on failed write
|
||||
* Fix to WaveBankReader for UWP platform
|
||||
* Retired VS 2012 projects
|
||||
* Xbox One platform updates
|
||||
* Minor code and project file cleanup
|
||||
|
||||
### January 5, 2016
|
||||
* Xbox One platform updates
|
||||
* *breaking change* Need to add use of **GraphicsMemory** class to Xbox One titles
|
||||
* Minor code cleanup
|
||||
|
||||
### November 30, 2015
|
||||
* SimpleMath improvements including Viewport class
|
||||
* Fixed bug with **Keyboard** for ``OpenBracket`` and later VK codes
|
||||
* Fixed bug with **Mouse** that reset the scrollwheel on app activate
|
||||
* ``MakeSpriteFont`` updated with ``/FastPack`` and ``/FeatureLevel`` switches
|
||||
* Updated for VS 2015 Update 1 and Windows 10 SDK (10586)
|
||||
|
||||
### October 30, 2015
|
||||
* DirectXTK for Audio 3D updates
|
||||
* *breaking change* emitters/listeners now use RH coordinates by default
|
||||
* **GeometricPrimitive** support for custom geometry
|
||||
* SimpleMath Matrix class improvements
|
||||
* DDS support for legacy bumpmap formats (V8U8, Q8W8V8U8, V16U16)
|
||||
* Mouse fix for WinRT implementation with multiple buttons pressed
|
||||
* Wireframe **CommonStates** no longer does backface culling
|
||||
* Xbox One platform updates
|
||||
* Minor code cleanup
|
||||
|
||||
### August 18, 2015
|
||||
* Xbox One platform updates
|
||||
|
||||
### July 29, 2015
|
||||
* Added **CreateBox** method to GeometricPrimitive
|
||||
* Added ``invertn`` optional parameter to **CreateSphere**
|
||||
* Updates for Keyboard, Mouse class
|
||||
* Fixed bug when loading older SDKMESH models
|
||||
* Updated for VS 2015 and Windows 10 SDK RTM
|
||||
* Retired VS 2010 and Windows Store 8.0 projects
|
||||
|
||||
### July 1, 2015
|
||||
* Added **Keyboard**, **Mouse** class
|
||||
* Support for loading pre-lit models with SDKMESH
|
||||
* **GamePad** implemented using ``Windows.Gaming.Input`` for Windows 10
|
||||
* DirectXTK for Audio updates for xWMA support with XAudio 2.9
|
||||
* Added **FindGlyph** and **GetSpriteSheet** methods to SpriteFont
|
||||
|
||||
### March 27, 2015
|
||||
* Added projects for Windows apps Technical Preview
|
||||
* GamePad temporarily uses 'null' device for universal Windows application platform
|
||||
|
||||
### February 25, 2015
|
||||
* DirectXTK for Audio updates
|
||||
+ *breaking change* pitch now defined as -1 to 1 with 0 as the default
|
||||
+ One-shot Play method with volume, pitch, and pan
|
||||
+ **GetMasterVolume** / **SetMasterVolume** method for AudioEngine
|
||||
+ Fix for compact wavebank validation
|
||||
+ Improved voice cleanup and shutdown
|
||||
* Minor code cleanup and C++11 ``=default``/``=delete`` usage
|
||||
|
||||
### January 26, 2015
|
||||
* GamePad class: emulate ``XInputEnable`` behavior for XInput 9.1.0
|
||||
* DirectXTK for Audio fix for Stop followed by Play doing a proper restart
|
||||
* DirectXTK for Audio fix when using XAudio 2.7 on a system with no audio device
|
||||
* Updates for Xbox One platform support
|
||||
* Minor code cleanup and C99 ``printf`` string conformance
|
||||
|
||||
### November 24, 2014
|
||||
* SimpleMath fix for Matrix ``operator !=``
|
||||
* DirectXTK for Audio workaround for XAudio 2.7 on Windows 7 problem
|
||||
* Updates for Windows phone 8.1 platform support
|
||||
* Updates for Visual Studio 2015 Technical Preview
|
||||
* Minor code cleanup
|
||||
|
||||
### October 28, 2014
|
||||
* Model support for loading from ``VBO`` files
|
||||
* Model render now sets samplers on slots 0,1 by default for dual-texture effects
|
||||
* Updates for Xbox One platform support
|
||||
* Minor code cleanup
|
||||
|
||||
### September 5, 2014
|
||||
* **GamePad** class: gamepad controller helper using XInput on Windows, IGamepad for Xbox One
|
||||
* SimpleMath updates; Matrix billboard methods; *breaking change*: Matrix::Identity() -> Matrix::Identity
|
||||
* SpriteBatch new optional **SetViewport** method
|
||||
* SpriteFont fix for white-space character rendering optimization
|
||||
* DDSTextureLoader fix for auto-gen mipmaps for volume textures
|
||||
* Explicit calling-convention annotation for public headers
|
||||
* Updates for Xbox One platform support
|
||||
* Minor code and project cleanup
|
||||
|
||||
### July 15, 2014
|
||||
* DirectXTK for Audio and XWBTool fixes
|
||||
* Updates to Xbox One platform support
|
||||
|
||||
### April 3, 2014
|
||||
* Windows phone 8.1 platform support
|
||||
|
||||
### February 24, 2014
|
||||
* DirectXHelper: new utility header with **MapGuard** and public version of **SetDebugObjectName** template
|
||||
* DDSTextureLoader: Optional support for auto-gen mipmaps
|
||||
* DDSTextureLoader/ScreenGrab: support for Direct3D 11 video formats including legacy "YUY2" DDS files
|
||||
* GeometricPrimtive: Handedness fix for tetrahedron, octahedron, dodecahedron, and icosahedron
|
||||
* ``SpriteBatch::SetRotation(DXGI_MODE_ROTATION_UNSPECIFIED)`` to disable viewport matrix
|
||||
* XboxDDSTextureLoader: optional forceSRGB parameter
|
||||
|
||||
### January 24, 2014
|
||||
* DirectXTK for Audio updated with voice management and optional mastering volume limiter
|
||||
* Added orientation rotation support to **SpriteBatch**
|
||||
* Fixed a resource leak with ``GetDefaultTexture`` used by some Effects
|
||||
* Code cleanup (removed ``DXGI_1_2_FORMATS`` control define; d2d1.h workaround not needed; ScopedObject typedef removed)
|
||||
|
||||
### December 24, 2013
|
||||
* Added **DirectX Tool Kit for Audio** using XAudio2
|
||||
* Xbox One platform support
|
||||
* ``MakeSpriteFont`` tool updated with more progress feedback when capturing large fonts
|
||||
* Minor updates for ``SDKMESH`` Model loader
|
||||
* Fixed bug in ``CMO`` Model loader when handling multiple textures
|
||||
* Improved debugging output
|
||||
|
||||
### October 28, 2013
|
||||
* Updated for Visual Studio 2013 and Windows 8.1 SDK RTM
|
||||
* Added **DGSLEffect**, **DGSLEffectFactory**, **VertexPositionNormalTangentColorTexture**, and **VertexPositionNormalTangentColorTextureSkinning**
|
||||
* Model loading and effect factories support loading skinned models
|
||||
* ``MakeSpriteFont`` now has a smooth vs. sharp antialiasing option: /sharp
|
||||
* Model loading from ``CMOs`` now handles UV transforms for texture coordinates
|
||||
* A number of small fixes for **EffectFactory**
|
||||
* Minor code and project cleanup
|
||||
* Added ``NO_D3D11_DEBUG_NAME`` compilation define to control population of Direct3D debug layer names for debug builds
|
||||
|
||||
### July 1, 2013
|
||||
* VS 2013 Preview projects added and updates for DirectXMath 3.05 ``__vectorcall``
|
||||
* Added use of sRGB WIC metadata for ``JPEG``, ``PNG``, and ``TIFF``
|
||||
* SaveToWIC functions updated with new optional setCustomProps parameter and error check with optional targetFormat
|
||||
|
||||
### May 30, 2013
|
||||
* Added more **GeometricPrimitives**: Cone, Tetrahedron, Octahedron, Dodecahedron, Icosahedron
|
||||
* Updated to support loading new metadata from DDS files (if present)
|
||||
* Fixed bug with loading of WIC 32bpp RGBE format images
|
||||
* Fixed bug when skipping mipmaps in a 1D or 2D array texture DDS file
|
||||
|
||||
### February 22, 2013
|
||||
* Added **SimpleMath** header
|
||||
* Fixed bug that prevented properly overriding EffectFactory::CreateTexture
|
||||
* Fixed forceSRGB logic in DDSTextureLoader and WICTextureLoader
|
||||
* Break circular reference chains when using SpriteBatch with a setCustomShaders lambda
|
||||
* Updated projects with ``/fp:fast`` for all configs, ``/arch:SSE2`` for Win32 configs
|
||||
* Sensibly named .pdb output files
|
||||
* Added ``WIC_USE_FACTORY_PROXY`` build option (uses WindowsCodecs.dll entrypoint rather than CoCreateInstance)
|
||||
|
||||
### January 25, 2013
|
||||
* **GeometricPrimitive** support for left-handed coordinates and drawing with custom effects
|
||||
* Model, ModelMesh, and ModelMeshPart added with loading of rigid non-animating models from .CMO and .SDKMESH files
|
||||
* EffectFactory helper class added
|
||||
|
||||
### December 11, 2012
|
||||
* Ex versions of **DDSTextureLoader** and **WICTextureLoader**
|
||||
* Removed use of ATL's ``CComPtr`` in favor of WRL's ``ComPtr`` for all platforms to support VS Express editions
|
||||
* Updated VS 2010 project for official 'property sheet' integration for Windows 8.0 SDK
|
||||
* Minor fix to **CommonStates** for Feature Level 9.1
|
||||
* Tweaked AlphaTestEffect.cpp to work around ARM NEON compiler codegen bug
|
||||
* Added dxguid.lib as a default library for Debug builds to resolve GUID link issues
|
||||
|
||||
### November 15, 2012
|
||||
* Added support for WIC2 when available on Windows 8 and Windows 7 with KB 2670838
|
||||
* Cleaned up warning level 4 warnings
|
||||
|
||||
### October 30, 2012
|
||||
* Added project files for Windows phone 8
|
||||
|
||||
### October 12, 2012
|
||||
* Added **PrimitiveBatch** for drawing user primitives
|
||||
* Debug object names for all D3D resources (for PIX and debug layer leak reporting)
|
||||
|
||||
### October 2, 2012
|
||||
* Added **ScreenGrab** module
|
||||
* Added **CreateGeoSphere** for drawing a geodesic sphere
|
||||
* Put DDSTextureLoader and WICTextureLoader into the DirectX C++ namespace
|
||||
|
||||
### September 7, 2012
|
||||
* Renamed project files for better naming consistency
|
||||
* Updated WICTextureLoader for Windows 8 96bpp floating-point formats
|
||||
* Win32 desktop projects updated to use Windows Vista (0x0600) rather than Windows 7 (0x0601) APIs
|
||||
* Tweaked SpriteBatch.cpp to workaround ARM NEON compiler codegen bug
|
||||
|
||||
### May 31, 2012
|
||||
* Updated Windows Store project for Visual Studio 2012 Release Candidate changes
|
||||
* Cleaned up x64 Debug configuration warnings and switched to use ``_DEBUG`` instead of ``DEBUG``
|
||||
* Minor fix for DDSTextureLoader's retry fallback that can happen with 10level9 feature levels
|
||||
|
||||
### May 2, 2012
|
||||
* Added **SpriteFont** implementation and the MakeSpriteFont utility
|
||||
|
||||
### March 29, 2012
|
||||
* WICTextureLoader updated with Windows 8 WIC native pixel formats
|
||||
|
||||
### March 6, 2012
|
||||
* Fix for too much temp memory used by WICTextureLoader
|
||||
* Add separate Visual Studio 11 projects for Desktop vs. Windows Store builds
|
||||
|
||||
### March 5, 2012
|
||||
* Bug fix for SpriteBatch with batches > 2048
|
||||
|
||||
### February 24, 2012
|
||||
* Original release
|
754
Sdk/External/DirectXTK/Inc/Audio.h
vendored
Normal file
754
Sdk/External/DirectXTK/Inc/Audio.h
vendored
Normal file
@ -0,0 +1,754 @@
|
||||
//--------------------------------------------------------------------------------------
|
||||
// File: Audio.h
|
||||
//
|
||||
// DirectXTK for Audio header
|
||||
//
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkId=248929
|
||||
// http://go.microsoft.com/fwlink/?LinkID=615561
|
||||
//--------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <objbase.h>
|
||||
#include <mmreg.h>
|
||||
#include <Audioclient.h>
|
||||
|
||||
#if (defined(_XBOX_ONE) && defined(_TITLE)) || defined(_GAMING_XBOX)
|
||||
#include <xma2defs.h>
|
||||
#pragma comment(lib,"acphal.lib")
|
||||
#endif
|
||||
|
||||
#ifndef XAUDIO2_HELPER_FUNCTIONS
|
||||
#define XAUDIO2_HELPER_FUNCTIONS
|
||||
#endif
|
||||
|
||||
#if defined(USING_XAUDIO2_REDIST) || (_WIN32_WINNT >= 0x0A00 /*_WIN32_WINNT_WIN10*/) || defined(_XBOX_ONE)
|
||||
#define USING_XAUDIO2_9
|
||||
#elif (_WIN32_WINNT >= 0x0602 /*_WIN32_WINNT_WIN8*/)
|
||||
#define USING_XAUDIO2_8
|
||||
#elif (_WIN32_WINNT >= 0x0601 /*_WIN32_WINNT_WIN7*/)
|
||||
#error Windows 7 SP1 requires the XAudio2Redist NuGet package https://aka.ms/xaudio2redist
|
||||
#else
|
||||
#error DirectX Tool Kit for Audio not supported on this platform
|
||||
#endif
|
||||
|
||||
#include <xaudio2.h>
|
||||
#include <xaudio2fx.h>
|
||||
#include <x3daudio.h>
|
||||
#include <xapofx.h>
|
||||
|
||||
#ifndef USING_XAUDIO2_REDIST
|
||||
#if defined(USING_XAUDIO2_8) && defined(NTDDI_WIN10) && !defined(_M_IX86)
|
||||
// The xaudio2_8.lib in the Windows 10 SDK for x86 is incorrectly annotated as __cdecl instead of __stdcall, so avoid using it in this case.
|
||||
#pragma comment(lib,"xaudio2_8.lib")
|
||||
#else
|
||||
#pragma comment(lib,"xaudio2.lib")
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#include <DirectXMath.h>
|
||||
|
||||
|
||||
#include <cstdint>
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
class SoundEffectInstance;
|
||||
class SoundStreamInstance;
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
struct AudioStatistics
|
||||
{
|
||||
size_t playingOneShots; // Number of one-shot sounds currently playing
|
||||
size_t playingInstances; // Number of sound effect instances currently playing
|
||||
size_t allocatedInstances; // Number of SoundEffectInstance allocated
|
||||
size_t allocatedVoices; // Number of XAudio2 voices allocated (standard, 3D, one-shots, and idle one-shots)
|
||||
size_t allocatedVoices3d; // Number of XAudio2 voices allocated for 3D
|
||||
size_t allocatedVoicesOneShot; // Number of XAudio2 voices allocated for one-shot sounds
|
||||
size_t allocatedVoicesIdle; // Number of XAudio2 voices allocated for one-shot sounds but not currently in use
|
||||
size_t audioBytes; // Total wave data (in bytes) in SoundEffects and in-memory WaveBanks
|
||||
#if (defined(_XBOX_ONE) && defined(_TITLE)) || defined(_GAMING_XBOX)
|
||||
size_t xmaAudioBytes; // Total wave data (in bytes) in SoundEffects and in-memory WaveBanks allocated with ApuAlloc
|
||||
#endif
|
||||
size_t streamingBytes; // Total size of streaming buffers (in bytes) in streaming WaveBanks
|
||||
};
|
||||
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
class IVoiceNotify
|
||||
{
|
||||
public:
|
||||
virtual ~IVoiceNotify() = default;
|
||||
|
||||
IVoiceNotify(const IVoiceNotify&) = delete;
|
||||
IVoiceNotify& operator=(const IVoiceNotify&) = delete;
|
||||
|
||||
IVoiceNotify(IVoiceNotify&&) = default;
|
||||
IVoiceNotify& operator=(IVoiceNotify&&) = default;
|
||||
|
||||
virtual void __cdecl OnBufferEnd() = 0;
|
||||
// Notfication that a voice buffer has finished
|
||||
// Note this is called from XAudio2's worker thread, so it should perform very minimal and thread-safe operations
|
||||
|
||||
virtual void __cdecl OnCriticalError() = 0;
|
||||
// Notification that the audio engine encountered a critical error
|
||||
|
||||
virtual void __cdecl OnReset() = 0;
|
||||
// Notification of an audio engine reset
|
||||
|
||||
virtual void __cdecl OnUpdate() = 0;
|
||||
// Notification of an audio engine per-frame update (opt-in)
|
||||
|
||||
virtual void __cdecl OnDestroyEngine() noexcept = 0;
|
||||
// Notification that the audio engine is being destroyed
|
||||
|
||||
virtual void __cdecl OnTrim() = 0;
|
||||
// Notification of a request to trim the voice pool
|
||||
|
||||
virtual void __cdecl GatherStatistics(AudioStatistics& stats) const = 0;
|
||||
// Contribute to statistics request
|
||||
|
||||
virtual void __cdecl OnDestroyParent() noexcept = 0;
|
||||
// Optional notification used by some objects
|
||||
|
||||
protected:
|
||||
IVoiceNotify() = default;
|
||||
};
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
enum AUDIO_ENGINE_FLAGS : uint32_t
|
||||
{
|
||||
AudioEngine_Default = 0x0,
|
||||
|
||||
AudioEngine_EnvironmentalReverb = 0x1,
|
||||
AudioEngine_ReverbUseFilters = 0x2,
|
||||
AudioEngine_UseMasteringLimiter = 0x4,
|
||||
|
||||
AudioEngine_Debug = 0x10000,
|
||||
AudioEngine_ThrowOnNoAudioHW = 0x20000,
|
||||
AudioEngine_DisableVoiceReuse = 0x40000,
|
||||
};
|
||||
|
||||
enum SOUND_EFFECT_INSTANCE_FLAGS : uint32_t
|
||||
{
|
||||
SoundEffectInstance_Default = 0x0,
|
||||
|
||||
SoundEffectInstance_Use3D = 0x1,
|
||||
SoundEffectInstance_ReverbUseFilters = 0x2,
|
||||
SoundEffectInstance_NoSetPitch = 0x4,
|
||||
|
||||
SoundEffectInstance_UseRedirectLFE = 0x10000,
|
||||
};
|
||||
|
||||
enum AUDIO_ENGINE_REVERB : unsigned int
|
||||
{
|
||||
Reverb_Off,
|
||||
Reverb_Default,
|
||||
Reverb_Generic,
|
||||
Reverb_Forest,
|
||||
Reverb_PaddedCell,
|
||||
Reverb_Room,
|
||||
Reverb_Bathroom,
|
||||
Reverb_LivingRoom,
|
||||
Reverb_StoneRoom,
|
||||
Reverb_Auditorium,
|
||||
Reverb_ConcertHall,
|
||||
Reverb_Cave,
|
||||
Reverb_Arena,
|
||||
Reverb_Hangar,
|
||||
Reverb_CarpetedHallway,
|
||||
Reverb_Hallway,
|
||||
Reverb_StoneCorridor,
|
||||
Reverb_Alley,
|
||||
Reverb_City,
|
||||
Reverb_Mountains,
|
||||
Reverb_Quarry,
|
||||
Reverb_Plain,
|
||||
Reverb_ParkingLot,
|
||||
Reverb_SewerPipe,
|
||||
Reverb_Underwater,
|
||||
Reverb_SmallRoom,
|
||||
Reverb_MediumRoom,
|
||||
Reverb_LargeRoom,
|
||||
Reverb_MediumHall,
|
||||
Reverb_LargeHall,
|
||||
Reverb_Plate,
|
||||
Reverb_MAX
|
||||
};
|
||||
|
||||
enum SoundState
|
||||
{
|
||||
STOPPED = 0,
|
||||
PLAYING,
|
||||
PAUSED
|
||||
};
|
||||
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
class AudioEngine
|
||||
{
|
||||
public:
|
||||
explicit AudioEngine(
|
||||
AUDIO_ENGINE_FLAGS flags = AudioEngine_Default,
|
||||
_In_opt_ const WAVEFORMATEX* wfx = nullptr,
|
||||
_In_opt_z_ const wchar_t* deviceId = nullptr,
|
||||
AUDIO_STREAM_CATEGORY category = AudioCategory_GameEffects) noexcept(false);
|
||||
|
||||
AudioEngine(AudioEngine&& moveFrom) noexcept;
|
||||
AudioEngine& operator= (AudioEngine&& moveFrom) noexcept;
|
||||
|
||||
AudioEngine(AudioEngine const&) = delete;
|
||||
AudioEngine& operator= (AudioEngine const&) = delete;
|
||||
|
||||
virtual ~AudioEngine();
|
||||
|
||||
bool __cdecl Update();
|
||||
// Performs per-frame processing for the audio engine, returns false if in 'silent mode'
|
||||
|
||||
bool __cdecl Reset(_In_opt_ const WAVEFORMATEX* wfx = nullptr, _In_opt_z_ const wchar_t* deviceId = nullptr);
|
||||
// Reset audio engine from critical error/silent mode using a new device; can also 'migrate' the graph
|
||||
// Returns true if succesfully reset, false if in 'silent mode' due to no default device
|
||||
// Note: One shots are lost, all SoundEffectInstances are in the STOPPED state after successful reset
|
||||
|
||||
void __cdecl Suspend() noexcept;
|
||||
void __cdecl Resume();
|
||||
// Suspend/resumes audio processing (i.e. global pause/resume)
|
||||
|
||||
float __cdecl GetMasterVolume() const noexcept;
|
||||
void __cdecl SetMasterVolume(float volume);
|
||||
// Master volume property for all sounds
|
||||
|
||||
void __cdecl SetReverb(AUDIO_ENGINE_REVERB reverb);
|
||||
void __cdecl SetReverb(_In_opt_ const XAUDIO2FX_REVERB_PARAMETERS* native);
|
||||
// Sets environmental reverb for 3D positional audio (if active)
|
||||
|
||||
void __cdecl SetMasteringLimit(int release, int loudness);
|
||||
// Sets the mastering volume limiter properties (if active)
|
||||
|
||||
AudioStatistics __cdecl GetStatistics() const;
|
||||
// Gathers audio engine statistics
|
||||
|
||||
WAVEFORMATEXTENSIBLE __cdecl GetOutputFormat() const noexcept;
|
||||
// Returns the format consumed by the mastering voice (which is the same as the device output if defaults are used)
|
||||
|
||||
uint32_t __cdecl GetChannelMask() const noexcept;
|
||||
// Returns the output channel mask
|
||||
|
||||
unsigned int __cdecl GetOutputChannels() const noexcept;
|
||||
// Returns the number of output channels
|
||||
|
||||
bool __cdecl IsAudioDevicePresent() const noexcept;
|
||||
// Returns true if the audio graph is operating normally, false if in 'silent mode'
|
||||
|
||||
bool __cdecl IsCriticalError() const noexcept;
|
||||
// Returns true if the audio graph is halted due to a critical error (which also places the engine into 'silent mode')
|
||||
|
||||
// Voice pool management.
|
||||
void __cdecl SetDefaultSampleRate(int sampleRate);
|
||||
// Sample rate for voices in the reuse pool (defaults to 44100)
|
||||
|
||||
void __cdecl SetMaxVoicePool(size_t maxOneShots, size_t maxInstances);
|
||||
// Maximum number of voices to allocate for one-shots and instances
|
||||
// Note: one-shots over this limit are ignored; too many instance voices throws an exception
|
||||
|
||||
void __cdecl TrimVoicePool();
|
||||
// Releases any currently unused voices
|
||||
|
||||
// Internal-use functions
|
||||
void __cdecl AllocateVoice(_In_ const WAVEFORMATEX* wfx,
|
||||
SOUND_EFFECT_INSTANCE_FLAGS flags, bool oneshot, _Outptr_result_maybenull_ IXAudio2SourceVoice** voice);
|
||||
|
||||
void __cdecl DestroyVoice(_In_ IXAudio2SourceVoice* voice) noexcept;
|
||||
// Should only be called for instance voices, not one-shots
|
||||
|
||||
void __cdecl RegisterNotify(_In_ IVoiceNotify* notify, bool usesUpdate);
|
||||
void __cdecl UnregisterNotify(_In_ IVoiceNotify* notify, bool usesOneShots, bool usesUpdate);
|
||||
|
||||
// XAudio2 interface access
|
||||
IXAudio2* __cdecl GetInterface() const noexcept;
|
||||
IXAudio2MasteringVoice* __cdecl GetMasterVoice() const noexcept;
|
||||
IXAudio2SubmixVoice* __cdecl GetReverbVoice() const noexcept;
|
||||
X3DAUDIO_HANDLE& __cdecl Get3DHandle() const noexcept;
|
||||
|
||||
// Static functions
|
||||
struct RendererDetail
|
||||
{
|
||||
std::wstring deviceId;
|
||||
std::wstring description;
|
||||
};
|
||||
|
||||
static std::vector<RendererDetail> __cdecl GetRendererDetails();
|
||||
// Returns a list of valid audio endpoint devices
|
||||
|
||||
private:
|
||||
// Private implementation.
|
||||
class Impl;
|
||||
std::unique_ptr<Impl> pImpl;
|
||||
};
|
||||
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
class WaveBank
|
||||
{
|
||||
public:
|
||||
WaveBank(_In_ AudioEngine* engine, _In_z_ const wchar_t* wbFileName);
|
||||
|
||||
WaveBank(WaveBank&& moveFrom) noexcept;
|
||||
WaveBank& operator= (WaveBank&& moveFrom) noexcept;
|
||||
|
||||
WaveBank(WaveBank const&) = delete;
|
||||
WaveBank& operator= (WaveBank const&) = delete;
|
||||
|
||||
virtual ~WaveBank();
|
||||
|
||||
void __cdecl Play(unsigned int index);
|
||||
void __cdecl Play(unsigned int index, float volume, float pitch, float pan);
|
||||
|
||||
void __cdecl Play(_In_z_ const char* name);
|
||||
void __cdecl Play(_In_z_ const char* name, float volume, float pitch, float pan);
|
||||
|
||||
std::unique_ptr<SoundEffectInstance> __cdecl CreateInstance(unsigned int index,
|
||||
SOUND_EFFECT_INSTANCE_FLAGS flags = SoundEffectInstance_Default);
|
||||
std::unique_ptr<SoundEffectInstance> __cdecl CreateInstance(_In_z_ const char* name,
|
||||
SOUND_EFFECT_INSTANCE_FLAGS flags = SoundEffectInstance_Default);
|
||||
|
||||
std::unique_ptr<SoundStreamInstance> __cdecl CreateStreamInstance(unsigned int index,
|
||||
SOUND_EFFECT_INSTANCE_FLAGS flags = SoundEffectInstance_Default);
|
||||
std::unique_ptr<SoundStreamInstance> __cdecl CreateStreamInstance(_In_z_ const char* name,
|
||||
SOUND_EFFECT_INSTANCE_FLAGS flags = SoundEffectInstance_Default);
|
||||
|
||||
bool __cdecl IsPrepared() const noexcept;
|
||||
bool __cdecl IsInUse() const noexcept;
|
||||
bool __cdecl IsStreamingBank() const noexcept;
|
||||
|
||||
size_t __cdecl GetSampleSizeInBytes(unsigned int index) const noexcept;
|
||||
// Returns size of wave audio data
|
||||
|
||||
size_t __cdecl GetSampleDuration(unsigned int index) const noexcept;
|
||||
// Returns the duration in samples
|
||||
|
||||
size_t __cdecl GetSampleDurationMS(unsigned int index) const noexcept;
|
||||
// Returns the duration in milliseconds
|
||||
|
||||
const WAVEFORMATEX* __cdecl GetFormat(unsigned int index, _Out_writes_bytes_(maxsize) WAVEFORMATEX* wfx, size_t maxsize) const noexcept;
|
||||
|
||||
int __cdecl Find(_In_z_ const char* name) const;
|
||||
|
||||
#ifdef USING_XAUDIO2_9
|
||||
bool __cdecl FillSubmitBuffer(unsigned int index, _Out_ XAUDIO2_BUFFER& buffer, _Out_ XAUDIO2_BUFFER_WMA& wmaBuffer) const;
|
||||
#else
|
||||
void __cdecl FillSubmitBuffer(unsigned int index, _Out_ XAUDIO2_BUFFER& buffer) const;
|
||||
#endif
|
||||
|
||||
void __cdecl UnregisterInstance(_In_ IVoiceNotify* instance);
|
||||
|
||||
HANDLE __cdecl GetAsyncHandle() const noexcept;
|
||||
|
||||
bool __cdecl GetPrivateData(unsigned int index, _Out_writes_bytes_(datasize) void* data, size_t datasize);
|
||||
|
||||
private:
|
||||
// Private implementation.
|
||||
class Impl;
|
||||
|
||||
std::unique_ptr<Impl> pImpl;
|
||||
};
|
||||
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
class SoundEffect
|
||||
{
|
||||
public:
|
||||
SoundEffect(_In_ AudioEngine* engine, _In_z_ const wchar_t* waveFileName);
|
||||
|
||||
SoundEffect(_In_ AudioEngine* engine, _Inout_ std::unique_ptr<uint8_t[]>& wavData,
|
||||
_In_ const WAVEFORMATEX* wfx, _In_reads_bytes_(audioBytes) const uint8_t* startAudio, size_t audioBytes);
|
||||
|
||||
SoundEffect(_In_ AudioEngine* engine, _Inout_ std::unique_ptr<uint8_t[]>& wavData,
|
||||
_In_ const WAVEFORMATEX* wfx, _In_reads_bytes_(audioBytes) const uint8_t* startAudio, size_t audioBytes,
|
||||
uint32_t loopStart, uint32_t loopLength);
|
||||
|
||||
#ifdef USING_XAUDIO2_9
|
||||
|
||||
SoundEffect(_In_ AudioEngine* engine, _Inout_ std::unique_ptr<uint8_t[]>& wavData,
|
||||
_In_ const WAVEFORMATEX* wfx, _In_reads_bytes_(audioBytes) const uint8_t* startAudio, size_t audioBytes,
|
||||
_In_reads_(seekCount) const uint32_t* seekTable, size_t seekCount);
|
||||
|
||||
#endif
|
||||
|
||||
SoundEffect(SoundEffect&& moveFrom) noexcept;
|
||||
SoundEffect& operator= (SoundEffect&& moveFrom) noexcept;
|
||||
|
||||
SoundEffect(SoundEffect const&) = delete;
|
||||
SoundEffect& operator= (SoundEffect const&) = delete;
|
||||
|
||||
virtual ~SoundEffect();
|
||||
|
||||
void __cdecl Play();
|
||||
void __cdecl Play(float volume, float pitch, float pan);
|
||||
|
||||
std::unique_ptr<SoundEffectInstance> __cdecl CreateInstance(SOUND_EFFECT_INSTANCE_FLAGS flags = SoundEffectInstance_Default);
|
||||
|
||||
bool __cdecl IsInUse() const noexcept;
|
||||
|
||||
size_t __cdecl GetSampleSizeInBytes() const noexcept;
|
||||
// Returns size of wave audio data
|
||||
|
||||
size_t __cdecl GetSampleDuration() const noexcept;
|
||||
// Returns the duration in samples
|
||||
|
||||
size_t __cdecl GetSampleDurationMS() const noexcept;
|
||||
// Returns the duration in milliseconds
|
||||
|
||||
const WAVEFORMATEX* __cdecl GetFormat() const noexcept;
|
||||
|
||||
#ifdef USING_XAUDIO2_9
|
||||
bool __cdecl FillSubmitBuffer(_Out_ XAUDIO2_BUFFER& buffer, _Out_ XAUDIO2_BUFFER_WMA& wmaBuffer) const;
|
||||
#else
|
||||
void __cdecl FillSubmitBuffer(_Out_ XAUDIO2_BUFFER& buffer) const;
|
||||
#endif
|
||||
|
||||
void __cdecl UnregisterInstance(_In_ IVoiceNotify* instance);
|
||||
|
||||
private:
|
||||
// Private implementation.
|
||||
class Impl;
|
||||
|
||||
std::unique_ptr<Impl> pImpl;
|
||||
};
|
||||
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
struct AudioListener : public X3DAUDIO_LISTENER
|
||||
{
|
||||
AudioListener() noexcept
|
||||
{
|
||||
memset(this, 0, sizeof(X3DAUDIO_LISTENER));
|
||||
|
||||
OrientFront.z = -1.f;
|
||||
|
||||
OrientTop.y = 1.f;
|
||||
}
|
||||
|
||||
void XM_CALLCONV SetPosition(FXMVECTOR v) noexcept
|
||||
{
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&Position), v);
|
||||
}
|
||||
void __cdecl SetPosition(const XMFLOAT3& pos) noexcept
|
||||
{
|
||||
Position.x = pos.x;
|
||||
Position.y = pos.y;
|
||||
Position.z = pos.z;
|
||||
}
|
||||
|
||||
void XM_CALLCONV SetVelocity(FXMVECTOR v) noexcept
|
||||
{
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&Velocity), v);
|
||||
}
|
||||
void __cdecl SetVelocity(const XMFLOAT3& vel) noexcept
|
||||
{
|
||||
Velocity.x = vel.x;
|
||||
Velocity.y = vel.y;
|
||||
Velocity.z = vel.z;
|
||||
}
|
||||
|
||||
void XM_CALLCONV SetOrientation(FXMVECTOR forward, FXMVECTOR up) noexcept
|
||||
{
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&OrientFront), forward);
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&OrientTop), up);
|
||||
}
|
||||
void __cdecl SetOrientation(const XMFLOAT3& forward, const XMFLOAT3& up) noexcept
|
||||
{
|
||||
OrientFront.x = forward.x; OrientTop.x = up.x;
|
||||
OrientFront.y = forward.y; OrientTop.y = up.y;
|
||||
OrientFront.z = forward.z; OrientTop.z = up.z;
|
||||
}
|
||||
|
||||
void XM_CALLCONV SetOrientationFromQuaternion(FXMVECTOR quat) noexcept
|
||||
{
|
||||
XMVECTOR forward = XMVector3Rotate(g_XMIdentityR2, quat);
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&OrientFront), forward);
|
||||
|
||||
XMVECTOR up = XMVector3Rotate(g_XMIdentityR1, quat);
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&OrientTop), up);
|
||||
}
|
||||
|
||||
void XM_CALLCONV Update(FXMVECTOR newPos, XMVECTOR upDir, float dt) noexcept
|
||||
// Updates velocity and orientation by tracking changes in position over time...
|
||||
{
|
||||
if (dt > 0.f)
|
||||
{
|
||||
XMVECTOR lastPos = XMLoadFloat3(reinterpret_cast<const XMFLOAT3*>(&Position));
|
||||
|
||||
XMVECTOR vDelta = XMVectorSubtract(newPos, lastPos);
|
||||
XMVECTOR vt = XMVectorReplicate(dt);
|
||||
XMVECTOR v = XMVectorDivide(vDelta, vt);
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&Velocity), v);
|
||||
|
||||
vDelta = XMVector3Normalize(vDelta);
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&OrientFront), vDelta);
|
||||
|
||||
v = XMVector3Cross(upDir, vDelta);
|
||||
v = XMVector3Normalize(v);
|
||||
|
||||
v = XMVector3Cross(vDelta, v);
|
||||
v = XMVector3Normalize(v);
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&OrientTop), v);
|
||||
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&Position), newPos);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
struct AudioEmitter : public X3DAUDIO_EMITTER
|
||||
{
|
||||
float EmitterAzimuths[XAUDIO2_MAX_AUDIO_CHANNELS];
|
||||
|
||||
AudioEmitter() noexcept :
|
||||
EmitterAzimuths{}
|
||||
{
|
||||
memset(this, 0, sizeof(X3DAUDIO_EMITTER));
|
||||
|
||||
OrientFront.z = -1.f;
|
||||
|
||||
OrientTop.y =
|
||||
ChannelRadius =
|
||||
CurveDistanceScaler =
|
||||
DopplerScaler = 1.f;
|
||||
|
||||
ChannelCount = 1;
|
||||
pChannelAzimuths = EmitterAzimuths;
|
||||
|
||||
InnerRadiusAngle = X3DAUDIO_PI / 4.0f;
|
||||
}
|
||||
|
||||
void XM_CALLCONV SetPosition(FXMVECTOR v) noexcept
|
||||
{
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&Position), v);
|
||||
}
|
||||
void __cdecl SetPosition(const XMFLOAT3& pos) noexcept
|
||||
{
|
||||
Position.x = pos.x;
|
||||
Position.y = pos.y;
|
||||
Position.z = pos.z;
|
||||
}
|
||||
|
||||
void XM_CALLCONV SetVelocity(FXMVECTOR v) noexcept
|
||||
{
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&Velocity), v);
|
||||
}
|
||||
void __cdecl SetVelocity(const XMFLOAT3& vel) noexcept
|
||||
{
|
||||
Velocity.x = vel.x;
|
||||
Velocity.y = vel.y;
|
||||
Velocity.z = vel.z;
|
||||
}
|
||||
|
||||
void XM_CALLCONV SetOrientation(FXMVECTOR forward, FXMVECTOR up) noexcept
|
||||
{
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&OrientFront), forward);
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&OrientTop), up);
|
||||
}
|
||||
void __cdecl SetOrientation(const XMFLOAT3& forward, const XMFLOAT3& up) noexcept
|
||||
{
|
||||
OrientFront.x = forward.x; OrientTop.x = up.x;
|
||||
OrientFront.y = forward.y; OrientTop.y = up.y;
|
||||
OrientFront.z = forward.z; OrientTop.z = up.z;
|
||||
}
|
||||
|
||||
void XM_CALLCONV SetOrientationFromQuaternion(FXMVECTOR quat) noexcept
|
||||
{
|
||||
XMVECTOR forward = XMVector3Rotate(g_XMIdentityR2, quat);
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&OrientFront), forward);
|
||||
|
||||
XMVECTOR up = XMVector3Rotate(g_XMIdentityR1, quat);
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&OrientTop), up);
|
||||
}
|
||||
|
||||
void XM_CALLCONV Update(FXMVECTOR newPos, XMVECTOR upDir, float dt) noexcept
|
||||
// Updates velocity and orientation by tracking changes in position over time...
|
||||
{
|
||||
if (dt > 0.f)
|
||||
{
|
||||
XMVECTOR lastPos = XMLoadFloat3(reinterpret_cast<const XMFLOAT3*>(&Position));
|
||||
|
||||
XMVECTOR vDelta = XMVectorSubtract(newPos, lastPos);
|
||||
XMVECTOR vt = XMVectorReplicate(dt);
|
||||
XMVECTOR v = XMVectorDivide(vDelta, vt);
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&Velocity), v);
|
||||
|
||||
vDelta = XMVector3Normalize(vDelta);
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&OrientFront), vDelta);
|
||||
|
||||
v = XMVector3Cross(upDir, vDelta);
|
||||
v = XMVector3Normalize(v);
|
||||
|
||||
v = XMVector3Cross(vDelta, v);
|
||||
v = XMVector3Normalize(v);
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&OrientTop), v);
|
||||
|
||||
XMStoreFloat3(reinterpret_cast<XMFLOAT3*>(&Position), newPos);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
class SoundEffectInstance
|
||||
{
|
||||
public:
|
||||
SoundEffectInstance(SoundEffectInstance&& moveFrom) noexcept;
|
||||
SoundEffectInstance& operator= (SoundEffectInstance&& moveFrom) noexcept;
|
||||
|
||||
SoundEffectInstance(SoundEffectInstance const&) = delete;
|
||||
SoundEffectInstance& operator= (SoundEffectInstance const&) = delete;
|
||||
|
||||
virtual ~SoundEffectInstance();
|
||||
|
||||
void __cdecl Play(bool loop = false);
|
||||
void __cdecl Stop(bool immediate = true) noexcept;
|
||||
void __cdecl Pause() noexcept;
|
||||
void __cdecl Resume();
|
||||
|
||||
void __cdecl SetVolume(float volume);
|
||||
void __cdecl SetPitch(float pitch);
|
||||
void __cdecl SetPan(float pan);
|
||||
|
||||
void __cdecl Apply3D(const AudioListener& listener, const AudioEmitter& emitter, bool rhcoords = true);
|
||||
|
||||
bool __cdecl IsLooped() const noexcept;
|
||||
|
||||
SoundState __cdecl GetState() noexcept;
|
||||
|
||||
IVoiceNotify* __cdecl GetVoiceNotify() const noexcept;
|
||||
|
||||
private:
|
||||
// Private implementation.
|
||||
class Impl;
|
||||
|
||||
std::unique_ptr<Impl> pImpl;
|
||||
|
||||
// Private constructors
|
||||
SoundEffectInstance(_In_ AudioEngine* engine, _In_ SoundEffect* effect, SOUND_EFFECT_INSTANCE_FLAGS flags);
|
||||
SoundEffectInstance(_In_ AudioEngine* engine, _In_ WaveBank* effect, unsigned int index, SOUND_EFFECT_INSTANCE_FLAGS flags);
|
||||
|
||||
friend std::unique_ptr<SoundEffectInstance> __cdecl SoundEffect::CreateInstance(SOUND_EFFECT_INSTANCE_FLAGS);
|
||||
friend std::unique_ptr<SoundEffectInstance> __cdecl WaveBank::CreateInstance(unsigned int, SOUND_EFFECT_INSTANCE_FLAGS);
|
||||
};
|
||||
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
class SoundStreamInstance
|
||||
{
|
||||
public:
|
||||
SoundStreamInstance(SoundStreamInstance&& moveFrom) noexcept;
|
||||
SoundStreamInstance& operator= (SoundStreamInstance&& moveFrom) noexcept;
|
||||
|
||||
SoundStreamInstance(SoundStreamInstance const&) = delete;
|
||||
SoundStreamInstance& operator= (SoundStreamInstance const&) = delete;
|
||||
|
||||
virtual ~SoundStreamInstance();
|
||||
|
||||
void __cdecl Play(bool loop = false);
|
||||
void __cdecl Stop(bool immediate = true) noexcept;
|
||||
void __cdecl Pause() noexcept;
|
||||
void __cdecl Resume();
|
||||
|
||||
void __cdecl SetVolume(float volume);
|
||||
void __cdecl SetPitch(float pitch);
|
||||
void __cdecl SetPan(float pan);
|
||||
|
||||
void __cdecl Apply3D(const AudioListener& listener, const AudioEmitter& emitter, bool rhcoords = true);
|
||||
|
||||
bool __cdecl IsLooped() const noexcept;
|
||||
|
||||
SoundState __cdecl GetState() noexcept;
|
||||
|
||||
IVoiceNotify* __cdecl GetVoiceNotify() const noexcept;
|
||||
|
||||
private:
|
||||
// Private implementation.
|
||||
class Impl;
|
||||
|
||||
std::unique_ptr<Impl> pImpl;
|
||||
|
||||
// Private constructors
|
||||
SoundStreamInstance(_In_ AudioEngine* engine, _In_ WaveBank* effect, unsigned int index, SOUND_EFFECT_INSTANCE_FLAGS flags);
|
||||
|
||||
friend std::unique_ptr<SoundStreamInstance> __cdecl WaveBank::CreateStreamInstance(unsigned int, SOUND_EFFECT_INSTANCE_FLAGS);
|
||||
};
|
||||
|
||||
|
||||
//----------------------------------------------------------------------------------
|
||||
class DynamicSoundEffectInstance
|
||||
{
|
||||
public:
|
||||
DynamicSoundEffectInstance(_In_ AudioEngine* engine,
|
||||
_In_opt_ std::function<void __cdecl(DynamicSoundEffectInstance*)> bufferNeeded,
|
||||
int sampleRate, int channels, int sampleBits = 16,
|
||||
SOUND_EFFECT_INSTANCE_FLAGS flags = SoundEffectInstance_Default);
|
||||
DynamicSoundEffectInstance(DynamicSoundEffectInstance&& moveFrom) noexcept;
|
||||
DynamicSoundEffectInstance& operator= (DynamicSoundEffectInstance&& moveFrom) noexcept;
|
||||
|
||||
DynamicSoundEffectInstance(DynamicSoundEffectInstance const&) = delete;
|
||||
DynamicSoundEffectInstance& operator= (DynamicSoundEffectInstance const&) = delete;
|
||||
|
||||
virtual ~DynamicSoundEffectInstance();
|
||||
|
||||
void __cdecl Play();
|
||||
void __cdecl Stop(bool immediate = true) noexcept;
|
||||
void __cdecl Pause() noexcept;
|
||||
void __cdecl Resume();
|
||||
|
||||
void __cdecl SetVolume(float volume);
|
||||
void __cdecl SetPitch(float pitch);
|
||||
void __cdecl SetPan(float pan);
|
||||
|
||||
void __cdecl Apply3D(const AudioListener& listener, const AudioEmitter& emitter, bool rhcoords = true);
|
||||
|
||||
void __cdecl SubmitBuffer(_In_reads_bytes_(audioBytes) const uint8_t* pAudioData, size_t audioBytes);
|
||||
void __cdecl SubmitBuffer(_In_reads_bytes_(audioBytes) const uint8_t* pAudioData, uint32_t offset, size_t audioBytes);
|
||||
|
||||
SoundState __cdecl GetState() noexcept;
|
||||
|
||||
size_t __cdecl GetSampleDuration(size_t bytes) const noexcept;
|
||||
// Returns duration in samples of a buffer of a given size
|
||||
|
||||
size_t __cdecl GetSampleDurationMS(size_t bytes) const noexcept;
|
||||
// Returns duration in milliseconds of a buffer of a given size
|
||||
|
||||
size_t __cdecl GetSampleSizeInBytes(uint64_t duration) const noexcept;
|
||||
// Returns size of a buffer for a duration given in milliseconds
|
||||
|
||||
int __cdecl GetPendingBufferCount() const noexcept;
|
||||
|
||||
const WAVEFORMATEX* __cdecl GetFormat() const noexcept;
|
||||
|
||||
private:
|
||||
// Private implementation.
|
||||
class Impl;
|
||||
|
||||
std::unique_ptr<Impl> pImpl;
|
||||
};
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wdeprecated-dynamic-exception-spec"
|
||||
#endif
|
||||
|
||||
DEFINE_ENUM_FLAG_OPERATORS(AUDIO_ENGINE_FLAGS);
|
||||
DEFINE_ENUM_FLAG_OPERATORS(SOUND_EFFECT_INSTANCE_FLAGS);
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user