mirror of
https://github.com/hedge-dev/XenosRecomp.git
synced 2025-10-30 07:12:17 +00:00
* Specialization constant & DXIL library implementation. * Fix alpha to coverage. * Add reverse Z implementation. * Avoid dynamic branches when loading array constants. * Remove "has bone" specialization constant. * Integrate smol-v.
37 lines
609 B
C++
37 lines
609 B
C++
#pragma once
|
|
|
|
#include <Windows.h>
|
|
#include <dxcapi.h>
|
|
|
|
#include <bit>
|
|
#include <cassert>
|
|
#include <cstdint>
|
|
#include <execution>
|
|
#include <filesystem>
|
|
#include <print>
|
|
#include <format>
|
|
#include <map>
|
|
#include <string>
|
|
#include <unordered_map>
|
|
#include <xxhash.h>
|
|
#include <zstd.h>
|
|
#include <smolv.h>
|
|
|
|
template<typename T>
|
|
struct be
|
|
{
|
|
T value;
|
|
|
|
T get() const
|
|
{
|
|
if constexpr (std::is_enum_v<T>)
|
|
return T(std::byteswap(std::underlying_type_t<T>(value)));
|
|
else
|
|
return std::byteswap(value);
|
|
}
|
|
|
|
operator T() const
|
|
{
|
|
return get();
|
|
}
|
|
};
|