Begin work for a standard port
This commit is contained in:
parent
01823b7830
commit
b7cf02f6f9
2
.gitignore
vendored
2
.gitignore
vendored
@ -30,3 +30,5 @@ x64
|
||||
/Tests
|
||||
/wiki
|
||||
/out
|
||||
*.o
|
||||
/CMakeFiles/*
|
||||
|
339
CMakeCache.txt
Normal file
339
CMakeCache.txt
Normal file
@ -0,0 +1,339 @@
|
||||
# This is the CMakeCache file.
|
||||
# For build in directory: /run/media/reece/Misc/GameEngine/Master/Public/DirectXTex
|
||||
# It was generated by CMake: /usr/bin/cmake
|
||||
# You can edit this file to change values found and used by cmake.
|
||||
# If you do not want to change any of the values, simply exit the editor.
|
||||
# If you do want to change a value, simply edit, save, and exit the editor.
|
||||
# The syntax for the file is as follows:
|
||||
# KEY:TYPE=VALUE
|
||||
# KEY is the name of a variable in the cache.
|
||||
# TYPE is a hint to GUIs for the type of VALUE, DO NOT EDIT TYPE!.
|
||||
# VALUE is the current value for the KEY.
|
||||
|
||||
########################
|
||||
# EXTERNAL cache entries
|
||||
########################
|
||||
|
||||
//Build with OpenMP support
|
||||
BC_USE_OPENMP:BOOL=ON
|
||||
|
||||
//Build with DirectX11 Runtime support
|
||||
BUILD_DX11:BOOL=ON
|
||||
|
||||
//Build with DirectX12 Runtime support
|
||||
BUILD_DX12:BOOL=ON
|
||||
|
||||
//Path to a program.
|
||||
CMAKE_ADDR2LINE:FILEPATH=/usr/bin/addr2line
|
||||
|
||||
//Path to a program.
|
||||
CMAKE_AR:FILEPATH=/usr/bin/ar
|
||||
|
||||
//Choose the type of build, options are: None Debug Release RelWithDebInfo
|
||||
// MinSizeRel ...
|
||||
CMAKE_BUILD_TYPE:STRING=
|
||||
|
||||
//Enable/Disable color output during build.
|
||||
CMAKE_COLOR_MAKEFILE:BOOL=ON
|
||||
|
||||
//No help, variable specified on the command line.
|
||||
CMAKE_CXX_COMPILER:UNINITIALIZED=/usr/bin/clang++
|
||||
|
||||
//LLVM archiver
|
||||
CMAKE_CXX_COMPILER_AR:FILEPATH=CMAKE_CXX_COMPILER_AR-NOTFOUND
|
||||
|
||||
//Generate index for LLVM archive
|
||||
CMAKE_CXX_COMPILER_RANLIB:FILEPATH=CMAKE_CXX_COMPILER_RANLIB-NOTFOUND
|
||||
|
||||
//Flags used by the CXX compiler during all build types.
|
||||
CMAKE_CXX_FLAGS:STRING=
|
||||
|
||||
//Flags used by the CXX compiler during DEBUG builds.
|
||||
CMAKE_CXX_FLAGS_DEBUG:STRING=
|
||||
|
||||
//Flags used by the CXX compiler during MINSIZEREL builds.
|
||||
CMAKE_CXX_FLAGS_MINSIZEREL:STRING=
|
||||
|
||||
//Flags used by the CXX compiler during RELEASE builds.
|
||||
CMAKE_CXX_FLAGS_RELEASE:STRING=
|
||||
|
||||
//Flags used by the CXX compiler during RELWITHDEBINFO builds.
|
||||
CMAKE_CXX_FLAGS_RELWITHDEBINFO:STRING=
|
||||
|
||||
//No help, variable specified on the command line.
|
||||
CMAKE_C_COMPILER:UNINITIALIZED=/usr/bin/clang
|
||||
|
||||
//Path to a program.
|
||||
CMAKE_DLLTOOL:FILEPATH=CMAKE_DLLTOOL-NOTFOUND
|
||||
|
||||
//Flags used by the linker during all build types.
|
||||
CMAKE_EXE_LINKER_FLAGS:STRING=
|
||||
|
||||
//Flags used by the linker during DEBUG builds.
|
||||
CMAKE_EXE_LINKER_FLAGS_DEBUG:STRING=
|
||||
|
||||
//Flags used by the linker during MINSIZEREL builds.
|
||||
CMAKE_EXE_LINKER_FLAGS_MINSIZEREL:STRING=
|
||||
|
||||
//Flags used by the linker during RELEASE builds.
|
||||
CMAKE_EXE_LINKER_FLAGS_RELEASE:STRING=
|
||||
|
||||
//Flags used by the linker during RELWITHDEBINFO builds.
|
||||
CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO:STRING=
|
||||
|
||||
//Enable/Disable output of compile commands during generation.
|
||||
CMAKE_EXPORT_COMPILE_COMMANDS:BOOL=
|
||||
|
||||
//Install path prefix, prepended onto install directories.
|
||||
CMAKE_INSTALL_PREFIX:PATH=/usr/local
|
||||
|
||||
//Path to a program.
|
||||
CMAKE_LINKER:FILEPATH=/usr/bin/ld
|
||||
|
||||
//Path to a program.
|
||||
CMAKE_MAKE_PROGRAM:FILEPATH=/usr/bin/make
|
||||
|
||||
//Flags used by the linker during the creation of modules during
|
||||
// all build types.
|
||||
CMAKE_MODULE_LINKER_FLAGS:STRING=
|
||||
|
||||
//Flags used by the linker during the creation of modules during
|
||||
// DEBUG builds.
|
||||
CMAKE_MODULE_LINKER_FLAGS_DEBUG:STRING=
|
||||
|
||||
//Flags used by the linker during the creation of modules during
|
||||
// MINSIZEREL builds.
|
||||
CMAKE_MODULE_LINKER_FLAGS_MINSIZEREL:STRING=
|
||||
|
||||
//Flags used by the linker during the creation of modules during
|
||||
// RELEASE builds.
|
||||
CMAKE_MODULE_LINKER_FLAGS_RELEASE:STRING=
|
||||
|
||||
//Flags used by the linker during the creation of modules during
|
||||
// RELWITHDEBINFO builds.
|
||||
CMAKE_MODULE_LINKER_FLAGS_RELWITHDEBINFO:STRING=
|
||||
|
||||
//Path to a program.
|
||||
CMAKE_NM:FILEPATH=/usr/bin/nm
|
||||
|
||||
//Path to a program.
|
||||
CMAKE_OBJCOPY:FILEPATH=/usr/bin/objcopy
|
||||
|
||||
//Path to a program.
|
||||
CMAKE_OBJDUMP:FILEPATH=/usr/bin/objdump
|
||||
|
||||
//Value Computed by CMake
|
||||
CMAKE_PROJECT_DESCRIPTION:STATIC=
|
||||
|
||||
//Value Computed by CMake
|
||||
CMAKE_PROJECT_HOMEPAGE_URL:STATIC=
|
||||
|
||||
//Value Computed by CMake
|
||||
CMAKE_PROJECT_NAME:STATIC=DirectXTex
|
||||
|
||||
//Path to a program.
|
||||
CMAKE_RANLIB:FILEPATH=/usr/bin/ranlib
|
||||
|
||||
//Path to a program.
|
||||
CMAKE_READELF:FILEPATH=/usr/bin/readelf
|
||||
|
||||
//Flags used by the linker during the creation of shared libraries
|
||||
// during all build types.
|
||||
CMAKE_SHARED_LINKER_FLAGS:STRING=
|
||||
|
||||
//Flags used by the linker during the creation of shared libraries
|
||||
// during DEBUG builds.
|
||||
CMAKE_SHARED_LINKER_FLAGS_DEBUG:STRING=
|
||||
|
||||
//Flags used by the linker during the creation of shared libraries
|
||||
// during MINSIZEREL builds.
|
||||
CMAKE_SHARED_LINKER_FLAGS_MINSIZEREL:STRING=
|
||||
|
||||
//Flags used by the linker during the creation of shared libraries
|
||||
// during RELEASE builds.
|
||||
CMAKE_SHARED_LINKER_FLAGS_RELEASE:STRING=
|
||||
|
||||
//Flags used by the linker during the creation of shared libraries
|
||||
// during RELWITHDEBINFO builds.
|
||||
CMAKE_SHARED_LINKER_FLAGS_RELWITHDEBINFO:STRING=
|
||||
|
||||
//If set, runtime paths are not added when installing shared libraries,
|
||||
// but are added when building.
|
||||
CMAKE_SKIP_INSTALL_RPATH:BOOL=NO
|
||||
|
||||
//If set, runtime paths are not added when using shared libraries.
|
||||
CMAKE_SKIP_RPATH:BOOL=NO
|
||||
|
||||
//Flags used by the linker during the creation of static libraries
|
||||
// during all build types.
|
||||
CMAKE_STATIC_LINKER_FLAGS:STRING=
|
||||
|
||||
//Flags used by the linker during the creation of static libraries
|
||||
// during DEBUG builds.
|
||||
CMAKE_STATIC_LINKER_FLAGS_DEBUG:STRING=
|
||||
|
||||
//Flags used by the linker during the creation of static libraries
|
||||
// during MINSIZEREL builds.
|
||||
CMAKE_STATIC_LINKER_FLAGS_MINSIZEREL:STRING=
|
||||
|
||||
//Flags used by the linker during the creation of static libraries
|
||||
// during RELEASE builds.
|
||||
CMAKE_STATIC_LINKER_FLAGS_RELEASE:STRING=
|
||||
|
||||
//Flags used by the linker during the creation of static libraries
|
||||
// during RELWITHDEBINFO builds.
|
||||
CMAKE_STATIC_LINKER_FLAGS_RELWITHDEBINFO:STRING=
|
||||
|
||||
//Path to a program.
|
||||
CMAKE_STRIP:FILEPATH=/usr/bin/strip
|
||||
|
||||
//If this value is on, makefiles will be generated without the
|
||||
// .SILENT directive, and all commands will be echoed to the console
|
||||
// during the make. This is useful for debugging only. With Visual
|
||||
// Studio IDE projects all commands are done without /nologo.
|
||||
CMAKE_VERBOSE_MAKEFILE:BOOL=FALSE
|
||||
|
||||
//Value Computed by CMake
|
||||
DirectXTex_BINARY_DIR:STATIC=/run/media/reece/Misc/GameEngine/Master/Public/DirectXTex
|
||||
|
||||
//Value Computed by CMake
|
||||
DirectXTex_SOURCE_DIR:STATIC=/run/media/reece/Misc/GameEngine/Master/Public/DirectXTex
|
||||
|
||||
//Use Static Code Analysis on build
|
||||
ENABLE_CODE_ANALYSIS:BOOL=OFF
|
||||
|
||||
|
||||
########################
|
||||
# INTERNAL cache entries
|
||||
########################
|
||||
|
||||
//ADVANCED property for variable: CMAKE_ADDR2LINE
|
||||
CMAKE_ADDR2LINE-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_AR
|
||||
CMAKE_AR-ADVANCED:INTERNAL=1
|
||||
//This is the directory where this CMakeCache.txt was created
|
||||
CMAKE_CACHEFILE_DIR:INTERNAL=/run/media/reece/Misc/GameEngine/Master/Public/DirectXTex
|
||||
//Major version of cmake used to create the current loaded cache
|
||||
CMAKE_CACHE_MAJOR_VERSION:INTERNAL=3
|
||||
//Minor version of cmake used to create the current loaded cache
|
||||
CMAKE_CACHE_MINOR_VERSION:INTERNAL=18
|
||||
//Patch version of cmake used to create the current loaded cache
|
||||
CMAKE_CACHE_PATCH_VERSION:INTERNAL=2
|
||||
//ADVANCED property for variable: CMAKE_COLOR_MAKEFILE
|
||||
CMAKE_COLOR_MAKEFILE-ADVANCED:INTERNAL=1
|
||||
//Path to CMake executable.
|
||||
CMAKE_COMMAND:INTERNAL=/usr/bin/cmake
|
||||
//Path to cpack program executable.
|
||||
CMAKE_CPACK_COMMAND:INTERNAL=/usr/bin/cpack
|
||||
//Path to ctest program executable.
|
||||
CMAKE_CTEST_COMMAND:INTERNAL=/usr/bin/ctest
|
||||
//ADVANCED property for variable: CMAKE_CXX_COMPILER
|
||||
CMAKE_CXX_COMPILER-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_CXX_COMPILER_AR
|
||||
CMAKE_CXX_COMPILER_AR-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_CXX_COMPILER_RANLIB
|
||||
CMAKE_CXX_COMPILER_RANLIB-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_CXX_FLAGS
|
||||
CMAKE_CXX_FLAGS-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_CXX_FLAGS_DEBUG
|
||||
CMAKE_CXX_FLAGS_DEBUG-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_CXX_FLAGS_MINSIZEREL
|
||||
CMAKE_CXX_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_CXX_FLAGS_RELEASE
|
||||
CMAKE_CXX_FLAGS_RELEASE-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_CXX_FLAGS_RELWITHDEBINFO
|
||||
CMAKE_CXX_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_DLLTOOL
|
||||
CMAKE_DLLTOOL-ADVANCED:INTERNAL=1
|
||||
//Path to cache edit program executable.
|
||||
CMAKE_EDIT_COMMAND:INTERNAL=/usr/bin/ccmake
|
||||
//Executable file format
|
||||
CMAKE_EXECUTABLE_FORMAT:INTERNAL=Unknown
|
||||
//ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS
|
||||
CMAKE_EXE_LINKER_FLAGS-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS_DEBUG
|
||||
CMAKE_EXE_LINKER_FLAGS_DEBUG-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS_MINSIZEREL
|
||||
CMAKE_EXE_LINKER_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS_RELEASE
|
||||
CMAKE_EXE_LINKER_FLAGS_RELEASE-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO
|
||||
CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_EXPORT_COMPILE_COMMANDS
|
||||
CMAKE_EXPORT_COMPILE_COMMANDS-ADVANCED:INTERNAL=1
|
||||
//Name of external makefile project generator.
|
||||
CMAKE_EXTRA_GENERATOR:INTERNAL=
|
||||
//Name of generator.
|
||||
CMAKE_GENERATOR:INTERNAL=Unix Makefiles
|
||||
//Generator instance identifier.
|
||||
CMAKE_GENERATOR_INSTANCE:INTERNAL=
|
||||
//Name of generator platform.
|
||||
CMAKE_GENERATOR_PLATFORM:INTERNAL=
|
||||
//Name of generator toolset.
|
||||
CMAKE_GENERATOR_TOOLSET:INTERNAL=
|
||||
//Source directory with the top level CMakeLists.txt file for this
|
||||
// project
|
||||
CMAKE_HOME_DIRECTORY:INTERNAL=/run/media/reece/Misc/GameEngine/Master/Public/DirectXTex
|
||||
//Install .so files without execute permission.
|
||||
CMAKE_INSTALL_SO_NO_EXE:INTERNAL=0
|
||||
//ADVANCED property for variable: CMAKE_LINKER
|
||||
CMAKE_LINKER-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_MAKE_PROGRAM
|
||||
CMAKE_MAKE_PROGRAM-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS
|
||||
CMAKE_MODULE_LINKER_FLAGS-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS_DEBUG
|
||||
CMAKE_MODULE_LINKER_FLAGS_DEBUG-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS_MINSIZEREL
|
||||
CMAKE_MODULE_LINKER_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS_RELEASE
|
||||
CMAKE_MODULE_LINKER_FLAGS_RELEASE-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS_RELWITHDEBINFO
|
||||
CMAKE_MODULE_LINKER_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_NM
|
||||
CMAKE_NM-ADVANCED:INTERNAL=1
|
||||
//number of local generators
|
||||
CMAKE_NUMBER_OF_MAKEFILES:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_OBJCOPY
|
||||
CMAKE_OBJCOPY-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_OBJDUMP
|
||||
CMAKE_OBJDUMP-ADVANCED:INTERNAL=1
|
||||
//Platform information initialized
|
||||
CMAKE_PLATFORM_INFO_INITIALIZED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_RANLIB
|
||||
CMAKE_RANLIB-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_READELF
|
||||
CMAKE_READELF-ADVANCED:INTERNAL=1
|
||||
//Path to CMake installation.
|
||||
CMAKE_ROOT:INTERNAL=/usr/share/cmake-3.18
|
||||
//ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS
|
||||
CMAKE_SHARED_LINKER_FLAGS-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS_DEBUG
|
||||
CMAKE_SHARED_LINKER_FLAGS_DEBUG-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS_MINSIZEREL
|
||||
CMAKE_SHARED_LINKER_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS_RELEASE
|
||||
CMAKE_SHARED_LINKER_FLAGS_RELEASE-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS_RELWITHDEBINFO
|
||||
CMAKE_SHARED_LINKER_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_SKIP_INSTALL_RPATH
|
||||
CMAKE_SKIP_INSTALL_RPATH-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_SKIP_RPATH
|
||||
CMAKE_SKIP_RPATH-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS
|
||||
CMAKE_STATIC_LINKER_FLAGS-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS_DEBUG
|
||||
CMAKE_STATIC_LINKER_FLAGS_DEBUG-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS_MINSIZEREL
|
||||
CMAKE_STATIC_LINKER_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS_RELEASE
|
||||
CMAKE_STATIC_LINKER_FLAGS_RELEASE-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS_RELWITHDEBINFO
|
||||
CMAKE_STATIC_LINKER_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
|
||||
//ADVANCED property for variable: CMAKE_STRIP
|
||||
CMAKE_STRIP-ADVANCED:INTERNAL=1
|
||||
//uname command
|
||||
CMAKE_UNAME:INTERNAL=/usr/bin/uname
|
||||
//ADVANCED property for variable: CMAKE_VERBOSE_MAKEFILE
|
||||
CMAKE_VERBOSE_MAKEFILE-ADVANCED:INTERNAL=1
|
||||
|
@ -20,14 +20,22 @@ option(BC_USE_OPENMP "Build with OpenMP support" ON)
|
||||
|
||||
option(ENABLE_CODE_ANALYSIS "Use Static Code Analysis on build" OFF)
|
||||
|
||||
set(CMAKE_CXX_STANDARD 14)
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||
set(CMAKE_CXX_EXTENSIONS OFF)
|
||||
|
||||
set(CMAKE_CXX_FLAGS "-fpermissive")
|
||||
|
||||
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")
|
||||
|
||||
if (WIN32)
|
||||
set (PLATFORM_FLAGS )
|
||||
else()
|
||||
set (PLATFORM_FLAGS _DXTX_NOWIN)
|
||||
endif()
|
||||
|
||||
set(LIBRARY_SOURCES
|
||||
DirectXTex/BC.h
|
||||
DirectXTex/BCDirectCompute.h
|
||||
@ -37,12 +45,11 @@ set(LIBRARY_SOURCES
|
||||
DirectXTex/DirectXTexP.h
|
||||
DirectXTex/filters.h
|
||||
DirectXTex/scoped.h
|
||||
|
||||
DirectXTex/BC.cpp
|
||||
DirectXTex/BC4BC5.cpp
|
||||
DirectXTex/BC6HBC7.cpp
|
||||
DirectXTex/BCDirectCompute.cpp
|
||||
DirectXTex/DirectXTexCompress.cpp
|
||||
DirectXTex/DirectXTexCompressGPU.cpp
|
||||
|
||||
DirectXTex/DirectXTexConvert.cpp
|
||||
DirectXTex/DirectXTexDDS.cpp
|
||||
DirectXTex/DirectXTexFlipRotate.cpp
|
||||
@ -54,12 +61,14 @@ set(LIBRARY_SOURCES
|
||||
DirectXTex/DirectXTexPMAlpha.cpp
|
||||
DirectXTex/DirectXTexResize.cpp
|
||||
DirectXTex/DirectXTexTGA.cpp
|
||||
DirectXTex/DirectXTexUtil.cpp
|
||||
DirectXTex/DirectXTexWIC.cpp)
|
||||
DirectXTex/DirectXTexUtil.cpp)
|
||||
|
||||
if (WIN32)
|
||||
set(LIBRARY_SOURCES ${LIBRARY_SOURCES} DirectXTex/DirectXTexCompressGPU.cpp)
|
||||
set(LIBRARY_SOURCES ${LIBRARY_SOURCES} DirectXTex/BCDirectCompute.cpp)
|
||||
set(LIBRARY_SOURCES ${LIBRARY_SOURCES} DirectXTex/DirectXTexWIC.cpp)
|
||||
endif()
|
||||
|
||||
set(SHADER_SOURCES
|
||||
DirectXTex/Shaders/BC6HEncode.hlsl
|
||||
DirectXTex/Shaders/BC7Encode.hlsl)
|
||||
|
||||
if(BUILD_DX11)
|
||||
set(LIBRARY_SOURCES ${LIBRARY_SOURCES} DirectXTex/DirectXTexD3D11.cpp)
|
||||
@ -68,6 +77,11 @@ if(BUILD_DX12)
|
||||
set(LIBRARY_SOURCES ${LIBRARY_SOURCES} DirectXTex/DirectXTexD3D12.cpp)
|
||||
endif()
|
||||
|
||||
set(SHADER_SOURCES
|
||||
DirectXTex/Shaders/BC6HEncode.hlsl
|
||||
DirectXTex/Shaders/BC7Encode.hlsl)
|
||||
|
||||
if (WIN32)
|
||||
add_library(${PROJECT_NAME} STATIC ${LIBRARY_SOURCES} DirectXTex/Shaders/Compiled/BC6HEncode_EncodeBlockCS.inc)
|
||||
|
||||
add_custom_command(
|
||||
@ -79,9 +93,18 @@ add_custom_command(
|
||||
WORKING_DIRECTORY "${PROJECT_SOURCE_DIR}/DirectXTex/Shaders"
|
||||
USES_TERMINAL)
|
||||
|
||||
else()
|
||||
|
||||
add_library(${PROJECT_NAME} STATIC ${LIBRARY_SOURCES})
|
||||
|
||||
endif()
|
||||
|
||||
|
||||
source_group(${PROJECT_NAME} REGULAR_EXPRESSION DirectXTex/*.*)
|
||||
|
||||
target_include_directories(${PROJECT_NAME} PUBLIC DirectXTex)
|
||||
target_include_directories(${PROJECT_NAME} PUBLIC DirectXMath)
|
||||
target_include_directories(${PROJECT_NAME} PUBLIC PlatformSupport)
|
||||
|
||||
if (${CMAKE_VERSION} VERSION_GREATER_EQUAL "3.16")
|
||||
target_precompile_headers(${PROJECT_NAME} PRIVATE DirectXTex/DirectXTexP.h)
|
||||
@ -130,9 +153,11 @@ if(MSVC)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# TODO FIX ME
|
||||
if ( CMAKE_CXX_COMPILER_ID MATCHES "Clang" )
|
||||
set(WarningsLib "-Wpedantic" "-Wextra")
|
||||
target_compile_options(${PROJECT_NAME} PRIVATE ${WarningsLib})
|
||||
target_compile_options(${PROJECT_NAME} PRIVATE "-fdeclspec")
|
||||
|
||||
# OpenMP is not supported for clang for Windows by default
|
||||
|
||||
@ -173,6 +198,7 @@ if ( CMAKE_CXX_COMPILER_ID MATCHES "MSVC" )
|
||||
target_compile_options(texdiag PRIVATE ${WarningsEXE})
|
||||
endif()
|
||||
|
||||
target_compile_definitions(${PROJECT_NAME} PRIVATE ${PLATFORM_FLAGS})
|
||||
if(WIN32)
|
||||
target_compile_definitions(${PROJECT_NAME} PRIVATE _UNICODE UNICODE)
|
||||
target_compile_definitions(texassemble PRIVATE _UNICODE UNICODE _WIN32_WINNT=0x0601)
|
||||
|
353
DirectXMath/DirectXCollision.h
Normal file
353
DirectXMath/DirectXCollision.h
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
DirectXMath/DirectXCollision.inl
Normal file
4816
DirectXMath/DirectXCollision.inl
Normal file
File diff suppressed because it is too large
Load Diff
165
DirectXMath/DirectXColors.h
Normal file
165
DirectXMath/DirectXColors.h
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
DirectXMath/DirectXMath.h
Normal file
2242
DirectXMath/DirectXMath.h
Normal file
File diff suppressed because it is too large
Load Diff
2187
DirectXMath/DirectXMathConvert.inl
Normal file
2187
DirectXMath/DirectXMathConvert.inl
Normal file
File diff suppressed because it is too large
Load Diff
3422
DirectXMath/DirectXMathMatrix.inl
Normal file
3422
DirectXMath/DirectXMathMatrix.inl
Normal file
File diff suppressed because it is too large
Load Diff
2452
DirectXMath/DirectXMathMisc.inl
Normal file
2452
DirectXMath/DirectXMathMisc.inl
Normal file
File diff suppressed because it is too large
Load Diff
14819
DirectXMath/DirectXMathVector.inl
Normal file
14819
DirectXMath/DirectXMathVector.inl
Normal file
File diff suppressed because it is too large
Load Diff
1216
DirectXMath/DirectXPackedVector.h
Normal file
1216
DirectXMath/DirectXPackedVector.h
Normal file
File diff suppressed because it is too large
Load Diff
4438
DirectXMath/DirectXPackedVector.inl
Normal file
4438
DirectXMath/DirectXPackedVector.inl
Normal file
File diff suppressed because it is too large
Load Diff
@ -412,7 +412,7 @@ namespace
|
||||
HDRColorA Error[NUM_PIXELS_PER_BLOCK];
|
||||
|
||||
if (flags & BC_FLAGS_DITHER_RGB)
|
||||
memset(Error, 0x00, NUM_PIXELS_PER_BLOCK * sizeof(HDRColorA));
|
||||
std::memset(Error, 0x00, NUM_PIXELS_PER_BLOCK * sizeof(HDRColorA));
|
||||
|
||||
size_t i;
|
||||
for (i = 0; i < NUM_PIXELS_PER_BLOCK; ++i)
|
||||
@ -598,7 +598,7 @@ namespace
|
||||
// Encode colors
|
||||
uint32_t dw = 0;
|
||||
if (flags & BC_FLAGS_DITHER_RGB)
|
||||
memset(Error, 0x00, NUM_PIXELS_PER_BLOCK * sizeof(HDRColorA));
|
||||
std::memset(Error, 0x00, NUM_PIXELS_PER_BLOCK * sizeof(HDRColorA));
|
||||
|
||||
for (i = 0; i < NUM_PIXELS_PER_BLOCK; ++i)
|
||||
{
|
||||
@ -1010,7 +1010,7 @@ void DirectX::D3DXEncodeBC3(uint8_t *pBC, const XMVECTOR *pColor, uint32_t flags
|
||||
EncodeSolidBC1(&pBC3->dxt1, Color);
|
||||
pBC3->alpha[0] = 0x00;
|
||||
pBC3->alpha[1] = 0x00;
|
||||
memset(pBC3->bitmap, 0x00, 6);
|
||||
std::memset(pBC3->bitmap, 0x00, 6);
|
||||
}
|
||||
#endif
|
||||
|
||||
@ -1022,7 +1022,7 @@ void DirectX::D3DXEncodeBC3(uint8_t *pBC, const XMVECTOR *pColor, uint32_t flags
|
||||
{
|
||||
pBC3->alpha[0] = 0xff;
|
||||
pBC3->alpha[1] = 0xff;
|
||||
memset(pBC3->bitmap, 0x00, 6);
|
||||
std::memset(pBC3->bitmap, 0x00, 6);
|
||||
return;
|
||||
}
|
||||
|
||||
@ -1043,7 +1043,7 @@ void DirectX::D3DXEncodeBC3(uint8_t *pBC, const XMVECTOR *pColor, uint32_t flags
|
||||
{
|
||||
pBC3->alpha[0] = bAlphaA;
|
||||
pBC3->alpha[1] = bAlphaB;
|
||||
memset(pBC3->bitmap, 0x00, 6);
|
||||
std::memset(pBC3->bitmap, 0x00, 6);
|
||||
return;
|
||||
}
|
||||
|
||||
@ -1088,7 +1088,7 @@ void DirectX::D3DXEncodeBC3(uint8_t *pBC, const XMVECTOR *pColor, uint32_t flags
|
||||
float fScale = (fStep[0] != fStep[1]) ? (fSteps / (fStep[1] - fStep[0])) : 0.0f;
|
||||
|
||||
if (flags & BC_FLAGS_DITHER_A)
|
||||
memset(fError, 0x00, NUM_PIXELS_PER_BLOCK * sizeof(float));
|
||||
std::memset(fError, 0x00, NUM_PIXELS_PER_BLOCK * sizeof(float));
|
||||
|
||||
for (size_t iSet = 0; iSet < 2; iSet++)
|
||||
{
|
||||
|
@ -8,14 +8,18 @@
|
||||
//
|
||||
// http://go.microsoft.com/fwlink/?LinkId=248926
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
#pragma once
|
||||
|
||||
// NOTE: we have already included these in the precompiled header.
|
||||
// including these here breaks ports when sal.h conflicts with libcxx stl and crt
|
||||
#if !defined(_DXTEX_PRIVATE)
|
||||
#include <algorithm>
|
||||
#include <cstdint>
|
||||
#include <functional>
|
||||
#include <vector>
|
||||
#endif
|
||||
|
||||
#if !defined(_DXTX_NOWIN)
|
||||
#if !defined(__d3d11_h__) && !defined(__d3d11_x_h__) && !defined(__d3d12_h__) && !defined(__d3d12_x_h__) && !defined(__XBOX_D3D12_X__)
|
||||
#ifdef _GAMING_XBOX_SCARLETT
|
||||
#include <d3d12_xs.h>
|
||||
@ -27,17 +31,19 @@
|
||||
#include <d3d11_1.h>
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#include <DirectXMath.h>
|
||||
|
||||
#if !defined(_DXTX_NOWIN)
|
||||
#include <OCIdl.h>
|
||||
#endif
|
||||
|
||||
#define DIRECTX_TEX_VERSION 190
|
||||
|
||||
struct IWICImagingFactory;
|
||||
struct IWICMetadataQueryReader;
|
||||
|
||||
|
||||
namespace DirectX
|
||||
{
|
||||
|
||||
@ -410,6 +416,8 @@ namespace DirectX
|
||||
HRESULT __cdecl SaveToTGAFile(_In_ const Image& image, _In_z_ const wchar_t* szFile, _In_opt_ const TexMetadata* metadata = nullptr) noexcept;
|
||||
|
||||
// WIC operations
|
||||
|
||||
#if !defined(_DXTX_NOWIN)
|
||||
HRESULT __cdecl LoadFromWICMemory(
|
||||
_In_reads_bytes_(size) const void* pSource, _In_ size_t size,
|
||||
_In_ WIC_FLAGS flags,
|
||||
@ -440,6 +448,7 @@ namespace DirectX
|
||||
_In_z_ const wchar_t* szFile, _In_opt_ const GUID* targetFormat = nullptr,
|
||||
_In_opt_ std::function<void __cdecl(IPropertyBag2*)> setCustomProps = nullptr);
|
||||
|
||||
#endif
|
||||
//---------------------------------------------------------------------------------
|
||||
// Texture conversion, resizing, mipmap generation, and block compression
|
||||
|
||||
@ -749,7 +758,9 @@ namespace DirectX
|
||||
WIC_CODEC_ICO, // Windows Icon (.ico)
|
||||
};
|
||||
|
||||
#if !defined(_DXTX_NOWIN)
|
||||
REFGUID __cdecl GetWICCodec(_In_ WICCodecs codec) noexcept;
|
||||
#endif
|
||||
|
||||
IWICImagingFactory* __cdecl GetWICFactory(bool& iswic2) noexcept;
|
||||
void __cdecl SetWICFactory(_In_opt_ IWICImagingFactory* pWIC) noexcept;
|
||||
|
@ -13,7 +13,10 @@
|
||||
|
||||
using namespace DirectX;
|
||||
using namespace DirectX::PackedVector;
|
||||
|
||||
#if !defined(_DXTX_NOWIN)
|
||||
using Microsoft::WRL::ComPtr;
|
||||
#endif
|
||||
|
||||
namespace
|
||||
{
|
||||
@ -2640,7 +2643,7 @@ HRESULT DirectX::_ConvertToR16G16B16A16(const Image& srcImage, ScratchImage& ima
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
ScopedAlignedArrayXMVECTOR scanline(static_cast<XMVECTOR*>(_aligned_malloc((sizeof(XMVECTOR) * srcImage.width), 16)));
|
||||
ScopedAlignedArrayXMVECTOR scanline(static_cast<XMVECTOR*>(AllocateVectorAligned((sizeof(XMVECTOR) * srcImage.width))));
|
||||
if (!scanline)
|
||||
{
|
||||
image.Release();
|
||||
@ -2693,7 +2696,7 @@ HRESULT DirectX::_ConvertFromR16G16B16A16(const Image& srcImage, const Image& de
|
||||
if (srcImage.width != destImage.width || srcImage.height != destImage.height)
|
||||
return E_FAIL;
|
||||
|
||||
ScopedAlignedArrayXMVECTOR scanline(static_cast<XMVECTOR*>(_aligned_malloc((sizeof(XMVECTOR) * srcImage.width), 16)));
|
||||
ScopedAlignedArrayXMVECTOR scanline(static_cast<XMVECTOR*>(AllocateVectorAligned((sizeof(XMVECTOR) * srcImage.width))));
|
||||
if (!scanline)
|
||||
return E_OUTOFMEMORY;
|
||||
|
||||
@ -4363,6 +4366,8 @@ bool DirectX::_StoreScanlineDither(
|
||||
|
||||
namespace
|
||||
{
|
||||
|
||||
#if !defined(_DXTX_NOWIN)
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Selection logic for using WIC vs. our own routines
|
||||
//-------------------------------------------------------------------------------------
|
||||
@ -4573,6 +4578,8 @@ namespace
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
// Convert the source image (not using WIC)
|
||||
@ -4597,7 +4604,7 @@ namespace
|
||||
if (filter & TEX_FILTER_DITHER_DIFFUSION)
|
||||
{
|
||||
// Error diffusion dithering (aka Floyd-Steinberg dithering)
|
||||
ScopedAlignedArrayXMVECTOR scanline(static_cast<XMVECTOR*>(_aligned_malloc((sizeof(XMVECTOR)*(width * 2 + 2)), 16)));
|
||||
ScopedAlignedArrayXMVECTOR scanline(static_cast<XMVECTOR*>(AllocateVectorAligned((sizeof(XMVECTOR)*(width * 2 + 2)))));
|
||||
if (!scanline)
|
||||
return E_OUTOFMEMORY;
|
||||
|
||||
@ -4620,7 +4627,7 @@ namespace
|
||||
}
|
||||
else
|
||||
{
|
||||
ScopedAlignedArrayXMVECTOR scanline(static_cast<XMVECTOR*>(_aligned_malloc((sizeof(XMVECTOR)*width), 16)));
|
||||
ScopedAlignedArrayXMVECTOR scanline(static_cast<XMVECTOR*>(AllocateVectorAligned((sizeof(XMVECTOR)*width))));
|
||||
if (!scanline)
|
||||
return E_OUTOFMEMORY;
|
||||
|
||||
@ -4856,12 +4863,14 @@ HRESULT DirectX::Convert(
|
||||
return E_POINTER;
|
||||
}
|
||||
|
||||
#if !defined(_DXTX_NOWIN)
|
||||
WICPixelFormatGUID pfGUID, targetGUID;
|
||||
if (UseWICConversion(filter, srcImage.format, format, pfGUID, targetGUID))
|
||||
{
|
||||
hr = ConvertUsingWIC(srcImage, pfGUID, targetGUID, filter, threshold, *rimage);
|
||||
}
|
||||
else
|
||||
#endif
|
||||
{
|
||||
hr = ConvertCustom(srcImage, filter, *rimage, threshold, 0);
|
||||
}
|
||||
@ -4920,8 +4929,14 @@ HRESULT DirectX::Convert(
|
||||
return E_POINTER;
|
||||
}
|
||||
|
||||
bool usewic;
|
||||
#if !defined(_DXTX_NOWIN)
|
||||
WICPixelFormatGUID pfGUID, targetGUID;
|
||||
bool usewic = !metadata.IsPMAlpha() && UseWICConversion(filter, metadata.format, format, pfGUID, targetGUID);
|
||||
usewic =!metadata.IsPMAlpha() && UseWICConversion(filter, metadata.format, format, pfGUID, targetGUID);
|
||||
#else
|
||||
usewic = false;
|
||||
#endif
|
||||
|
||||
|
||||
switch (metadata.dimension)
|
||||
{
|
||||
@ -4951,11 +4966,13 @@ HRESULT DirectX::Convert(
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
#if !defined(_DXTX_NOWIN)
|
||||
if (usewic)
|
||||
{
|
||||
hr = ConvertUsingWIC(src, pfGUID, targetGUID, filter, threshold, dst);
|
||||
}
|
||||
else
|
||||
#endif
|
||||
{
|
||||
hr = ConvertCustom(src, filter, dst, threshold, 0);
|
||||
}
|
||||
@ -5004,11 +5021,13 @@ HRESULT DirectX::Convert(
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
#if !defined(_DXTX_NOWIN)
|
||||
if (usewic)
|
||||
{
|
||||
hr = ConvertUsingWIC(src, pfGUID, targetGUID, filter, threshold, dst);
|
||||
}
|
||||
else
|
||||
#endif
|
||||
{
|
||||
hr = ConvertCustom(src, filter, dst, threshold, slice);
|
||||
}
|
||||
|
@ -1575,32 +1575,10 @@ HRESULT DirectX::GetMetadataFromDDSFile(
|
||||
if (!szFile)
|
||||
return E_INVALIDARG;
|
||||
|
||||
#if (_WIN32_WINNT >= _WIN32_WINNT_WIN8)
|
||||
ScopedHandle hFile(safe_handle(CreateFile2(szFile, GENERIC_READ, FILE_SHARE_READ, OPEN_EXISTING, nullptr)));
|
||||
#else
|
||||
ScopedHandle hFile(safe_handle(CreateFileW(szFile, GENERIC_READ, FILE_SHARE_READ, nullptr, OPEN_EXISTING,
|
||||
FILE_FLAG_SEQUENTIAL_SCAN, 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 (4 GB should be plenty large enough for a valid DDS file)
|
||||
if (fileInfo.EndOfFile.HighPart > 0)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_FILE_TOO_LARGE);
|
||||
}
|
||||
ScopedReadFile hFile(szFile);
|
||||
|
||||
// Need at least enough data to fill the standard header and magic number to be a valid DDS
|
||||
if (fileInfo.EndOfFile.LowPart < (sizeof(DDS_HEADER) + sizeof(uint32_t)))
|
||||
if (hFile.GetLength() < (sizeof(DDS_HEADER) + sizeof(uint32_t)))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
@ -1610,9 +1588,9 @@ HRESULT DirectX::GetMetadataFromDDSFile(
|
||||
uint8_t header[MAX_HEADER_SIZE] = {};
|
||||
|
||||
DWORD bytesRead = 0;
|
||||
if (!ReadFile(hFile.get(), header, MAX_HEADER_SIZE, &bytesRead, nullptr))
|
||||
if (!(bytesRead = hFile.Read(header, MAX_HEADER_SIZE)))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
uint32_t convFlags = 0;
|
||||
@ -1708,33 +1686,11 @@ HRESULT DirectX::LoadFromDDSFile(
|
||||
|
||||
image.Release();
|
||||
|
||||
#if (_WIN32_WINNT >= _WIN32_WINNT_WIN8)
|
||||
ScopedHandle hFile(safe_handle(CreateFile2(szFile, GENERIC_READ, FILE_SHARE_READ, OPEN_EXISTING, nullptr)));
|
||||
#else
|
||||
ScopedHandle hFile(safe_handle(CreateFileW(szFile, GENERIC_READ, FILE_SHARE_READ, nullptr, OPEN_EXISTING,
|
||||
FILE_FLAG_SEQUENTIAL_SCAN, 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 (4 GB should be plenty large enough for a valid DDS file)
|
||||
if (fileInfo.EndOfFile.HighPart > 0)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_FILE_TOO_LARGE);
|
||||
}
|
||||
ScopedReadFile hFile(szFile);
|
||||
|
||||
// Need at least enough data to fill the standard header and magic number to be a valid DDS
|
||||
if (fileInfo.EndOfFile.LowPart < (sizeof(DDS_HEADER) + sizeof(uint32_t)))
|
||||
if (hFile.GetLength() < (sizeof(DDS_HEADER) + sizeof(uint32_t)))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
@ -1744,9 +1700,9 @@ HRESULT DirectX::LoadFromDDSFile(
|
||||
uint8_t header[MAX_HEADER_SIZE] = {};
|
||||
|
||||
DWORD bytesRead = 0;
|
||||
if (!ReadFile(hFile.get(), header, MAX_HEADER_SIZE, &bytesRead, nullptr))
|
||||
if (!(bytesRead = hFile.Read(header, MAX_HEADER_SIZE)))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
uint32_t convFlags = 0;
|
||||
@ -1760,12 +1716,7 @@ HRESULT DirectX::LoadFromDDSFile(
|
||||
if (!(convFlags & CONV_FLAGS_DX10))
|
||||
{
|
||||
// Must reset file position since we read more than the standard header above
|
||||
LARGE_INTEGER filePos = { { sizeof(uint32_t) + sizeof(DDS_HEADER), 0 } };
|
||||
if (!SetFilePointerEx(hFile.get(), filePos, nullptr, FILE_BEGIN))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
}
|
||||
|
||||
hFile.SeekBegin(sizeof(uint32_t) + sizeof(DDS_HEADER));
|
||||
offset = sizeof(uint32_t) + sizeof(DDS_HEADER);
|
||||
}
|
||||
|
||||
@ -1778,9 +1729,9 @@ HRESULT DirectX::LoadFromDDSFile(
|
||||
return E_OUTOFMEMORY;
|
||||
}
|
||||
|
||||
if (!ReadFile(hFile.get(), pal8.get(), 256 * sizeof(uint32_t), &bytesRead, nullptr))
|
||||
if (!(bytesRead = hFile.Read(pal8.get(), 256 * sizeof(uint32_t))))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (bytesRead != (256 * sizeof(uint32_t)))
|
||||
@ -1791,7 +1742,7 @@ HRESULT DirectX::LoadFromDDSFile(
|
||||
offset += (256 * sizeof(uint32_t));
|
||||
}
|
||||
|
||||
DWORD remaining = fileInfo.EndOfFile.LowPart - offset;
|
||||
DWORD remaining = hFile.GetLength() - offset;
|
||||
if (remaining == 0)
|
||||
return E_FAIL;
|
||||
|
||||
@ -1808,10 +1759,10 @@ HRESULT DirectX::LoadFromDDSFile(
|
||||
return E_OUTOFMEMORY;
|
||||
}
|
||||
|
||||
if (!ReadFile(hFile.get(), temp.get(), remaining, &bytesRead, nullptr))
|
||||
if (!(bytesRead = hFile.Read(temp.get(), remaining)))
|
||||
{
|
||||
image.Release();
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (bytesRead != remaining)
|
||||
@ -1857,10 +1808,10 @@ HRESULT DirectX::LoadFromDDSFile(
|
||||
return HRESULT_FROM_WIN32(ERROR_ARITHMETIC_OVERFLOW);
|
||||
}
|
||||
|
||||
if (!ReadFile(hFile.get(), image.GetPixels(), static_cast<DWORD>(image.GetPixelsSize()), &bytesRead, nullptr))
|
||||
if (!(bytesRead = hFile.Read(image.GetPixels(), static_cast<DWORD>(image.GetPixelsSize()))))
|
||||
{
|
||||
image.Release();
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (convFlags & (CONV_FLAGS_SWIZZLE | CONV_FLAGS_NOALPHA))
|
||||
@ -2133,25 +2084,9 @@ HRESULT DirectX::SaveToDDSFile(
|
||||
return hr;
|
||||
|
||||
// Create file and write header
|
||||
#if (_WIN32_WINNT >= _WIN32_WINNT_WIN8)
|
||||
ScopedHandle hFile(safe_handle(CreateFile2(szFile, GENERIC_WRITE | DELETE, 0, CREATE_ALWAYS, nullptr)));
|
||||
#else
|
||||
ScopedHandle hFile(safe_handle(CreateFileW(szFile, GENERIC_WRITE | DELETE, 0, nullptr, CREATE_ALWAYS, 0, nullptr)));
|
||||
#endif
|
||||
if (!hFile)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
}
|
||||
ScopedWriteFile hFile(szFile);
|
||||
|
||||
auto_delete_file delonfail(hFile.get());
|
||||
|
||||
DWORD bytesWritten;
|
||||
if (!WriteFile(hFile.get(), header, static_cast<DWORD>(required), &bytesWritten, nullptr))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
}
|
||||
|
||||
if (bytesWritten != required)
|
||||
if (! hFile.Write(header, static_cast<DWORD>(required)))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
@ -2183,15 +2118,12 @@ HRESULT DirectX::SaveToDDSFile(
|
||||
|
||||
if ((images[index].slicePitch == ddsSlicePitch) && (ddsSlicePitch <= UINT32_MAX))
|
||||
{
|
||||
if (!WriteFile(hFile.get(), images[index].pixels, static_cast<DWORD>(ddsSlicePitch), &bytesWritten, nullptr))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
}
|
||||
|
||||
if (bytesWritten != ddsSlicePitch)
|
||||
if (! hFile.Write(images[index].pixels, static_cast<DWORD>(ddsSlicePitch)))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -2210,12 +2142,7 @@ HRESULT DirectX::SaveToDDSFile(
|
||||
size_t lines = ComputeScanlines(metadata.format, images[index].height);
|
||||
for (size_t j = 0; j < lines; ++j)
|
||||
{
|
||||
if (!WriteFile(hFile.get(), sPtr, static_cast<DWORD>(ddsRowPitch), &bytesWritten, nullptr))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
}
|
||||
|
||||
if (bytesWritten != ddsRowPitch)
|
||||
if (!hFile.Write(sPtr, static_cast<DWORD>(ddsRowPitch)))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
@ -2256,12 +2183,7 @@ HRESULT DirectX::SaveToDDSFile(
|
||||
|
||||
if ((images[index].slicePitch == ddsSlicePitch) && (ddsSlicePitch <= UINT32_MAX))
|
||||
{
|
||||
if (!WriteFile(hFile.get(), images[index].pixels, static_cast<DWORD>(ddsSlicePitch), &bytesWritten, nullptr))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
}
|
||||
|
||||
if (bytesWritten != ddsSlicePitch)
|
||||
if (!hFile.Write(images[index].pixels, static_cast<DWORD>(ddsSlicePitch)))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
@ -2283,16 +2205,10 @@ HRESULT DirectX::SaveToDDSFile(
|
||||
size_t lines = ComputeScanlines(metadata.format, images[index].height);
|
||||
for (size_t j = 0; j < lines; ++j)
|
||||
{
|
||||
if (!WriteFile(hFile.get(), sPtr, static_cast<DWORD>(ddsRowPitch), &bytesWritten, nullptr))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
}
|
||||
|
||||
if (bytesWritten != ddsRowPitch)
|
||||
if (!hFile.Write(sPtr, static_cast<DWORD>(ddsRowPitch)))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
sPtr += rowPitch;
|
||||
}
|
||||
}
|
||||
@ -2308,7 +2224,7 @@ HRESULT DirectX::SaveToDDSFile(
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
delonfail.clear();
|
||||
//delonfail.clear();
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
@ -580,32 +580,10 @@ HRESULT DirectX::GetMetadataFromHDRFile(const wchar_t* szFile, TexMetadata& meta
|
||||
if (!szFile)
|
||||
return E_INVALIDARG;
|
||||
|
||||
#if (_WIN32_WINNT >= _WIN32_WINNT_WIN8)
|
||||
ScopedHandle hFile(safe_handle(CreateFile2(szFile, GENERIC_READ, FILE_SHARE_READ, OPEN_EXISTING, nullptr)));
|
||||
#else
|
||||
ScopedHandle hFile(safe_handle(CreateFileW(szFile, GENERIC_READ, FILE_SHARE_READ, nullptr, OPEN_EXISTING,
|
||||
FILE_FLAG_SEQUENTIAL_SCAN, 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 (4 GB should be plenty large enough for a valid HDR file)
|
||||
if (fileInfo.EndOfFile.HighPart > 0)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(ERROR_FILE_TOO_LARGE);
|
||||
}
|
||||
ScopedReadFile hFile(szFile);
|
||||
|
||||
// Need at least enough data to fill the standard header to be a valid HDR
|
||||
if (fileInfo.EndOfFile.LowPart < sizeof(g_Signature))
|
||||
if (szFile.GetLength() < sizeof(g_Signature))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
@ -615,7 +593,7 @@ HRESULT DirectX::GetMetadataFromHDRFile(const wchar_t* szFile, TexMetadata& meta
|
||||
DWORD bytesRead = 0;
|
||||
if (!ReadFile(hFile.get(), header, std::min<DWORD>(sizeof(header), fileInfo.EndOfFile.LowPart), &bytesRead, nullptr))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
size_t offset;
|
||||
@ -860,14 +838,14 @@ HRESULT DirectX::LoadFromHDRFile(const wchar_t* szFile, TexMetadata* metadata, S
|
||||
#endif
|
||||
if (!hFile)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
// Get the file size
|
||||
FILE_STANDARD_INFO fileInfo;
|
||||
if (!GetFileInformationByHandleEx(hFile.get(), FileStandardInfo, &fileInfo, sizeof(fileInfo)))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
// File is too big for 32-bit allocation, so reject read (4 GB should be plenty large enough for a valid HDR file)
|
||||
@ -892,7 +870,7 @@ HRESULT DirectX::LoadFromHDRFile(const wchar_t* szFile, TexMetadata* metadata, S
|
||||
DWORD bytesRead = 0;
|
||||
if (!ReadFile(hFile.get(), temp.get(), fileInfo.EndOfFile.LowPart, &bytesRead, nullptr))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (bytesRead != fileInfo.EndOfFile.LowPart)
|
||||
@ -1055,7 +1033,7 @@ HRESULT DirectX::SaveToHDRFile(const Image& image, const wchar_t* szFile) noexce
|
||||
#endif
|
||||
if (!hFile)
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
auto_delete_file delonfail(hFile.get());
|
||||
@ -1082,7 +1060,7 @@ HRESULT DirectX::SaveToHDRFile(const Image& image, const wchar_t* szFile) noexce
|
||||
DWORD bytesWritten;
|
||||
if (!WriteFile(hFile.get(), blob.GetBufferPointer(), bytesToWrite, &bytesWritten, nullptr))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (bytesWritten != bytesToWrite)
|
||||
@ -1108,7 +1086,7 @@ HRESULT DirectX::SaveToHDRFile(const Image& image, const wchar_t* szFile) noexce
|
||||
DWORD bytesWritten;
|
||||
if (!WriteFile(hFile.get(), header, headerLen, &bytesWritten, nullptr))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (bytesWritten != headerLen)
|
||||
@ -1124,7 +1102,7 @@ HRESULT DirectX::SaveToHDRFile(const Image& image, const wchar_t* szFile) noexce
|
||||
|
||||
if (!WriteFile(hFile.get(), rgbe, static_cast<DWORD>(rowPitch), &bytesWritten, nullptr))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (bytesWritten != rowPitch)
|
||||
@ -1154,7 +1132,7 @@ HRESULT DirectX::SaveToHDRFile(const Image& image, const wchar_t* szFile) noexce
|
||||
|
||||
if (!WriteFile(hFile.get(), enc, static_cast<DWORD>(encSize), &bytesWritten, nullptr))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (bytesWritten != encSize)
|
||||
@ -1164,7 +1142,7 @@ HRESULT DirectX::SaveToHDRFile(const Image& image, const wchar_t* szFile) noexce
|
||||
{
|
||||
if (!WriteFile(hFile.get(), rgbe, static_cast<DWORD>(rowPitch), &bytesWritten, nullptr))
|
||||
{
|
||||
return HRESULT_FROM_WIN32(GetLastError());
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (bytesWritten != rowPitch)
|
||||
|
@ -74,6 +74,28 @@
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
#endif
|
||||
|
||||
|
||||
#include <malloc.h>
|
||||
#include <memory>
|
||||
#include <vector>
|
||||
#include <time.h>
|
||||
#include <stdlib.h>
|
||||
#include <cstdlib>
|
||||
#include <search.h>
|
||||
#include <algorithm>
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <functional>
|
||||
#include <string.h>
|
||||
#include <cstdlib>
|
||||
#include <filesystem>
|
||||
#include <ios>
|
||||
#include <fstream>
|
||||
|
||||
#include <assert.h>
|
||||
|
||||
#if !defined(_DXTX_NOWIN)
|
||||
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable : 4005)
|
||||
#define NOMINMAX
|
||||
@ -107,29 +129,32 @@
|
||||
|
||||
#define _XM_NO_XMVECTOR_OVERLOADS_
|
||||
|
||||
#include <DirectXMath.h>
|
||||
#include <DirectXPackedVector.h>
|
||||
#include <assert.h>
|
||||
|
||||
#include <malloc.h>
|
||||
#include <memory>
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include <time.h>
|
||||
#include <stdlib.h>
|
||||
#include <search.h>
|
||||
|
||||
#include <Ole2.h>
|
||||
|
||||
#include "DirectXTex.h"
|
||||
|
||||
#include <wincodec.h>
|
||||
|
||||
#include <wrl\client.h>
|
||||
|
||||
#else // !defined(_DXTX_NOWIN)
|
||||
|
||||
#if defined(__clang__)
|
||||
#include "ClangCommon.hpp"
|
||||
#endif
|
||||
#include "Win32Public.hpp"
|
||||
#include "MSVCStubs.hpp"
|
||||
|
||||
#endif
|
||||
|
||||
#include "StdFS.hpp"
|
||||
|
||||
#define _DXTEX_PRIVATE
|
||||
#include "DirectXTex.h"
|
||||
|
||||
#include <DirectXMath.h>
|
||||
#include <DirectXPackedVector.h>
|
||||
|
||||
#include "scoped.h"
|
||||
|
||||
|
||||
#define XBOX_DXGI_FORMAT_R10G10B10_7E3_A2_FLOAT DXGI_FORMAT(116)
|
||||
#define XBOX_DXGI_FORMAT_R10G10B10_6E4_A2_FLOAT DXGI_FORMAT(117)
|
||||
#define XBOX_DXGI_FORMAT_D16_UNORM_S8_UINT DXGI_FORMAT(118)
|
||||
@ -155,6 +180,7 @@ namespace DirectX
|
||||
|
||||
TEX_FILTER_FLAGS __cdecl _CheckWICColorSpace(_In_ const GUID& sourceGUID, _In_ const GUID& targetGUID) noexcept;
|
||||
|
||||
#if !defined(_DXTX_NOWIN)
|
||||
inline WICBitmapDitherType __cdecl _GetWICDither(_In_ TEX_FILTER_FLAGS flags) noexcept
|
||||
{
|
||||
static_assert(TEX_FILTER_DITHER == 0x10000, "TEX_FILTER_DITHER* flag values don't match mask");
|
||||
@ -235,6 +261,7 @@ namespace DirectX
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
// Image helper functions
|
||||
|
@ -9,50 +9,16 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <assert.h>
|
||||
#include <memory>
|
||||
#include <malloc.h>
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
struct aligned_deleter { void operator()(void* p) noexcept { _aligned_free(p); } };
|
||||
struct aligned_deleter { void operator()(void* p) noexcept { std::free(p); } };
|
||||
|
||||
using ScopedAlignedArrayFloat = std::unique_ptr<float[], aligned_deleter>;
|
||||
|
||||
using ScopedAlignedArrayXMVECTOR = std::unique_ptr<DirectX::XMVECTOR[], aligned_deleter>;
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
struct handle_closer { void operator()(HANDLE h) noexcept { assert(h != INVALID_HANDLE_VALUE); if (h) CloseHandle(h); } };
|
||||
|
||||
using ScopedHandle = std::unique_ptr<void, handle_closer>;
|
||||
|
||||
inline HANDLE safe_handle(HANDLE h) noexcept { return (h == INVALID_HANDLE_VALUE) ? nullptr : h; }
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
struct find_closer { void operator()(HANDLE h) noexcept { assert(h != INVALID_HANDLE_VALUE); if (h) FindClose(h); } };
|
||||
|
||||
using ScopedFindHandle = std::unique_ptr<void, find_closer>;
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
class auto_delete_file
|
||||
static inline void * AllocateVectorAligned(size_t length)
|
||||
{
|
||||
public:
|
||||
auto_delete_file(HANDLE hFile) noexcept : m_handle(hFile) {}
|
||||
|
||||
auto_delete_file(const auto_delete_file&) = delete;
|
||||
auto_delete_file& operator=(const auto_delete_file&) = delete;
|
||||
|
||||
~auto_delete_file()
|
||||
{
|
||||
if (m_handle)
|
||||
{
|
||||
FILE_DISPOSITION_INFO info = {};
|
||||
info.DeleteFile = TRUE;
|
||||
(void)SetFileInformationByHandle(m_handle, FileDispositionInfo, &info, sizeof(info));
|
||||
return std::aligned_alloc(16, length);
|
||||
}
|
||||
}
|
||||
|
||||
void clear() noexcept { m_handle = nullptr; }
|
||||
|
||||
private:
|
||||
HANDLE m_handle;
|
||||
};
|
||||
|
917
Makefile
Normal file
917
Makefile
Normal file
@ -0,0 +1,917 @@
|
||||
# CMAKE generated file: DO NOT EDIT!
|
||||
# Generated by "Unix Makefiles" Generator, CMake Version 3.18
|
||||
|
||||
# Default target executed when no arguments are given to make.
|
||||
default_target: all
|
||||
|
||||
.PHONY : default_target
|
||||
|
||||
# Allow only one "make -f Makefile2" at a time, but pass parallelism.
|
||||
.NOTPARALLEL:
|
||||
|
||||
|
||||
#=============================================================================
|
||||
# Special targets provided by cmake.
|
||||
|
||||
# Disable implicit rules so canonical targets will work.
|
||||
.SUFFIXES:
|
||||
|
||||
|
||||
# Disable VCS-based implicit rules.
|
||||
% : %,v
|
||||
|
||||
|
||||
# Disable VCS-based implicit rules.
|
||||
% : RCS/%
|
||||
|
||||
|
||||
# Disable VCS-based implicit rules.
|
||||
% : RCS/%,v
|
||||
|
||||
|
||||
# Disable VCS-based implicit rules.
|
||||
% : SCCS/s.%
|
||||
|
||||
|
||||
# Disable VCS-based implicit rules.
|
||||
% : s.%
|
||||
|
||||
|
||||
.SUFFIXES: .hpux_make_needs_suffix_list
|
||||
|
||||
|
||||
# Command-line flag to silence nested $(MAKE).
|
||||
$(VERBOSE)MAKESILENT = -s
|
||||
|
||||
#Suppress display of executed commands.
|
||||
$(VERBOSE).SILENT:
|
||||
|
||||
# A target that is always out of date.
|
||||
cmake_force:
|
||||
|
||||
.PHONY : cmake_force
|
||||
|
||||
#=============================================================================
|
||||
# Set environment variables for the build.
|
||||
|
||||
# The shell in which to execute make rules.
|
||||
SHELL = /bin/sh
|
||||
|
||||
# The CMake executable.
|
||||
CMAKE_COMMAND = /usr/bin/cmake
|
||||
|
||||
# The command to remove a file.
|
||||
RM = /usr/bin/cmake -E rm -f
|
||||
|
||||
# Escaping for special characters.
|
||||
EQUALS = =
|
||||
|
||||
# The top-level source directory on which CMake was run.
|
||||
CMAKE_SOURCE_DIR = /run/media/reece/Misc/GameEngine/Master/Public/DirectXTex
|
||||
|
||||
# The top-level build directory on which CMake was run.
|
||||
CMAKE_BINARY_DIR = /run/media/reece/Misc/GameEngine/Master/Public/DirectXTex
|
||||
|
||||
#=============================================================================
|
||||
# Targets provided globally by CMake.
|
||||
|
||||
# Special rule for the target edit_cache
|
||||
edit_cache:
|
||||
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Running CMake cache editor..."
|
||||
/usr/bin/ccmake -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR)
|
||||
.PHONY : edit_cache
|
||||
|
||||
# Special rule for the target edit_cache
|
||||
edit_cache/fast: edit_cache
|
||||
|
||||
.PHONY : edit_cache/fast
|
||||
|
||||
# Special rule for the target rebuild_cache
|
||||
rebuild_cache:
|
||||
@$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Running CMake to regenerate build system..."
|
||||
/usr/bin/cmake --regenerate-during-build -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR)
|
||||
.PHONY : rebuild_cache
|
||||
|
||||
# Special rule for the target rebuild_cache
|
||||
rebuild_cache/fast: rebuild_cache
|
||||
|
||||
.PHONY : rebuild_cache/fast
|
||||
|
||||
# The main all target
|
||||
all: cmake_check_build_system
|
||||
$(CMAKE_COMMAND) -E cmake_progress_start /run/media/reece/Misc/GameEngine/Master/Public/DirectXTex/CMakeFiles /run/media/reece/Misc/GameEngine/Master/Public/DirectXTex//CMakeFiles/progress.marks
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 all
|
||||
$(CMAKE_COMMAND) -E cmake_progress_start /run/media/reece/Misc/GameEngine/Master/Public/DirectXTex/CMakeFiles 0
|
||||
.PHONY : all
|
||||
|
||||
# The main clean target
|
||||
clean:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 clean
|
||||
.PHONY : clean
|
||||
|
||||
# The main clean target
|
||||
clean/fast: clean
|
||||
|
||||
.PHONY : clean/fast
|
||||
|
||||
# Prepare targets for installation.
|
||||
preinstall: all
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 preinstall
|
||||
.PHONY : preinstall
|
||||
|
||||
# Prepare targets for installation.
|
||||
preinstall/fast:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 preinstall
|
||||
.PHONY : preinstall/fast
|
||||
|
||||
# clear depends
|
||||
depend:
|
||||
$(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 1
|
||||
.PHONY : depend
|
||||
|
||||
#=============================================================================
|
||||
# Target rules for targets named texdiag
|
||||
|
||||
# Build rule for target.
|
||||
texdiag: cmake_check_build_system
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 texdiag
|
||||
.PHONY : texdiag
|
||||
|
||||
# fast build rule for target.
|
||||
texdiag/fast:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texdiag.dir/build.make CMakeFiles/texdiag.dir/build
|
||||
.PHONY : texdiag/fast
|
||||
|
||||
#=============================================================================
|
||||
# Target rules for targets named texconv
|
||||
|
||||
# Build rule for target.
|
||||
texconv: cmake_check_build_system
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 texconv
|
||||
.PHONY : texconv
|
||||
|
||||
# fast build rule for target.
|
||||
texconv/fast:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texconv.dir/build.make CMakeFiles/texconv.dir/build
|
||||
.PHONY : texconv/fast
|
||||
|
||||
#=============================================================================
|
||||
# Target rules for targets named texassemble
|
||||
|
||||
# Build rule for target.
|
||||
texassemble: cmake_check_build_system
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 texassemble
|
||||
.PHONY : texassemble
|
||||
|
||||
# fast build rule for target.
|
||||
texassemble/fast:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texassemble.dir/build.make CMakeFiles/texassemble.dir/build
|
||||
.PHONY : texassemble/fast
|
||||
|
||||
#=============================================================================
|
||||
# Target rules for targets named DirectXTex
|
||||
|
||||
# Build rule for target.
|
||||
DirectXTex: cmake_check_build_system
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 DirectXTex
|
||||
.PHONY : DirectXTex
|
||||
|
||||
# fast build rule for target.
|
||||
DirectXTex/fast:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/build
|
||||
.PHONY : DirectXTex/fast
|
||||
|
||||
DirectXTex/BC.o: DirectXTex/BC.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/BC.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/BC.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/BC.cpp.o
|
||||
.PHONY : DirectXTex/BC.cpp.o
|
||||
|
||||
DirectXTex/BC.i: DirectXTex/BC.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/BC.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/BC.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/BC.cpp.i
|
||||
.PHONY : DirectXTex/BC.cpp.i
|
||||
|
||||
DirectXTex/BC.s: DirectXTex/BC.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/BC.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/BC.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/BC.cpp.s
|
||||
.PHONY : DirectXTex/BC.cpp.s
|
||||
|
||||
DirectXTex/BC4BC5.o: DirectXTex/BC4BC5.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/BC4BC5.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/BC4BC5.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/BC4BC5.cpp.o
|
||||
.PHONY : DirectXTex/BC4BC5.cpp.o
|
||||
|
||||
DirectXTex/BC4BC5.i: DirectXTex/BC4BC5.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/BC4BC5.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/BC4BC5.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/BC4BC5.cpp.i
|
||||
.PHONY : DirectXTex/BC4BC5.cpp.i
|
||||
|
||||
DirectXTex/BC4BC5.s: DirectXTex/BC4BC5.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/BC4BC5.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/BC4BC5.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/BC4BC5.cpp.s
|
||||
.PHONY : DirectXTex/BC4BC5.cpp.s
|
||||
|
||||
DirectXTex/BC6HBC7.o: DirectXTex/BC6HBC7.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/BC6HBC7.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/BC6HBC7.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/BC6HBC7.cpp.o
|
||||
.PHONY : DirectXTex/BC6HBC7.cpp.o
|
||||
|
||||
DirectXTex/BC6HBC7.i: DirectXTex/BC6HBC7.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/BC6HBC7.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/BC6HBC7.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/BC6HBC7.cpp.i
|
||||
.PHONY : DirectXTex/BC6HBC7.cpp.i
|
||||
|
||||
DirectXTex/BC6HBC7.s: DirectXTex/BC6HBC7.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/BC6HBC7.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/BC6HBC7.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/BC6HBC7.cpp.s
|
||||
.PHONY : DirectXTex/BC6HBC7.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexConvert.o: DirectXTex/DirectXTexConvert.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexConvert.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexConvert.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexConvert.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexConvert.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexConvert.i: DirectXTex/DirectXTexConvert.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexConvert.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexConvert.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexConvert.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexConvert.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexConvert.s: DirectXTex/DirectXTexConvert.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexConvert.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexConvert.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexConvert.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexConvert.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexD3D11.o: DirectXTex/DirectXTexD3D11.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexD3D11.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexD3D11.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexD3D11.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexD3D11.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexD3D11.i: DirectXTex/DirectXTexD3D11.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexD3D11.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexD3D11.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexD3D11.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexD3D11.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexD3D11.s: DirectXTex/DirectXTexD3D11.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexD3D11.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexD3D11.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexD3D11.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexD3D11.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexD3D12.o: DirectXTex/DirectXTexD3D12.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexD3D12.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexD3D12.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexD3D12.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexD3D12.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexD3D12.i: DirectXTex/DirectXTexD3D12.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexD3D12.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexD3D12.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexD3D12.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexD3D12.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexD3D12.s: DirectXTex/DirectXTexD3D12.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexD3D12.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexD3D12.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexD3D12.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexD3D12.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexDDS.o: DirectXTex/DirectXTexDDS.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexDDS.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexDDS.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexDDS.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexDDS.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexDDS.i: DirectXTex/DirectXTexDDS.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexDDS.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexDDS.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexDDS.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexDDS.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexDDS.s: DirectXTex/DirectXTexDDS.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexDDS.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexDDS.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexDDS.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexDDS.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexFlipRotate.o: DirectXTex/DirectXTexFlipRotate.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexFlipRotate.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexFlipRotate.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexFlipRotate.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexFlipRotate.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexFlipRotate.i: DirectXTex/DirectXTexFlipRotate.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexFlipRotate.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexFlipRotate.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexFlipRotate.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexFlipRotate.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexFlipRotate.s: DirectXTex/DirectXTexFlipRotate.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexFlipRotate.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexFlipRotate.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexFlipRotate.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexFlipRotate.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexHDR.o: DirectXTex/DirectXTexHDR.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexHDR.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexHDR.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexHDR.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexHDR.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexHDR.i: DirectXTex/DirectXTexHDR.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexHDR.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexHDR.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexHDR.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexHDR.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexHDR.s: DirectXTex/DirectXTexHDR.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexHDR.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexHDR.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexHDR.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexHDR.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexImage.o: DirectXTex/DirectXTexImage.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexImage.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexImage.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexImage.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexImage.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexImage.i: DirectXTex/DirectXTexImage.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexImage.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexImage.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexImage.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexImage.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexImage.s: DirectXTex/DirectXTexImage.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexImage.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexImage.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexImage.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexImage.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexMipmaps.o: DirectXTex/DirectXTexMipmaps.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexMipmaps.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexMipmaps.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexMipmaps.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexMipmaps.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexMipmaps.i: DirectXTex/DirectXTexMipmaps.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexMipmaps.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexMipmaps.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexMipmaps.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexMipmaps.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexMipmaps.s: DirectXTex/DirectXTexMipmaps.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexMipmaps.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexMipmaps.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexMipmaps.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexMipmaps.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexMisc.o: DirectXTex/DirectXTexMisc.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexMisc.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexMisc.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexMisc.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexMisc.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexMisc.i: DirectXTex/DirectXTexMisc.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexMisc.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexMisc.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexMisc.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexMisc.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexMisc.s: DirectXTex/DirectXTexMisc.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexMisc.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexMisc.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexMisc.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexMisc.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexNormalMaps.o: DirectXTex/DirectXTexNormalMaps.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexNormalMaps.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexNormalMaps.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexNormalMaps.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexNormalMaps.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexNormalMaps.i: DirectXTex/DirectXTexNormalMaps.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexNormalMaps.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexNormalMaps.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexNormalMaps.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexNormalMaps.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexNormalMaps.s: DirectXTex/DirectXTexNormalMaps.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexNormalMaps.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexNormalMaps.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexNormalMaps.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexNormalMaps.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexPMAlpha.o: DirectXTex/DirectXTexPMAlpha.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexPMAlpha.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexPMAlpha.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexPMAlpha.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexPMAlpha.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexPMAlpha.i: DirectXTex/DirectXTexPMAlpha.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexPMAlpha.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexPMAlpha.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexPMAlpha.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexPMAlpha.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexPMAlpha.s: DirectXTex/DirectXTexPMAlpha.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexPMAlpha.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexPMAlpha.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexPMAlpha.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexPMAlpha.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexResize.o: DirectXTex/DirectXTexResize.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexResize.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexResize.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexResize.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexResize.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexResize.i: DirectXTex/DirectXTexResize.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexResize.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexResize.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexResize.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexResize.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexResize.s: DirectXTex/DirectXTexResize.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexResize.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexResize.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexResize.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexResize.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexTGA.o: DirectXTex/DirectXTexTGA.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexTGA.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexTGA.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexTGA.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexTGA.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexTGA.i: DirectXTex/DirectXTexTGA.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexTGA.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexTGA.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexTGA.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexTGA.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexTGA.s: DirectXTex/DirectXTexTGA.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexTGA.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexTGA.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexTGA.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexTGA.cpp.s
|
||||
|
||||
DirectXTex/DirectXTexUtil.o: DirectXTex/DirectXTexUtil.cpp.o
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexUtil.o
|
||||
|
||||
# target to build an object file
|
||||
DirectXTex/DirectXTexUtil.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexUtil.cpp.o
|
||||
.PHONY : DirectXTex/DirectXTexUtil.cpp.o
|
||||
|
||||
DirectXTex/DirectXTexUtil.i: DirectXTex/DirectXTexUtil.cpp.i
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexUtil.i
|
||||
|
||||
# target to preprocess a source file
|
||||
DirectXTex/DirectXTexUtil.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexUtil.cpp.i
|
||||
.PHONY : DirectXTex/DirectXTexUtil.cpp.i
|
||||
|
||||
DirectXTex/DirectXTexUtil.s: DirectXTex/DirectXTexUtil.cpp.s
|
||||
|
||||
.PHONY : DirectXTex/DirectXTexUtil.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
DirectXTex/DirectXTexUtil.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/DirectXTex/DirectXTexUtil.cpp.s
|
||||
.PHONY : DirectXTex/DirectXTexUtil.cpp.s
|
||||
|
||||
Texassemble/AnimatedGif.o: Texassemble/AnimatedGif.cpp.o
|
||||
|
||||
.PHONY : Texassemble/AnimatedGif.o
|
||||
|
||||
# target to build an object file
|
||||
Texassemble/AnimatedGif.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texassemble.dir/build.make CMakeFiles/texassemble.dir/Texassemble/AnimatedGif.cpp.o
|
||||
.PHONY : Texassemble/AnimatedGif.cpp.o
|
||||
|
||||
Texassemble/AnimatedGif.i: Texassemble/AnimatedGif.cpp.i
|
||||
|
||||
.PHONY : Texassemble/AnimatedGif.i
|
||||
|
||||
# target to preprocess a source file
|
||||
Texassemble/AnimatedGif.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texassemble.dir/build.make CMakeFiles/texassemble.dir/Texassemble/AnimatedGif.cpp.i
|
||||
.PHONY : Texassemble/AnimatedGif.cpp.i
|
||||
|
||||
Texassemble/AnimatedGif.s: Texassemble/AnimatedGif.cpp.s
|
||||
|
||||
.PHONY : Texassemble/AnimatedGif.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
Texassemble/AnimatedGif.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texassemble.dir/build.make CMakeFiles/texassemble.dir/Texassemble/AnimatedGif.cpp.s
|
||||
.PHONY : Texassemble/AnimatedGif.cpp.s
|
||||
|
||||
Texassemble/texassemble.o: Texassemble/texassemble.cpp.o
|
||||
|
||||
.PHONY : Texassemble/texassemble.o
|
||||
|
||||
# target to build an object file
|
||||
Texassemble/texassemble.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texassemble.dir/build.make CMakeFiles/texassemble.dir/Texassemble/texassemble.cpp.o
|
||||
.PHONY : Texassemble/texassemble.cpp.o
|
||||
|
||||
Texassemble/texassemble.i: Texassemble/texassemble.cpp.i
|
||||
|
||||
.PHONY : Texassemble/texassemble.i
|
||||
|
||||
# target to preprocess a source file
|
||||
Texassemble/texassemble.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texassemble.dir/build.make CMakeFiles/texassemble.dir/Texassemble/texassemble.cpp.i
|
||||
.PHONY : Texassemble/texassemble.cpp.i
|
||||
|
||||
Texassemble/texassemble.s: Texassemble/texassemble.cpp.s
|
||||
|
||||
.PHONY : Texassemble/texassemble.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
Texassemble/texassemble.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texassemble.dir/build.make CMakeFiles/texassemble.dir/Texassemble/texassemble.cpp.s
|
||||
.PHONY : Texassemble/texassemble.cpp.s
|
||||
|
||||
Texconv/ExtendedBMP.o: Texconv/ExtendedBMP.cpp.o
|
||||
|
||||
.PHONY : Texconv/ExtendedBMP.o
|
||||
|
||||
# target to build an object file
|
||||
Texconv/ExtendedBMP.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texconv.dir/build.make CMakeFiles/texconv.dir/Texconv/ExtendedBMP.cpp.o
|
||||
.PHONY : Texconv/ExtendedBMP.cpp.o
|
||||
|
||||
Texconv/ExtendedBMP.i: Texconv/ExtendedBMP.cpp.i
|
||||
|
||||
.PHONY : Texconv/ExtendedBMP.i
|
||||
|
||||
# target to preprocess a source file
|
||||
Texconv/ExtendedBMP.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texconv.dir/build.make CMakeFiles/texconv.dir/Texconv/ExtendedBMP.cpp.i
|
||||
.PHONY : Texconv/ExtendedBMP.cpp.i
|
||||
|
||||
Texconv/ExtendedBMP.s: Texconv/ExtendedBMP.cpp.s
|
||||
|
||||
.PHONY : Texconv/ExtendedBMP.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
Texconv/ExtendedBMP.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texconv.dir/build.make CMakeFiles/texconv.dir/Texconv/ExtendedBMP.cpp.s
|
||||
.PHONY : Texconv/ExtendedBMP.cpp.s
|
||||
|
||||
Texconv/PortablePixMap.o: Texconv/PortablePixMap.cpp.o
|
||||
|
||||
.PHONY : Texconv/PortablePixMap.o
|
||||
|
||||
# target to build an object file
|
||||
Texconv/PortablePixMap.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texconv.dir/build.make CMakeFiles/texconv.dir/Texconv/PortablePixMap.cpp.o
|
||||
.PHONY : Texconv/PortablePixMap.cpp.o
|
||||
|
||||
Texconv/PortablePixMap.i: Texconv/PortablePixMap.cpp.i
|
||||
|
||||
.PHONY : Texconv/PortablePixMap.i
|
||||
|
||||
# target to preprocess a source file
|
||||
Texconv/PortablePixMap.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texconv.dir/build.make CMakeFiles/texconv.dir/Texconv/PortablePixMap.cpp.i
|
||||
.PHONY : Texconv/PortablePixMap.cpp.i
|
||||
|
||||
Texconv/PortablePixMap.s: Texconv/PortablePixMap.cpp.s
|
||||
|
||||
.PHONY : Texconv/PortablePixMap.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
Texconv/PortablePixMap.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texconv.dir/build.make CMakeFiles/texconv.dir/Texconv/PortablePixMap.cpp.s
|
||||
.PHONY : Texconv/PortablePixMap.cpp.s
|
||||
|
||||
Texconv/texconv.o: Texconv/texconv.cpp.o
|
||||
|
||||
.PHONY : Texconv/texconv.o
|
||||
|
||||
# target to build an object file
|
||||
Texconv/texconv.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texconv.dir/build.make CMakeFiles/texconv.dir/Texconv/texconv.cpp.o
|
||||
.PHONY : Texconv/texconv.cpp.o
|
||||
|
||||
Texconv/texconv.i: Texconv/texconv.cpp.i
|
||||
|
||||
.PHONY : Texconv/texconv.i
|
||||
|
||||
# target to preprocess a source file
|
||||
Texconv/texconv.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texconv.dir/build.make CMakeFiles/texconv.dir/Texconv/texconv.cpp.i
|
||||
.PHONY : Texconv/texconv.cpp.i
|
||||
|
||||
Texconv/texconv.s: Texconv/texconv.cpp.s
|
||||
|
||||
.PHONY : Texconv/texconv.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
Texconv/texconv.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texconv.dir/build.make CMakeFiles/texconv.dir/Texconv/texconv.cpp.s
|
||||
.PHONY : Texconv/texconv.cpp.s
|
||||
|
||||
Texdiag/texdiag.o: Texdiag/texdiag.cpp.o
|
||||
|
||||
.PHONY : Texdiag/texdiag.o
|
||||
|
||||
# target to build an object file
|
||||
Texdiag/texdiag.cpp.o:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texdiag.dir/build.make CMakeFiles/texdiag.dir/Texdiag/texdiag.cpp.o
|
||||
.PHONY : Texdiag/texdiag.cpp.o
|
||||
|
||||
Texdiag/texdiag.i: Texdiag/texdiag.cpp.i
|
||||
|
||||
.PHONY : Texdiag/texdiag.i
|
||||
|
||||
# target to preprocess a source file
|
||||
Texdiag/texdiag.cpp.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texdiag.dir/build.make CMakeFiles/texdiag.dir/Texdiag/texdiag.cpp.i
|
||||
.PHONY : Texdiag/texdiag.cpp.i
|
||||
|
||||
Texdiag/texdiag.s: Texdiag/texdiag.cpp.s
|
||||
|
||||
.PHONY : Texdiag/texdiag.s
|
||||
|
||||
# target to generate assembly for a file
|
||||
Texdiag/texdiag.cpp.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/texdiag.dir/build.make CMakeFiles/texdiag.dir/Texdiag/texdiag.cpp.s
|
||||
.PHONY : Texdiag/texdiag.cpp.s
|
||||
|
||||
# target to build an object file
|
||||
cmake_pch.hxx.pch:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/cmake_pch.hxx.pch
|
||||
.PHONY : cmake_pch.hxx.pch
|
||||
|
||||
# target to preprocess a source file
|
||||
cmake_pch.hxx.i:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/cmake_pch.hxx.i
|
||||
.PHONY : cmake_pch.hxx.i
|
||||
|
||||
# target to generate assembly for a file
|
||||
cmake_pch.hxx.s:
|
||||
$(MAKE) $(MAKESILENT) -f CMakeFiles/DirectXTex.dir/build.make CMakeFiles/DirectXTex.dir/cmake_pch.hxx.s
|
||||
.PHONY : cmake_pch.hxx.s
|
||||
|
||||
# Help Target
|
||||
help:
|
||||
@echo "The following are some of the valid targets for this Makefile:"
|
||||
@echo "... all (the default if no target is provided)"
|
||||
@echo "... clean"
|
||||
@echo "... depend"
|
||||
@echo "... edit_cache"
|
||||
@echo "... rebuild_cache"
|
||||
@echo "... DirectXTex"
|
||||
@echo "... texassemble"
|
||||
@echo "... texconv"
|
||||
@echo "... texdiag"
|
||||
@echo "... DirectXTex/BC.o"
|
||||
@echo "... DirectXTex/BC.i"
|
||||
@echo "... DirectXTex/BC.s"
|
||||
@echo "... DirectXTex/BC4BC5.o"
|
||||
@echo "... DirectXTex/BC4BC5.i"
|
||||
@echo "... DirectXTex/BC4BC5.s"
|
||||
@echo "... DirectXTex/BC6HBC7.o"
|
||||
@echo "... DirectXTex/BC6HBC7.i"
|
||||
@echo "... DirectXTex/BC6HBC7.s"
|
||||
@echo "... DirectXTex/DirectXTexConvert.o"
|
||||
@echo "... DirectXTex/DirectXTexConvert.i"
|
||||
@echo "... DirectXTex/DirectXTexConvert.s"
|
||||
@echo "... DirectXTex/DirectXTexD3D11.o"
|
||||
@echo "... DirectXTex/DirectXTexD3D11.i"
|
||||
@echo "... DirectXTex/DirectXTexD3D11.s"
|
||||
@echo "... DirectXTex/DirectXTexD3D12.o"
|
||||
@echo "... DirectXTex/DirectXTexD3D12.i"
|
||||
@echo "... DirectXTex/DirectXTexD3D12.s"
|
||||
@echo "... DirectXTex/DirectXTexDDS.o"
|
||||
@echo "... DirectXTex/DirectXTexDDS.i"
|
||||
@echo "... DirectXTex/DirectXTexDDS.s"
|
||||
@echo "... DirectXTex/DirectXTexFlipRotate.o"
|
||||
@echo "... DirectXTex/DirectXTexFlipRotate.i"
|
||||
@echo "... DirectXTex/DirectXTexFlipRotate.s"
|
||||
@echo "... DirectXTex/DirectXTexHDR.o"
|
||||
@echo "... DirectXTex/DirectXTexHDR.i"
|
||||
@echo "... DirectXTex/DirectXTexHDR.s"
|
||||
@echo "... DirectXTex/DirectXTexImage.o"
|
||||
@echo "... DirectXTex/DirectXTexImage.i"
|
||||
@echo "... DirectXTex/DirectXTexImage.s"
|
||||
@echo "... DirectXTex/DirectXTexMipmaps.o"
|
||||
@echo "... DirectXTex/DirectXTexMipmaps.i"
|
||||
@echo "... DirectXTex/DirectXTexMipmaps.s"
|
||||
@echo "... DirectXTex/DirectXTexMisc.o"
|
||||
@echo "... DirectXTex/DirectXTexMisc.i"
|
||||
@echo "... DirectXTex/DirectXTexMisc.s"
|
||||
@echo "... DirectXTex/DirectXTexNormalMaps.o"
|
||||
@echo "... DirectXTex/DirectXTexNormalMaps.i"
|
||||
@echo "... DirectXTex/DirectXTexNormalMaps.s"
|
||||
@echo "... DirectXTex/DirectXTexPMAlpha.o"
|
||||
@echo "... DirectXTex/DirectXTexPMAlpha.i"
|
||||
@echo "... DirectXTex/DirectXTexPMAlpha.s"
|
||||
@echo "... DirectXTex/DirectXTexResize.o"
|
||||
@echo "... DirectXTex/DirectXTexResize.i"
|
||||
@echo "... DirectXTex/DirectXTexResize.s"
|
||||
@echo "... DirectXTex/DirectXTexTGA.o"
|
||||
@echo "... DirectXTex/DirectXTexTGA.i"
|
||||
@echo "... DirectXTex/DirectXTexTGA.s"
|
||||
@echo "... DirectXTex/DirectXTexUtil.o"
|
||||
@echo "... DirectXTex/DirectXTexUtil.i"
|
||||
@echo "... DirectXTex/DirectXTexUtil.s"
|
||||
@echo "... Texassemble/AnimatedGif.o"
|
||||
@echo "... Texassemble/AnimatedGif.i"
|
||||
@echo "... Texassemble/AnimatedGif.s"
|
||||
@echo "... Texassemble/texassemble.o"
|
||||
@echo "... Texassemble/texassemble.i"
|
||||
@echo "... Texassemble/texassemble.s"
|
||||
@echo "... Texconv/ExtendedBMP.o"
|
||||
@echo "... Texconv/ExtendedBMP.i"
|
||||
@echo "... Texconv/ExtendedBMP.s"
|
||||
@echo "... Texconv/PortablePixMap.o"
|
||||
@echo "... Texconv/PortablePixMap.i"
|
||||
@echo "... Texconv/PortablePixMap.s"
|
||||
@echo "... Texconv/texconv.o"
|
||||
@echo "... Texconv/texconv.i"
|
||||
@echo "... Texconv/texconv.s"
|
||||
@echo "... Texdiag/texdiag.o"
|
||||
@echo "... Texdiag/texdiag.i"
|
||||
@echo "... Texdiag/texdiag.s"
|
||||
@echo "... cmake_pch.hxx.pch"
|
||||
@echo "... cmake_pch.hxx.i"
|
||||
@echo "... cmake_pch.hxx.s"
|
||||
.PHONY : help
|
||||
|
||||
|
||||
|
||||
#=============================================================================
|
||||
# Special targets to cleanup operation of make.
|
||||
|
||||
# Special rule to run CMake to check the build system integrity.
|
||||
# No rule that depends on this can have commands that come from listfiles
|
||||
# because they might be regenerated.
|
||||
cmake_check_build_system:
|
||||
$(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 0
|
||||
.PHONY : cmake_check_build_system
|
||||
|
124
PlatformSupport/ClangBsearch.hpp
Normal file
124
PlatformSupport/ClangBsearch.hpp
Normal file
@ -0,0 +1,124 @@
|
||||
/*------------------------------------------------------------------
|
||||
* bsearch_s.c
|
||||
*
|
||||
* September 2017, Reini Urban
|
||||
*
|
||||
* Copyright (c) 2017 by Reini Urban
|
||||
* All rights reserved.
|
||||
*
|
||||
* 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.
|
||||
*------------------------------------------------------------------
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
#include <stdlib.h>
|
||||
|
||||
|
||||
/**
|
||||
* @def bsearch_s(key,base,nmemb,size,compar,context)
|
||||
* @brief
|
||||
* The \c bsearch_s function finds an element equal to element pointed to
|
||||
* by key in an array pointed to by base. The array contains count elements
|
||||
* of size bytes and must be partitioned with respect to key, that is, all
|
||||
* the elements that compare less than must appear before all the elements
|
||||
* that compare equal to, and those must appear before all the elements
|
||||
* that compare greater than the key object. A fully sorted array satisfies
|
||||
* these requirements. The elements are compared using function pointed to
|
||||
* by comp. The behavior is undefined if the array is not already
|
||||
* partitioned with respect to *key in ascending order according to the
|
||||
* same criterion that compar uses.
|
||||
*
|
||||
* @remark SPECIFIED IN
|
||||
* * C11 standard (ISO/IEC 9899:2011):
|
||||
* K.3.6.3.1 The bsearch_s function (p: 608-609)
|
||||
* http://en.cppreference.com/w/c/algorithm/bsearch
|
||||
*
|
||||
* @param[in] key pointer to the element to search for
|
||||
* @param[in] base pointer to the array to examine
|
||||
* @param[in] nmemb number of elements in the array
|
||||
* @param[in] size size of each element in the array in bytes
|
||||
* @param[in] compar comparison function which returns a negative integer
|
||||
* value if the first argument is less than the second, a
|
||||
* positive integer value if the first argument is greater
|
||||
* than the second and zero if the arguments are equal. key
|
||||
* is passed as the first argument, an element from the
|
||||
* array as the second. The signature of the comparison
|
||||
* function should be equivalent to the following: int
|
||||
* cmp(const void *a, const void *b); The function must not
|
||||
* modify the objects passed to it and must return
|
||||
* consistent results when called for the same objects,
|
||||
* regardless of their positions in the array.
|
||||
* @param[in] context additional information (e.g., collating sequence), passed
|
||||
* to compar as the third argument
|
||||
*
|
||||
* @pre key, base or compar shall not be a null pointer (unless nmemb is zero).
|
||||
* @pre nmemb or size shall not be greater than RSIZE_MAX_MEM.
|
||||
*
|
||||
* If the array contains several elements that compar would indicate as
|
||||
* equal to the element searched for, then it is unspecified which element the
|
||||
* function will return as the result.
|
||||
*
|
||||
* @return Pointer to an element in the array that compares equal to *key, or
|
||||
* null pointer if such element has not been found, or any run-time
|
||||
* constraint violation.
|
||||
*
|
||||
* @note
|
||||
* Despite the name, neither C nor POSIX standards require this function to
|
||||
* be implemented using binary search or make any complexity guarantees.
|
||||
* Unlike other bounds-checked functions, bsearch_s does not treat arrays
|
||||
* of zero size as a runtime constraint violation and instead indicates
|
||||
* element not found (the other function that accepts arrays of zero size
|
||||
* is qsort_s).
|
||||
*
|
||||
* @retval NULL when not found or any error
|
||||
*
|
||||
* errno values:
|
||||
* ESNULLP when key, base or compar are a NULL pointer, and nmemb is > 0
|
||||
* ESLEMAX when nmemb or size > RSIZE_MAX_MEM
|
||||
*
|
||||
* @see
|
||||
* qsort_s()
|
||||
*/
|
||||
|
||||
static void *
|
||||
bsearch_s(const void *key, const void *base, size_t nmemb, size_t size,
|
||||
int (*compar)(void *k, const void *key, const void *val),
|
||||
void *context)
|
||||
{
|
||||
errno = 0;
|
||||
|
||||
while (nmemb > 0) {
|
||||
void *ptry = (char *)base + size * (nmemb / 2);
|
||||
int sign = compar(context, key, ptry);
|
||||
if (!sign)
|
||||
return ptry;
|
||||
else if (nmemb == 1)
|
||||
break;
|
||||
else if (sign < 0) {
|
||||
nmemb /= 2;
|
||||
} else {
|
||||
base = ptry;
|
||||
nmemb -= nmemb / 2;
|
||||
}
|
||||
}
|
||||
return NULL;
|
||||
}
|
15
PlatformSupport/ClangCommon.hpp
Normal file
15
PlatformSupport/ClangCommon.hpp
Normal file
@ -0,0 +1,15 @@
|
||||
#pragma once
|
||||
|
||||
#include "ClangBsearch.hpp"
|
||||
|
||||
static int memcpy_s(void * dest, size_t destsz,
|
||||
const void * src, size_t count)
|
||||
{
|
||||
size_t minVal = std::min(destsz, count);
|
||||
if (count > destsz)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
std::memcpy(dest, src, minVal);
|
||||
return 0;
|
||||
}
|
2957
PlatformSupport/MSVCSal.h
Normal file
2957
PlatformSupport/MSVCSal.h
Normal file
File diff suppressed because it is too large
Load Diff
39
PlatformSupport/MSVCStubs.hpp
Normal file
39
PlatformSupport/MSVCStubs.hpp
Normal file
@ -0,0 +1,39 @@
|
||||
#include <cstdint>
|
||||
|
||||
#define __cdecl
|
||||
|
||||
typedef struct _GUID {
|
||||
unsigned long Data1;
|
||||
unsigned short Data2;
|
||||
unsigned short Data3;
|
||||
unsigned char Data4[8];
|
||||
} GUID;
|
||||
|
||||
typedef size_t HANDLE;
|
||||
|
||||
#define UNREFERENCED_PARAMETER
|
||||
|
||||
#define DEFINE_ENUM_FLAG_OPERATORS(ENUMTYPE) \
|
||||
extern "C++" { \
|
||||
inline ENUMTYPE operator | (ENUMTYPE a, ENUMTYPE b) { return ENUMTYPE(((int)a) | ((int)b)); } \
|
||||
inline ENUMTYPE &operator |= (ENUMTYPE &a, ENUMTYPE b) { return (ENUMTYPE &)(((int &)a) |= ((int)b)); } \
|
||||
inline ENUMTYPE operator & (ENUMTYPE a, ENUMTYPE b) { return ENUMTYPE(((int)a) & ((int)b)); } \
|
||||
inline ENUMTYPE &operator &= (ENUMTYPE &a, ENUMTYPE b) { return (ENUMTYPE &)(((int &)a) &= ((int)b)); } \
|
||||
inline ENUMTYPE operator ~ (ENUMTYPE a) { return ENUMTYPE(~((int)a)); } \
|
||||
inline ENUMTYPE operator ^ (ENUMTYPE a, ENUMTYPE b) { return ENUMTYPE(((int)a) ^ ((int)b)); } \
|
||||
inline ENUMTYPE &operator ^= (ENUMTYPE &a, ENUMTYPE b) { return (ENUMTYPE &)(((int &)a) ^= ((int)b)); } \
|
||||
}
|
||||
|
||||
#define ARRAYSIZE(a) \
|
||||
((sizeof(a) / sizeof(*(a))) / \
|
||||
static_cast<size_t>(!(sizeof(a) % sizeof(*(a)))))
|
||||
|
||||
#define _countof(array) (sizeof(array) / sizeof(array[0]))
|
||||
|
||||
#include "MSVCSal.h"
|
||||
|
||||
#include <stdbool.h>
|
||||
|
||||
#define BOOL int
|
||||
#define TRUE 1
|
||||
#define FALSE 0
|
173
PlatformSupport/StdFS.hpp
Normal file
173
PlatformSupport/StdFS.hpp
Normal file
@ -0,0 +1,173 @@
|
||||
#pragma once
|
||||
|
||||
template<typename T>
|
||||
class ScopedFile
|
||||
{
|
||||
public:
|
||||
|
||||
|
||||
ScopedFile(const std::string & path, bool reset = false)
|
||||
{
|
||||
init(path, reset);
|
||||
}
|
||||
|
||||
ScopedFile(const std::wstring & path, bool reset = false)
|
||||
{
|
||||
std::wstring_convert<std::codecvt_utf8<wchar_t>, wchar_t> converter;
|
||||
init(converter.to_bytes(path), reset);
|
||||
}
|
||||
|
||||
~ScopedFile()
|
||||
{
|
||||
_stream.close();
|
||||
|
||||
if (this->_temp)
|
||||
{
|
||||
DeleteFile();
|
||||
}
|
||||
}
|
||||
|
||||
virtual size_t GetLength();
|
||||
virtual void SeekBegin(size_t offset);
|
||||
virtual void DeleteFile();
|
||||
|
||||
void MakeTemp()
|
||||
{
|
||||
this->_temp = false;
|
||||
}
|
||||
|
||||
protected:
|
||||
|
||||
T _stream;
|
||||
std::string _path;
|
||||
private:
|
||||
|
||||
|
||||
void init(const std::string & path, bool reset)
|
||||
{
|
||||
this->_path = path;
|
||||
this->_temp = false;
|
||||
|
||||
if (reset)
|
||||
{
|
||||
_stream.open(path, std::ios::trunc);
|
||||
_stream.close();
|
||||
}
|
||||
|
||||
_stream.open(path, std::ios::binary);
|
||||
}
|
||||
|
||||
|
||||
bool _temp;
|
||||
};
|
||||
|
||||
class ScopedWriteFile : public ScopedFile<std::ofstream>
|
||||
{
|
||||
public:
|
||||
|
||||
ScopedWriteFile(const std::string & name, bool reset = false) : ScopedFile(name, reset)
|
||||
{
|
||||
// -
|
||||
}
|
||||
|
||||
ScopedWriteFile(const std::wstring & name, bool reset = false) : ScopedFile(name, reset)
|
||||
{
|
||||
// -
|
||||
}
|
||||
|
||||
void SeekBegin(size_t offset)
|
||||
{
|
||||
_stream.seekp(offset, std::ios_base::beg);
|
||||
}
|
||||
|
||||
size_t GetLength()
|
||||
{
|
||||
if (!_stream.is_open())
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
auto old = _stream.tellp();
|
||||
_stream.seekp(0, std::ios_base::end);
|
||||
auto ret = static_cast<size_t>(_stream.tellp());
|
||||
_stream.seekp(old, std::ios_base::beg);
|
||||
return ret;
|
||||
}
|
||||
|
||||
bool Write(const void * in, size_t length)
|
||||
{
|
||||
if (!_stream.is_open())
|
||||
{
|
||||
return false;
|
||||
}
|
||||
if (!_stream.write(reinterpret_cast<const char *>(in), length))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
void DeleteFile()
|
||||
{
|
||||
std::filesystem::remove(_path);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
class ScopedReadFile : public ScopedFile<std::ifstream>
|
||||
{
|
||||
public:
|
||||
|
||||
ScopedReadFile(const std::string & name) : ScopedFile(name, false)
|
||||
{
|
||||
// -
|
||||
}
|
||||
|
||||
ScopedReadFile(const std::wstring & name) : ScopedFile(name, false)
|
||||
{
|
||||
// -
|
||||
}
|
||||
|
||||
void SeekBegin(size_t offset)
|
||||
{
|
||||
_stream.seekg(offset, std::ios_base::beg);
|
||||
}
|
||||
|
||||
void SeekEnd(size_t offset)
|
||||
{
|
||||
_stream.seekg(offset, std::ios_base::end);
|
||||
}
|
||||
|
||||
size_t GetLength()
|
||||
{
|
||||
if (!_stream.is_open())
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
auto old = _stream.tellg();
|
||||
_stream.seekg(0, std::ios_base::end);
|
||||
auto ret = static_cast<size_t>(_stream.tellg());
|
||||
_stream.seekg(old, std::ios_base::beg);
|
||||
return ret;
|
||||
}
|
||||
|
||||
size_t Read(void * in, size_t length)
|
||||
{
|
||||
if (!_stream.is_open())
|
||||
{
|
||||
return false;
|
||||
}
|
||||
return _stream.read(reinterpret_cast<char *>(in), length) ? length : _stream.gcount();
|
||||
}
|
||||
|
||||
size_t Read(size_t length)
|
||||
{
|
||||
std::vector<uint8_t> in;
|
||||
in.resize(length);
|
||||
return Read(in.data(), length);
|
||||
}
|
||||
|
||||
void DeleteFile()
|
||||
{
|
||||
std::filesystem::remove(_path);
|
||||
}
|
||||
};
|
124
PlatformSupport/Win32DXG.hpp
Normal file
124
PlatformSupport/Win32DXG.hpp
Normal file
@ -0,0 +1,124 @@
|
||||
typedef enum DXGI_FORMAT {
|
||||
DXGI_FORMAT_UNKNOWN,
|
||||
DXGI_FORMAT_R32G32B32A32_TYPELESS,
|
||||
DXGI_FORMAT_R32G32B32A32_FLOAT,
|
||||
DXGI_FORMAT_R32G32B32A32_UINT,
|
||||
DXGI_FORMAT_R32G32B32A32_SINT,
|
||||
DXGI_FORMAT_R32G32B32_TYPELESS,
|
||||
DXGI_FORMAT_R32G32B32_FLOAT,
|
||||
DXGI_FORMAT_R32G32B32_UINT,
|
||||
DXGI_FORMAT_R32G32B32_SINT,
|
||||
DXGI_FORMAT_R16G16B16A16_TYPELESS,
|
||||
DXGI_FORMAT_R16G16B16A16_FLOAT,
|
||||
DXGI_FORMAT_R16G16B16A16_UNORM,
|
||||
DXGI_FORMAT_R16G16B16A16_UINT,
|
||||
DXGI_FORMAT_R16G16B16A16_SNORM,
|
||||
DXGI_FORMAT_R16G16B16A16_SINT,
|
||||
DXGI_FORMAT_R32G32_TYPELESS,
|
||||
DXGI_FORMAT_R32G32_FLOAT,
|
||||
DXGI_FORMAT_R32G32_UINT,
|
||||
DXGI_FORMAT_R32G32_SINT,
|
||||
DXGI_FORMAT_R32G8X24_TYPELESS,
|
||||
DXGI_FORMAT_D32_FLOAT_S8X24_UINT,
|
||||
DXGI_FORMAT_R32_FLOAT_X8X24_TYPELESS,
|
||||
DXGI_FORMAT_X32_TYPELESS_G8X24_UINT,
|
||||
DXGI_FORMAT_R10G10B10A2_TYPELESS,
|
||||
DXGI_FORMAT_R10G10B10A2_UNORM,
|
||||
DXGI_FORMAT_R10G10B10A2_UINT,
|
||||
DXGI_FORMAT_R11G11B10_FLOAT,
|
||||
DXGI_FORMAT_R8G8B8A8_TYPELESS,
|
||||
DXGI_FORMAT_R8G8B8A8_UNORM,
|
||||
DXGI_FORMAT_R8G8B8A8_UNORM_SRGB,
|
||||
DXGI_FORMAT_R8G8B8A8_UINT,
|
||||
DXGI_FORMAT_R8G8B8A8_SNORM,
|
||||
DXGI_FORMAT_R8G8B8A8_SINT,
|
||||
DXGI_FORMAT_R16G16_TYPELESS,
|
||||
DXGI_FORMAT_R16G16_FLOAT,
|
||||
DXGI_FORMAT_R16G16_UNORM,
|
||||
DXGI_FORMAT_R16G16_UINT,
|
||||
DXGI_FORMAT_R16G16_SNORM,
|
||||
DXGI_FORMAT_R16G16_SINT,
|
||||
DXGI_FORMAT_R32_TYPELESS,
|
||||
DXGI_FORMAT_D32_FLOAT,
|
||||
DXGI_FORMAT_R32_FLOAT,
|
||||
DXGI_FORMAT_R32_UINT,
|
||||
DXGI_FORMAT_R32_SINT,
|
||||
DXGI_FORMAT_R24G8_TYPELESS,
|
||||
DXGI_FORMAT_D24_UNORM_S8_UINT,
|
||||
DXGI_FORMAT_R24_UNORM_X8_TYPELESS,
|
||||
DXGI_FORMAT_X24_TYPELESS_G8_UINT,
|
||||
DXGI_FORMAT_R8G8_TYPELESS,
|
||||
DXGI_FORMAT_R8G8_UNORM,
|
||||
DXGI_FORMAT_R8G8_UINT,
|
||||
DXGI_FORMAT_R8G8_SNORM,
|
||||
DXGI_FORMAT_R8G8_SINT,
|
||||
DXGI_FORMAT_R16_TYPELESS,
|
||||
DXGI_FORMAT_R16_FLOAT,
|
||||
DXGI_FORMAT_D16_UNORM,
|
||||
DXGI_FORMAT_R16_UNORM,
|
||||
DXGI_FORMAT_R16_UINT,
|
||||
DXGI_FORMAT_R16_SNORM,
|
||||
DXGI_FORMAT_R16_SINT,
|
||||
DXGI_FORMAT_R8_TYPELESS,
|
||||
DXGI_FORMAT_R8_UNORM,
|
||||
DXGI_FORMAT_R8_UINT,
|
||||
DXGI_FORMAT_R8_SNORM,
|
||||
DXGI_FORMAT_R8_SINT,
|
||||
DXGI_FORMAT_A8_UNORM,
|
||||
DXGI_FORMAT_R1_UNORM,
|
||||
DXGI_FORMAT_R9G9B9E5_SHAREDEXP,
|
||||
DXGI_FORMAT_R8G8_B8G8_UNORM,
|
||||
DXGI_FORMAT_G8R8_G8B8_UNORM,
|
||||
DXGI_FORMAT_BC1_TYPELESS,
|
||||
DXGI_FORMAT_BC1_UNORM,
|
||||
DXGI_FORMAT_BC1_UNORM_SRGB,
|
||||
DXGI_FORMAT_BC2_TYPELESS,
|
||||
DXGI_FORMAT_BC2_UNORM,
|
||||
DXGI_FORMAT_BC2_UNORM_SRGB,
|
||||
DXGI_FORMAT_BC3_TYPELESS,
|
||||
DXGI_FORMAT_BC3_UNORM,
|
||||
DXGI_FORMAT_BC3_UNORM_SRGB,
|
||||
DXGI_FORMAT_BC4_TYPELESS,
|
||||
DXGI_FORMAT_BC4_UNORM,
|
||||
DXGI_FORMAT_BC4_SNORM,
|
||||
DXGI_FORMAT_BC5_TYPELESS,
|
||||
DXGI_FORMAT_BC5_UNORM,
|
||||
DXGI_FORMAT_BC5_SNORM,
|
||||
DXGI_FORMAT_B5G6R5_UNORM,
|
||||
DXGI_FORMAT_B5G5R5A1_UNORM,
|
||||
DXGI_FORMAT_B8G8R8A8_UNORM,
|
||||
DXGI_FORMAT_B8G8R8X8_UNORM,
|
||||
DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM,
|
||||
DXGI_FORMAT_B8G8R8A8_TYPELESS,
|
||||
DXGI_FORMAT_B8G8R8A8_UNORM_SRGB,
|
||||
DXGI_FORMAT_B8G8R8X8_TYPELESS,
|
||||
DXGI_FORMAT_B8G8R8X8_UNORM_SRGB,
|
||||
DXGI_FORMAT_BC6H_TYPELESS,
|
||||
DXGI_FORMAT_BC6H_UF16,
|
||||
DXGI_FORMAT_BC6H_SF16,
|
||||
DXGI_FORMAT_BC7_TYPELESS,
|
||||
DXGI_FORMAT_BC7_UNORM,
|
||||
DXGI_FORMAT_BC7_UNORM_SRGB,
|
||||
DXGI_FORMAT_AYUV,
|
||||
DXGI_FORMAT_Y410,
|
||||
DXGI_FORMAT_Y416,
|
||||
DXGI_FORMAT_NV12,
|
||||
DXGI_FORMAT_P010,
|
||||
DXGI_FORMAT_P016,
|
||||
DXGI_FORMAT_420_OPAQUE,
|
||||
DXGI_FORMAT_YUY2,
|
||||
DXGI_FORMAT_Y210,
|
||||
DXGI_FORMAT_Y216,
|
||||
DXGI_FORMAT_NV11,
|
||||
DXGI_FORMAT_AI44,
|
||||
DXGI_FORMAT_IA44,
|
||||
DXGI_FORMAT_P8,
|
||||
DXGI_FORMAT_A8P8,
|
||||
DXGI_FORMAT_B4G4R4A4_UNORM,
|
||||
DXGI_FORMAT_P208,
|
||||
DXGI_FORMAT_V208,
|
||||
DXGI_FORMAT_V408,
|
||||
DXGI_FORMAT_SAMPLER_FEEDBACK_MIN_MIP_OPAQUE,
|
||||
DXGI_FORMAT_SAMPLER_FEEDBACK_MIP_REGION_USED_OPAQUE,
|
||||
DXGI_FORMAT_FORCE_UINT
|
||||
} ;
|
76
PlatformSupport/Win32Errors.hpp
Normal file
76
PlatformSupport/Win32Errors.hpp
Normal file
@ -0,0 +1,76 @@
|
||||
#pragma once
|
||||
|
||||
#include <cinttypes>
|
||||
|
||||
using HRESULT = LONG;
|
||||
using WORD = int16_t;
|
||||
using DWORD = uint32_t;
|
||||
using UINT = uint32_t;
|
||||
using INT = int32_t;
|
||||
|
||||
#define FACILITY_WIN32 7
|
||||
|
||||
#define SEVERITY_SUCCESS 0
|
||||
#define SEVERITY_ERROR 1
|
||||
|
||||
#define __HRESULT_FROM_WIN32(x) ((HRESULT)(x) <= 0 ? ((HRESULT)(x)) : ((HRESULT) (((x) & 0x0000FFFF) | (FACILITY_WIN32 << 16) | 0x80000000)))
|
||||
#define HRESULT_FROM_WIN32(x) __HRESULT_FROM_WIN32(x)
|
||||
|
||||
#define FAILED(hr) (((HRESULT)(hr)) < 0)
|
||||
#define IS_ERROR(Status) (((unsigned long)(Status)) >> 31 == SEVERITY_ERROR)
|
||||
|
||||
#define S_OK ((HRESULT)0)
|
||||
#define S_FALSE ((HRESULT)1L)
|
||||
#define E_UNEXPECTED ((HRESULT)(0x8000FFFFL))
|
||||
#define E_NOTIMPL ((HRESULT)(0x80004001L))
|
||||
#define E_OUTOFMEMORY ((HRESULT)(0x8007000EL))
|
||||
#define E_INVALIDARG ((HRESULT)(0x80070057L))
|
||||
#define E_NOINTERFACE ((HRESULT)(0x80004002L))
|
||||
#define E_POINTER ((HRESULT)(0x80004003L))
|
||||
#define E_HANDLE ((HRESULT)(0x80070006L))
|
||||
#define E_ABORT ((HRESULT)(0x80004004L))
|
||||
#define E_FAIL ((HRESULT)(0x80004005L))
|
||||
#define E_ACCESSDENIED ((HRESULT)(0x80070005L))
|
||||
#define E_PENDING ((HRESULT)(0x8000000AL))
|
||||
|
||||
#define ERROR_ACCESS_DENIED 5
|
||||
#define ERROR_INVALID_HANDLE 6
|
||||
#define ERROR_OUTOFMEMORY 14
|
||||
#define ERROR_NOT_SUPPORTED 50
|
||||
#define ERROR_INVALID_PARAMETER 87
|
||||
#define ERROR_CALL_NOT_IMPLEMENTED 120
|
||||
#define ERROR_INVALID_NAME 123
|
||||
#define ERROR_MOD_NOT_FOUND 126
|
||||
#define ERROR_NO_MORE_ITEMS 259
|
||||
#define ERROR_INVALID_ADDRESS 487
|
||||
|
||||
#define ERROR_ARITHMETIC_OVERFLOW 534
|
||||
|
||||
|
||||
#define ERROR_SUCCESS 0
|
||||
#define ERROR_INVALID_FUNCTION 1
|
||||
#define ERROR_FILE_NOT_FOUND 2
|
||||
#define ERROR_PATH_NOT_FOUND 3
|
||||
#define ERROR_TOO_MANY_OPEN_FILES 4
|
||||
#define ERROR_ACCESS_DENIED 5
|
||||
#define ERROR_INVALID_HANDLE 6
|
||||
#define ERROR_ARENA_TRASHED 7
|
||||
#define ERROR_NOT_ENOUGH_MEMORY 8
|
||||
#define ERROR_INVALID_BLOCK 9
|
||||
#define ERROR_BAD_ENVIRONMENT 10
|
||||
#define ERROR_BAD_FORMAT 11
|
||||
#define ERROR_INVALID_ACCESS 12
|
||||
#define ERROR_INVALID_DATA 13
|
||||
#define ERROR_OUTOFMEMORY 14
|
||||
|
||||
#define ERROR_FILE_EXISTS 80
|
||||
#define ERROR_CANNOT_MAKE 82
|
||||
|
||||
#define ERROR_INSUFFICIENT_BUFFER 122
|
||||
#define ERROR_INVALID_STATE 5023
|
||||
#define ERROR_FILE_TOO_LARGE 223
|
||||
#define ERROR_HANDLE_EOF 38
|
||||
#define ERROR_FILE_TOO_LARGE 223
|
||||
|
||||
#define E_NOT_SUFFICIENT_BUFFER HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER)
|
||||
#define E_NOT_VALID_STATE HRESULT_FROM_WIN32(ERROR_INVALID_STATE)
|
7
PlatformSupport/Win32Public.hpp
Normal file
7
PlatformSupport/Win32Public.hpp
Normal file
@ -0,0 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#if defined(_DXTX_NOWIN)
|
||||
using LONG = size_t;
|
||||
#include "Win32DXG.hpp"
|
||||
#include "Win32Errors.hpp"
|
||||
#endif
|
54
cmake_install.cmake
Normal file
54
cmake_install.cmake
Normal file
@ -0,0 +1,54 @@
|
||||
# Install script for directory: /run/media/reece/Misc/GameEngine/Master/Public/DirectXTex
|
||||
|
||||
# Set the install prefix
|
||||
if(NOT DEFINED CMAKE_INSTALL_PREFIX)
|
||||
set(CMAKE_INSTALL_PREFIX "/usr/local")
|
||||
endif()
|
||||
string(REGEX REPLACE "/$" "" CMAKE_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}")
|
||||
|
||||
# Set the install configuration name.
|
||||
if(NOT DEFINED CMAKE_INSTALL_CONFIG_NAME)
|
||||
if(BUILD_TYPE)
|
||||
string(REGEX REPLACE "^[^A-Za-z0-9_]+" ""
|
||||
CMAKE_INSTALL_CONFIG_NAME "${BUILD_TYPE}")
|
||||
else()
|
||||
set(CMAKE_INSTALL_CONFIG_NAME "")
|
||||
endif()
|
||||
message(STATUS "Install configuration: \"${CMAKE_INSTALL_CONFIG_NAME}\"")
|
||||
endif()
|
||||
|
||||
# Set the component getting installed.
|
||||
if(NOT CMAKE_INSTALL_COMPONENT)
|
||||
if(COMPONENT)
|
||||
message(STATUS "Install component: \"${COMPONENT}\"")
|
||||
set(CMAKE_INSTALL_COMPONENT "${COMPONENT}")
|
||||
else()
|
||||
set(CMAKE_INSTALL_COMPONENT)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Install shared libraries without execute permission?
|
||||
if(NOT DEFINED CMAKE_INSTALL_SO_NO_EXE)
|
||||
set(CMAKE_INSTALL_SO_NO_EXE "0")
|
||||
endif()
|
||||
|
||||
# Is this installation the result of a crosscompile?
|
||||
if(NOT DEFINED CMAKE_CROSSCOMPILING)
|
||||
set(CMAKE_CROSSCOMPILING "FALSE")
|
||||
endif()
|
||||
|
||||
# Set default install directory permissions.
|
||||
if(NOT DEFINED CMAKE_OBJDUMP)
|
||||
set(CMAKE_OBJDUMP "/usr/bin/objdump")
|
||||
endif()
|
||||
|
||||
if(CMAKE_INSTALL_COMPONENT)
|
||||
set(CMAKE_INSTALL_MANIFEST "install_manifest_${CMAKE_INSTALL_COMPONENT}.txt")
|
||||
else()
|
||||
set(CMAKE_INSTALL_MANIFEST "install_manifest.txt")
|
||||
endif()
|
||||
|
||||
string(REPLACE ";" "\n" CMAKE_INSTALL_MANIFEST_CONTENT
|
||||
"${CMAKE_INSTALL_MANIFEST_FILES}")
|
||||
file(WRITE "/run/media/reece/Misc/GameEngine/Master/Public/DirectXTex/${CMAKE_INSTALL_MANIFEST}"
|
||||
"${CMAKE_INSTALL_MANIFEST_CONTENT}")
|
Loading…
Reference in New Issue
Block a user