diff --git a/DirectXTex/BC6HBC7.cpp b/DirectXTex/BC6HBC7.cpp
index b2e73b9..ea11c41 100644
--- a/DirectXTex/BC6HBC7.cpp
+++ b/DirectXTex/BC6HBC7.cpp
@@ -1084,7 +1084,7 @@ inline static void FillWithErrorColors( _Out_cap_c_(NUM_PIXELS_PER_BLOCK) HDRCol
{
for(size_t i = 0; i < NUM_PIXELS_PER_BLOCK; ++i)
{
-#ifdef DEBUG
+#ifdef _DEBUG
// Use Magenta in debug as a highly-visible error color
pOut[i] = HDRColorA(1.0f, 0.0f, 1.0f, 1.0f);
#else
@@ -1150,7 +1150,7 @@ void D3DX_BC6H::Decode(bool bSigned, HDRColorA* pOut) const
case BZ: aEndPts[1].B.b |= 1 << uint32_t(desc[uCurBit].m_uBit); break;
default:
{
-#ifdef DEBUG
+#ifdef _DEBUG
OutputDebugStringA( "BC6H: Invalid header bits encountered during decoding\n" );
#endif
FillWithErrorColors( pOut );
@@ -1194,7 +1194,7 @@ void D3DX_BC6H::Decode(bool bSigned, HDRColorA* pOut) const
size_t uNumBits = IsFixUpOffset(info.uPartitions, uShape, i) ? info.uIndexPrec-1 : info.uIndexPrec;
if ( uStartBit + uNumBits > 128 )
{
-#ifdef DEBUG
+#ifdef _DEBUG
OutputDebugStringA( "BC6H: Invalid block encountered during decoding\n" );
#endif
FillWithErrorColors( pOut );
@@ -1204,7 +1204,7 @@ void D3DX_BC6H::Decode(bool bSigned, HDRColorA* pOut) const
if ( uIndex >= ((info.uPartitions > 0) ? 8 : 16) )
{
-#ifdef DEBUG
+#ifdef _DEBUG
OutputDebugStringA( "BC6H: Invalid index encountered during decoding\n" );
#endif
FillWithErrorColors( pOut );
@@ -1239,7 +1239,7 @@ void D3DX_BC6H::Decode(bool bSigned, HDRColorA* pOut) const
}
else
{
-#ifdef DEBUG
+#ifdef _DEBUG
OutputDebugStringA( "BC6H: Invalid mode encountered during decoding\n" );
#endif
FillWithErrorColors( pOut );
@@ -1945,7 +1945,7 @@ void D3DX_BC7::Decode(HDRColorA* pOut) const
{
if ( uStartBit + RGBAPrec.r > 128 )
{
-#ifdef DEBUG
+#ifdef _DEBUG
OutputDebugStringA( "BC7: Invalid block encountered during decoding\n" );
#endif
FillWithErrorColors( pOut );
@@ -1960,7 +1960,7 @@ void D3DX_BC7::Decode(HDRColorA* pOut) const
{
if ( uStartBit + RGBAPrec.g > 128 )
{
-#ifdef DEBUG
+#ifdef _DEBUG
OutputDebugStringA( "BC7: Invalid block encountered during decoding\n" );
#endif
FillWithErrorColors( pOut );
@@ -1975,7 +1975,7 @@ void D3DX_BC7::Decode(HDRColorA* pOut) const
{
if ( uStartBit + RGBAPrec.b > 128 )
{
-#ifdef DEBUG
+#ifdef _DEBUG
OutputDebugStringA( "BC7: Invalid block encountered during decoding\n" );
#endif
FillWithErrorColors( pOut );
@@ -1990,7 +1990,7 @@ void D3DX_BC7::Decode(HDRColorA* pOut) const
{
if ( uStartBit + RGBAPrec.a > 128 )
{
-#ifdef DEBUG
+#ifdef _DEBUG
OutputDebugStringA( "BC7: Invalid block encountered during decoding\n" );
#endif
FillWithErrorColors( pOut );
@@ -2007,7 +2007,7 @@ void D3DX_BC7::Decode(HDRColorA* pOut) const
{
if ( uStartBit > 127 )
{
-#ifdef DEBUG
+#ifdef _DEBUG
OutputDebugStringA( "BC7: Invalid block encountered during decoding\n" );
#endif
FillWithErrorColors( pOut );
@@ -2045,7 +2045,7 @@ void D3DX_BC7::Decode(HDRColorA* pOut) const
size_t uNumBits = IsFixUpOffset(ms_aInfo[uMode].uPartitions, uShape, i) ? uIndexPrec - 1 : uIndexPrec;
if ( uStartBit + uNumBits > 128 )
{
-#ifdef DEBUG
+#ifdef _DEBUG
OutputDebugStringA( "BC7: Invalid block encountered during decoding\n" );
#endif
FillWithErrorColors( pOut );
@@ -2062,7 +2062,7 @@ void D3DX_BC7::Decode(HDRColorA* pOut) const
size_t uNumBits = i ? uIndexPrec2 : uIndexPrec2 - 1;
if ( uStartBit + uNumBits > 128 )
{
-#ifdef DEBUG
+#ifdef _DEBUG
OutputDebugStringA( "BC7: Invalid block encountered during decoding\n" );
#endif
FillWithErrorColors( pOut );
@@ -2104,7 +2104,7 @@ void D3DX_BC7::Decode(HDRColorA* pOut) const
}
else
{
-#ifdef DEBUG
+#ifdef _DEBUG
OutputDebugStringA( "BC7: Invalid mode encountered during decoding\n" );
#endif
FillWithErrorColors( pOut );
diff --git a/DirectXTex/DirectXTexConvert.cpp b/DirectXTex/DirectXTexConvert.cpp
index e9aadce..e722070 100644
--- a/DirectXTex/DirectXTexConvert.cpp
+++ b/DirectXTex/DirectXTexConvert.cpp
@@ -1818,7 +1818,7 @@ static int __cdecl _ConvertCompare( void *context, const void* ptr1, const void
DWORD _GetConvertFlags( DXGI_FORMAT format )
{
-#ifdef DEBUG
+#ifdef _DEBUG
// Ensure conversion table is in ascending order
assert( _countof(g_ConvertTable) > 0 );
DXGI_FORMAT lastvalue = g_ConvertTable[0].format;
@@ -1844,7 +1844,7 @@ void _ConvertScanline( XMVECTOR* pBuffer, size_t count, DXGI_FORMAT outFormat, D
if ( !pBuffer )
return;
-#ifdef DEBUG
+#ifdef _DEBUG
// Ensure conversion table is in ascending order
assert( _countof(g_ConvertTable) > 0 );
DXGI_FORMAT lastvalue = g_ConvertTable[0].format;
diff --git a/DirectXTex/DirectXTex_11_Desktop.vcxproj b/DirectXTex/DirectXTex_11_Desktop.vcxproj
index d3bd56b..90e2830 100644
--- a/DirectXTex/DirectXTex_11_Desktop.vcxproj
+++ b/DirectXTex/DirectXTex_11_Desktop.vcxproj
@@ -143,7 +143,7 @@
Sync
..\XNAMath;%(AdditionalIncludeDirectories)
%(AdditionalOptions)
- WIN32;_DEBUG;DEBUG;PROFILE;_WINDOWS;_LIB;D3DXFX_LARGEADDRESS_HANDLE;DXGI_1_2_FORMATS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions)
+ _UNICODE;UNICODE;WIN32;_DEBUG;_LIB;DXGI_1_2_FORMATS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions)
EditAndContinue
EnableFastChecks
Use
@@ -184,7 +184,7 @@
Sync
..\XNAMath;%(AdditionalIncludeDirectories)
%(AdditionalOptions)
- WIN32;_DEBUG;DEBUG;PROFILE;_WINDOWS;_LIB;D3DXFX_LARGEADDRESS_HANDLE;DXGI_1_2_FORMATS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions)
+ _UNICODE;UNICODE;WIN32;_DEBUG;_LIB;DXGI_1_2_FORMATS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions)
EnableFastChecks
Use
DirectXTexP.h
@@ -226,7 +226,7 @@
Sync
..\XNAMath;%(AdditionalIncludeDirectories)
%(AdditionalOptions)
- WIN32;NDEBUG;_WINDOWS;_LIB;D3DXFX_LARGEADDRESS_HANDLE;DXGI_1_2_FORMATS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions)
+ _UNICODE;UNICODE;WIN32;NDEBUG;_LIB;DXGI_1_2_FORMATS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions)
Use
DirectXTexP.h
@@ -268,7 +268,7 @@
Sync
..\XNAMath;%(AdditionalIncludeDirectories)
%(AdditionalOptions)
- WIN32;NDEBUG;_WINDOWS;_LIB;D3DXFX_LARGEADDRESS_HANDLE;DXGI_1_2_FORMATS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions)
+ _UNICODE;UNICODE;WIN32;NDEBUG;_LIB;DXGI_1_2_FORMATS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions)
Use
DirectXTexP.h
@@ -311,7 +311,7 @@
Sync
..\XNAMath;%(AdditionalIncludeDirectories)
%(AdditionalOptions)
- WIN32;NDEBUG;PROFILE;_WINDOWS;_LIB;D3DXFX_LARGEADDRESS_HANDLE;DXGI_1_2_FORMATS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions)
+ _UNICODE;UNICODE;WIN32;NDEBUG;PROFILE;_LIB;DXGI_1_2_FORMATS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions)
Use
DirectXTexP.h
@@ -353,7 +353,7 @@
Sync
..\XNAMath;%(AdditionalIncludeDirectories)
%(AdditionalOptions)
- WIN32;NDEBUG;PROFILE;_WINDOWS;_LIB;D3DXFX_LARGEADDRESS_HANDLE;DXGI_1_2_FORMATS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions)
+ _UNICODE;UNICODE;WIN32;NDEBUG;PROFILE;_LIB;DXGI_1_2_FORMATS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions)
Use
DirectXTexP.h
diff --git a/DirectXTex/DirectXTex_11_Metro.sln b/DirectXTex/DirectXTex_11_Metro.sln
new file mode 100644
index 0000000..659f67b
--- /dev/null
+++ b/DirectXTex/DirectXTex_11_Metro.sln
@@ -0,0 +1,40 @@
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio 2012
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectXTex", "DirectXTex_11_Metro.vcxproj", "{371B9FA9-4C90-4AC6-A123-ACED756D6C77}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|ARM = Debug|ARM
+ Debug|Win32 = Debug|Win32
+ Debug|x64 = Debug|x64
+ Profile|ARM = Profile|ARM
+ Profile|Win32 = Profile|Win32
+ Profile|x64 = Profile|x64
+ Release|ARM = Release|ARM
+ Release|Win32 = Release|Win32
+ Release|x64 = Release|x64
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Debug|ARM.ActiveCfg = Debug|ARM
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Debug|ARM.Build.0 = Debug|ARM
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Debug|Win32.ActiveCfg = Debug|Win32
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Debug|Win32.Build.0 = Debug|Win32
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Debug|x64.ActiveCfg = Debug|x64
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Debug|x64.Build.0 = Debug|x64
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Profile|ARM.ActiveCfg = Profile|ARM
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Profile|ARM.Build.0 = Profile|ARM
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Profile|Win32.ActiveCfg = Profile|Win32
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Profile|Win32.Build.0 = Profile|Win32
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Profile|x64.ActiveCfg = Profile|x64
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Profile|x64.Build.0 = Profile|x64
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Release|ARM.ActiveCfg = Release|ARM
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Release|ARM.Build.0 = Release|ARM
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Release|Win32.ActiveCfg = Release|Win32
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Release|Win32.Build.0 = Release|Win32
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Release|x64.ActiveCfg = Release|x64
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}.Release|x64.Build.0 = Release|x64
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+EndGlobal
diff --git a/DirectXTex/DirectXTex_11_Metro.vcxproj b/DirectXTex/DirectXTex_11_Metro.vcxproj
new file mode 100644
index 0000000..af6af25
--- /dev/null
+++ b/DirectXTex/DirectXTex_11_Metro.vcxproj
@@ -0,0 +1,604 @@
+
+
+
+
+ Debug
+ ARM
+
+
+ Debug
+ Win32
+
+
+ Debug
+ x64
+
+
+ Profile
+ ARM
+
+
+ Profile
+ Win32
+
+
+ Profile
+ x64
+
+
+ Release
+ ARM
+
+
+ Release
+ Win32
+
+
+ Release
+ x64
+
+
+
+ DirectXTex
+ {371B9FA9-4C90-4AC6-A123-ACED756D6C77}
+ DirectXTex
+ Win32Proj
+ $(VCTargetsPath11)
+ en-US
+ 11.0
+ true
+
+
+
+ StaticLibrary
+ Unicode
+ v110
+
+
+ StaticLibrary
+ Unicode
+ v110
+
+
+ StaticLibrary
+ Unicode
+ v110
+
+
+ StaticLibrary
+ true
+ Unicode
+ v110
+
+
+ StaticLibrary
+ true
+ Unicode
+ v110
+
+
+ StaticLibrary
+ true
+ Unicode
+ v110
+
+
+ StaticLibrary
+ true
+ Unicode
+ v110
+
+
+ StaticLibrary
+ true
+ Unicode
+ v110
+
+
+ StaticLibrary
+ true
+ Unicode
+ v110
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ true
+ true
+ $(ExecutablePath)
+ $(IncludePath)
+ $(LibraryPath)
+
+
+ true
+ true
+ $(ExecutablePath)
+ $(IncludePath)
+ $(LibraryPath)
+
+
+ true
+ true
+ $(ExecutablePath)
+ $(IncludePath)
+ $(LibraryPath)
+
+
+ false
+ true
+ $(ExecutablePath)
+ $(IncludePath)
+ $(LibraryPath)
+
+
+ false
+ true
+ $(ExecutablePath)
+ $(IncludePath)
+ $(LibraryPath)
+
+
+ false
+ true
+ $(ExecutablePath)
+ $(IncludePath)
+ $(LibraryPath)
+
+
+ false
+ true
+ $(ExecutablePath)
+ $(IncludePath)
+ $(LibraryPath)
+
+
+ false
+ true
+ $(ExecutablePath)
+ $(IncludePath)
+ $(LibraryPath)
+
+
+ false
+ true
+ $(ExecutablePath)
+ $(IncludePath)
+ $(LibraryPath)
+
+
+
+ Level4
+ Disabled
+ MultiThreadedDebugDLL
+ true
+ true
+ Fast
+ StreamingSIMDExtensions2
+ Sync
+ %(AdditionalOptions)
+ _UNICODE;UNICODE;_DEBUG;_LIB;DXGI_1_2_FORMATS;%(PreprocessorDefinitions)
+ EnableFastChecks
+ Use
+ DirectXTexP.h
+
+
+ %(AdditionalOptions)
+ %(AdditionalDependencies)
+ Windows
+ true
+ true
+ true
+ true
+ MachineX86
+ AsInvoker
+ %(DelayLoadDLLs)
+
+
+ false
+
+
+
+
+
+
+
+
+
+
+
+
+ Level4
+ Disabled
+ MultiThreadedDebugDLL
+ true
+ true
+ Fast
+ Sync
+ %(AdditionalOptions)
+ _UNICODE;UNICODE;_DEBUG;_LIB;DXGI_1_2_FORMATS;%(PreprocessorDefinitions)
+ EnableFastChecks
+ Use
+ DirectXTexP.h
+
+
+ %(AdditionalOptions)
+ %(AdditionalDependencies)
+ Windows
+ true
+ true
+ true
+ true
+ AsInvoker
+ %(DelayLoadDLLs)
+
+
+ false
+
+
+
+
+
+
+
+
+
+
+
+
+ Level4
+ Disabled
+ MultiThreadedDebugDLL
+ true
+ true
+ Fast
+ Sync
+ %(AdditionalOptions)
+ _UNICODE;UNICODE;_DEBUG;_LIB;DXGI_1_2_FORMATS;%(PreprocessorDefinitions)
+ EnableFastChecks
+ Use
+ DirectXTexP.h
+
+
+ %(AdditionalOptions)
+ %(AdditionalDependencies)
+ Windows
+ true
+ true
+ true
+ true
+ MachineX64
+ AsInvoker
+ %(DelayLoadDLLs)
+
+
+ false
+
+
+
+
+
+
+
+
+
+
+
+
+ Level4
+ MaxSpeed
+ MultiThreadedDLL
+ true
+ true
+ true
+ Fast
+ StreamingSIMDExtensions2
+ Sync
+ %(AdditionalOptions)
+ _UNICODE;UNICODE;NDEBUG;_LIB;DXGI_1_2_FORMATS;%(PreprocessorDefinitions)
+ Use
+ DirectXTexP.h
+
+
+ %(AdditionalOptions)
+ %(AdditionalDependencies)
+ true
+ Windows
+ true
+ true
+ true
+ true
+ true
+ MachineX86
+ AsInvoker
+ %(DelayLoadDLLs)
+
+
+ false
+
+
+
+
+
+
+
+
+
+
+
+
+ Level4
+ MaxSpeed
+ MultiThreadedDLL
+ true
+ true
+ true
+ Fast
+ Sync
+ %(AdditionalOptions)
+ _UNICODE;UNICODE;NDEBUG;_LIB;DXGI_1_2_FORMATS;%(PreprocessorDefinitions)
+ Use
+ DirectXTexP.h
+
+
+ %(AdditionalOptions)
+ %(AdditionalDependencies)
+ true
+ Windows
+ true
+ true
+ true
+ true
+ true
+ AsInvoker
+ %(DelayLoadDLLs)
+
+
+ false
+
+
+
+
+
+
+
+
+
+
+
+
+ Level4
+ MaxSpeed
+ MultiThreadedDLL
+ true
+ true
+ true
+ Fast
+ Sync
+ %(AdditionalOptions)
+ _UNICODE;UNICODE;NDEBUG;_LIB;DXGI_1_2_FORMATS;%(PreprocessorDefinitions)
+ Use
+ DirectXTexP.h
+
+
+ %(AdditionalOptions)
+ %(AdditionalDependencies)
+ true
+ Windows
+ true
+ true
+ true
+ true
+ true
+ MachineX64
+ AsInvoker
+ %(DelayLoadDLLs)
+
+
+ false
+
+
+
+
+
+
+
+
+
+
+
+
+ Level4
+ MaxSpeed
+ MultiThreadedDLL
+ true
+ true
+ true
+ Fast
+ StreamingSIMDExtensions2
+ Sync
+ %(AdditionalOptions)
+ _UNICODE;UNICODE;NDEBUG;PROFILE;_LIB;DXGI_1_2_FORMATS;%(PreprocessorDefinitions)
+ Use
+ DirectXTexP.h
+
+
+ %(AdditionalOptions)
+ %(AdditionalDependencies)
+ true
+ Windows
+ true
+ true
+ true
+ true
+ true
+ MachineX86
+ AsInvoker
+ %(DelayLoadDLLs)
+
+
+ false
+
+
+
+
+
+
+
+
+
+
+
+
+ Level4
+ MaxSpeed
+ MultiThreadedDLL
+ true
+ true
+ true
+ Fast
+ Sync
+ %(AdditionalOptions)
+ _UNICODE;UNICODE;NDEBUG;PROFILE;_LIB;DXGI_1_2_FORMATS;%(PreprocessorDefinitions)
+ Use
+ DirectXTexP.h
+
+
+ %(AdditionalOptions)
+ %(AdditionalDependencies)
+ true
+ Windows
+ true
+ true
+ true
+ true
+ true
+ AsInvoker
+ %(DelayLoadDLLs)
+
+
+ false
+
+
+
+
+
+
+
+
+
+
+
+
+ Level4
+ MaxSpeed
+ MultiThreadedDLL
+ true
+ true
+ true
+ Fast
+ Sync
+ %(AdditionalOptions)
+ _UNICODE;UNICODE;NDEBUG;PROFILE;_LIB;DXGI_1_2_FORMATS;%(PreprocessorDefinitions)
+ Use
+ DirectXTexP.h
+
+
+ %(AdditionalOptions)
+ %(AdditionalDependencies)
+ true
+ Windows
+ true
+ true
+ true
+ true
+ true
+ MachineX64
+ AsInvoker
+ %(DelayLoadDLLs)
+
+
+ false
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Create
+ Create
+ Create
+ Create
+ Create
+ Create
+ Create
+ Create
+ Create
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/DirectXTex/DirectXTex_11_Metro.vcxproj.filters b/DirectXTex/DirectXTex_11_Metro.vcxproj.filters
new file mode 100644
index 0000000..d528cc8
--- /dev/null
+++ b/DirectXTex/DirectXTex_11_Metro.vcxproj.filters
@@ -0,0 +1,37 @@
+
+
+
+
+{8e114980-c1a3-4ada-ad7c-83caadf5daeb}
+rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+