Fixed some lingering use of Win32 types

This commit is contained in:
Chuck Walbourn 2020-02-24 22:11:22 -08:00
parent 821b7c7ef5
commit 11211b08d6
7 changed files with 23 additions and 23 deletions

View File

@ -143,7 +143,7 @@ namespace DirectX
_In_reads_opt_(nFaces*3) const float *pIMTArray,
_In_opt_ std::function<HRESULT __cdecl(float percentComplete)> statusCallBack,
_In_ float callbackFrequency,
_In_ DWORD options,
_In_ unsigned int options,
_Inout_ std::vector<UVAtlasVertex>& vMeshOutVertexBuffer,
_Inout_ std::vector<uint8_t>& vMeshOutIndexBuffer,
_Inout_opt_ std::vector<uint32_t>* pvFacePartitioning = nullptr,
@ -189,7 +189,7 @@ namespace DirectX
_In_reads_opt_(nFaces*3) const float *pIMTArray,
_In_opt_ std::function<HRESULT __cdecl(float percentComplete)> statusCallBack,
_In_ float callbackFrequency,
_In_ DWORD options,
_In_ unsigned int options,
_Inout_ std::vector<UVAtlasVertex>& vMeshOutVertexBuffer,
_Inout_ std::vector<uint8_t>& vMeshOutIndexBuffer,
_Inout_opt_ std::vector<uint32_t>* pvFacePartitioning,
@ -307,7 +307,7 @@ namespace DirectX
_In_reads_(width*height*4) const float* pTexture,
_In_ size_t width,
_In_ size_t height,
_In_ DWORD options,
_In_ unsigned int options,
_In_opt_ std::function<HRESULT __cdecl(float percentComplete)> statusCallBack,
_Out_writes_(nFaces * 3) float* pIMTArray) noexcept;
@ -334,7 +334,7 @@ namespace DirectX
_In_ size_t height,
_In_ size_t signalDimension,
_In_ size_t nComponents,
_In_ DWORD options,
_In_ unsigned int options,
_In_opt_ std::function<HRESULT __cdecl(float percentComplete)> statusCallBack,
_Out_writes_(nFaces * 3) float* pIMTArray) noexcept;

View File

@ -253,7 +253,7 @@ namespace
_In_reads_opt_(nFaces * 3) const float *pIMTArray,
_In_opt_ LPISOCHARTCALLBACK statusCallBack,
_In_ float callbackFrequency,
_In_ DWORD options,
_In_ unsigned int options,
_Inout_ std::vector<UVAtlasVertex>& vMeshOutVertexBuffer,
_Inout_ std::vector<uint8_t>& vMeshOutIndexBuffer,
_Inout_opt_ std::vector<uint32_t> *pvFacePartitioning,
@ -579,7 +579,7 @@ HRESULT __cdecl DirectX::UVAtlasPartition(
const float *pIMTArray,
std::function<HRESULT __cdecl(float percentComplete)> statusCallBack,
float callbackFrequency,
DWORD options,
unsigned int options,
std::vector<UVAtlasVertex>& vMeshOutVertexBuffer,
std::vector<uint8_t>& vMeshOutIndexBuffer,
std::vector<uint32_t>* pvFacePartitioning,
@ -660,7 +660,7 @@ HRESULT __cdecl DirectX::UVAtlasCreate(
const float *pIMTArray,
std::function<HRESULT __cdecl(float percentComplete)> statusCallBack,
float callbackFrequency,
DWORD options,
unsigned int options,
std::vector<UVAtlasVertex>& vMeshOutVertexBuffer,
std::vector<uint8_t>& vMeshOutIndexBuffer,
std::vector<uint32_t>* pvFacePartitioning,
@ -1239,7 +1239,7 @@ HRESULT __cdecl DirectX::UVAtlasComputeIMTFromTexture(
const float* pTexture,
size_t width,
size_t height,
DWORD options,
unsigned int options,
std::function<HRESULT __cdecl(float percentComplete)> statusCallBack,
float* pIMTArray) noexcept
{
@ -1642,7 +1642,7 @@ HRESULT __cdecl DirectX::UVAtlasComputeIMTFromPerTexelSignal(
size_t height,
size_t signalDimension,
size_t nComponents,
DWORD options,
unsigned int options,
std::function<HRESULT __cdecl(float percentComplete)> statusCallBack,
float* pIMTArray) noexcept
{
@ -1826,7 +1826,7 @@ HRESULT __cdecl DirectX::UVAtlasApplyRemap(
//-------------------------------------------------------------------------------------
#ifdef _DEBUG
_Use_decl_annotations_
void __cdecl UVAtlasDebugPrintf(unsigned int lvl, LPCSTR szFormat, ...)
void __cdecl UVAtlasDebugPrintf(unsigned int lvl, const char* szFormat, ...)
{
if (lvl > 0)
{

View File

@ -36,7 +36,7 @@ namespace
float* pMaxStretchOut,
LPISOCHARTCALLBACK pCallback,
float Frequency,
DWORD dwOptions)
unsigned int dwOptions)
{
if (!CheckInitializeParameters(
pVertexArray,
@ -175,7 +175,7 @@ HRESULT Isochart::isochart(
float* pMaxStretchOut,
LPISOCHARTCALLBACK pCallback,
float Frequency,
DWORD dwOptions)
unsigned int dwOptions)
{
// 1. Check input parameter
if (!CheckIsochartInput(
@ -311,7 +311,7 @@ HRESULT Isochart::isochartpartition(
LPISOCHARTCALLBACK pCallback,
float Frequency,
const uint32_t* pSplitHint,
DWORD dwOptions)
unsigned int dwOptions)
{
unsigned int dwTotalStage = STAGE_TOTAL(Stage);
unsigned int dwDoneStage = STAGE_DONE(Stage);

View File

@ -47,7 +47,7 @@ enum ISOCHARTOPTION
// all internal geodesic distance computation tries to use the new approach implemented in geodesicdist.lib (except IMT is specified), this is precise but slower
_OPTION_ISOCHART_GEODESIC_QUALITY = 0x02
};
const DWORD _OPTIONMASK_ISOCHART_GEODESIC = _OPTION_ISOCHART_GEODESIC_FAST | _OPTION_ISOCHART_GEODESIC_QUALITY ;
const unsigned int _OPTIONMASK_ISOCHART_GEODESIC = _OPTION_ISOCHART_GEODESIC_FAST | _OPTION_ISOCHART_GEODESIC_QUALITY ;
HRESULT
isochart(
@ -72,7 +72,7 @@ isochart(
// Callback parameters
LPISOCHARTCALLBACK pCallback = nullptr,
float Frequency = 0.01f, // Call callback function each time completed 1% work of all task
DWORD dwOptions = _OPTION_ISOCHART_DEFAULT );
unsigned int dwOptions = _OPTION_ISOCHART_DEFAULT );
HRESULT
isochartpartition(
@ -102,7 +102,7 @@ isochartpartition(
// CAN be splitted, set the that ajacency to -1.
// Usually, it's easier for user to specified the edge that CAN NOT be
// splitted, make sure to validate the input
_In_ DWORD dwOptions =_OPTION_ISOCHART_DEFAULT );
_In_ unsigned int dwOptions =_OPTION_ISOCHART_DEFAULT );
// Class IIsochartEngine for the advanced usage
@ -126,7 +126,7 @@ public:
const FLOAT3* pIMTArray,
const uint32_t* pOriginalAjacency,
const uint32_t* pSplitHint,
DWORD dwOptions) noexcept = 0;
unsigned int dwOptions) noexcept = 0;
virtual HRESULT Free() noexcept = 0;

View File

@ -90,7 +90,7 @@ HRESULT CIsochartEngine::Initialize(
const FLOAT3* pIMTArray,
const uint32_t* pOriginalAjacency,
const uint32_t* pSplitHint,
DWORD dwOptions) noexcept
unsigned int dwOptions) noexcept
{
DPF(1, "Initialize...");
@ -1827,7 +1827,7 @@ bool Isochart::CheckInitializeParameters(
const void* pFaceIndexArray,
size_t FaceCount,
const FLOAT3* pIMTArray,
DWORD dwOptions)
unsigned int dwOptions)
{
UNREFERENCED_PARAMETER(VertexCount);
UNREFERENCED_PARAMETER(FaceCount);

View File

@ -36,7 +36,7 @@ public:
const FLOAT3* pIMTArray,
const uint32_t* pOriginalAjacency,
const uint32_t* pSplitHint,
DWORD dwOptions) noexcept override;
unsigned int dwOptions) noexcept override;
virtual HRESULT Free() noexcept override;
@ -242,7 +242,7 @@ private:
HANDLE m_hMutex; // Mutex
DWORD m_dwOptions ;
unsigned int m_dwOptions ;
friend CIsochartMesh ;
};
@ -258,7 +258,7 @@ bool CheckInitializeParameters(
const void* pFaceIndexArray,
size_t FaceCount,
const FLOAT3* pIMTArray,
DWORD dwOptions);
unsigned int dwOptions);
// Check Partition parameters
bool CheckPartitionParameters(

View File

@ -87,7 +87,7 @@
#include "UVAtlas.h"
#ifdef _DEBUG
extern void __cdecl UVAtlasDebugPrintf(unsigned int lvl, _In_z_ _Printf_format_string_ LPCSTR szFormat, ...);
extern void __cdecl UVAtlasDebugPrintf(unsigned int lvl, _In_z_ _Printf_format_string_ const char* szFormat, ...);
#define DPF UVAtlasDebugPrintf
#else
#define DPF(...)