Files
LGram16 dd97ddec92 Restructure repository to include all source folders
Move git root from Client/ to src/ to track all source code:
- Client: Game client source (moved to Client/Client/)
- Server: Game server source
- GameTools: Development tools
- CryptoSource: Encryption utilities
- database: Database scripts
- Script: Game scripts
- rylCoder_16.02.2008_src: Legacy coder tools
- GMFont, Game: Additional resources

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-29 20:17:20 +09:00

96 lines
3.1 KiB
C++

// EnumD3D.h: interface for the CEnumD3D class.
//
//////////////////////////////////////////////////////////////////////
#if !defined(AFX_ENUMD3D_H__9D5F8359_25F1_49DD_8C6A_CADE38529740__INCLUDED_)
#define AFX_ENUMD3D_H__9D5F8359_25F1_49DD_8C6A_CADE38529740__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include <d3d8.h>
#include "List.h"
//-----------------------------------------------------------------------------
// Name: struct D3DModeInfo
// Desc: Structure for holding information about a display mode
//-----------------------------------------------------------------------------
struct D3DModeInfo
{
DWORD Width; // Screen width in this mode
DWORD Height; // Screen height in this mode
D3DFORMAT Format; // Pixel format in this mode
DWORD dwBehavior; // Hardware / Software / Mixed vertex processing
D3DFORMAT DepthStencilFormat; // Which depth/stencil format to use with this mode
};
//-----------------------------------------------------------------------------
// Name: struct D3DDeviceInfo
// Desc: Structure for holding information about a Direct3D device, including
// a list of modes compatible with this device
//-----------------------------------------------------------------------------
struct D3DDeviceInfo
{
// Device data
D3DDEVTYPE DeviceType; // Reference, HAL, etc.
D3DCAPS8 d3dCaps; // Capabilities of this device
const TCHAR* strDesc; // Name of this device
BOOL bCanDoWindowed; // Whether this device can work in windowed mode
// Modes for this device
DWORD dwNumModes;
D3DModeInfo modes[150];
// Current state
DWORD dwCurrentMode;
BOOL bWindowed;
D3DMULTISAMPLE_TYPE MultiSampleType;
};
//-----------------------------------------------------------------------------
// Name: struct D3DAdapterInfo
// Desc: Structure for holding information about an adapter, including a list
// of devices available on this adapter
//-----------------------------------------------------------------------------
struct D3DAdapterInfo
{
// Adapter data
D3DADAPTER_IDENTIFIER8 d3dAdapterIdentifier;
D3DDISPLAYMODE d3ddmDesktop; // Desktop display mode for this adapter
// Devices for this adapter
DWORD dwNumDevices;
D3DDeviceInfo devices[5];
// Current state
DWORD dwCurrentDevice;
};
class CEnumD3D
{
static BOOL m_bWindowed;
static long m_dwMinDepthBits;
static long m_dwMinStencilBits;
public:
static long m_nAdapter,m_nDevice,m_nMode;
static LPDIRECT3D8 m_pD3D;
static DWORD m_dwNumAdapters;
static BOOL m_bUseDepthBuffer;
static DWORD m_dwAdapter;
static D3DAdapterInfo m_Adapters[10];
static HRESULT ConfirmDevice(D3DCAPS8*,DWORD,D3DFORMAT);
static BOOL FindDepthStencilFormat(UINT iAdapter, D3DDEVTYPE DeviceType, D3DFORMAT TargetFormat, D3DFORMAT *pDepthStencilFormat);
static HRESULT Enum();
CEnumD3D();
virtual ~CEnumD3D();
};
#endif // !defined(AFX_ENUMD3D_H__9D5F8359_25F1_49DD_8C6A_CADE38529740__INCLUDED_)