Skip to content

Trim all trailing whitespace from source #7

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 9, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
400 changes: 200 additions & 200 deletions C++/DXUT/Core/DXUT.cpp

Large diffs are not rendered by default.

40 changes: 20 additions & 20 deletions C++/DXUT/Core/DXUT.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
#define _WIN32_WINNT 0x0600
#endif

// #define DXUT_AUTOLIB to automatically include the libs needed for DXUT
// #define DXUT_AUTOLIB to automatically include the libs needed for DXUT
#ifdef DXUT_AUTOLIB
#pragma comment( lib, "dxerr.lib" )
#pragma comment( lib, "dxguid.lib" )
Expand All @@ -47,8 +47,8 @@

#pragma warning( disable : 4100 ) // disable unreference formal parameter warnings for /W4 builds

// Enable extra D3D debugging in debug builds if using the debug DirectX runtime.
// This makes D3D objects work well in the debugger watch window, but slows down
// Enable extra D3D debugging in debug builds if using the debug DirectX runtime.
// This makes D3D objects work well in the debugger watch window, but slows down
// performance slightly.
#if defined(DEBUG) || defined(_DEBUG)
#ifndef D3D_DEBUG_INFO
Expand All @@ -62,12 +62,12 @@
#include <assert.h>
#include <wchar.h>
#include <mmsystem.h>
#include <commctrl.h> // for InitCommonControls()
#include <commctrl.h> // for InitCommonControls()
#include <shellapi.h> // for ExtractIcon()
#include <new.h> // for placement new
#include <shlobj.h>
#include <math.h>
#include <limits.h>
#include <math.h>
#include <limits.h>
#include <stdio.h>

// CRT's memory leak detection
Expand All @@ -90,7 +90,7 @@
// XInput includes
#include <xinput.h>

// HRESULT translation for Direct3D and other APIs
// HRESULT translation for Direct3D and other APIs
#include "dxerr.h"


Expand All @@ -112,10 +112,10 @@

#ifndef SAFE_DELETE
#define SAFE_DELETE(p) { if (p) { delete (p); (p)=NULL; } }
#endif
#endif
#ifndef SAFE_DELETE_ARRAY
#define SAFE_DELETE_ARRAY(p) { if (p) { delete[] (p); (p)=NULL; } }
#endif
#endif
#ifndef SAFE_RELEASE
#define SAFE_RELEASE(p) { if (p) { (p)->Release(); (p)=NULL; } }
#endif
Expand Down Expand Up @@ -173,7 +173,7 @@ struct DXUTDeviceSettings
#define DXUTERR_DEVICEREMOVED MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x090A)

//--------------------------------------------------------------------------------------
// Callback registration
// Callback registration
//--------------------------------------------------------------------------------------

// General callbacks
Expand Down Expand Up @@ -229,13 +229,13 @@ void WINAPI DXUTSetCallbackD3D10DeviceDestroyed( LPDXUTCALLBACKD3D10DEVICEDESTRO
//--------------------------------------------------------------------------------------
// Initialization
//--------------------------------------------------------------------------------------
HRESULT WINAPI DXUTInit( bool bParseCommandLine = true,
bool bShowMsgBoxOnError = true,
__in_opt WCHAR* strExtraCommandLineParams = NULL,
HRESULT WINAPI DXUTInit( bool bParseCommandLine = true,
bool bShowMsgBoxOnError = true,
__in_opt WCHAR* strExtraCommandLineParams = NULL,
bool bThreadSafeDXUT = false );

// Choose either DXUTCreateWindow or DXUTSetWindow. If using DXUTSetWindow, consider using DXUTStaticWndProc
HRESULT WINAPI DXUTCreateWindow( const WCHAR* strWindowTitle = L"Direct3D Window",
HRESULT WINAPI DXUTCreateWindow( const WCHAR* strWindowTitle = L"Direct3D Window",
HINSTANCE hInstance = NULL, HICON hIcon = NULL, HMENU hMenu = NULL,
int x = CW_USEDEFAULT, int y = CW_USEDEFAULT );
HRESULT WINAPI DXUTSetWindow( HWND hWndFocus, HWND hWndDeviceFullScreen, HWND hWndDeviceWindowed, bool bHandleMessages = true );
Expand All @@ -247,15 +247,15 @@ HRESULT WINAPI DXUTCreateDeviceFromSettings( DXUTDeviceSettings* pDeviceSettings
HRESULT WINAPI DXUTSetD3D9Device( IDirect3DDevice9* pd3dDevice );
HRESULT WINAPI DXUTSetD3D10Device( ID3D10Device* pd3dDevice, IDXGISwapChain* pSwapChain );

// Choose either DXUTMainLoop or implement your own main loop
// Choose either DXUTMainLoop or implement your own main loop
HRESULT WINAPI DXUTMainLoop( HACCEL hAccel = NULL );

// If not using DXUTMainLoop consider using DXUTRender3DEnvironment
void WINAPI DXUTRender3DEnvironment();
void WINAPI DXUTRender3DEnvironment();


//--------------------------------------------------------------------------------------
// Common Tasks
// Common Tasks
//--------------------------------------------------------------------------------------
HRESULT WINAPI DXUTToggleFullScreen();
HRESULT WINAPI DXUTToggleREF();
Expand All @@ -276,7 +276,7 @@ void WINAPI DXUTSetIsInGammaCorrectMode( bool bGammaCorrect );


//--------------------------------------------------------------------------------------
// State Retrieval
// State Retrieval
//--------------------------------------------------------------------------------------

// Direct3D 9
Expand All @@ -302,7 +302,7 @@ bool WINAPI DXUTDoesAppSupportD3D10();
bool WINAPI DXUTIsAppRenderingWithD3D10();

// General
DXUTDeviceSettings WINAPI DXUTGetDeviceSettings();
DXUTDeviceSettings WINAPI DXUTGetDeviceSettings();
HINSTANCE WINAPI DXUTGetHINSTANCE();
HWND WINAPI DXUTGetHWND();
HWND WINAPI DXUTGetHWNDFocus();
Expand Down Expand Up @@ -333,7 +333,7 @@ bool WINAPI DXUTIsKeyDown( BYTE vKey ); // Pass a virtual-key code, ex. VK_
bool WINAPI DXUTWasKeyPressed( BYTE vKey ); // Like DXUTIsKeyDown() but return true only if the key was just pressed
bool WINAPI DXUTIsMouseButtonDown( BYTE vButton ); // Pass a virtual-key code: VK_LBUTTON, VK_RBUTTON, VK_MBUTTON, VK_XBUTTON1, VK_XBUTTON2
HRESULT WINAPI DXUTCreateState(); // Optional method to create DXUT's memory. If its not called by the application it will be automatically called when needed
void WINAPI DXUTDestroyState(); // Optional method to destroy DXUT's memory. If its not called by the application it will be automatically called after the application exits WinMain
void WINAPI DXUTDestroyState(); // Optional method to destroy DXUT's memory. If its not called by the application it will be automatically called after the application exits WinMain

//--------------------------------------------------------------------------------------
// DXUT core layer includes
Expand Down
Loading