mirror of
https://github.com/isledecomp/isle-portable.git
synced 2024-11-15 03:24:59 -05:00
include directx 5 sdk
This is almost certainly abandonware, fairly small (<1MB), and is going to save us a lot of dev environment headaches
This commit is contained in:
parent
67816d5213
commit
b59d8ef5cf
31 changed files with 14476 additions and 64 deletions
28
.github/workflows/build.yml
vendored
28
.github/workflows/build.yml
vendored
|
@ -14,34 +14,6 @@ jobs:
|
|||
repository: 'itsmattkc/msvc420'
|
||||
path: msvc420
|
||||
|
||||
- name: Restore cached DX5 SDK
|
||||
id: cache-dx5
|
||||
uses: actions/cache/restore@v3
|
||||
with:
|
||||
path: dx5sdk
|
||||
key: dx5sdk
|
||||
|
||||
- name: Download DX5 SDK
|
||||
if: ${{ !steps.cache-dx5.outputs.cache-hit }}
|
||||
run: |
|
||||
cd dx5sdk
|
||||
curl -fLOSs https://archive.org/download/idx5sdk/idx5sdk.exe
|
||||
7z x .\idx5sdk.exe
|
||||
7z x .\DX5SDK.EXE
|
||||
|
||||
- name: Cache DX5 SDK
|
||||
if: ${{ !steps.cache-dx5.outputs.cache-hit }}
|
||||
uses: actions/cache/save@v3
|
||||
with:
|
||||
path: dx5sdk
|
||||
key: dx5sdk
|
||||
|
||||
- name: Setup DX5 SDK
|
||||
run: |
|
||||
cd dx5sdk
|
||||
cd cdrom
|
||||
.\SETUP.EXE /s
|
||||
|
||||
- name: Setup cmake
|
||||
uses: jwlawson/actions-setup-cmake@v1.13
|
||||
with:
|
||||
|
|
896
3rdparty/dx5/inc/d3d.h
vendored
Normal file
896
3rdparty/dx5/inc/d3d.h
vendored
Normal file
|
@ -0,0 +1,896 @@
|
|||
/*==========================================================================;
|
||||
*
|
||||
* Copyright (C) 1995-1997 Microsoft Corporation. All Rights Reserved.
|
||||
*
|
||||
* File: d3d.h
|
||||
* Content: Direct3D include file
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _D3D_H_
|
||||
#define _D3D_H_
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#ifdef _WIN32
|
||||
#define COM_NO_WINDOWS_H
|
||||
#include <objbase.h>
|
||||
#else
|
||||
#include "d3dcom.h"
|
||||
#endif
|
||||
|
||||
#ifdef _WIN32
|
||||
#define D3DAPI WINAPI
|
||||
#else
|
||||
#define D3DAPI
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Interface IID's
|
||||
*/
|
||||
#if defined( _WIN32 ) && !defined( _NO_COM)
|
||||
DEFINE_GUID( IID_IDirect3D, 0x3BBA0080,0x2421,0x11CF,0xA3,0x1A,0x00,0xAA,0x00,0xB9,0x33,0x56 );
|
||||
DEFINE_GUID( IID_IDirect3D2, 0x6aae1ec1,0x662a,0x11d0,0x88,0x9d,0x00,0xaa,0x00,0xbb,0xb7,0x6a);
|
||||
|
||||
DEFINE_GUID( IID_IDirect3DRampDevice, 0xF2086B20,0x259F,0x11CF,0xA3,0x1A,0x00,0xAA,0x00,0xB9,0x33,0x56 );
|
||||
DEFINE_GUID( IID_IDirect3DRGBDevice, 0xA4665C60,0x2673,0x11CF,0xA3,0x1A,0x00,0xAA,0x00,0xB9,0x33,0x56 );
|
||||
DEFINE_GUID( IID_IDirect3DHALDevice, 0x84E63dE0,0x46AA,0x11CF,0x81,0x6F,0x00,0x00,0xC0,0x20,0x15,0x6E );
|
||||
DEFINE_GUID( IID_IDirect3DMMXDevice, 0x881949a1,0xd6f3,0x11d0,0x89,0xab,0x00,0xa0,0xc9,0x05,0x41,0x29 );
|
||||
|
||||
DEFINE_GUID( IID_IDirect3DDevice, 0x64108800,0x957d,0X11d0,0x89,0xab,0x00,0xa0,0xc9,0x05,0x41,0x29 );
|
||||
DEFINE_GUID( IID_IDirect3DDevice2, 0x93281501, 0x8cf8, 0x11d0, 0x89, 0xab, 0x0, 0xa0, 0xc9, 0x5, 0x41, 0x29);
|
||||
DEFINE_GUID( IID_IDirect3DTexture, 0x2CDCD9E0,0x25A0,0x11CF,0xA3,0x1A,0x00,0xAA,0x00,0xB9,0x33,0x56 );
|
||||
DEFINE_GUID( IID_IDirect3DTexture2, 0x93281502, 0x8cf8, 0x11d0, 0x89, 0xab, 0x0, 0xa0, 0xc9, 0x5, 0x41, 0x29);
|
||||
DEFINE_GUID( IID_IDirect3DLight, 0x4417C142,0x33AD,0x11CF,0x81,0x6F,0x00,0x00,0xC0,0x20,0x15,0x6E );
|
||||
DEFINE_GUID( IID_IDirect3DMaterial, 0x4417C144,0x33AD,0x11CF,0x81,0x6F,0x00,0x00,0xC0,0x20,0x15,0x6E );
|
||||
DEFINE_GUID( IID_IDirect3DMaterial2, 0x93281503, 0x8cf8, 0x11d0, 0x89, 0xab, 0x0, 0xa0, 0xc9, 0x5, 0x41, 0x29);
|
||||
DEFINE_GUID( IID_IDirect3DExecuteBuffer,0x4417C145,0x33AD,0x11CF,0x81,0x6F,0x00,0x00,0xC0,0x20,0x15,0x6E );
|
||||
DEFINE_GUID( IID_IDirect3DViewport, 0x4417C146,0x33AD,0x11CF,0x81,0x6F,0x00,0x00,0xC0,0x20,0x15,0x6E );
|
||||
DEFINE_GUID( IID_IDirect3DViewport2, 0x93281500, 0x8cf8, 0x11d0, 0x89, 0xab, 0x0, 0xa0, 0xc9, 0x5, 0x41, 0x29);
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Data structures
|
||||
*/
|
||||
#ifdef __cplusplus
|
||||
|
||||
/* 'struct' not 'class' per the way DECLARE_INTERFACE_ is defined */
|
||||
struct IDirect3D;
|
||||
struct IDirect3D2;
|
||||
struct IDirect3DDevice;
|
||||
struct IDirect3DDevice2;
|
||||
struct IDirect3DExecuteBuffer;
|
||||
struct IDirect3DLight;
|
||||
struct IDirect3DMaterial;
|
||||
struct IDirect3DMaterial2;
|
||||
struct IDirect3DTexture;
|
||||
struct IDirect3DTexture2;
|
||||
struct IDirect3DViewport;
|
||||
struct IDirect3DViewport2;
|
||||
typedef struct IDirect3D *LPDIRECT3D;
|
||||
typedef struct IDirect3D2 *LPDIRECT3D2;
|
||||
typedef struct IDirect3DDevice *LPDIRECT3DDEVICE;
|
||||
typedef struct IDirect3DDevice2 *LPDIRECT3DDEVICE2;
|
||||
typedef struct IDirect3DExecuteBuffer *LPDIRECT3DEXECUTEBUFFER;
|
||||
typedef struct IDirect3DLight *LPDIRECT3DLIGHT;
|
||||
typedef struct IDirect3DMaterial *LPDIRECT3DMATERIAL;
|
||||
typedef struct IDirect3DMaterial2 *LPDIRECT3DMATERIAL2;
|
||||
typedef struct IDirect3DTexture *LPDIRECT3DTEXTURE;
|
||||
typedef struct IDirect3DTexture2 *LPDIRECT3DTEXTURE2;
|
||||
typedef struct IDirect3DViewport *LPDIRECT3DVIEWPORT;
|
||||
typedef struct IDirect3DViewport2 *LPDIRECT3DVIEWPORT2;
|
||||
|
||||
#else
|
||||
|
||||
typedef struct IDirect3D *LPDIRECT3D;
|
||||
typedef struct IDirect3D2 *LPDIRECT3D2;
|
||||
typedef struct IDirect3DDevice *LPDIRECT3DDEVICE;
|
||||
typedef struct IDirect3DDevice2 *LPDIRECT3DDEVICE2;
|
||||
typedef struct IDirect3DExecuteBuffer *LPDIRECT3DEXECUTEBUFFER;
|
||||
typedef struct IDirect3DLight *LPDIRECT3DLIGHT;
|
||||
typedef struct IDirect3DMaterial *LPDIRECT3DMATERIAL;
|
||||
typedef struct IDirect3DMaterial2 *LPDIRECT3DMATERIAL2;
|
||||
typedef struct IDirect3DTexture *LPDIRECT3DTEXTURE;
|
||||
typedef struct IDirect3DTexture2 *LPDIRECT3DTEXTURE2;
|
||||
typedef struct IDirect3DViewport *LPDIRECT3DVIEWPORT;
|
||||
typedef struct IDirect3DViewport2 *LPDIRECT3DVIEWPORT2;
|
||||
|
||||
#endif
|
||||
|
||||
#include "d3dtypes.h"
|
||||
#include "d3dcaps.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
* IDirect3D
|
||||
*/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3D
|
||||
DECLARE_INTERFACE_(IDirect3D, IUnknown)
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID* ppvObj) PURE;
|
||||
STDMETHOD_(ULONG, AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG, Release) (THIS) PURE;
|
||||
/*** IDirect3D methods ***/
|
||||
STDMETHOD(Initialize) (THIS_ REFIID) PURE;
|
||||
STDMETHOD(EnumDevices)(THIS_ LPD3DENUMDEVICESCALLBACK, LPVOID) PURE;
|
||||
STDMETHOD(CreateLight) (THIS_ LPDIRECT3DLIGHT*, IUnknown*) PURE;
|
||||
STDMETHOD(CreateMaterial) (THIS_ LPDIRECT3DMATERIAL*, IUnknown*) PURE;
|
||||
STDMETHOD(CreateViewport) (THIS_ LPDIRECT3DVIEWPORT*, IUnknown*) PURE;
|
||||
STDMETHOD(FindDevice)(THIS_ LPD3DFINDDEVICESEARCH, LPD3DFINDDEVICERESULT) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirect3D_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b)
|
||||
#define IDirect3D_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirect3D_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirect3D_Initialize(p, a) (p)->lpVtbl->Initialize(p, a)
|
||||
#define IDirect3D_EnumDevices(p, a, b) (p)->lpVtbl->EnumDevices(p, a, b)
|
||||
#define IDirect3D_CreateLight(p, a, b) (p)->lpVtbl->CreateLight(p, a, b)
|
||||
#define IDirect3D_CreateMaterial(p, a, b) (p)->lpVtbl->CreateMaterial(p, a, b)
|
||||
#define IDirect3D_CreateViewport(p, a, b) (p)->lpVtbl->CreateViewport(p, a, b)
|
||||
#define IDirect3D_FindDevice(p, a, b) (p)->lpVtbl->FindDevice(p, a, b)
|
||||
#else
|
||||
#define IDirect3D_QueryInterface(p, a, b) (p)->QueryInterface(a, b)
|
||||
#define IDirect3D_AddRef(p) (p)->AddRef()
|
||||
#define IDirect3D_Release(p) (p)->Release()
|
||||
#define IDirect3D_Initialize(p, a) (p)->Initialize(a)
|
||||
#define IDirect3D_EnumDevices(p, a, b) (p)->EnumDevices(a, b)
|
||||
#define IDirect3D_CreateLight(p, a, b) (p)->CreateLight(a, b)
|
||||
#define IDirect3D_CreateMaterial(p, a, b) (p)->CreateMaterial(a, b)
|
||||
#define IDirect3D_CreateViewport(p, a, b) (p)->CreateViewport(a, b)
|
||||
#define IDirect3D_FindDevice(p, a, b) (p)->FindDevice(a, b)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* IDirect3D2
|
||||
*/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3D2
|
||||
DECLARE_INTERFACE_(IDirect3D2, IUnknown)
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID* ppvObj) PURE;
|
||||
STDMETHOD_(ULONG, AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG, Release) (THIS) PURE;
|
||||
/*** IDirect3D methods ***/
|
||||
STDMETHOD(EnumDevices)(THIS_ LPD3DENUMDEVICESCALLBACK, LPVOID) PURE;
|
||||
STDMETHOD(CreateLight) (THIS_ LPDIRECT3DLIGHT*, IUnknown*) PURE;
|
||||
STDMETHOD(CreateMaterial) (THIS_ LPDIRECT3DMATERIAL2*, IUnknown*) PURE;
|
||||
STDMETHOD(CreateViewport) (THIS_ LPDIRECT3DVIEWPORT2*, IUnknown*) PURE;
|
||||
STDMETHOD(FindDevice)(THIS_ LPD3DFINDDEVICESEARCH, LPD3DFINDDEVICERESULT) PURE;
|
||||
|
||||
STDMETHOD(CreateDevice)(THIS_ REFCLSID, LPDIRECTDRAWSURFACE, LPDIRECT3DDEVICE2 *) PURE;
|
||||
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirect3D2_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b)
|
||||
#define IDirect3D2_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirect3D2_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirect3D2_EnumDevices(p, a, b) (p)->lpVtbl->EnumDevices(p, a, b)
|
||||
#define IDirect3D2_CreateLight(p, a, b) (p)->lpVtbl->CreateLight(p, a, b)
|
||||
#define IDirect3D2_CreateMaterial(p, a, b) (p)->lpVtbl->CreateMaterial(p, a, b)
|
||||
#define IDirect3D2_CreateViewport(p, a, b) (p)->lpVtbl->CreateViewport(p, a, b)
|
||||
#define IDirect3D2_FindDevice(p, a, b) (p)->lpVtbl->FindDevice(p, a, b)
|
||||
#define IDirect3D2_CreateDevice(p, a, b, c) (p)->lpVtbl->CreateDevice(p, a, b, c)
|
||||
#else
|
||||
#define IDirect3D2_QueryInterface(p, a, b) (p)->QueryInterface(a, b)
|
||||
#define IDirect3D2_AddRef(p) (p)->AddRef()
|
||||
#define IDirect3D2_Release(p) (p)->Release()
|
||||
#define IDirect3D2_EnumDevices(p, a, b) (p)->EnumDevices(a, b)
|
||||
#define IDirect3D2_CreateLight(p, a, b) (p)->CreateLight(a, b)
|
||||
#define IDirect3D2_CreateMaterial(p, a, b) (p)->CreateMaterial(a, b)
|
||||
#define IDirect3D2_CreateViewport(p, a, b) (p)->CreateViewport(a, b)
|
||||
#define IDirect3D2_FindDevice(p, a, b) (p)->FindDevice(a, b)
|
||||
#define IDirect3D2_CreateDevice(p, a, b, c) (p)->CreateDevice(a, b, c)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* IDirect3DDevice
|
||||
*/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3DDevice
|
||||
DECLARE_INTERFACE_(IDirect3DDevice, IUnknown)
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID* ppvObj) PURE;
|
||||
STDMETHOD_(ULONG, AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG, Release) (THIS) PURE;
|
||||
/*** IDirect3DDevice methods ***/
|
||||
STDMETHOD(Initialize) (THIS_ LPDIRECT3D, LPGUID, LPD3DDEVICEDESC) PURE;
|
||||
STDMETHOD(GetCaps) (THIS_ LPD3DDEVICEDESC, LPD3DDEVICEDESC) PURE;
|
||||
STDMETHOD(SwapTextureHandles) (THIS_ LPDIRECT3DTEXTURE, LPDIRECT3DTEXTURE) PURE;
|
||||
STDMETHOD(CreateExecuteBuffer) (THIS_ LPD3DEXECUTEBUFFERDESC, LPDIRECT3DEXECUTEBUFFER*, IUnknown*) PURE;
|
||||
STDMETHOD(GetStats) (THIS_ LPD3DSTATS) PURE;
|
||||
STDMETHOD(Execute) (THIS_ LPDIRECT3DEXECUTEBUFFER, LPDIRECT3DVIEWPORT, DWORD) PURE;
|
||||
STDMETHOD(AddViewport) (THIS_ LPDIRECT3DVIEWPORT) PURE;
|
||||
STDMETHOD(DeleteViewport) (THIS_ LPDIRECT3DVIEWPORT) PURE;
|
||||
STDMETHOD(NextViewport) (THIS_ LPDIRECT3DVIEWPORT, LPDIRECT3DVIEWPORT*, DWORD) PURE;
|
||||
STDMETHOD(Pick) (THIS_ LPDIRECT3DEXECUTEBUFFER, LPDIRECT3DVIEWPORT, DWORD, LPD3DRECT) PURE;
|
||||
STDMETHOD(GetPickRecords)(THIS_ LPDWORD, LPD3DPICKRECORD) PURE;
|
||||
STDMETHOD(EnumTextureFormats) (THIS_ LPD3DENUMTEXTUREFORMATSCALLBACK, LPVOID) PURE;
|
||||
STDMETHOD(CreateMatrix) (THIS_ LPD3DMATRIXHANDLE) PURE;
|
||||
STDMETHOD(SetMatrix) (THIS_ D3DMATRIXHANDLE, const LPD3DMATRIX) PURE;
|
||||
STDMETHOD(GetMatrix) (THIS_ D3DMATRIXHANDLE, LPD3DMATRIX) PURE;
|
||||
STDMETHOD(DeleteMatrix) (THIS_ D3DMATRIXHANDLE) PURE;
|
||||
STDMETHOD_(HRESULT, BeginScene) (THIS) PURE;
|
||||
STDMETHOD_(HRESULT, EndScene) (THIS) PURE;
|
||||
STDMETHOD(GetDirect3D) (THIS_ LPDIRECT3D*) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirect3DDevice_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b)
|
||||
#define IDirect3DDevice_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirect3DDevice_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirect3DDevice_Initialize(p, a, b, c) (p)->lpVtbl->Initialize(p, a, b, c)
|
||||
#define IDirect3DDevice_GetCaps(p, a, b) (p)->lpVtbl->GetCaps(p, a, b)
|
||||
#define IDirect3DDevice_SwapTextureHandles(p, a, b) (p)->lpVtbl->SwapTextureHandles(p, a, b)
|
||||
#define IDirect3DDevice_CreateExecuteBuffer(p, a, b, c) (p)->lpVtbl->CreateExecuteBuffer(p, a, b, c)
|
||||
#define IDirect3DDevice_GetStats(p, a) (p)->lpVtbl->GetStats(p, a)
|
||||
#define IDirect3DDevice_Execute(p, a, b, c) (p)->lpVtbl->Execute(p, a, b, c)
|
||||
#define IDirect3DDevice_AddViewport(p, a) (p)->lpVtbl->AddViewport(p, a)
|
||||
#define IDirect3DDevice_DeleteViewport(p, a) (p)->lpVtbl->DeleteViewport(p, a)
|
||||
#define IDirect3DDevice_NextViewport(p, a, b) (p)->lpVtbl->NextViewport(p, a, b)
|
||||
#define IDirect3DDevice_Pick(p, a, b, c, d) (p)->lpVtbl->Pick(p, a, b, c, d)
|
||||
#define IDirect3DDevice_GetPickRecords(p, a, b) (p)->lpVtbl->GetPickRecords(p, a, b)
|
||||
#define IDirect3DDevice_EnumTextureFormats(p, a, b) (p)->lpVtbl->EnumTextureFormats(p, a, b)
|
||||
#define IDirect3DDevice_CreateMatrix(p, a) (p)->lpVtbl->CreateMatrix(p, a)
|
||||
#define IDirect3DDevice_SetMatrix(p, a, b) (p)->lpVtbl->SetMatrix(p, a, b)
|
||||
#define IDirect3DDevice_GetMatrix(p, a, b) (p)->lpVtbl->GetMatrix(p, a, b)
|
||||
#define IDirect3DDevice_DeleteMatrix(p, a) (p)->lpVtbl->DeleteMatrix(p, a)
|
||||
#define IDirect3DDevice_BeginScene(p) (p)->lpVtbl->BeginScene(p)
|
||||
#define IDirect3DDevice_EndScene(p) (p)->lpVtbl->EndScene(p)
|
||||
#define IDirect3DDevice_GetDirect3D(p, a) (p)->lpVtbl->GetDirect3D(p, a)
|
||||
#else
|
||||
#define IDirect3DDevice_QueryInterface(p, a, b) (p)->QueryInterface(a, b)
|
||||
#define IDirect3DDevice_AddRef(p) (p)->AddRef()
|
||||
#define IDirect3DDevice_Release(p) (p)->Release()
|
||||
#define IDirect3DDevice_Initialize(p, a, b, c) (p)->Initialize(a, b, c)
|
||||
#define IDirect3DDevice_GetCaps(p, a, b) (p)->GetCaps(a, b)
|
||||
#define IDirect3DDevice_SwapTextureHandles(p, a, b) (p)->SwapTextureHandles(a, b)
|
||||
#define IDirect3DDevice_CreateExecuteBuffer(p, a, b, c) (p)->CreateExecuteBuffer(a, b, c)
|
||||
#define IDirect3DDevice_GetStats(p, a) (p)->GetStats(a)
|
||||
#define IDirect3DDevice_Execute(p, a, b, c) (p)->Execute(a, b, c)
|
||||
#define IDirect3DDevice_AddViewport(p, a) (p)->AddViewport(a)
|
||||
#define IDirect3DDevice_DeleteViewport(p, a) (p)->DeleteViewport(a)
|
||||
#define IDirect3DDevice_NextViewport(p, a, b) (p)->NextViewport(a, b)
|
||||
#define IDirect3DDevice_Pick(p, a, b, c, d) (p)->Pick(a, b, c, d)
|
||||
#define IDirect3DDevice_GetPickRecords(p, a, b) (p)->GetPickRecords(a, b)
|
||||
#define IDirect3DDevice_EnumTextureFormats(p, a, b) (p)->EnumTextureFormats(a, b)
|
||||
#define IDirect3DDevice_CreateMatrix(p, a) (p)->CreateMatrix(a)
|
||||
#define IDirect3DDevice_SetMatrix(p, a, b) (p)->SetMatrix(a, b)
|
||||
#define IDirect3DDevice_GetMatrix(p, a, b) (p)->GetMatrix(a, b)
|
||||
#define IDirect3DDevice_DeleteMatrix(p, a) (p)->DeleteMatrix(a)
|
||||
#define IDirect3DDevice_BeginScene(p) (p)->BeginScene()
|
||||
#define IDirect3DDevice_EndScene(p) (p)->EndScene()
|
||||
#define IDirect3DDevice_GetDirect3D(p, a) (p)->GetDirect3D(a)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* IDirect3DDevice2
|
||||
*/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3DDevice2
|
||||
DECLARE_INTERFACE_(IDirect3DDevice2, IUnknown)
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID* ppvObj) PURE;
|
||||
STDMETHOD_(ULONG, AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG, Release) (THIS) PURE;
|
||||
/*** IDirect3DDevice2 methods ***/
|
||||
STDMETHOD(GetCaps) (THIS_ LPD3DDEVICEDESC, LPD3DDEVICEDESC) PURE;
|
||||
STDMETHOD(SwapTextureHandles) (THIS_ LPDIRECT3DTEXTURE2, LPDIRECT3DTEXTURE2) PURE;
|
||||
STDMETHOD(GetStats) (THIS_ LPD3DSTATS) PURE;
|
||||
STDMETHOD(AddViewport) (THIS_ LPDIRECT3DVIEWPORT2) PURE;
|
||||
STDMETHOD(DeleteViewport) (THIS_ LPDIRECT3DVIEWPORT2) PURE;
|
||||
STDMETHOD(NextViewport) (THIS_ LPDIRECT3DVIEWPORT2, LPDIRECT3DVIEWPORT2*, DWORD) PURE;
|
||||
STDMETHOD(EnumTextureFormats) (THIS_ LPD3DENUMTEXTUREFORMATSCALLBACK, LPVOID) PURE;
|
||||
STDMETHOD_(HRESULT, BeginScene) (THIS) PURE;
|
||||
STDMETHOD_(HRESULT, EndScene) (THIS) PURE;
|
||||
STDMETHOD(GetDirect3D) (THIS_ LPDIRECT3D2*) PURE;
|
||||
|
||||
/*** DrawPrimitive API ***/
|
||||
STDMETHOD(SetCurrentViewport) (THIS_ LPDIRECT3DVIEWPORT2) PURE;
|
||||
STDMETHOD(GetCurrentViewport) (THIS_ LPDIRECT3DVIEWPORT2 *) PURE;
|
||||
|
||||
STDMETHOD(SetRenderTarget) (THIS_ LPDIRECTDRAWSURFACE, DWORD) PURE;
|
||||
STDMETHOD(GetRenderTarget) (THIS_ LPDIRECTDRAWSURFACE *) PURE;
|
||||
|
||||
STDMETHOD(Begin) (THIS_ D3DPRIMITIVETYPE, D3DVERTEXTYPE, DWORD) PURE;
|
||||
STDMETHOD(BeginIndexed) (THIS_ D3DPRIMITIVETYPE, D3DVERTEXTYPE, LPVOID, DWORD, DWORD) PURE;
|
||||
STDMETHOD(Vertex) (THIS_ LPVOID) PURE;
|
||||
STDMETHOD(Index) (THIS_ WORD) PURE;
|
||||
STDMETHOD(End) (THIS_ DWORD) PURE;
|
||||
|
||||
STDMETHOD(GetRenderState) (THIS_ D3DRENDERSTATETYPE, LPDWORD) PURE;
|
||||
STDMETHOD(SetRenderState) (THIS_ D3DRENDERSTATETYPE, DWORD) PURE;
|
||||
STDMETHOD(GetLightState) (THIS_ D3DLIGHTSTATETYPE, LPDWORD) PURE;
|
||||
STDMETHOD(SetLightState) (THIS_ D3DLIGHTSTATETYPE, DWORD) PURE;
|
||||
STDMETHOD(SetTransform) (THIS_ D3DTRANSFORMSTATETYPE, LPD3DMATRIX) PURE;
|
||||
STDMETHOD(GetTransform) (THIS_ D3DTRANSFORMSTATETYPE, LPD3DMATRIX) PURE;
|
||||
STDMETHOD(MultiplyTransform) (THIS_ D3DTRANSFORMSTATETYPE, LPD3DMATRIX) PURE;
|
||||
|
||||
STDMETHOD(DrawPrimitive) (THIS_ D3DPRIMITIVETYPE, D3DVERTEXTYPE, LPVOID, DWORD, DWORD) PURE;
|
||||
STDMETHOD(DrawIndexedPrimitive) (THIS_ D3DPRIMITIVETYPE, D3DVERTEXTYPE, LPVOID, DWORD, LPWORD, DWORD, DWORD) PURE;
|
||||
|
||||
STDMETHOD(SetClipStatus) (THIS_ LPD3DCLIPSTATUS) PURE;
|
||||
STDMETHOD(GetClipStatus) (THIS_ LPD3DCLIPSTATUS) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirect3DDevice2_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b)
|
||||
#define IDirect3DDevice2_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirect3DDevice2_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirect3DDevice2_GetCaps(p, a, b) (p)->lpVtbl->GetCaps(p, a, b)
|
||||
#define IDirect3DDevice2_SwapTextureHandles(p, a, b) (p)->lpVtbl->SwapTextureHandles(p, a, b)
|
||||
#define IDirect3DDevice2_GetStats(p, a) (p)->lpVtbl->CreateViewport(p, a)
|
||||
#define IDirect3DDevice2_AddViewport(p, a) (p)->lpVtbl->AddViewport(p, a)
|
||||
#define IDirect3DDevice2_DeleteViewport(p, a) (p)->lpVtbl->DeleteViewport(p, a)
|
||||
#define IDirect3DDevice2_NextViewport(p, a, b) (p)->lpVtbl->NextViewport(p, a, b)
|
||||
#define IDirect3DDevice2_EnumTextureFormats(p, a, b) (p)->lpVtbl->EnumTextureFormats(p, a, b)
|
||||
#define IDirect3DDevice2_BeginScene(p) (p)->lpVtbl->BeginScene(p)
|
||||
#define IDirect3DDevice2_EndScene(p) (p)->lpVtbl->EndScene(p)
|
||||
#define IDirect3DDevice2_GetDirect3D(p, a) (p)->lpVtbl->GetDirect3D(p, a)
|
||||
|
||||
#define IDirect3DDevice2_SetCurrentViewport(p, a) (p)->lpVtbl->SetCurrentViewport(p, a)
|
||||
#define IDirect3DDevice2_GetCurrentViewport(p, a) (p)->lpVtbl->GetCurrentViewport(p, a)
|
||||
|
||||
#define IDirect3DDevice2_SetRenderTarget(p, a, b) (p)->lpVtbl->SetRenderTarget(p, a, b)
|
||||
#define IDirect3DDevice2_GetRenderTarget(p, a) (p)->lpVtbl->GetRenderTarget(p, a)
|
||||
|
||||
#define IDirect3DDevice2_Begin(p, a, b, c) (p)->lpVtbl->Begin(p, a, b, c)
|
||||
#define IDirect3DDevice2_BeginIndexed(p, a, b, c, d, e) (p)->lpVtbl->Begin(p, a, b, c, d, e)
|
||||
#define IDirect3DDevice2_Vertex(p, a) (p)->lpVtbl->Vertex(p, a)
|
||||
#define IDirect3DDevice2_Index(p, a) (p)->lpVtbl->Index(p, a)
|
||||
#define IDirect3DDevice2_End(p, a) (p)->lpVtbl->End(p, a)
|
||||
|
||||
#define IDirect3DDevice2_GetRenderState(p, a, b) (p)->lpVtbl->GetRenderState(p, a, b)
|
||||
#define IDirect3DDevice2_SetRenderState(p, a, b) (p)->lpVtbl->SetRenderState(p, a, b)
|
||||
#define IDirect3DDevice2_GetLightState(p, a, b) (p)->lpVtbl->GetLightState(p, a, b)
|
||||
#define IDirect3DDevice2_SetLightState(p, a, b) (p)->lpVtbl->SetLightState(p, a, b)
|
||||
#define IDirect3DDevice2_SetTransform(p, a, b) (p)->lpVtbl->SetTransform(p, a, b)
|
||||
#define IDirect3DDevice2_GetTransform(p, a, b) (p)->lpVtbl->GetTransform(p, a, b)
|
||||
#define IDirect3DDevice2_MultiplyTransform(p, a, b) (p)->lpVtbl->MultiplyTransform(p, a, b)
|
||||
|
||||
#define IDirect3DDevice2_DrawPrimitive(p, a, b, c, d, e) (p)->lpVtbl->DrawPrimitive(p, a, b, c, d, e)
|
||||
#define IDirect3DDevice2_DrawIndexedPrimitive(p, a, b, c, d, e, f, g) \
|
||||
(p)->lpVtbl->DrawIndexedPrimitive(p, a, b, c, d, e, f, g)
|
||||
#define IDirect3DDevice2_SetClipStatus(p, a) (p)->lpVtbl->SetClipStatus(p, a)
|
||||
#define IDirect3DDevice2_GetClipStatus(p, a) (p)->lpVtbl->GetClipStatus(p, a)
|
||||
#else
|
||||
#define IDirect3DDevice2_QueryInterface(p, a, b) (p)->QueryInterface(a, b)
|
||||
#define IDirect3DDevice2_AddRef(p) (p)->AddRef()
|
||||
#define IDirect3DDevice2_Release(p) (p)->Release()
|
||||
#define IDirect3DDevice2_GetCaps(p, a, b) (p)->GetCaps(a, b)
|
||||
#define IDirect3DDevice2_SwapTextureHandles(p, a, b) (p)->SwapTextureHandles(a, b)
|
||||
#define IDirect3DDevice2_GetStats(p, a) (p)->CreateViewport(a)
|
||||
#define IDirect3DDevice2_AddViewport(p, a) (p)->AddViewport(a)
|
||||
#define IDirect3DDevice2_DeleteViewport(p, a) (p)->DeleteViewport(a)
|
||||
#define IDirect3DDevice2_NextViewport(p, a, b) (p)->NextViewport(a, b)
|
||||
#define IDirect3DDevice2_EnumTextureFormats(p, a, b) (p)->EnumTextureFormats(a, b)
|
||||
#define IDirect3DDevice2_BeginScene(p) (p)->BeginScene()
|
||||
#define IDirect3DDevice2_EndScene(p) (p)->EndScene()
|
||||
#define IDirect3DDevice2_GetDirect3D(p, a) (p)->GetDirect3D(a)
|
||||
|
||||
#define IDirect3DDevice2_SetCurrentViewport(p, a) (p)->SetCurrentViewport(a)
|
||||
#define IDirect3DDevice2_GetCurrentViewport(p, a) (p)->GetCurrentViewport(a)
|
||||
|
||||
#define IDirect3DDevice2_SetRenderTarget(p, a, b) (p)->SetRenderTarget(a, b)
|
||||
#define IDirect3DDevice2_GetRenderTarget(p, a) (p)->GetRenderTarget(a)
|
||||
|
||||
#define IDirect3DDevice2_Begin(p, a, b, c) (p)->Begin(a, b, c)
|
||||
#define IDirect3DDevice2_BeginIndexed(p, a, b, c, d, e) (p)->Begin(a, b, c, d, e)
|
||||
#define IDirect3DDevice2_Vertex(p, a) (p)->Vertex(a)
|
||||
#define IDirect3DDevice2_Index(p, a) (p)->Index(a)
|
||||
#define IDirect3DDevice2_End(p, a) (p)->End(a)
|
||||
|
||||
#define IDirect3DDevice2_GetRenderState(p, a, b) (p)->GetRenderState(a, b)
|
||||
#define IDirect3DDevice2_SetRenderState(p, a, b) (p)->SetRenderState(a, b)
|
||||
#define IDirect3DDevice2_GetLightState(p, a, b) (p)->GetLightState(a, b)
|
||||
#define IDirect3DDevice2_SetLightState(p, a, b) (p)->SetLightState(a, b)
|
||||
#define IDirect3DDevice2_SetTransform(p, a, b) (p)->SetTransform(a, b)
|
||||
#define IDirect3DDevice2_GetTransform(p, a, b) (p)->GetTransform(a, b)
|
||||
#define IDirect3DDevice2_MultiplyTransform(p, a, b) (p)->MultiplyTransform(a, b)
|
||||
|
||||
#define IDirect3DDevice2_DrawPrimitive(p, a, b, c, d, e) (p)->DrawPrimitive(a, b, c, d, e)
|
||||
#define IDirect3DDevice2_DrawIndexedPrimitive(p, a, b, c, d, e, f, g) \
|
||||
(p)->DrawIndexedPrimitive(a, b, c, d, e, f, g)
|
||||
#define IDirect3DDevice2_SetClipStatus(p, a) (p)->SetClipStatus(a)
|
||||
#define IDirect3DDevice2_GetClipStatus(p, a) (p)->GetClipStatus(a)
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* IDirect3DExecuteBuffer
|
||||
*/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3DExecuteBuffer
|
||||
DECLARE_INTERFACE_(IDirect3DExecuteBuffer, IUnknown)
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID* ppvObj) PURE;
|
||||
STDMETHOD_(ULONG, AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG, Release) (THIS) PURE;
|
||||
/*** IDirect3DExecuteBuffer methods ***/
|
||||
STDMETHOD(Initialize) (THIS_ LPDIRECT3DDEVICE, LPD3DEXECUTEBUFFERDESC) PURE;
|
||||
STDMETHOD(Lock) (THIS_ LPD3DEXECUTEBUFFERDESC) PURE;
|
||||
STDMETHOD_(HRESULT, Unlock) (THIS) PURE;
|
||||
STDMETHOD(SetExecuteData) (THIS_ LPD3DEXECUTEDATA) PURE;
|
||||
STDMETHOD(GetExecuteData) (THIS_ LPD3DEXECUTEDATA) PURE;
|
||||
STDMETHOD(Validate) (THIS_ LPDWORD, LPD3DVALIDATECALLBACK, LPVOID, DWORD) PURE;
|
||||
STDMETHOD(Optimize) (THIS_ DWORD) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirect3DExecuteBuffer_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b)
|
||||
#define IDirect3DExecuteBuffer_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirect3DExecuteBuffer_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirect3DExecuteBuffer_Initialize(p, a, b) (p)->lpVtbl->Initialize(p, a, b)
|
||||
#define IDirect3DExecuteBuffer_Lock(p, a) (p)->lpVtbl->Lock(p, a)
|
||||
#define IDirect3DExecuteBuffer_Unlock(p) (p)->lpVtbl->Unlock(p)
|
||||
#define IDirect3DExecuteBuffer_SetExecuteData(p, a) (p)->lpVtbl->SetExecuteData(p, a)
|
||||
#define IDirect3DExecuteBuffer_GetExecuteData(p, a) (p)->lpVtbl->GetExecuteData(p, a)
|
||||
#define IDirect3DExecuteBuffer_Validate(p, a, b, c, d) (p)->lpVtbl->Validate(p, a, b, c, d)
|
||||
#define IDirect3DExecuteBuffer_Optimize(p, a) (p)->lpVtbl->Optimize(p, a)
|
||||
#else
|
||||
#define IDirect3DExecuteBuffer_QueryInterface(p, a, b) (p)->QueryInterface(a, b)
|
||||
#define IDirect3DExecuteBuffer_AddRef(p) (p)->AddRef()
|
||||
#define IDirect3DExecuteBuffer_Release(p) (p)->Release()
|
||||
#define IDirect3DExecuteBuffer_Initialize(p, a, b) (p)->Initialize(a, b)
|
||||
#define IDirect3DExecuteBuffer_Lock(p, a) (p)->Lock(a)
|
||||
#define IDirect3DExecuteBuffer_Unlock(p) (p)->Unlock()
|
||||
#define IDirect3DExecuteBuffer_SetExecuteData(p, a) (p)->SetExecuteData(a)
|
||||
#define IDirect3DExecuteBuffer_GetExecuteData(p, a) (p)->GetExecuteData(a)
|
||||
#define IDirect3DExecuteBuffer_Validate(p, a, b, c, d) (p)->Validate(a, b, c, d)
|
||||
#define IDirect3DExecuteBuffer_Optimize(p, a) (p)->Optimize(a)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* IDirect3DLight
|
||||
*/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3DLight
|
||||
DECLARE_INTERFACE_(IDirect3DLight, IUnknown)
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID* ppvObj) PURE;
|
||||
STDMETHOD_(ULONG, AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG, Release) (THIS) PURE;
|
||||
/*** IDirect3DLight methods ***/
|
||||
STDMETHOD(Initialize) (THIS_ LPDIRECT3D) PURE;
|
||||
STDMETHOD(SetLight) (THIS_ LPD3DLIGHT) PURE;
|
||||
STDMETHOD(GetLight) (THIS_ LPD3DLIGHT) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirect3DLight_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b)
|
||||
#define IDirect3DLight_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirect3DLight_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirect3DLight_Initialize(p, a) (p)->lpVtbl->Initialize(p, a)
|
||||
#define IDirect3DLight_SetLight(p, a) (p)->lpVtbl->SetLight(p, a)
|
||||
#define IDirect3DLight_GetLight(p, a) (p)->lpVtbl->GetLight(p, a)
|
||||
#else
|
||||
#define IDirect3DLight_QueryInterface(p, a, b) (p)->QueryInterface(a, b)
|
||||
#define IDirect3DLight_AddRef(p) (p)->AddRef()
|
||||
#define IDirect3DLight_Release(p) (p)->Release()
|
||||
#define IDirect3DLight_Initialize(p, a) (p)->Initialize(a)
|
||||
#define IDirect3DLight_SetLight(p, a) (p)->SetLight(a)
|
||||
#define IDirect3DLight_GetLight(p, a) (p)->GetLight(a)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* IDirect3DMaterial
|
||||
*/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3DMaterial
|
||||
DECLARE_INTERFACE_(IDirect3DMaterial, IUnknown)
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID* ppvObj) PURE;
|
||||
STDMETHOD_(ULONG, AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG, Release) (THIS) PURE;
|
||||
/*** IDirect3DMaterial methods ***/
|
||||
STDMETHOD(Initialize) (THIS_ LPDIRECT3D) PURE;
|
||||
STDMETHOD(SetMaterial) (THIS_ LPD3DMATERIAL) PURE;
|
||||
STDMETHOD(GetMaterial) (THIS_ LPD3DMATERIAL) PURE;
|
||||
STDMETHOD(GetHandle) (THIS_ LPDIRECT3DDEVICE, LPD3DMATERIALHANDLE) PURE;
|
||||
STDMETHOD_(HRESULT, Reserve) (THIS) PURE;
|
||||
STDMETHOD_(HRESULT, Unreserve) (THIS) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirect3DMaterial_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b)
|
||||
#define IDirect3DMaterial_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirect3DMaterial_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirect3DMaterial_Initialize(p, a) (p)->lpVtbl->Initialize(p, a)
|
||||
#define IDirect3DMaterial_SetMaterial(p, a) (p)->lpVtbl->SetMaterial(p, a)
|
||||
#define IDirect3DMaterial_GetMaterial(p, a) (p)->lpVtbl->GetMaterial(p, a)
|
||||
#define IDirect3DMaterial_GetHandle(p, a, b) (p)->lpVtbl->GetHandle(p, a, b)
|
||||
#define IDirect3DMaterial_Reserve(p) (p)->lpVtbl->Reserve(p)
|
||||
#define IDirect3DMaterial_Unreserve(p) (p)->lpVtbl->Unreserve(p)
|
||||
#else
|
||||
#define IDirect3DMaterial_QueryInterface(p, a, b) (p)->QueryInterface(a, b)
|
||||
#define IDirect3DMaterial_AddRef(p) (p)->AddRef()
|
||||
#define IDirect3DMaterial_Release(p) (p)->Release()
|
||||
#define IDirect3DMaterial_Initialize(p, a) (p)->Initialize(a)
|
||||
#define IDirect3DMaterial_SetMaterial(p, a) (p)->SetMaterial(a)
|
||||
#define IDirect3DMaterial_GetMaterial(p, a) (p)->GetMaterial(a)
|
||||
#define IDirect3DMaterial_GetHandle(p, a, b) (p)->GetHandle(a, b)
|
||||
#define IDirect3DMaterial_Reserve(p) (p)->Reserve()
|
||||
#define IDirect3DMaterial_Unreserve(p) (p)->Unreserve()
|
||||
#endif
|
||||
|
||||
/*
|
||||
* IDirect3DMaterial2
|
||||
*/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3DMaterial2
|
||||
DECLARE_INTERFACE_(IDirect3DMaterial2, IUnknown)
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID* ppvObj) PURE;
|
||||
STDMETHOD_(ULONG, AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG, Release) (THIS) PURE;
|
||||
/*** IDirect3DMaterial2 methods ***/
|
||||
STDMETHOD(SetMaterial) (THIS_ LPD3DMATERIAL) PURE;
|
||||
STDMETHOD(GetMaterial) (THIS_ LPD3DMATERIAL) PURE;
|
||||
STDMETHOD(GetHandle) (THIS_ LPDIRECT3DDEVICE2, LPD3DMATERIALHANDLE) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirect3DMaterial2_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b)
|
||||
#define IDirect3DMaterial2_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirect3DMaterial2_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirect3DMaterial2_SetMaterial(p, a) (p)->lpVtbl->SetMaterial(p, a)
|
||||
#define IDirect3DMaterial2_GetMaterial(p, a) (p)->lpVtbl->GetMaterial(p, a)
|
||||
#define IDirect3DMaterial2_GetHandle(p, a, b) (p)->lpVtbl->GetHandle(p, a, b)
|
||||
#else
|
||||
#define IDirect3DMaterial2_QueryInterface(p, a, b) (p)->QueryInterface(a, b)
|
||||
#define IDirect3DMaterial2_AddRef(p) (p)->AddRef()
|
||||
#define IDirect3DMaterial2_Release(p) (p)->Release()
|
||||
#define IDirect3DMaterial2_SetMaterial(p, a) (p)->SetMaterial(a)
|
||||
#define IDirect3DMaterial2_GetMaterial(p, a) (p)->GetMaterial(a)
|
||||
#define IDirect3DMaterial2_GetHandle(p, a, b) (p)->GetHandle(a, b)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* IDirect3DTexture
|
||||
*/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3DTexture
|
||||
DECLARE_INTERFACE_(IDirect3DTexture, IUnknown)
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID* ppvObj) PURE;
|
||||
STDMETHOD_(ULONG, AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG, Release) (THIS) PURE;
|
||||
/*** IDirect3DTexture methods ***/
|
||||
STDMETHOD(Initialize) (THIS_ LPDIRECT3DDEVICE, LPDIRECTDRAWSURFACE) PURE;
|
||||
STDMETHOD(GetHandle) (THIS_ LPDIRECT3DDEVICE, LPD3DTEXTUREHANDLE) PURE;
|
||||
STDMETHOD(PaletteChanged) (THIS_ DWORD, DWORD) PURE;
|
||||
STDMETHOD(Load) (THIS_ LPDIRECT3DTEXTURE) PURE;
|
||||
STDMETHOD_(HRESULT, Unload) (THIS) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirect3DTexture_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b)
|
||||
#define IDirect3DTexture_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirect3DTexture_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirect3DTexture_Initialize(p, a, b) (p)->lpVtbl->Initialize(p, a, b)
|
||||
#define IDirect3DTexture_GetHandle(p, a, b) (p)->lpVtbl->GetHandle(p, a, b)
|
||||
#define IDirect3DTexture_PaletteChanged(p, a, b) (p)->lpVtbl->PaletteChanged(p, a, b)
|
||||
#define IDirect3DTexture_Load(p, a) (p)->lpVtbl->Load(p, a)
|
||||
#define IDirect3DTexture_Unload(p) (p)->lpVtbl->Unload(p)
|
||||
#else
|
||||
#define IDirect3DTexture_QueryInterface(p, a, b) (p)->QueryInterface(a, b)
|
||||
#define IDirect3DTexture_AddRef(p) (p)->AddRef()
|
||||
#define IDirect3DTexture_Release(p) (p)->Release()
|
||||
#define IDirect3DTexture_Initialize(p, a, b) (p)->Initialize(a, b)
|
||||
#define IDirect3DTexture_GetHandle(p, a, b) (p)->GetHandle(a, b)
|
||||
#define IDirect3DTexture_PaletteChanged(p, a, b) (p)->PaletteChanged(a, b)
|
||||
#define IDirect3DTexture_Load(p, a) (p)->Load(a)
|
||||
#define IDirect3DTexture_Unload(p) (p)->Unload()
|
||||
#endif
|
||||
|
||||
/*
|
||||
* IDirect3DTexture2
|
||||
*/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3DTexture2
|
||||
DECLARE_INTERFACE_(IDirect3DTexture2, IUnknown)
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID* ppvObj) PURE;
|
||||
STDMETHOD_(ULONG, AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG, Release) (THIS) PURE;
|
||||
/*** IDirect3DTexture2 methods ***/
|
||||
STDMETHOD(GetHandle) (THIS_ LPDIRECT3DDEVICE2, LPD3DTEXTUREHANDLE) PURE;
|
||||
STDMETHOD(PaletteChanged) (THIS_ DWORD, DWORD) PURE;
|
||||
STDMETHOD(Load) (THIS_ LPDIRECT3DTEXTURE2) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirect3DTexture2_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b)
|
||||
#define IDirect3DTexture2_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirect3DTexture2_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirect3DTexture2_GetHandle(p, a, b) (p)->lpVtbl->GetHandle(p, a, b)
|
||||
#define IDirect3DTexture2_PaletteChanged(p, a, b) (p)->lpVtbl->PaletteChanged(p, a, b)
|
||||
#define IDirect3DTexture2_Load(p, a) (p)->lpVtbl->Load(p, a)
|
||||
#else
|
||||
#define IDirect3DTexture2_QueryInterface(p, a, b) (p)->QueryInterface(a, b)
|
||||
#define IDirect3DTexture2_AddRef(p) (p)->AddRef()
|
||||
#define IDirect3DTexture2_Release(p) (p)->Release()
|
||||
#define IDirect3DTexture2_GetHandle(p, a, b) (p)->GetHandle(a, b)
|
||||
#define IDirect3DTexture2_PaletteChanged(p, a, b) (p)->PaletteChanged(a, b)
|
||||
#define IDirect3DTexture2_Load(p, a) (p)->Load(a)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* IDirect3DViewport
|
||||
*/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3DViewport
|
||||
DECLARE_INTERFACE_(IDirect3DViewport, IUnknown)
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID* ppvObj) PURE;
|
||||
STDMETHOD_(ULONG, AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG, Release) (THIS) PURE;
|
||||
/*** IDirect3DViewport methods ***/
|
||||
STDMETHOD(Initialize) (THIS_ LPDIRECT3D) PURE;
|
||||
STDMETHOD(GetViewport) (THIS_ LPD3DVIEWPORT) PURE;
|
||||
STDMETHOD(SetViewport) (THIS_ LPD3DVIEWPORT) PURE;
|
||||
STDMETHOD(TransformVertices) (THIS_ DWORD, LPD3DTRANSFORMDATA, DWORD, LPDWORD) PURE;
|
||||
STDMETHOD(LightElements) (THIS_ DWORD, LPD3DLIGHTDATA) PURE;
|
||||
STDMETHOD(SetBackground) (THIS_ D3DMATERIALHANDLE) PURE;
|
||||
STDMETHOD(GetBackground) (THIS_ LPD3DMATERIALHANDLE, LPBOOL) PURE;
|
||||
STDMETHOD(SetBackgroundDepth) (THIS_ LPDIRECTDRAWSURFACE) PURE;
|
||||
STDMETHOD(GetBackgroundDepth) (THIS_ LPDIRECTDRAWSURFACE*, LPBOOL) PURE;
|
||||
STDMETHOD(Clear) (THIS_ DWORD, LPD3DRECT, DWORD) PURE;
|
||||
STDMETHOD(AddLight) (THIS_ LPDIRECT3DLIGHT) PURE;
|
||||
STDMETHOD(DeleteLight) (THIS_ LPDIRECT3DLIGHT) PURE;
|
||||
STDMETHOD(NextLight) (THIS_ LPDIRECT3DLIGHT, LPDIRECT3DLIGHT*, DWORD) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirect3DViewport_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b)
|
||||
#define IDirect3DViewport_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirect3DViewport_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirect3DViewport_Initialize(p, a) (p)->lpVtbl->Initialize(p, a)
|
||||
#define IDirect3DViewport_GetViewport(p, a) (p)->lpVtbl->GetViewport(p, a)
|
||||
#define IDirect3DViewport_SetViewport(p, a) (p)->lpVtbl->SetViewport(p, a)
|
||||
#define IDirect3DViewport_TransformVertices(p, a, b, c, d) (p)->lpVtbl->TransformVertices(p, a, b, c, d)
|
||||
#define IDirect3DViewport_LightElements(p, a, b) (p)->lpVtbl->LightElements(p, a, b)
|
||||
#define IDirect3DViewport_SetBackground(p, a) (p)->lpVtbl->SetBackground(p, a)
|
||||
#define IDirect3DViewport_GetBackground(p, a, b) (p)->lpVtbl->GetBackground(p, a, b)
|
||||
#define IDirect3DViewport_SetBackgroundDepth(p, a) (p)->lpVtbl->SetBackgroundDepth(p, a)
|
||||
#define IDirect3DViewport_GetBackgroundDepth(p, a, b) (p)->lpVtbl->GetBackgroundDepth(p, a, b)
|
||||
#define IDirect3DViewport_Clear(p, a, b, c) (p)->lpVtbl->Clear(p, a, b, c)
|
||||
#define IDirect3DViewport_AddLight(p, a) (p)->lpVtbl->AddLight(p, a)
|
||||
#define IDirect3DViewport_DeleteLight(p, a) (p)->lpVtbl->DeleteLight(p, a)
|
||||
#define IDirect3DViewport_NextLight(p, a, b, c) (p)->lpVtbl->NextLight(p, a, b, c)
|
||||
#else
|
||||
#define IDirect3DViewport_QueryInterface(p, a, b) (p)->QueryInterface(a, b)
|
||||
#define IDirect3DViewport_AddRef(p) (p)->AddRef()
|
||||
#define IDirect3DViewport_Release(p) (p)->Release()
|
||||
#define IDirect3DViewport_Initialize(p, a) (p)->Initialize(a)
|
||||
#define IDirect3DViewport_GetViewport(p, a) (p)->GetViewport(a)
|
||||
#define IDirect3DViewport_SetViewport(p, a) (p)->SetViewport(a)
|
||||
#define IDirect3DViewport_TransformVertices(p, a, b, c, d) (p)->TransformVertices(a, b, c, d)
|
||||
#define IDirect3DViewport_LightElements(p, a, b) (p)->LightElements(a, b)
|
||||
#define IDirect3DViewport_SetBackground(p, a) (p)->SetBackground(a)
|
||||
#define IDirect3DViewport_GetBackground(p, a, b) (p)->GetBackground(a, b)
|
||||
#define IDirect3DViewport_SetBackgroundDepth(p, a) (p)->SetBackgroundDepth(a)
|
||||
#define IDirect3DViewport_GetBackgroundDepth(p, a, b) (p)->GetBackgroundDepth(a, b)
|
||||
#define IDirect3DViewport_Clear(p, a, b, c) (p)->Clear(a, b, c)
|
||||
#define IDirect3DViewport_AddLight(p, a) (p)->AddLight(a)
|
||||
#define IDirect3DViewport_DeleteLight(p, a) (p)->DeleteLight(a)
|
||||
#define IDirect3DViewport_NextLight(p, a, b, c) (p)->NextLight(a, b, c)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* IDirect3DViewport2
|
||||
*/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3DViewport2
|
||||
DECLARE_INTERFACE_(IDirect3DViewport2, IDirect3DViewport)
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID* ppvObj) PURE;
|
||||
STDMETHOD_(ULONG, AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG, Release) (THIS) PURE;
|
||||
/*** IDirect3DViewport methods ***/
|
||||
STDMETHOD(Initialize) (THIS_ LPDIRECT3D) PURE;
|
||||
STDMETHOD(GetViewport) (THIS_ LPD3DVIEWPORT) PURE;
|
||||
STDMETHOD(SetViewport) (THIS_ LPD3DVIEWPORT) PURE;
|
||||
STDMETHOD(TransformVertices) (THIS_ DWORD, LPD3DTRANSFORMDATA, DWORD, LPDWORD) PURE;
|
||||
STDMETHOD(LightElements) (THIS_ DWORD, LPD3DLIGHTDATA) PURE;
|
||||
STDMETHOD(SetBackground) (THIS_ D3DMATERIALHANDLE) PURE;
|
||||
STDMETHOD(GetBackground) (THIS_ LPD3DMATERIALHANDLE, LPBOOL) PURE;
|
||||
STDMETHOD(SetBackgroundDepth) (THIS_ LPDIRECTDRAWSURFACE) PURE;
|
||||
STDMETHOD(GetBackgroundDepth) (THIS_ LPDIRECTDRAWSURFACE*, LPBOOL) PURE;
|
||||
STDMETHOD(Clear) (THIS_ DWORD, LPD3DRECT, DWORD) PURE;
|
||||
STDMETHOD(AddLight) (THIS_ LPDIRECT3DLIGHT) PURE;
|
||||
STDMETHOD(DeleteLight) (THIS_ LPDIRECT3DLIGHT) PURE;
|
||||
STDMETHOD(NextLight) (THIS_ LPDIRECT3DLIGHT, LPDIRECT3DLIGHT*, DWORD) PURE;
|
||||
/*** IDirect3DViewport2 methods ***/
|
||||
STDMETHOD(GetViewport2) (THIS_ LPD3DVIEWPORT2) PURE;
|
||||
STDMETHOD(SetViewport2) (THIS_ LPD3DVIEWPORT2) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirect3DViewport2_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b)
|
||||
#define IDirect3DViewport2_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirect3DViewport2_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirect3DViewport2_Initialize(p, a) (p)->lpVtbl->Initialize(p, a)
|
||||
#define IDirect3DViewport2_GetViewport(p, a) (p)->lpVtbl->GetViewport(p, a)
|
||||
#define IDirect3DViewport2_SetViewport(p, a) (p)->lpVtbl->SetViewport(p, a)
|
||||
#define IDirect3DViewport2_TransformVertices(p, a, b, c, d) (p)->lpVtbl->TransformVertices(p, a, b, c, d)
|
||||
#define IDirect3DViewport2_LightElements(p, a, b) (p)->lpVtbl->LightElements(p, a, b)
|
||||
#define IDirect3DViewport2_SetBackground(p, a) (p)->lpVtbl->SetBackground(p, a)
|
||||
#define IDirect3DViewport2_GetBackground(p, a, b) (p)->lpVtbl->GetBackground(p, a, b)
|
||||
#define IDirect3DViewport2_SetBackgroundDepth(p, a) (p)->lpVtbl->SetBackgroundDepth(p, a)
|
||||
#define IDirect3DViewport2_GetBackgroundDepth(p, a, b) (p)->lpVtbl->GetBackgroundDepth(p, a, b)
|
||||
#define IDirect3DViewport2_Clear(p, a, b, c) (p)->lpVtbl->Clear(p, a, b, c)
|
||||
#define IDirect3DViewport2_AddLight(p, a) (p)->lpVtbl->AddLight(p, a)
|
||||
#define IDirect3DViewport2_DeleteLight(p, a) (p)->lpVtbl->DeleteLight(p, a)
|
||||
#define IDirect3DViewport2_NextLight(p, a, b, c) (p)->lpVtbl->NextLight(p, a, b, c)
|
||||
#define IDirect3DViewport2_GetViewport2(p, a) (p)->lpVtbl->GetViewport2(p, a)
|
||||
#define IDirect3DViewport2_SetViewport2(p, a) (p)->lpVtbl->SetViewport2(p, a)
|
||||
#else
|
||||
#define IDirect3DViewport2_QueryInterface(p, a, b) (p)->QueryInterface(a, b)
|
||||
#define IDirect3DViewport2_AddRef(p) (p)->AddRef()
|
||||
#define IDirect3DViewport2_Release(p) (p)->Release()
|
||||
#define IDirect3DViewport2_Initialize(p, a) (p)->Initialize(a)
|
||||
#define IDirect3DViewport2_GetViewport(p, a) (p)->GetViewport(a)
|
||||
#define IDirect3DViewport2_SetViewport(p, a) (p)->SetViewport(a)
|
||||
#define IDirect3DViewport2_TransformVertices(p, a, b, c, d) (p)->TransformVertices(a, b, c, d)
|
||||
#define IDirect3DViewport2_LightElements(p, a, b) (p)->LightElements(a, b)
|
||||
#define IDirect3DViewport2_SetBackground(p, a) (p)->SetBackground(a)
|
||||
#define IDirect3DViewport2_GetBackground(p, a, b) (p)->GetBackground(a, b)
|
||||
#define IDirect3DViewport2_SetBackgroundDepth(p, a) (p)->SetBackgroundDepth(a)
|
||||
#define IDirect3DViewport2_GetBackgroundDepth(p, a, b) (p)->GetBackgroundDepth(a, b)
|
||||
#define IDirect3DViewport2_Clear(p, a, b, c) (p)->Clear(a, b, c)
|
||||
#define IDirect3DViewport2_AddLight(p, a) (p)->AddLight(a)
|
||||
#define IDirect3DViewport2_DeleteLight(p, a) (p)->DeleteLight(a)
|
||||
#define IDirect3DViewport2_NextLight(p, a, b, c) (p)->NextLight(a, b, c)
|
||||
#define IDirect3DViewport2_GetViewport2(p, a) (p)->GetViewport2(a)
|
||||
#define IDirect3DViewport2_SetViewport2(p, a) (p)->SetViewport2(a)
|
||||
#endif
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* Flags for IDirect3DDevice::NextViewport
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* Return the next viewport
|
||||
*/
|
||||
#define D3DNEXT_NEXT 0x00000001l
|
||||
|
||||
/*
|
||||
* Return the first viewport
|
||||
*/
|
||||
#define D3DNEXT_HEAD 0x00000002l
|
||||
|
||||
/*
|
||||
* Return the last viewport
|
||||
*/
|
||||
#define D3DNEXT_TAIL 0x00000004l
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* Flags for DrawPrimitive/DrawIndexedPrimitive
|
||||
* Also valid for Begin/BeginIndexed
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* Wait until the device is ready to draw the primitive
|
||||
* This will cause DP to not return DDERR_WASSTILLDRAWING
|
||||
*/
|
||||
#define D3DDP_WAIT 0x00000001l
|
||||
|
||||
|
||||
/*
|
||||
* Hint that the primitives have been clipped by the application.
|
||||
*/
|
||||
#define D3DDP_DONOTCLIP 0x00000004l
|
||||
|
||||
/*
|
||||
* Hint that the extents need not be updated.
|
||||
*/
|
||||
#define D3DDP_DONOTUPDATEEXTENTS 0x00000008l
|
||||
|
||||
/*
|
||||
* Direct3D Errors
|
||||
* DirectDraw error codes are used when errors not specified here.
|
||||
*/
|
||||
#define D3D_OK DD_OK
|
||||
#define D3DERR_BADMAJORVERSION MAKE_DDHRESULT(700)
|
||||
#define D3DERR_BADMINORVERSION MAKE_DDHRESULT(701)
|
||||
|
||||
/*
|
||||
* An invalid device was requested by the application.
|
||||
*/
|
||||
#define D3DERR_INVALID_DEVICE MAKE_DDHRESULT(705)
|
||||
#define D3DERR_INITFAILED MAKE_DDHRESULT(706)
|
||||
|
||||
/*
|
||||
* SetRenderTarget attempted on a device that was
|
||||
* QI'd off the render target.
|
||||
*/
|
||||
#define D3DERR_DEVICEAGGREGATED MAKE_DDHRESULT(707)
|
||||
|
||||
#define D3DERR_EXECUTE_CREATE_FAILED MAKE_DDHRESULT(710)
|
||||
#define D3DERR_EXECUTE_DESTROY_FAILED MAKE_DDHRESULT(711)
|
||||
#define D3DERR_EXECUTE_LOCK_FAILED MAKE_DDHRESULT(712)
|
||||
#define D3DERR_EXECUTE_UNLOCK_FAILED MAKE_DDHRESULT(713)
|
||||
#define D3DERR_EXECUTE_LOCKED MAKE_DDHRESULT(714)
|
||||
#define D3DERR_EXECUTE_NOT_LOCKED MAKE_DDHRESULT(715)
|
||||
|
||||
#define D3DERR_EXECUTE_FAILED MAKE_DDHRESULT(716)
|
||||
#define D3DERR_EXECUTE_CLIPPED_FAILED MAKE_DDHRESULT(717)
|
||||
|
||||
#define D3DERR_TEXTURE_NO_SUPPORT MAKE_DDHRESULT(720)
|
||||
#define D3DERR_TEXTURE_CREATE_FAILED MAKE_DDHRESULT(721)
|
||||
#define D3DERR_TEXTURE_DESTROY_FAILED MAKE_DDHRESULT(722)
|
||||
#define D3DERR_TEXTURE_LOCK_FAILED MAKE_DDHRESULT(723)
|
||||
#define D3DERR_TEXTURE_UNLOCK_FAILED MAKE_DDHRESULT(724)
|
||||
#define D3DERR_TEXTURE_LOAD_FAILED MAKE_DDHRESULT(725)
|
||||
#define D3DERR_TEXTURE_SWAP_FAILED MAKE_DDHRESULT(726)
|
||||
#define D3DERR_TEXTURE_LOCKED MAKE_DDHRESULT(727)
|
||||
#define D3DERR_TEXTURE_NOT_LOCKED MAKE_DDHRESULT(728)
|
||||
#define D3DERR_TEXTURE_GETSURF_FAILED MAKE_DDHRESULT(729)
|
||||
|
||||
#define D3DERR_MATRIX_CREATE_FAILED MAKE_DDHRESULT(730)
|
||||
#define D3DERR_MATRIX_DESTROY_FAILED MAKE_DDHRESULT(731)
|
||||
#define D3DERR_MATRIX_SETDATA_FAILED MAKE_DDHRESULT(732)
|
||||
#define D3DERR_MATRIX_GETDATA_FAILED MAKE_DDHRESULT(733)
|
||||
#define D3DERR_SETVIEWPORTDATA_FAILED MAKE_DDHRESULT(734)
|
||||
|
||||
#define D3DERR_INVALIDCURRENTVIEWPORT MAKE_DDHRESULT(735)
|
||||
#define D3DERR_INVALIDPRIMITIVETYPE MAKE_DDHRESULT(736)
|
||||
#define D3DERR_INVALIDVERTEXTYPE MAKE_DDHRESULT(737)
|
||||
#define D3DERR_TEXTURE_BADSIZE MAKE_DDHRESULT(738)
|
||||
#define D3DERR_INVALIDRAMPTEXTURE MAKE_DDHRESULT(739)
|
||||
|
||||
#define D3DERR_MATERIAL_CREATE_FAILED MAKE_DDHRESULT(740)
|
||||
#define D3DERR_MATERIAL_DESTROY_FAILED MAKE_DDHRESULT(741)
|
||||
#define D3DERR_MATERIAL_SETDATA_FAILED MAKE_DDHRESULT(742)
|
||||
#define D3DERR_MATERIAL_GETDATA_FAILED MAKE_DDHRESULT(743)
|
||||
#define D3DERR_INVALIDPALETTE MAKE_DDHRESULT(744)
|
||||
|
||||
#define D3DERR_ZBUFF_NEEDS_SYSTEMMEMORY MAKE_DDHRESULT(745)
|
||||
#define D3DERR_ZBUFF_NEEDS_VIDEOMEMORY MAKE_DDHRESULT(746)
|
||||
#define D3DERR_SURFACENOTINVIDMEM MAKE_DDHRESULT(747)
|
||||
|
||||
#define D3DERR_LIGHT_SET_FAILED MAKE_DDHRESULT(750)
|
||||
#define D3DERR_LIGHTHASVIEWPORT MAKE_DDHRESULT(751)
|
||||
#define D3DERR_LIGHTNOTINTHISVIEWPORT MAKE_DDHRESULT(752)
|
||||
|
||||
#define D3DERR_SCENE_IN_SCENE MAKE_DDHRESULT(760)
|
||||
#define D3DERR_SCENE_NOT_IN_SCENE MAKE_DDHRESULT(761)
|
||||
#define D3DERR_SCENE_BEGIN_FAILED MAKE_DDHRESULT(762)
|
||||
#define D3DERR_SCENE_END_FAILED MAKE_DDHRESULT(763)
|
||||
|
||||
#define D3DERR_INBEGIN MAKE_DDHRESULT(770)
|
||||
#define D3DERR_NOTINBEGIN MAKE_DDHRESULT(771)
|
||||
#define D3DERR_NOVIEWPORTS MAKE_DDHRESULT(772)
|
||||
#define D3DERR_VIEWPORTDATANOTSET MAKE_DDHRESULT(773)
|
||||
#define D3DERR_VIEWPORTHASNODEVICE MAKE_DDHRESULT(774)
|
||||
#define D3DERR_NOCURRENTVIEWPORT MAKE_DDHRESULT(775)
|
||||
|
||||
#ifdef __cplusplus
|
||||
};
|
||||
#endif
|
||||
|
||||
#endif /* _D3D_H_ */
|
313
3rdparty/dx5/inc/d3dcaps.h
vendored
Normal file
313
3rdparty/dx5/inc/d3dcaps.h
vendored
Normal file
|
@ -0,0 +1,313 @@
|
|||
/*==========================================================================;
|
||||
*
|
||||
* Copyright (C) 1995-1997 Microsoft Corporation. All Rights Reserved.
|
||||
*
|
||||
* File: d3dcaps.h
|
||||
* Content: Direct3D capabilities include file
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _D3DCAPS_H
|
||||
#define _D3DCAPS_H
|
||||
|
||||
/*
|
||||
* Pull in DirectDraw include file automatically:
|
||||
*/
|
||||
#include <ddraw.h>
|
||||
|
||||
#pragma pack(4)
|
||||
|
||||
/* Description of capabilities of transform */
|
||||
|
||||
typedef struct _D3DTRANSFORMCAPS {
|
||||
DWORD dwSize;
|
||||
DWORD dwCaps;
|
||||
} D3DTRANSFORMCAPS, *LPD3DTRANSFORMCAPS;
|
||||
|
||||
#define D3DTRANSFORMCAPS_CLIP 0x00000001L /* Will clip whilst transforming */
|
||||
|
||||
/* Description of capabilities of lighting */
|
||||
|
||||
typedef struct _D3DLIGHTINGCAPS {
|
||||
DWORD dwSize;
|
||||
DWORD dwCaps; /* Lighting caps */
|
||||
DWORD dwLightingModel; /* Lighting model - RGB or mono */
|
||||
DWORD dwNumLights; /* Number of lights that can be handled */
|
||||
} D3DLIGHTINGCAPS, *LPD3DLIGHTINGCAPS;
|
||||
|
||||
#define D3DLIGHTINGMODEL_RGB 0x00000001L
|
||||
#define D3DLIGHTINGMODEL_MONO 0x00000002L
|
||||
|
||||
#define D3DLIGHTCAPS_POINT 0x00000001L /* Point lights supported */
|
||||
#define D3DLIGHTCAPS_SPOT 0x00000002L /* Spot lights supported */
|
||||
#define D3DLIGHTCAPS_DIRECTIONAL 0x00000004L /* Directional lights supported */
|
||||
#define D3DLIGHTCAPS_PARALLELPOINT 0x00000008L /* Parallel point lights supported */
|
||||
|
||||
/* Description of capabilities for each primitive type */
|
||||
|
||||
typedef struct _D3DPrimCaps {
|
||||
DWORD dwSize;
|
||||
DWORD dwMiscCaps; /* Capability flags */
|
||||
DWORD dwRasterCaps;
|
||||
DWORD dwZCmpCaps;
|
||||
DWORD dwSrcBlendCaps;
|
||||
DWORD dwDestBlendCaps;
|
||||
DWORD dwAlphaCmpCaps;
|
||||
DWORD dwShadeCaps;
|
||||
DWORD dwTextureCaps;
|
||||
DWORD dwTextureFilterCaps;
|
||||
DWORD dwTextureBlendCaps;
|
||||
DWORD dwTextureAddressCaps;
|
||||
DWORD dwStippleWidth; /* maximum width and height of */
|
||||
DWORD dwStippleHeight; /* of supported stipple (up to 32x32) */
|
||||
} D3DPRIMCAPS, *LPD3DPRIMCAPS;
|
||||
|
||||
/* D3DPRIMCAPS dwMiscCaps */
|
||||
|
||||
#define D3DPMISCCAPS_MASKPLANES 0x00000001L
|
||||
#define D3DPMISCCAPS_MASKZ 0x00000002L
|
||||
#define D3DPMISCCAPS_LINEPATTERNREP 0x00000004L
|
||||
#define D3DPMISCCAPS_CONFORMANT 0x00000008L
|
||||
#define D3DPMISCCAPS_CULLNONE 0x00000010L
|
||||
#define D3DPMISCCAPS_CULLCW 0x00000020L
|
||||
#define D3DPMISCCAPS_CULLCCW 0x00000040L
|
||||
|
||||
/* D3DPRIMCAPS dwRasterCaps */
|
||||
|
||||
#define D3DPRASTERCAPS_DITHER 0x00000001L
|
||||
#define D3DPRASTERCAPS_ROP2 0x00000002L
|
||||
#define D3DPRASTERCAPS_XOR 0x00000004L
|
||||
#define D3DPRASTERCAPS_PAT 0x00000008L
|
||||
#define D3DPRASTERCAPS_ZTEST 0x00000010L
|
||||
#define D3DPRASTERCAPS_SUBPIXEL 0x00000020L
|
||||
#define D3DPRASTERCAPS_SUBPIXELX 0x00000040L
|
||||
#define D3DPRASTERCAPS_FOGVERTEX 0x00000080L
|
||||
#define D3DPRASTERCAPS_FOGTABLE 0x00000100L
|
||||
#define D3DPRASTERCAPS_STIPPLE 0x00000200L
|
||||
#define D3DPRASTERCAPS_ANTIALIASSORTDEPENDENT 0x00000400L
|
||||
#define D3DPRASTERCAPS_ANTIALIASSORTINDEPENDENT 0x00000800L
|
||||
#define D3DPRASTERCAPS_ANTIALIASEDGES 0x00001000L
|
||||
#define D3DPRASTERCAPS_MIPMAPLODBIAS 0x00002000L
|
||||
#define D3DPRASTERCAPS_ZBIAS 0x00004000L
|
||||
#define D3DPRASTERCAPS_ZBUFFERLESSHSR 0x00008000L
|
||||
#define D3DPRASTERCAPS_FOGRANGE 0x00010000L
|
||||
#define D3DPRASTERCAPS_ANISOTROPY 0x00020000L
|
||||
|
||||
/* D3DPRIMCAPS dwZCmpCaps, dwAlphaCmpCaps */
|
||||
|
||||
#define D3DPCMPCAPS_NEVER 0x00000001L
|
||||
#define D3DPCMPCAPS_LESS 0x00000002L
|
||||
#define D3DPCMPCAPS_EQUAL 0x00000004L
|
||||
#define D3DPCMPCAPS_LESSEQUAL 0x00000008L
|
||||
#define D3DPCMPCAPS_GREATER 0x00000010L
|
||||
#define D3DPCMPCAPS_NOTEQUAL 0x00000020L
|
||||
#define D3DPCMPCAPS_GREATEREQUAL 0x00000040L
|
||||
#define D3DPCMPCAPS_ALWAYS 0x00000080L
|
||||
|
||||
/* D3DPRIMCAPS dwSourceBlendCaps, dwDestBlendCaps */
|
||||
|
||||
#define D3DPBLENDCAPS_ZERO 0x00000001L
|
||||
#define D3DPBLENDCAPS_ONE 0x00000002L
|
||||
#define D3DPBLENDCAPS_SRCCOLOR 0x00000004L
|
||||
#define D3DPBLENDCAPS_INVSRCCOLOR 0x00000008L
|
||||
#define D3DPBLENDCAPS_SRCALPHA 0x00000010L
|
||||
#define D3DPBLENDCAPS_INVSRCALPHA 0x00000020L
|
||||
#define D3DPBLENDCAPS_DESTALPHA 0x00000040L
|
||||
#define D3DPBLENDCAPS_INVDESTALPHA 0x00000080L
|
||||
#define D3DPBLENDCAPS_DESTCOLOR 0x00000100L
|
||||
#define D3DPBLENDCAPS_INVDESTCOLOR 0x00000200L
|
||||
#define D3DPBLENDCAPS_SRCALPHASAT 0x00000400L
|
||||
#define D3DPBLENDCAPS_BOTHSRCALPHA 0x00000800L
|
||||
#define D3DPBLENDCAPS_BOTHINVSRCALPHA 0x00001000L
|
||||
|
||||
/* D3DPRIMCAPS dwShadeCaps */
|
||||
|
||||
#define D3DPSHADECAPS_COLORFLATMONO 0x00000001L
|
||||
#define D3DPSHADECAPS_COLORFLATRGB 0x00000002L
|
||||
#define D3DPSHADECAPS_COLORGOURAUDMONO 0x00000004L
|
||||
#define D3DPSHADECAPS_COLORGOURAUDRGB 0x00000008L
|
||||
#define D3DPSHADECAPS_COLORPHONGMONO 0x00000010L
|
||||
#define D3DPSHADECAPS_COLORPHONGRGB 0x00000020L
|
||||
|
||||
#define D3DPSHADECAPS_SPECULARFLATMONO 0x00000040L
|
||||
#define D3DPSHADECAPS_SPECULARFLATRGB 0x00000080L
|
||||
#define D3DPSHADECAPS_SPECULARGOURAUDMONO 0x00000100L
|
||||
#define D3DPSHADECAPS_SPECULARGOURAUDRGB 0x00000200L
|
||||
#define D3DPSHADECAPS_SPECULARPHONGMONO 0x00000400L
|
||||
#define D3DPSHADECAPS_SPECULARPHONGRGB 0x00000800L
|
||||
|
||||
#define D3DPSHADECAPS_ALPHAFLATBLEND 0x00001000L
|
||||
#define D3DPSHADECAPS_ALPHAFLATSTIPPLED 0x00002000L
|
||||
#define D3DPSHADECAPS_ALPHAGOURAUDBLEND 0x00004000L
|
||||
#define D3DPSHADECAPS_ALPHAGOURAUDSTIPPLED 0x00008000L
|
||||
#define D3DPSHADECAPS_ALPHAPHONGBLEND 0x00010000L
|
||||
#define D3DPSHADECAPS_ALPHAPHONGSTIPPLED 0x00020000L
|
||||
|
||||
#define D3DPSHADECAPS_FOGFLAT 0x00040000L
|
||||
#define D3DPSHADECAPS_FOGGOURAUD 0x00080000L
|
||||
#define D3DPSHADECAPS_FOGPHONG 0x00100000L
|
||||
|
||||
/* D3DPRIMCAPS dwTextureCaps */
|
||||
|
||||
#define D3DPTEXTURECAPS_PERSPECTIVE 0x00000001L
|
||||
#define D3DPTEXTURECAPS_POW2 0x00000002L
|
||||
#define D3DPTEXTURECAPS_ALPHA 0x00000004L
|
||||
#define D3DPTEXTURECAPS_TRANSPARENCY 0x00000008L
|
||||
#define D3DPTEXTURECAPS_BORDER 0x00000010L
|
||||
#define D3DPTEXTURECAPS_SQUAREONLY 0x00000020L
|
||||
|
||||
/* D3DPRIMCAPS dwTextureFilterCaps */
|
||||
|
||||
#define D3DPTFILTERCAPS_NEAREST 0x00000001L
|
||||
#define D3DPTFILTERCAPS_LINEAR 0x00000002L
|
||||
#define D3DPTFILTERCAPS_MIPNEAREST 0x00000004L
|
||||
#define D3DPTFILTERCAPS_MIPLINEAR 0x00000008L
|
||||
#define D3DPTFILTERCAPS_LINEARMIPNEAREST 0x00000010L
|
||||
#define D3DPTFILTERCAPS_LINEARMIPLINEAR 0x00000020L
|
||||
|
||||
/* D3DPRIMCAPS dwTextureBlendCaps */
|
||||
|
||||
#define D3DPTBLENDCAPS_DECAL 0x00000001L
|
||||
#define D3DPTBLENDCAPS_MODULATE 0x00000002L
|
||||
#define D3DPTBLENDCAPS_DECALALPHA 0x00000004L
|
||||
#define D3DPTBLENDCAPS_MODULATEALPHA 0x00000008L
|
||||
#define D3DPTBLENDCAPS_DECALMASK 0x00000010L
|
||||
#define D3DPTBLENDCAPS_MODULATEMASK 0x00000020L
|
||||
#define D3DPTBLENDCAPS_COPY 0x00000040L
|
||||
#define D3DPTBLENDCAPS_ADD 0x00000080L
|
||||
|
||||
/* D3DPRIMCAPS dwTextureAddressCaps */
|
||||
#define D3DPTADDRESSCAPS_WRAP 0x00000001L
|
||||
#define D3DPTADDRESSCAPS_MIRROR 0x00000002L
|
||||
#define D3DPTADDRESSCAPS_CLAMP 0x00000004L
|
||||
#define D3DPTADDRESSCAPS_BORDER 0x00000008L
|
||||
#define D3DPTADDRESSCAPS_INDEPENDENTUV 0x00000010L
|
||||
|
||||
/*
|
||||
* Description for a device.
|
||||
* This is used to describe a device that is to be created or to query
|
||||
* the current device.
|
||||
*/
|
||||
typedef struct _D3DDeviceDesc {
|
||||
DWORD dwSize; /* Size of D3DDEVICEDESC structure */
|
||||
DWORD dwFlags; /* Indicates which fields have valid data */
|
||||
D3DCOLORMODEL dcmColorModel; /* Color model of device */
|
||||
DWORD dwDevCaps; /* Capabilities of device */
|
||||
D3DTRANSFORMCAPS dtcTransformCaps; /* Capabilities of transform */
|
||||
BOOL bClipping; /* Device can do 3D clipping */
|
||||
D3DLIGHTINGCAPS dlcLightingCaps; /* Capabilities of lighting */
|
||||
D3DPRIMCAPS dpcLineCaps;
|
||||
D3DPRIMCAPS dpcTriCaps;
|
||||
DWORD dwDeviceRenderBitDepth; /* One of DDBB_8, 16, etc.. */
|
||||
DWORD dwDeviceZBufferBitDepth;/* One of DDBD_16, 32, etc.. */
|
||||
DWORD dwMaxBufferSize; /* Maximum execute buffer size */
|
||||
DWORD dwMaxVertexCount; /* Maximum vertex count */
|
||||
// *** New fields for DX5 *** //
|
||||
|
||||
// Width and height caps are 0 for legacy HALs.
|
||||
DWORD dwMinTextureWidth, dwMinTextureHeight;
|
||||
DWORD dwMaxTextureWidth, dwMaxTextureHeight;
|
||||
DWORD dwMinStippleWidth, dwMaxStippleWidth;
|
||||
DWORD dwMinStippleHeight, dwMaxStippleHeight;
|
||||
} D3DDEVICEDESC, *LPD3DDEVICEDESC;
|
||||
|
||||
#define D3DDEVICEDESCSIZE (sizeof(D3DDEVICEDESC))
|
||||
|
||||
typedef HRESULT (FAR PASCAL * LPD3DENUMDEVICESCALLBACK)(LPGUID lpGuid, LPSTR lpDeviceDescription, LPSTR lpDeviceName, LPD3DDEVICEDESC, LPD3DDEVICEDESC, LPVOID);
|
||||
|
||||
/* D3DDEVICEDESC dwFlags indicating valid fields */
|
||||
|
||||
#define D3DDD_COLORMODEL 0x00000001L /* dcmColorModel is valid */
|
||||
#define D3DDD_DEVCAPS 0x00000002L /* dwDevCaps is valid */
|
||||
#define D3DDD_TRANSFORMCAPS 0x00000004L /* dtcTransformCaps is valid */
|
||||
#define D3DDD_LIGHTINGCAPS 0x00000008L /* dlcLightingCaps is valid */
|
||||
#define D3DDD_BCLIPPING 0x00000010L /* bClipping is valid */
|
||||
#define D3DDD_LINECAPS 0x00000020L /* dpcLineCaps is valid */
|
||||
#define D3DDD_TRICAPS 0x00000040L /* dpcTriCaps is valid */
|
||||
#define D3DDD_DEVICERENDERBITDEPTH 0x00000080L /* dwDeviceRenderBitDepth is valid */
|
||||
#define D3DDD_DEVICEZBUFFERBITDEPTH 0x00000100L /* dwDeviceZBufferBitDepth is valid */
|
||||
#define D3DDD_MAXBUFFERSIZE 0x00000200L /* dwMaxBufferSize is valid */
|
||||
#define D3DDD_MAXVERTEXCOUNT 0x00000400L /* dwMaxVertexCount is valid */
|
||||
|
||||
/* D3DDEVICEDESC dwDevCaps flags */
|
||||
|
||||
#define D3DDEVCAPS_FLOATTLVERTEX 0x00000001L /* Device accepts floating point */
|
||||
/* for post-transform vertex data */
|
||||
#define D3DDEVCAPS_SORTINCREASINGZ 0x00000002L /* Device needs data sorted for increasing Z*/
|
||||
#define D3DDEVCAPS_SORTDECREASINGZ 0X00000004L /* Device needs data sorted for decreasing Z*/
|
||||
#define D3DDEVCAPS_SORTEXACT 0x00000008L /* Device needs data sorted exactly */
|
||||
|
||||
#define D3DDEVCAPS_EXECUTESYSTEMMEMORY 0x00000010L /* Device can use execute buffers from system memory */
|
||||
#define D3DDEVCAPS_EXECUTEVIDEOMEMORY 0x00000020L /* Device can use execute buffers from video memory */
|
||||
#define D3DDEVCAPS_TLVERTEXSYSTEMMEMORY 0x00000040L /* Device can use TL buffers from system memory */
|
||||
#define D3DDEVCAPS_TLVERTEXVIDEOMEMORY 0x00000080L /* Device can use TL buffers from video memory */
|
||||
#define D3DDEVCAPS_TEXTURESYSTEMMEMORY 0x00000100L /* Device can texture from system memory */
|
||||
#define D3DDEVCAPS_TEXTUREVIDEOMEMORY 0x00000200L /* Device can texture from device memory */
|
||||
#define D3DDEVCAPS_DRAWPRIMTLVERTEX 0x00000400L /* Device can draw TLVERTEX primitives */
|
||||
#define D3DDEVCAPS_CANRENDERAFTERFLIP 0x00000800L /* Device can render without waiting for flip to complete */
|
||||
#define D3DDEVCAPS_TEXTURENONLOCALVIDMEM 0x00001000L /* Device can texture from nonlocal video memory */
|
||||
|
||||
#define D3DFDS_COLORMODEL 0x00000001L /* Match color model */
|
||||
#define D3DFDS_GUID 0x00000002L /* Match guid */
|
||||
#define D3DFDS_HARDWARE 0x00000004L /* Match hardware/software */
|
||||
#define D3DFDS_TRIANGLES 0x00000008L /* Match in triCaps */
|
||||
#define D3DFDS_LINES 0x00000010L /* Match in lineCaps */
|
||||
#define D3DFDS_MISCCAPS 0x00000020L /* Match primCaps.dwMiscCaps */
|
||||
#define D3DFDS_RASTERCAPS 0x00000040L /* Match primCaps.dwRasterCaps */
|
||||
#define D3DFDS_ZCMPCAPS 0x00000080L /* Match primCaps.dwZCmpCaps */
|
||||
#define D3DFDS_ALPHACMPCAPS 0x00000100L /* Match primCaps.dwAlphaCmpCaps */
|
||||
#define D3DFDS_SRCBLENDCAPS 0x00000200L /* Match primCaps.dwSourceBlendCaps */
|
||||
#define D3DFDS_DSTBLENDCAPS 0x00000400L /* Match primCaps.dwDestBlendCaps */
|
||||
#define D3DFDS_SHADECAPS 0x00000800L /* Match primCaps.dwShadeCaps */
|
||||
#define D3DFDS_TEXTURECAPS 0x00001000L /* Match primCaps.dwTextureCaps */
|
||||
#define D3DFDS_TEXTUREFILTERCAPS 0x00002000L /* Match primCaps.dwTextureFilterCaps */
|
||||
#define D3DFDS_TEXTUREBLENDCAPS 0x00004000L /* Match primCaps.dwTextureBlendCaps */
|
||||
#define D3DFDS_TEXTUREADDRESSCAPS 0x00008000L /* Match primCaps.dwTextureBlendCaps */
|
||||
|
||||
/*
|
||||
* FindDevice arguments
|
||||
*/
|
||||
typedef struct _D3DFINDDEVICESEARCH {
|
||||
DWORD dwSize;
|
||||
DWORD dwFlags;
|
||||
BOOL bHardware;
|
||||
D3DCOLORMODEL dcmColorModel;
|
||||
GUID guid;
|
||||
DWORD dwCaps;
|
||||
D3DPRIMCAPS dpcPrimCaps;
|
||||
} D3DFINDDEVICESEARCH, *LPD3DFINDDEVICESEARCH;
|
||||
|
||||
typedef struct _D3DFINDDEVICERESULT {
|
||||
DWORD dwSize;
|
||||
GUID guid; /* guid which matched */
|
||||
D3DDEVICEDESC ddHwDesc; /* hardware D3DDEVICEDESC */
|
||||
D3DDEVICEDESC ddSwDesc; /* software D3DDEVICEDESC */
|
||||
} D3DFINDDEVICERESULT, *LPD3DFINDDEVICERESULT;
|
||||
|
||||
|
||||
/*
|
||||
* Description of execute buffer.
|
||||
*/
|
||||
typedef struct _D3DExecuteBufferDesc {
|
||||
DWORD dwSize; /* size of this structure */
|
||||
DWORD dwFlags; /* flags indicating which fields are valid */
|
||||
DWORD dwCaps; /* capabilities of execute buffer */
|
||||
DWORD dwBufferSize; /* size of execute buffer data */
|
||||
LPVOID lpData; /* pointer to actual data */
|
||||
} D3DEXECUTEBUFFERDESC, *LPD3DEXECUTEBUFFERDESC;
|
||||
|
||||
/* D3DEXECUTEBUFFER dwFlags indicating valid fields */
|
||||
|
||||
#define D3DDEB_BUFSIZE 0x00000001l /* buffer size valid */
|
||||
#define D3DDEB_CAPS 0x00000002l /* caps valid */
|
||||
#define D3DDEB_LPDATA 0x00000004l /* lpData valid */
|
||||
|
||||
/* D3DEXECUTEBUFFER dwCaps */
|
||||
|
||||
#define D3DDEBCAPS_SYSTEMMEMORY 0x00000001l /* buffer in system memory */
|
||||
#define D3DDEBCAPS_VIDEOMEMORY 0x00000002l /* buffer in device memory */
|
||||
#define D3DDEBCAPS_MEM (D3DDEBCAPS_SYSTEMMEMORY|D3DDEBCAPS_VIDEOMEMORY)
|
||||
|
||||
#pragma pack()
|
||||
|
||||
#endif /* _D3DCAPS_H_ */
|
229
3rdparty/dx5/inc/d3drm.h
vendored
Normal file
229
3rdparty/dx5/inc/d3drm.h
vendored
Normal file
|
@ -0,0 +1,229 @@
|
|||
/*==========================================================================;
|
||||
*
|
||||
* Copyright (C) 1995-1997 Microsoft Corporation. All Rights Reserved.
|
||||
*
|
||||
* File: d3drm.h
|
||||
* Content: Direct3DRM include file
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef __D3DRM_H__
|
||||
#define __D3DRM_H__
|
||||
|
||||
#include "ddraw.h"
|
||||
#include "d3drmobj.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
struct IDirect3DRM;
|
||||
#endif
|
||||
|
||||
|
||||
DEFINE_GUID(IID_IDirect3DRM, 0x2bc49361, 0x8327, 0x11cf, 0xac, 0x4a, 0x0, 0x0, 0xc0, 0x38, 0x25, 0xa1);
|
||||
DEFINE_GUID(IID_IDirect3DRM2, 0x4516ecc8, 0x8f20, 0x11d0, 0x9b, 0x6d, 0x00, 0x00, 0xc0, 0x78, 0x1b, 0xc3);
|
||||
WIN_TYPES(IDirect3DRM, DIRECT3DRM);
|
||||
WIN_TYPES(IDirect3DRM2, DIRECT3DRM2);
|
||||
|
||||
|
||||
/* Create a Direct3DRM API */
|
||||
STDAPI Direct3DRMCreate(LPDIRECT3DRM FAR *lplpDirect3DRM);
|
||||
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3DRM
|
||||
|
||||
DECLARE_INTERFACE_(IDirect3DRM, IUnknown)
|
||||
{
|
||||
IUNKNOWN_METHODS(PURE);
|
||||
|
||||
STDMETHOD(CreateObject)
|
||||
(THIS_ REFCLSID rclsid, LPUNKNOWN pUnkOuter, REFIID riid, LPVOID FAR* ppv) PURE;
|
||||
STDMETHOD(CreateFrame) (THIS_ LPDIRECT3DRMFRAME, LPDIRECT3DRMFRAME *) PURE;
|
||||
STDMETHOD(CreateMesh) (THIS_ LPDIRECT3DRMMESH *) PURE;
|
||||
STDMETHOD(CreateMeshBuilder)(THIS_ LPDIRECT3DRMMESHBUILDER *) PURE;
|
||||
STDMETHOD(CreateFace) (THIS_ LPDIRECT3DRMFACE *) PURE;
|
||||
STDMETHOD(CreateAnimation) (THIS_ LPDIRECT3DRMANIMATION *) PURE;
|
||||
STDMETHOD(CreateAnimationSet)(THIS_ LPDIRECT3DRMANIMATIONSET *) PURE;
|
||||
STDMETHOD(CreateTexture) (THIS_ LPD3DRMIMAGE, LPDIRECT3DRMTEXTURE *) PURE;
|
||||
STDMETHOD(CreateLight) (THIS_ D3DRMLIGHTTYPE, D3DCOLOR, LPDIRECT3DRMLIGHT *) PURE;
|
||||
STDMETHOD(CreateLightRGB)
|
||||
(THIS_ D3DRMLIGHTTYPE, D3DVALUE, D3DVALUE, D3DVALUE, LPDIRECT3DRMLIGHT *) PURE;
|
||||
STDMETHOD(CreateMaterial) (THIS_ D3DVALUE, LPDIRECT3DRMMATERIAL *) PURE;
|
||||
STDMETHOD(CreateDevice) (THIS_ DWORD, DWORD, LPDIRECT3DRMDEVICE *) PURE;
|
||||
|
||||
/* Create a Windows Device using DirectDraw surfaces */
|
||||
STDMETHOD(CreateDeviceFromSurface)
|
||||
( THIS_ LPGUID lpGUID, LPDIRECTDRAW lpDD,
|
||||
LPDIRECTDRAWSURFACE lpDDSBack, LPDIRECT3DRMDEVICE *
|
||||
) PURE;
|
||||
|
||||
/* Create a Windows Device using D3D objects */
|
||||
STDMETHOD(CreateDeviceFromD3D)
|
||||
( THIS_ LPDIRECT3D lpD3D, LPDIRECT3DDEVICE lpD3DDev,
|
||||
LPDIRECT3DRMDEVICE *
|
||||
) PURE;
|
||||
|
||||
STDMETHOD(CreateDeviceFromClipper)
|
||||
( THIS_ LPDIRECTDRAWCLIPPER lpDDClipper, LPGUID lpGUID,
|
||||
int width, int height, LPDIRECT3DRMDEVICE *) PURE;
|
||||
|
||||
STDMETHOD(CreateTextureFromSurface)(THIS_ LPDIRECTDRAWSURFACE lpDDS, LPDIRECT3DRMTEXTURE *) PURE;
|
||||
|
||||
STDMETHOD(CreateShadow)
|
||||
( THIS_ LPDIRECT3DRMVISUAL, LPDIRECT3DRMLIGHT,
|
||||
D3DVALUE px, D3DVALUE py, D3DVALUE pz,
|
||||
D3DVALUE nx, D3DVALUE ny, D3DVALUE nz,
|
||||
LPDIRECT3DRMVISUAL *
|
||||
) PURE;
|
||||
STDMETHOD(CreateViewport)
|
||||
( THIS_ LPDIRECT3DRMDEVICE, LPDIRECT3DRMFRAME, DWORD, DWORD,
|
||||
DWORD, DWORD, LPDIRECT3DRMVIEWPORT *
|
||||
) PURE;
|
||||
STDMETHOD(CreateWrap)
|
||||
( THIS_ D3DRMWRAPTYPE, LPDIRECT3DRMFRAME,
|
||||
D3DVALUE ox, D3DVALUE oy, D3DVALUE oz,
|
||||
D3DVALUE dx, D3DVALUE dy, D3DVALUE dz,
|
||||
D3DVALUE ux, D3DVALUE uy, D3DVALUE uz,
|
||||
D3DVALUE ou, D3DVALUE ov,
|
||||
D3DVALUE su, D3DVALUE sv,
|
||||
LPDIRECT3DRMWRAP *
|
||||
) PURE;
|
||||
STDMETHOD(CreateUserVisual) (THIS_ D3DRMUSERVISUALCALLBACK, LPVOID lPArg, LPDIRECT3DRMUSERVISUAL *) PURE;
|
||||
STDMETHOD(LoadTexture) (THIS_ const char *, LPDIRECT3DRMTEXTURE *) PURE;
|
||||
STDMETHOD(LoadTextureFromResource) (THIS_ HRSRC rs, LPDIRECT3DRMTEXTURE *) PURE;
|
||||
|
||||
STDMETHOD(SetSearchPath) (THIS_ LPCSTR) PURE;
|
||||
STDMETHOD(AddSearchPath) (THIS_ LPCSTR) PURE;
|
||||
STDMETHOD(GetSearchPath) (THIS_ DWORD *size_return, LPSTR path_return) PURE;
|
||||
STDMETHOD(SetDefaultTextureColors)(THIS_ DWORD) PURE;
|
||||
STDMETHOD(SetDefaultTextureShades)(THIS_ DWORD) PURE;
|
||||
|
||||
STDMETHOD(GetDevices) (THIS_ LPDIRECT3DRMDEVICEARRAY *) PURE;
|
||||
STDMETHOD(GetNamedObject) (THIS_ const char *, LPDIRECT3DRMOBJECT *) PURE;
|
||||
|
||||
STDMETHOD(EnumerateObjects) (THIS_ D3DRMOBJECTCALLBACK, LPVOID) PURE;
|
||||
|
||||
STDMETHOD(Load)
|
||||
( THIS_ LPVOID, LPVOID, LPIID *, DWORD, D3DRMLOADOPTIONS,
|
||||
D3DRMLOADCALLBACK, LPVOID, D3DRMLOADTEXTURECALLBACK, LPVOID,
|
||||
LPDIRECT3DRMFRAME
|
||||
) PURE;
|
||||
STDMETHOD(Tick) (THIS_ D3DVALUE) PURE;
|
||||
};
|
||||
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3DRM2
|
||||
|
||||
DECLARE_INTERFACE_(IDirect3DRM2, IUnknown)
|
||||
{
|
||||
IUNKNOWN_METHODS(PURE);
|
||||
|
||||
STDMETHOD(CreateObject)
|
||||
(THIS_ REFCLSID rclsid, LPUNKNOWN pUnkOuter, REFIID riid, LPVOID FAR* ppv) PURE;
|
||||
STDMETHOD(CreateFrame) (THIS_ LPDIRECT3DRMFRAME, LPDIRECT3DRMFRAME2 *) PURE;
|
||||
STDMETHOD(CreateMesh) (THIS_ LPDIRECT3DRMMESH *) PURE;
|
||||
STDMETHOD(CreateMeshBuilder)(THIS_ LPDIRECT3DRMMESHBUILDER2 *) PURE;
|
||||
STDMETHOD(CreateFace) (THIS_ LPDIRECT3DRMFACE *) PURE;
|
||||
STDMETHOD(CreateAnimation) (THIS_ LPDIRECT3DRMANIMATION *) PURE;
|
||||
STDMETHOD(CreateAnimationSet)(THIS_ LPDIRECT3DRMANIMATIONSET *) PURE;
|
||||
STDMETHOD(CreateTexture) (THIS_ LPD3DRMIMAGE, LPDIRECT3DRMTEXTURE2 *) PURE;
|
||||
STDMETHOD(CreateLight) (THIS_ D3DRMLIGHTTYPE, D3DCOLOR, LPDIRECT3DRMLIGHT *) PURE;
|
||||
STDMETHOD(CreateLightRGB)
|
||||
(THIS_ D3DRMLIGHTTYPE, D3DVALUE, D3DVALUE, D3DVALUE, LPDIRECT3DRMLIGHT *) PURE;
|
||||
STDMETHOD(CreateMaterial) (THIS_ D3DVALUE, LPDIRECT3DRMMATERIAL *) PURE;
|
||||
STDMETHOD(CreateDevice) (THIS_ DWORD, DWORD, LPDIRECT3DRMDEVICE2 *) PURE;
|
||||
|
||||
/* Create a Windows Device using DirectDraw surfaces */
|
||||
STDMETHOD(CreateDeviceFromSurface)
|
||||
( THIS_ LPGUID lpGUID, LPDIRECTDRAW lpDD,
|
||||
LPDIRECTDRAWSURFACE lpDDSBack, LPDIRECT3DRMDEVICE2 *
|
||||
) PURE;
|
||||
|
||||
/* Create a Windows Device using D3D objects */
|
||||
STDMETHOD(CreateDeviceFromD3D)
|
||||
( THIS_ LPDIRECT3D2 lpD3D, LPDIRECT3DDEVICE2 lpD3DDev,
|
||||
LPDIRECT3DRMDEVICE2 *
|
||||
) PURE;
|
||||
|
||||
STDMETHOD(CreateDeviceFromClipper)
|
||||
( THIS_ LPDIRECTDRAWCLIPPER lpDDClipper, LPGUID lpGUID,
|
||||
int width, int height, LPDIRECT3DRMDEVICE2 *) PURE;
|
||||
|
||||
STDMETHOD(CreateTextureFromSurface)(THIS_ LPDIRECTDRAWSURFACE lpDDS, LPDIRECT3DRMTEXTURE2 *) PURE;
|
||||
|
||||
STDMETHOD(CreateShadow)
|
||||
( THIS_ LPDIRECT3DRMVISUAL, LPDIRECT3DRMLIGHT,
|
||||
D3DVALUE px, D3DVALUE py, D3DVALUE pz,
|
||||
D3DVALUE nx, D3DVALUE ny, D3DVALUE nz,
|
||||
LPDIRECT3DRMVISUAL *
|
||||
) PURE;
|
||||
STDMETHOD(CreateViewport)
|
||||
( THIS_ LPDIRECT3DRMDEVICE, LPDIRECT3DRMFRAME, DWORD, DWORD,
|
||||
DWORD, DWORD, LPDIRECT3DRMVIEWPORT *
|
||||
) PURE;
|
||||
STDMETHOD(CreateWrap)
|
||||
( THIS_ D3DRMWRAPTYPE, LPDIRECT3DRMFRAME,
|
||||
D3DVALUE ox, D3DVALUE oy, D3DVALUE oz,
|
||||
D3DVALUE dx, D3DVALUE dy, D3DVALUE dz,
|
||||
D3DVALUE ux, D3DVALUE uy, D3DVALUE uz,
|
||||
D3DVALUE ou, D3DVALUE ov,
|
||||
D3DVALUE su, D3DVALUE sv,
|
||||
LPDIRECT3DRMWRAP *
|
||||
) PURE;
|
||||
STDMETHOD(CreateUserVisual) (THIS_ D3DRMUSERVISUALCALLBACK, LPVOID lPArg, LPDIRECT3DRMUSERVISUAL *) PURE;
|
||||
STDMETHOD(LoadTexture) (THIS_ const char *, LPDIRECT3DRMTEXTURE2 *) PURE;
|
||||
STDMETHOD(LoadTextureFromResource) (THIS_ HMODULE hModule, LPCTSTR strName, LPCTSTR strType, LPDIRECT3DRMTEXTURE2 *) PURE;
|
||||
|
||||
STDMETHOD(SetSearchPath) (THIS_ LPCSTR) PURE;
|
||||
STDMETHOD(AddSearchPath) (THIS_ LPCSTR) PURE;
|
||||
STDMETHOD(GetSearchPath) (THIS_ DWORD *size_return, LPSTR path_return) PURE;
|
||||
STDMETHOD(SetDefaultTextureColors)(THIS_ DWORD) PURE;
|
||||
STDMETHOD(SetDefaultTextureShades)(THIS_ DWORD) PURE;
|
||||
|
||||
STDMETHOD(GetDevices) (THIS_ LPDIRECT3DRMDEVICEARRAY *) PURE;
|
||||
STDMETHOD(GetNamedObject) (THIS_ const char *, LPDIRECT3DRMOBJECT *) PURE;
|
||||
|
||||
STDMETHOD(EnumerateObjects) (THIS_ D3DRMOBJECTCALLBACK, LPVOID) PURE;
|
||||
|
||||
STDMETHOD(Load)
|
||||
( THIS_ LPVOID, LPVOID, LPIID *, DWORD, D3DRMLOADOPTIONS,
|
||||
D3DRMLOADCALLBACK, LPVOID, D3DRMLOADTEXTURECALLBACK, LPVOID,
|
||||
LPDIRECT3DRMFRAME
|
||||
) PURE;
|
||||
STDMETHOD(Tick) (THIS_ D3DVALUE) PURE;
|
||||
|
||||
STDMETHOD(CreateProgressiveMesh)(THIS_ LPDIRECT3DRMPROGRESSIVEMESH *) PURE;
|
||||
};
|
||||
|
||||
#define D3DRM_OK DD_OK
|
||||
#define D3DRMERR_BADOBJECT MAKE_DDHRESULT(781)
|
||||
#define D3DRMERR_BADTYPE MAKE_DDHRESULT(782)
|
||||
#define D3DRMERR_BADALLOC MAKE_DDHRESULT(783)
|
||||
#define D3DRMERR_FACEUSED MAKE_DDHRESULT(784)
|
||||
#define D3DRMERR_NOTFOUND MAKE_DDHRESULT(785)
|
||||
#define D3DRMERR_NOTDONEYET MAKE_DDHRESULT(786)
|
||||
#define D3DRMERR_FILENOTFOUND MAKE_DDHRESULT(787)
|
||||
#define D3DRMERR_BADFILE MAKE_DDHRESULT(788)
|
||||
#define D3DRMERR_BADDEVICE MAKE_DDHRESULT(789)
|
||||
#define D3DRMERR_BADVALUE MAKE_DDHRESULT(790)
|
||||
#define D3DRMERR_BADMAJORVERSION MAKE_DDHRESULT(791)
|
||||
#define D3DRMERR_BADMINORVERSION MAKE_DDHRESULT(792)
|
||||
#define D3DRMERR_UNABLETOEXECUTE MAKE_DDHRESULT(793)
|
||||
#define D3DRMERR_LIBRARYNOTFOUND MAKE_DDHRESULT(794)
|
||||
#define D3DRMERR_INVALIDLIBRARY MAKE_DDHRESULT(795)
|
||||
#define D3DRMERR_PENDING MAKE_DDHRESULT(796)
|
||||
#define D3DRMERR_NOTENOUGHDATA MAKE_DDHRESULT(797)
|
||||
#define D3DRMERR_REQUESTTOOLARGE MAKE_DDHRESULT(798)
|
||||
#define D3DRMERR_REQUESTTOOSMALL MAKE_DDHRESULT(799)
|
||||
#define D3DRMERR_CONNECTIONLOST MAKE_DDHRESULT(800)
|
||||
#define D3DRMERR_LOADABORTED MAKE_DDHRESULT(801)
|
||||
#define D3DRMERR_NOINTERNET MAKE_DDHRESULT(802)
|
||||
#define D3DRMERR_BADCACHEFILE MAKE_DDHRESULT(803)
|
||||
#define D3DRMERR_BOXNOTSET MAKE_DDHRESULT(804)
|
||||
#define D3DRMERR_BADPMDATA MAKE_DDHRESULT(805)
|
||||
|
||||
#ifdef __cplusplus
|
||||
};
|
||||
#endif
|
||||
|
||||
#endif /* _D3DRMAPI_H_ */
|
||||
|
472
3rdparty/dx5/inc/d3drmdef.h
vendored
Normal file
472
3rdparty/dx5/inc/d3drmdef.h
vendored
Normal file
|
@ -0,0 +1,472 @@
|
|||
/*==========================================================================;
|
||||
*
|
||||
* Copyright (C) 1995-1997 Microsoft Corporation. All Rights Reserved.
|
||||
*
|
||||
* File: d3drm.h
|
||||
* Content: Direct3DRM include file
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef __D3DRMDEFS_H__
|
||||
#define __D3DRMDEFS_H__
|
||||
|
||||
#include <stddef.h>
|
||||
#include "d3dtypes.h"
|
||||
|
||||
#ifdef WIN32
|
||||
#define D3DRMAPI __stdcall
|
||||
#else
|
||||
#define D3DRMAPI
|
||||
#endif
|
||||
|
||||
#if defined(__cplusplus)
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef TRUE
|
||||
#define FALSE 0
|
||||
#define TRUE 1
|
||||
#endif
|
||||
|
||||
typedef struct _D3DRMVECTOR4D
|
||||
{ D3DVALUE x, y, z, w;
|
||||
} D3DRMVECTOR4D, *LPD3DRMVECTOR4D;
|
||||
|
||||
typedef D3DVALUE D3DRMMATRIX4D[4][4];
|
||||
|
||||
typedef struct _D3DRMQUATERNION
|
||||
{ D3DVALUE s;
|
||||
D3DVECTOR v;
|
||||
} D3DRMQUATERNION, *LPD3DRMQUATERNION;
|
||||
|
||||
typedef struct _D3DRMRAY
|
||||
{ D3DVECTOR dvDir;
|
||||
D3DVECTOR dvPos;
|
||||
} D3DRMRAY, *LPD3DRMRAY;
|
||||
|
||||
typedef struct _D3DRMBOX
|
||||
{ D3DVECTOR min, max;
|
||||
} D3DRMBOX, *LPD3DRMBOX;
|
||||
|
||||
typedef void (*D3DRMWRAPCALLBACK)
|
||||
(LPD3DVECTOR, int* u, int* v, LPD3DVECTOR a, LPD3DVECTOR b, LPVOID);
|
||||
|
||||
typedef enum _D3DRMLIGHTTYPE
|
||||
{ D3DRMLIGHT_AMBIENT,
|
||||
D3DRMLIGHT_POINT,
|
||||
D3DRMLIGHT_SPOT,
|
||||
D3DRMLIGHT_DIRECTIONAL,
|
||||
D3DRMLIGHT_PARALLELPOINT
|
||||
} D3DRMLIGHTTYPE, *LPD3DRMLIGHTTYPE;
|
||||
|
||||
typedef enum _D3DRMSHADEMODE {
|
||||
D3DRMSHADE_FLAT = 0,
|
||||
D3DRMSHADE_GOURAUD = 1,
|
||||
D3DRMSHADE_PHONG = 2,
|
||||
|
||||
D3DRMSHADE_MASK = 7,
|
||||
D3DRMSHADE_MAX = 8
|
||||
} D3DRMSHADEMODE, *LPD3DRMSHADEMODE;
|
||||
|
||||
typedef enum _D3DRMLIGHTMODE {
|
||||
D3DRMLIGHT_OFF = 0 * D3DRMSHADE_MAX,
|
||||
D3DRMLIGHT_ON = 1 * D3DRMSHADE_MAX,
|
||||
|
||||
D3DRMLIGHT_MASK = 7 * D3DRMSHADE_MAX,
|
||||
D3DRMLIGHT_MAX = 8 * D3DRMSHADE_MAX
|
||||
} D3DRMLIGHTMODE, *LPD3DRMLIGHTMODE;
|
||||
|
||||
typedef enum _D3DRMFILLMODE {
|
||||
D3DRMFILL_POINTS = 0 * D3DRMLIGHT_MAX,
|
||||
D3DRMFILL_WIREFRAME = 1 * D3DRMLIGHT_MAX,
|
||||
D3DRMFILL_SOLID = 2 * D3DRMLIGHT_MAX,
|
||||
|
||||
D3DRMFILL_MASK = 7 * D3DRMLIGHT_MAX,
|
||||
D3DRMFILL_MAX = 8 * D3DRMLIGHT_MAX
|
||||
} D3DRMFILLMODE, *LPD3DRMFILLMODE;
|
||||
|
||||
typedef DWORD D3DRMRENDERQUALITY, *LPD3DRMRENDERQUALITY;
|
||||
|
||||
#define D3DRMRENDER_WIREFRAME (D3DRMSHADE_FLAT+D3DRMLIGHT_OFF+D3DRMFILL_WIREFRAME)
|
||||
#define D3DRMRENDER_UNLITFLAT (D3DRMSHADE_FLAT+D3DRMLIGHT_OFF+D3DRMFILL_SOLID)
|
||||
#define D3DRMRENDER_FLAT (D3DRMSHADE_FLAT+D3DRMLIGHT_ON+D3DRMFILL_SOLID)
|
||||
#define D3DRMRENDER_GOURAUD (D3DRMSHADE_GOURAUD+D3DRMLIGHT_ON+D3DRMFILL_SOLID)
|
||||
#define D3DRMRENDER_PHONG (D3DRMSHADE_PHONG+D3DRMLIGHT_ON+D3DRMFILL_SOLID)
|
||||
|
||||
#define D3DRMRENDERMODE_BLENDEDTRANSPARENCY 1
|
||||
#define D3DRMRENDERMODE_SORTEDTRANSPARENCY 2
|
||||
|
||||
typedef enum _D3DRMTEXTUREQUALITY
|
||||
{ D3DRMTEXTURE_NEAREST, /* choose nearest texel */
|
||||
D3DRMTEXTURE_LINEAR, /* interpolate 4 texels */
|
||||
D3DRMTEXTURE_MIPNEAREST, /* nearest texel in nearest mipmap */
|
||||
D3DRMTEXTURE_MIPLINEAR, /* interpolate 2 texels from 2 mipmaps */
|
||||
D3DRMTEXTURE_LINEARMIPNEAREST, /* interpolate 4 texels in nearest mipmap */
|
||||
D3DRMTEXTURE_LINEARMIPLINEAR /* interpolate 8 texels from 2 mipmaps */
|
||||
} D3DRMTEXTUREQUALITY, *LPD3DRMTEXTUREQUALITY;
|
||||
|
||||
typedef enum _D3DRMCOMBINETYPE
|
||||
{ D3DRMCOMBINE_REPLACE,
|
||||
D3DRMCOMBINE_BEFORE,
|
||||
D3DRMCOMBINE_AFTER
|
||||
} D3DRMCOMBINETYPE, *LPD3DRMCOMBINETYPE;
|
||||
|
||||
typedef D3DCOLORMODEL D3DRMCOLORMODEL, *LPD3DRMCOLORMODEL;
|
||||
|
||||
typedef enum _D3DRMPALETTEFLAGS
|
||||
{ D3DRMPALETTE_FREE, /* renderer may use this entry freely */
|
||||
D3DRMPALETTE_READONLY, /* fixed but may be used by renderer */
|
||||
D3DRMPALETTE_RESERVED /* may not be used by renderer */
|
||||
} D3DRMPALETTEFLAGS, *LPD3DRMPALETTEFLAGS;
|
||||
|
||||
typedef struct _D3DRMPALETTEENTRY
|
||||
{ unsigned char red; /* 0 .. 255 */
|
||||
unsigned char green; /* 0 .. 255 */
|
||||
unsigned char blue; /* 0 .. 255 */
|
||||
unsigned char flags; /* one of D3DRMPALETTEFLAGS */
|
||||
} D3DRMPALETTEENTRY, *LPD3DRMPALETTEENTRY;
|
||||
|
||||
typedef struct _D3DRMIMAGE
|
||||
{ int width, height; /* width and height in pixels */
|
||||
int aspectx, aspecty; /* aspect ratio for non-square pixels */
|
||||
int depth; /* bits per pixel */
|
||||
int rgb; /* if false, pixels are indices into a
|
||||
palette otherwise, pixels encode
|
||||
RGB values. */
|
||||
int bytes_per_line; /* number of bytes of memory for a
|
||||
scanline. This must be a multiple
|
||||
of 4. */
|
||||
void* buffer1; /* memory to render into (first buffer). */
|
||||
void* buffer2; /* second rendering buffer for double
|
||||
buffering, set to NULL for single
|
||||
buffering. */
|
||||
unsigned long red_mask;
|
||||
unsigned long green_mask;
|
||||
unsigned long blue_mask;
|
||||
unsigned long alpha_mask; /* if rgb is true, these are masks for
|
||||
the red, green and blue parts of a
|
||||
pixel. Otherwise, these are masks
|
||||
for the significant bits of the
|
||||
red, green and blue elements in the
|
||||
palette. For instance, most SVGA
|
||||
displays use 64 intensities of red,
|
||||
green and blue, so the masks should
|
||||
all be set to 0xfc. */
|
||||
int palette_size; /* number of entries in palette */
|
||||
D3DRMPALETTEENTRY* palette; /* description of the palette (only if
|
||||
rgb is false). Must be (1<<depth)
|
||||
elements. */
|
||||
} D3DRMIMAGE, *LPD3DRMIMAGE;
|
||||
|
||||
typedef enum _D3DRMWRAPTYPE
|
||||
{ D3DRMWRAP_FLAT,
|
||||
D3DRMWRAP_CYLINDER,
|
||||
D3DRMWRAP_SPHERE,
|
||||
D3DRMWRAP_CHROME
|
||||
} D3DRMWRAPTYPE, *LPD3DRMWRAPTYPE;
|
||||
|
||||
#define D3DRMWIREFRAME_CULL 1 /* cull backfaces */
|
||||
#define D3DRMWIREFRAME_HIDDENLINE 2 /* lines are obscured by closer objects */
|
||||
|
||||
typedef enum _D3DRMPROJECTIONTYPE
|
||||
{ D3DRMPROJECT_PERSPECTIVE,
|
||||
D3DRMPROJECT_ORTHOGRAPHIC,
|
||||
D3DRMPROJECT_RIGHTHANDPERSPECTIVE,
|
||||
D3DRMPROJECT_RIGHTHANDORTHOGRAPHIC
|
||||
} D3DRMPROJECTIONTYPE, *LPD3DRMPROJECTIONTYPE;
|
||||
|
||||
typedef enum _D3DRMXOFFORMAT
|
||||
{ D3DRMXOF_BINARY,
|
||||
D3DRMXOF_COMPRESSED,
|
||||
D3DRMXOF_TEXT
|
||||
} D3DRMXOFFORMAT, *LPD3DRMXOFFORMAT;
|
||||
|
||||
typedef DWORD D3DRMSAVEOPTIONS;
|
||||
#define D3DRMXOFSAVE_NORMALS 1
|
||||
#define D3DRMXOFSAVE_TEXTURECOORDINATES 2
|
||||
#define D3DRMXOFSAVE_MATERIALS 4
|
||||
#define D3DRMXOFSAVE_TEXTURENAMES 8
|
||||
#define D3DRMXOFSAVE_ALL 15
|
||||
#define D3DRMXOFSAVE_TEMPLATES 16
|
||||
#define D3DRMXOFSAVE_TEXTURETOPOLOGY 32
|
||||
|
||||
typedef enum _D3DRMCOLORSOURCE
|
||||
{ D3DRMCOLOR_FROMFACE,
|
||||
D3DRMCOLOR_FROMVERTEX
|
||||
} D3DRMCOLORSOURCE, *LPD3DRMCOLORSOURCE;
|
||||
|
||||
typedef enum _D3DRMFRAMECONSTRAINT
|
||||
{ D3DRMCONSTRAIN_Z, /* use only X and Y rotations */
|
||||
D3DRMCONSTRAIN_Y, /* use only X and Z rotations */
|
||||
D3DRMCONSTRAIN_X /* use only Y and Z rotations */
|
||||
} D3DRMFRAMECONSTRAINT, *LPD3DRMFRAMECONSTRAINT;
|
||||
|
||||
typedef enum _D3DRMMATERIALMODE
|
||||
{ D3DRMMATERIAL_FROMMESH,
|
||||
D3DRMMATERIAL_FROMPARENT,
|
||||
D3DRMMATERIAL_FROMFRAME
|
||||
} D3DRMMATERIALMODE, *LPD3DRMMATERIALMODE;
|
||||
|
||||
typedef enum _D3DRMFOGMODE
|
||||
{ D3DRMFOG_LINEAR, /* linear between start and end */
|
||||
D3DRMFOG_EXPONENTIAL, /* density * exp(-distance) */
|
||||
D3DRMFOG_EXPONENTIALSQUARED /* density * exp(-distance*distance) */
|
||||
} D3DRMFOGMODE, *LPD3DRMFOGMODE;
|
||||
|
||||
typedef enum _D3DRMZBUFFERMODE {
|
||||
D3DRMZBUFFER_FROMPARENT, /* default */
|
||||
D3DRMZBUFFER_ENABLE, /* enable zbuffering */
|
||||
D3DRMZBUFFER_DISABLE /* disable zbuffering */
|
||||
} D3DRMZBUFFERMODE, *LPD3DRMZBUFFERMODE;
|
||||
|
||||
typedef enum _D3DRMSORTMODE {
|
||||
D3DRMSORT_FROMPARENT, /* default */
|
||||
D3DRMSORT_NONE, /* don't sort child frames */
|
||||
D3DRMSORT_FRONTTOBACK, /* sort child frames front-to-back */
|
||||
D3DRMSORT_BACKTOFRONT /* sort child frames back-to-front */
|
||||
} D3DRMSORTMODE, *LPD3DRMSORTMODE;
|
||||
|
||||
/*
|
||||
* Values for flags in Frame2::AddMoveCallback.
|
||||
*/
|
||||
#define D3DRMCALLBACK_PREORDER 0
|
||||
#define D3DRMCALLBACK_POSTORDER 1
|
||||
|
||||
/*
|
||||
* Values for flags in MeshBuilder2::RayPick.
|
||||
*/
|
||||
#define D3DRMRAYPICK_ONLYBOUNDINGBOXES 1
|
||||
#define D3DRMRAYPICK_IGNOREFURTHERPRIMITIVES 2
|
||||
#define D3DRMRAYPICK_INTERPOLATEUV 4
|
||||
#define D3DRMRAYPICK_INTERPOLATECOLOR 8
|
||||
#define D3DRMRAYPICK_INTERPOLATENORMAL 0x10
|
||||
|
||||
/*
|
||||
* Values for flags in MeshBuilder2::GenerateNormals.
|
||||
*/
|
||||
#define D3DRMGENERATENORMALS_PRECOMPACT 1
|
||||
#define D3DRMGENERATENORMALS_USECREASEANGLE 2
|
||||
|
||||
typedef DWORD D3DRMANIMATIONOPTIONS;
|
||||
#define D3DRMANIMATION_OPEN 0x01L
|
||||
#define D3DRMANIMATION_CLOSED 0x02L
|
||||
#define D3DRMANIMATION_LINEARPOSITION 0x04L
|
||||
#define D3DRMANIMATION_SPLINEPOSITION 0x08L
|
||||
#define D3DRMANIMATION_SCALEANDROTATION 0x00000010L
|
||||
#define D3DRMANIMATION_POSITION 0x00000020L
|
||||
|
||||
typedef DWORD D3DRMINTERPOLATIONOPTIONS;
|
||||
#define D3DRMINTERPOLATION_OPEN 0x01L
|
||||
#define D3DRMINTERPOLATION_CLOSED 0x02L
|
||||
#define D3DRMINTERPOLATION_NEAREST 0x0100L
|
||||
#define D3DRMINTERPOLATION_LINEAR 0x04L
|
||||
#define D3DRMINTERPOLATION_SPLINE 0x08L
|
||||
#define D3DRMINTERPOLATION_VERTEXCOLOR 0x40L
|
||||
#define D3DRMINTERPOLATION_SLERPNORMALS 0x80L
|
||||
|
||||
typedef DWORD D3DRMLOADOPTIONS;
|
||||
|
||||
#define D3DRMLOAD_FROMFILE 0x00L
|
||||
#define D3DRMLOAD_FROMRESOURCE 0x01L
|
||||
#define D3DRMLOAD_FROMMEMORY 0x02L
|
||||
#define D3DRMLOAD_FROMSTREAM 0x04L
|
||||
#define D3DRMLOAD_FROMURL 0x08L
|
||||
|
||||
#define D3DRMLOAD_BYNAME 0x10L
|
||||
#define D3DRMLOAD_BYPOSITION 0x20L
|
||||
#define D3DRMLOAD_BYGUID 0x40L
|
||||
#define D3DRMLOAD_FIRST 0x80L
|
||||
|
||||
#define D3DRMLOAD_INSTANCEBYREFERENCE 0x100L
|
||||
#define D3DRMLOAD_INSTANCEBYCOPYING 0x200L
|
||||
|
||||
#define D3DRMLOAD_ASYNCHRONOUS 0x400L
|
||||
|
||||
typedef struct _D3DRMLOADRESOURCE {
|
||||
HMODULE hModule;
|
||||
LPCTSTR lpName;
|
||||
LPCTSTR lpType;
|
||||
} D3DRMLOADRESOURCE, *LPD3DRMLOADRESOURCE;
|
||||
|
||||
typedef struct _D3DRMLOADMEMORY {
|
||||
LPVOID lpMemory;
|
||||
DWORD dSize;
|
||||
} D3DRMLOADMEMORY, *LPD3DRMLOADMEMORY;
|
||||
|
||||
#define D3DRMPMESHSTATUS_VALID 0x01L
|
||||
#define D3DRMPMESHSTATUS_INTERRUPTED 0x02L
|
||||
#define D3DRMPMESHSTATUS_BASEMESHCOMPLETE 0x04L
|
||||
#define D3DRMPMESHSTATUS_COMPLETE 0x08L
|
||||
#define D3DRMPMESHSTATUS_RENDERABLE 0x10L
|
||||
|
||||
#define D3DRMPMESHEVENT_BASEMESH 0x01L
|
||||
#define D3DRMPMESHEVENT_COMPLETE 0x02L
|
||||
|
||||
typedef struct _D3DRMPMESHLOADSTATUS {
|
||||
DWORD dwSize; // Size of this structure
|
||||
DWORD dwPMeshSize; // Total Size (bytes)
|
||||
DWORD dwBaseMeshSize; // Total Size of the Base Mesh
|
||||
DWORD dwBytesLoaded; // Total bytes loaded
|
||||
DWORD dwVerticesLoaded; // Number of vertices loaded
|
||||
DWORD dwFacesLoaded; // Number of faces loaded
|
||||
HRESULT dwLoadResult; // Result of the load operation
|
||||
DWORD dwFlags;
|
||||
} D3DRMPMESHLOADSTATUS, *LPD3DRMPMESHLOADSTATUS;
|
||||
|
||||
typedef enum _D3DRMUSERVISUALREASON {
|
||||
D3DRMUSERVISUAL_CANSEE,
|
||||
D3DRMUSERVISUAL_RENDER
|
||||
} D3DRMUSERVISUALREASON, *LPD3DRMUSERVISUALREASON;
|
||||
|
||||
|
||||
typedef DWORD D3DRMMAPPING, D3DRMMAPPINGFLAG, *LPD3DRMMAPPING;
|
||||
static const D3DRMMAPPINGFLAG D3DRMMAP_WRAPU = 1;
|
||||
static const D3DRMMAPPINGFLAG D3DRMMAP_WRAPV = 2;
|
||||
static const D3DRMMAPPINGFLAG D3DRMMAP_PERSPCORRECT = 4;
|
||||
|
||||
typedef struct _D3DRMVERTEX
|
||||
{ D3DVECTOR position;
|
||||
D3DVECTOR normal;
|
||||
D3DVALUE tu, tv;
|
||||
D3DCOLOR color;
|
||||
} D3DRMVERTEX, *LPD3DRMVERTEX;
|
||||
|
||||
typedef LONG D3DRMGROUPINDEX; /* group indexes begin a 0 */
|
||||
static const D3DRMGROUPINDEX D3DRMGROUP_ALLGROUPS = -1;
|
||||
|
||||
/*
|
||||
* Create a color from three components in the range 0-1 inclusive.
|
||||
*/
|
||||
extern D3DCOLOR D3DRMAPI D3DRMCreateColorRGB(D3DVALUE red,
|
||||
D3DVALUE green,
|
||||
D3DVALUE blue);
|
||||
|
||||
/*
|
||||
* Create a color from four components in the range 0-1 inclusive.
|
||||
*/
|
||||
extern D3DCOLOR D3DRMAPI D3DRMCreateColorRGBA(D3DVALUE red,
|
||||
D3DVALUE green,
|
||||
D3DVALUE blue,
|
||||
D3DVALUE alpha);
|
||||
|
||||
/*
|
||||
* Get the red component of a color.
|
||||
*/
|
||||
extern D3DVALUE D3DRMAPI D3DRMColorGetRed(D3DCOLOR);
|
||||
|
||||
/*
|
||||
* Get the green component of a color.
|
||||
*/
|
||||
extern D3DVALUE D3DRMAPI D3DRMColorGetGreen(D3DCOLOR);
|
||||
|
||||
/*
|
||||
* Get the blue component of a color.
|
||||
*/
|
||||
extern D3DVALUE D3DRMAPI D3DRMColorGetBlue(D3DCOLOR);
|
||||
|
||||
/*
|
||||
* Get the alpha component of a color.
|
||||
*/
|
||||
extern D3DVALUE D3DRMAPI D3DRMColorGetAlpha(D3DCOLOR);
|
||||
|
||||
/*
|
||||
* Add two vectors. Returns its first argument.
|
||||
*/
|
||||
extern LPD3DVECTOR D3DRMAPI D3DRMVectorAdd(LPD3DVECTOR d,
|
||||
LPD3DVECTOR s1,
|
||||
LPD3DVECTOR s2);
|
||||
|
||||
/*
|
||||
* Subtract two vectors. Returns its first argument.
|
||||
*/
|
||||
extern LPD3DVECTOR D3DRMAPI D3DRMVectorSubtract(LPD3DVECTOR d,
|
||||
LPD3DVECTOR s1,
|
||||
LPD3DVECTOR s2);
|
||||
/*
|
||||
* Reflect a ray about a given normal. Returns its first argument.
|
||||
*/
|
||||
extern LPD3DVECTOR D3DRMAPI D3DRMVectorReflect(LPD3DVECTOR d,
|
||||
LPD3DVECTOR ray,
|
||||
LPD3DVECTOR norm);
|
||||
|
||||
/*
|
||||
* Calculate the vector cross product. Returns its first argument.
|
||||
*/
|
||||
extern LPD3DVECTOR D3DRMAPI D3DRMVectorCrossProduct(LPD3DVECTOR d,
|
||||
LPD3DVECTOR s1,
|
||||
LPD3DVECTOR s2);
|
||||
/*
|
||||
* Return the vector dot product.
|
||||
*/
|
||||
extern D3DVALUE D3DRMAPI D3DRMVectorDotProduct(LPD3DVECTOR s1,
|
||||
LPD3DVECTOR s2);
|
||||
|
||||
/*
|
||||
* Scale a vector so that its modulus is 1. Returns its argument or
|
||||
* NULL if there was an error (e.g. a zero vector was passed).
|
||||
*/
|
||||
extern LPD3DVECTOR D3DRMAPI D3DRMVectorNormalize(LPD3DVECTOR);
|
||||
#define D3DRMVectorNormalise D3DRMVectorNormalize
|
||||
|
||||
/*
|
||||
* Return the length of a vector (e.g. sqrt(x*x + y*y + z*z)).
|
||||
*/
|
||||
extern D3DVALUE D3DRMAPI D3DRMVectorModulus(LPD3DVECTOR v);
|
||||
|
||||
/*
|
||||
* Set the rotation part of a matrix to be a rotation of theta radians
|
||||
* around the given axis.
|
||||
*/
|
||||
|
||||
extern LPD3DVECTOR D3DRMAPI D3DRMVectorRotate(LPD3DVECTOR r, LPD3DVECTOR v, LPD3DVECTOR axis, D3DVALUE theta);
|
||||
|
||||
/*
|
||||
* Scale a vector uniformly in all three axes
|
||||
*/
|
||||
extern LPD3DVECTOR D3DRMAPI D3DRMVectorScale(LPD3DVECTOR d, LPD3DVECTOR s, D3DVALUE factor);
|
||||
|
||||
/*
|
||||
* Return a random unit vector
|
||||
*/
|
||||
extern LPD3DVECTOR D3DRMAPI D3DRMVectorRandom(LPD3DVECTOR d);
|
||||
|
||||
/*
|
||||
* Returns a unit quaternion that represents a rotation of theta radians
|
||||
* around the given axis.
|
||||
*/
|
||||
|
||||
extern LPD3DRMQUATERNION D3DRMAPI D3DRMQuaternionFromRotation(LPD3DRMQUATERNION quat,
|
||||
LPD3DVECTOR v,
|
||||
D3DVALUE theta);
|
||||
|
||||
/*
|
||||
* Calculate the product of two quaternions
|
||||
*/
|
||||
extern LPD3DRMQUATERNION D3DRMAPI D3DRMQuaternionMultiply(LPD3DRMQUATERNION q,
|
||||
LPD3DRMQUATERNION a,
|
||||
LPD3DRMQUATERNION b);
|
||||
|
||||
/*
|
||||
* Interpolate between two quaternions
|
||||
*/
|
||||
extern LPD3DRMQUATERNION D3DRMAPI D3DRMQuaternionSlerp(LPD3DRMQUATERNION q,
|
||||
LPD3DRMQUATERNION a,
|
||||
LPD3DRMQUATERNION b,
|
||||
D3DVALUE alpha);
|
||||
|
||||
/*
|
||||
* Calculate the matrix for the rotation that a unit quaternion represents
|
||||
*/
|
||||
extern void D3DRMAPI D3DRMMatrixFromQuaternion(D3DRMMATRIX4D dmMat, LPD3DRMQUATERNION lpDqQuat);
|
||||
|
||||
/*
|
||||
* Calculate the quaternion that corresponds to a rotation matrix
|
||||
*/
|
||||
extern LPD3DRMQUATERNION D3DRMAPI D3DRMQuaternionFromMatrix(LPD3DRMQUATERNION, D3DRMMATRIX4D);
|
||||
|
||||
|
||||
#if defined(__cplusplus)
|
||||
};
|
||||
#endif
|
||||
|
||||
#endif
|
1100
3rdparty/dx5/inc/d3drmobj.h
vendored
Normal file
1100
3rdparty/dx5/inc/d3drmobj.h
vendored
Normal file
File diff suppressed because it is too large
Load diff
48
3rdparty/dx5/inc/d3drmwin.h
vendored
Normal file
48
3rdparty/dx5/inc/d3drmwin.h
vendored
Normal file
|
@ -0,0 +1,48 @@
|
|||
/*==========================================================================;
|
||||
*
|
||||
* Copyright (C) 1995-1997 Microsoft Corporation. All Rights Reserved.
|
||||
*
|
||||
* File: d3drm.h
|
||||
* Content: Direct3DRM include file
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef __D3DRMWIN_H__
|
||||
#define __D3DRMWIN_H__
|
||||
|
||||
#ifndef WIN32
|
||||
#define WIN32
|
||||
#endif
|
||||
|
||||
#include "d3drm.h"
|
||||
#include "ddraw.h"
|
||||
#include "d3d.h"
|
||||
|
||||
/*
|
||||
* GUIDS used by Direct3DRM Windows interface
|
||||
*/
|
||||
DEFINE_GUID(IID_IDirect3DRMWinDevice, 0xc5016cc0, 0xd273, 0x11ce, 0xac, 0x48, 0x0, 0x0, 0xc0, 0x38, 0x25, 0xa1);
|
||||
|
||||
WIN_TYPES(IDirect3DRMWinDevice, DIRECT3DRMWINDEVICE);
|
||||
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirect3DRMWinDevice
|
||||
|
||||
DECLARE_INTERFACE_(IDirect3DRMWinDevice, IDirect3DRMObject)
|
||||
{
|
||||
IUNKNOWN_METHODS(PURE);
|
||||
IDIRECT3DRMOBJECT_METHODS(PURE);
|
||||
|
||||
/*
|
||||
* IDirect3DRMWinDevice methods
|
||||
*/
|
||||
|
||||
/* Repaint the window with the last frame which was rendered. */
|
||||
STDMETHOD(HandlePaint)(THIS_ HDC hdc) PURE;
|
||||
|
||||
/* Respond to a WM_ACTIVATE message. */
|
||||
STDMETHOD(HandleActivate)(THIS_ WORD wparam) PURE;
|
||||
};
|
||||
|
||||
|
||||
#endif
|
1201
3rdparty/dx5/inc/d3dtypes.h
vendored
Normal file
1201
3rdparty/dx5/inc/d3dtypes.h
vendored
Normal file
File diff suppressed because it is too large
Load diff
240
3rdparty/dx5/inc/d3dvec.inl
vendored
Normal file
240
3rdparty/dx5/inc/d3dvec.inl
vendored
Normal file
|
@ -0,0 +1,240 @@
|
|||
|
||||
/******************************************************************
|
||||
* *
|
||||
* D3DVec.inl *
|
||||
* *
|
||||
* Float-valued 3D vector class for Direct3D. *
|
||||
* *
|
||||
* Copyright (c) 1996-1997 Microsoft Corp. All rights reserved. *
|
||||
* *
|
||||
******************************************************************/
|
||||
|
||||
#include <math.h>
|
||||
|
||||
// =====================================
|
||||
// Constructors
|
||||
// =====================================
|
||||
|
||||
inline
|
||||
_D3DVECTOR::_D3DVECTOR(D3DVALUE f)
|
||||
{
|
||||
x = y = z = f;
|
||||
}
|
||||
|
||||
inline
|
||||
_D3DVECTOR::_D3DVECTOR(D3DVALUE _x, D3DVALUE _y, D3DVALUE _z)
|
||||
{
|
||||
x = _x; y = _y; z = _z;
|
||||
}
|
||||
|
||||
inline
|
||||
_D3DVECTOR::_D3DVECTOR(const D3DVALUE f[3])
|
||||
{
|
||||
x = f[0]; y = f[1]; z = f[2];
|
||||
}
|
||||
|
||||
// =====================================
|
||||
// Access grants
|
||||
// =====================================
|
||||
|
||||
inline const D3DVALUE&
|
||||
_D3DVECTOR::operator[](int i) const
|
||||
{
|
||||
return (&x)[i];
|
||||
}
|
||||
|
||||
inline D3DVALUE&
|
||||
_D3DVECTOR::operator[](int i)
|
||||
{
|
||||
return (&x)[i];
|
||||
}
|
||||
|
||||
|
||||
// =====================================
|
||||
// Assignment operators
|
||||
// =====================================
|
||||
|
||||
inline _D3DVECTOR&
|
||||
_D3DVECTOR::operator += (const _D3DVECTOR& v)
|
||||
{
|
||||
x += v.x; y += v.y; z += v.z;
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline _D3DVECTOR&
|
||||
_D3DVECTOR::operator -= (const _D3DVECTOR& v)
|
||||
{
|
||||
x -= v.x; y -= v.y; z -= v.z;
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline _D3DVECTOR&
|
||||
_D3DVECTOR::operator *= (const _D3DVECTOR& v)
|
||||
{
|
||||
x *= v.x; y *= v.y; z *= v.z;
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline _D3DVECTOR&
|
||||
_D3DVECTOR::operator /= (const _D3DVECTOR& v)
|
||||
{
|
||||
x /= v.x; y /= v.y; z /= v.z;
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline _D3DVECTOR&
|
||||
_D3DVECTOR::operator *= (D3DVALUE s)
|
||||
{
|
||||
x *= s; y *= s; z *= s;
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline _D3DVECTOR&
|
||||
_D3DVECTOR::operator /= (D3DVALUE s)
|
||||
{
|
||||
x /= s; y /= s; z /= s;
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline _D3DVECTOR
|
||||
operator + (const _D3DVECTOR& v)
|
||||
{
|
||||
return v;
|
||||
}
|
||||
|
||||
inline _D3DVECTOR
|
||||
operator - (const _D3DVECTOR& v)
|
||||
{
|
||||
return _D3DVECTOR(-v.x, -v.y, -v.z);
|
||||
}
|
||||
|
||||
inline _D3DVECTOR
|
||||
operator + (const _D3DVECTOR& v1, const _D3DVECTOR& v2)
|
||||
{
|
||||
return _D3DVECTOR(v1.x+v2.x, v1.y+v2.y, v1.z+v2.z);
|
||||
}
|
||||
|
||||
inline _D3DVECTOR
|
||||
operator - (const _D3DVECTOR& v1, const _D3DVECTOR& v2)
|
||||
{
|
||||
return _D3DVECTOR(v1.x-v2.x, v1.y-v2.y, v1.z-v2.z);
|
||||
}
|
||||
|
||||
inline _D3DVECTOR
|
||||
operator * (const _D3DVECTOR& v1, const _D3DVECTOR& v2)
|
||||
{
|
||||
return _D3DVECTOR(v1.x*v2.x, v1.y*v2.y, v1.z*v2.z);
|
||||
}
|
||||
|
||||
inline _D3DVECTOR
|
||||
operator / (const _D3DVECTOR& v1, const _D3DVECTOR& v2)
|
||||
{
|
||||
return _D3DVECTOR(v1.x/v2.x, v1.y/v2.y, v1.z/v2.z);
|
||||
}
|
||||
|
||||
inline int
|
||||
operator < (const _D3DVECTOR& v1, const _D3DVECTOR& v2)
|
||||
{
|
||||
return v1[0] < v2[0] && v1[1] < v2[1] && v1[2] < v2[2];
|
||||
}
|
||||
|
||||
inline int
|
||||
operator <= (const _D3DVECTOR& v1, const _D3DVECTOR& v2)
|
||||
{
|
||||
return v1[0] <= v2[0] && v1[1] <= v2[1] && v1[2] <= v2[2];
|
||||
}
|
||||
|
||||
inline _D3DVECTOR
|
||||
operator * (const _D3DVECTOR& v, D3DVALUE s)
|
||||
{
|
||||
return _D3DVECTOR(s*v.x, s*v.y, s*v.z);
|
||||
}
|
||||
|
||||
inline _D3DVECTOR
|
||||
operator * (D3DVALUE s, const _D3DVECTOR& v)
|
||||
{
|
||||
return _D3DVECTOR(s*v.x, s*v.y, s*v.z);
|
||||
}
|
||||
|
||||
inline _D3DVECTOR
|
||||
operator / (const _D3DVECTOR& v, D3DVALUE s)
|
||||
{
|
||||
return _D3DVECTOR(v.x/s, v.y/s, v.z/s);
|
||||
}
|
||||
|
||||
inline int
|
||||
operator == (const _D3DVECTOR& v1, const _D3DVECTOR& v2)
|
||||
{
|
||||
return v1.x==v2.x && v1.y==v2.y && v1.z == v2.z;
|
||||
}
|
||||
|
||||
inline D3DVALUE
|
||||
Magnitude (const _D3DVECTOR& v)
|
||||
{
|
||||
return (D3DVALUE) sqrt(SquareMagnitude(v));
|
||||
}
|
||||
|
||||
inline D3DVALUE
|
||||
SquareMagnitude (const _D3DVECTOR& v)
|
||||
{
|
||||
return v.x*v.x + v.y*v.y + v.z*v.z;
|
||||
}
|
||||
|
||||
inline _D3DVECTOR
|
||||
Normalize (const _D3DVECTOR& v)
|
||||
{
|
||||
return v / Magnitude(v);
|
||||
}
|
||||
|
||||
inline D3DVALUE
|
||||
Min (const _D3DVECTOR& v)
|
||||
{
|
||||
D3DVALUE ret = v.x;
|
||||
if (v.y < ret) ret = v.y;
|
||||
if (v.z < ret) ret = v.z;
|
||||
return ret;
|
||||
}
|
||||
|
||||
inline D3DVALUE
|
||||
Max (const _D3DVECTOR& v)
|
||||
{
|
||||
D3DVALUE ret = v.x;
|
||||
if (ret < v.y) ret = v.y;
|
||||
if (ret < v.z) ret = v.z;
|
||||
return ret;
|
||||
}
|
||||
|
||||
inline _D3DVECTOR
|
||||
Minimize (const _D3DVECTOR& v1, const _D3DVECTOR& v2)
|
||||
{
|
||||
return _D3DVECTOR( v1[0] < v2[0] ? v1[0] : v2[0],
|
||||
v1[1] < v2[1] ? v1[1] : v2[1],
|
||||
v1[2] < v2[2] ? v1[2] : v2[2]);
|
||||
}
|
||||
|
||||
inline _D3DVECTOR
|
||||
Maximize (const _D3DVECTOR& v1, const _D3DVECTOR& v2)
|
||||
{
|
||||
return _D3DVECTOR( v1[0] > v2[0] ? v1[0] : v2[0],
|
||||
v1[1] > v2[1] ? v1[1] : v2[1],
|
||||
v1[2] > v2[2] ? v1[2] : v2[2]);
|
||||
}
|
||||
|
||||
inline D3DVALUE
|
||||
DotProduct (const _D3DVECTOR& v1, const _D3DVECTOR& v2)
|
||||
{
|
||||
return v1.x*v2.x + v1.y * v2.y + v1.z*v2.z;
|
||||
}
|
||||
|
||||
inline _D3DVECTOR
|
||||
CrossProduct (const _D3DVECTOR& v1, const _D3DVECTOR& v2)
|
||||
{
|
||||
_D3DVECTOR result;
|
||||
|
||||
result[0] = v1[1] * v2[2] - v1[2] * v2[1];
|
||||
result[1] = v1[2] * v2[0] - v1[0] * v2[2];
|
||||
result[2] = v1[0] * v2[1] - v1[1] * v2[0];
|
||||
|
||||
return result;
|
||||
}
|
||||
|
3791
3rdparty/dx5/inc/ddraw.h
vendored
Normal file
3791
3rdparty/dx5/inc/ddraw.h
vendored
Normal file
File diff suppressed because it is too large
Load diff
1849
3rdparty/dx5/inc/dinput.h
vendored
Normal file
1849
3rdparty/dx5/inc/dinput.h
vendored
Normal file
File diff suppressed because it is too large
Load diff
1710
3rdparty/dx5/inc/dplay.h
vendored
Normal file
1710
3rdparty/dx5/inc/dplay.h
vendored
Normal file
File diff suppressed because it is too large
Load diff
627
3rdparty/dx5/inc/dplobby.h
vendored
Normal file
627
3rdparty/dx5/inc/dplobby.h
vendored
Normal file
|
@ -0,0 +1,627 @@
|
|||
/*==========================================================================;
|
||||
*
|
||||
* Copyright (C) 1996-1997 Microsoft Corporation. All Rights Reserved.
|
||||
*
|
||||
* File: dplobby.h
|
||||
* Content: DirectPlayLobby include file
|
||||
***************************************************************************/
|
||||
#ifndef __DPLOBBY_INCLUDED__
|
||||
#define __DPLOBBY_INCLUDED__
|
||||
|
||||
#include "dplay.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
/*
|
||||
* GUIDS used by DirectPlay objects
|
||||
*/
|
||||
|
||||
/* {AF465C71-9588-11cf-A020-00AA006157AC} */
|
||||
DEFINE_GUID(IID_IDirectPlayLobby, 0xaf465c71, 0x9588, 0x11cf, 0xa0, 0x20, 0x0, 0xaa, 0x0, 0x61, 0x57, 0xac);
|
||||
/* {26C66A70-B367-11cf-A024-00AA006157AC} */
|
||||
DEFINE_GUID(IID_IDirectPlayLobbyA, 0x26c66a70, 0xb367, 0x11cf, 0xa0, 0x24, 0x0, 0xaa, 0x0, 0x61, 0x57, 0xac);
|
||||
/* {0194C220-A303-11d0-9C4F-00A0C905425E} */
|
||||
DEFINE_GUID(IID_IDirectPlayLobby2, 0x194c220, 0xa303, 0x11d0, 0x9c, 0x4f, 0x0, 0xa0, 0xc9, 0x5, 0x42, 0x5e);
|
||||
/* {1BB4AF80-A303-11d0-9C4F-00A0C905425E} */
|
||||
DEFINE_GUID(IID_IDirectPlayLobby2A, 0x1bb4af80, 0xa303, 0x11d0, 0x9c, 0x4f, 0x0, 0xa0, 0xc9, 0x5, 0x42, 0x5e);
|
||||
/* {2FE8F810-B2A5-11d0-A787-0000F803ABFC} */
|
||||
DEFINE_GUID(CLSID_DirectPlayLobby, 0x2fe8f810, 0xb2a5, 0x11d0, 0xa7, 0x87, 0x0, 0x0, 0xf8, 0x3, 0xab, 0xfc);
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* IDirectPlayLobby Structures
|
||||
*
|
||||
* Various structures used to invoke DirectPlayLobby.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
typedef struct IDirectPlayLobby FAR *LPDIRECTPLAYLOBBY;
|
||||
typedef struct IDirectPlayLobby FAR *LPDIRECTPLAYLOBBYA;
|
||||
typedef struct IDirectPlayLobby IDirectPlayLobbyA;
|
||||
|
||||
typedef struct IDirectPlayLobby2 FAR *LPDIRECTPLAYLOBBY2;
|
||||
typedef struct IDirectPlayLobby2 FAR *LPDIRECTPLAYLOBBY2A;
|
||||
typedef struct IDirectPlayLobby2 IDirectPlayLobby2A;
|
||||
|
||||
|
||||
/*
|
||||
* DPLAPPINFO
|
||||
* Used to hold information about a registered DirectPlay
|
||||
* application
|
||||
*/
|
||||
typedef struct DPLAPPINFO
|
||||
{
|
||||
DWORD dwSize; // Size of this structure
|
||||
GUID guidApplication; // GUID of the Application
|
||||
union
|
||||
{
|
||||
LPSTR lpszAppNameA; // Pointer to the Application Name
|
||||
LPWSTR lpszAppName;
|
||||
};
|
||||
|
||||
} DPLAPPINFO, FAR *LPDPLAPPINFO;
|
||||
|
||||
/*
|
||||
* LPCDPLAPPINFO
|
||||
* A constant pointer to DPLAPPINFO
|
||||
*/
|
||||
typedef const DPLAPPINFO FAR *LPCDPLAPPINFO;
|
||||
|
||||
/*
|
||||
* DPCOMPOUNDADDRESSELEMENT
|
||||
*
|
||||
* An array of these is passed to CreateCompoundAddresses()
|
||||
*/
|
||||
typedef struct DPCOMPOUNDADDRESSELEMENT
|
||||
{
|
||||
GUID guidDataType;
|
||||
DWORD dwDataSize;
|
||||
LPVOID lpData;
|
||||
} DPCOMPOUNDADDRESSELEMENT, FAR *LPDPCOMPOUNDADDRESSELEMENT;
|
||||
|
||||
/*
|
||||
* LPCDPCOMPOUNDADDRESSELEMENT
|
||||
* A constant pointer to DPCOMPOUNDADDRESSELEMENT
|
||||
*/
|
||||
typedef const DPCOMPOUNDADDRESSELEMENT FAR *LPCDPCOMPOUNDADDRESSELEMENT;
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* Enumeration Method Callback Prototypes
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* Callback for EnumAddress()
|
||||
*/
|
||||
typedef BOOL (FAR PASCAL *LPDPENUMADDRESSCALLBACK)(
|
||||
REFGUID guidDataType,
|
||||
DWORD dwDataSize,
|
||||
LPCVOID lpData,
|
||||
LPVOID lpContext);
|
||||
|
||||
/*
|
||||
* Callback for EnumAddressTypes()
|
||||
*/
|
||||
typedef BOOL (FAR PASCAL *LPDPLENUMADDRESSTYPESCALLBACK)(
|
||||
REFGUID guidDataType,
|
||||
LPVOID lpContext,
|
||||
DWORD dwFlags);
|
||||
|
||||
/*
|
||||
* Callback for EnumLocalApplications()
|
||||
*/
|
||||
typedef BOOL (FAR PASCAL * LPDPLENUMLOCALAPPLICATIONSCALLBACK)(
|
||||
LPCDPLAPPINFO lpAppInfo,
|
||||
LPVOID lpContext,
|
||||
DWORD dwFlags);
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* DirectPlayLobby API Prototypes
|
||||
*
|
||||
****************************************************************************/
|
||||
#ifdef UNICODE
|
||||
#define DirectPlayLobbyCreate DirectPlayLobbyCreateW
|
||||
#else
|
||||
#define DirectPlayLobbyCreate DirectPlayLobbyCreateA
|
||||
#endif /* UNICODE */
|
||||
|
||||
extern HRESULT WINAPI DirectPlayLobbyCreateW(LPGUID, LPDIRECTPLAYLOBBY *, IUnknown *, LPVOID, DWORD );
|
||||
extern HRESULT WINAPI DirectPlayLobbyCreateA(LPGUID, LPDIRECTPLAYLOBBYA *, IUnknown *, LPVOID, DWORD );
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* IDirectPlayLobby (and IDirectPlayLobbyA) Interface
|
||||
*
|
||||
****************************************************************************/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirectPlayLobby
|
||||
DECLARE_INTERFACE_( IDirectPlayLobby, IUnknown )
|
||||
{
|
||||
/* IUnknown Methods */
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID * ppvObj) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
/* IDirectPlayLobby Methods */
|
||||
STDMETHOD(Connect) (THIS_ DWORD, LPDIRECTPLAY2 *, IUnknown FAR *) PURE;
|
||||
STDMETHOD(CreateAddress) (THIS_ REFGUID, REFGUID, LPCVOID, DWORD, LPVOID, LPDWORD) PURE;
|
||||
STDMETHOD(EnumAddress) (THIS_ LPDPENUMADDRESSCALLBACK, LPCVOID, DWORD, LPVOID) PURE;
|
||||
STDMETHOD(EnumAddressTypes) (THIS_ LPDPLENUMADDRESSTYPESCALLBACK, REFGUID, LPVOID, DWORD) PURE;
|
||||
STDMETHOD(EnumLocalApplications)(THIS_ LPDPLENUMLOCALAPPLICATIONSCALLBACK, LPVOID, DWORD) PURE;
|
||||
STDMETHOD(GetConnectionSettings)(THIS_ DWORD, LPVOID, LPDWORD) PURE;
|
||||
STDMETHOD(ReceiveLobbyMessage) (THIS_ DWORD, DWORD, LPDWORD, LPVOID, LPDWORD) PURE;
|
||||
STDMETHOD(RunApplication) (THIS_ DWORD, LPDWORD, LPDPLCONNECTION, HANDLE) PURE;
|
||||
STDMETHOD(SendLobbyMessage) (THIS_ DWORD, DWORD, LPVOID, DWORD) PURE;
|
||||
STDMETHOD(SetConnectionSettings)(THIS_ DWORD, DWORD, LPDPLCONNECTION) PURE;
|
||||
STDMETHOD(SetLobbyMessageEvent) (THIS_ DWORD, DWORD, HANDLE) PURE;
|
||||
|
||||
};
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* IDirectPlayLobby2 (and IDirectPlayLobby2A) Interface
|
||||
*
|
||||
****************************************************************************/
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirectPlayLobby2
|
||||
DECLARE_INTERFACE_( IDirectPlayLobby2, IDirectPlayLobby )
|
||||
{
|
||||
/* IUnknown Methods */
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID * ppvObj) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
/* IDirectPlayLobby Methods */
|
||||
STDMETHOD(Connect) (THIS_ DWORD, LPDIRECTPLAY2 *, IUnknown FAR *) PURE;
|
||||
STDMETHOD(CreateAddress) (THIS_ REFGUID, REFGUID, LPCVOID, DWORD, LPVOID, LPDWORD) PURE;
|
||||
STDMETHOD(EnumAddress) (THIS_ LPDPENUMADDRESSCALLBACK, LPCVOID, DWORD, LPVOID) PURE;
|
||||
STDMETHOD(EnumAddressTypes) (THIS_ LPDPLENUMADDRESSTYPESCALLBACK, REFGUID, LPVOID, DWORD) PURE;
|
||||
STDMETHOD(EnumLocalApplications)(THIS_ LPDPLENUMLOCALAPPLICATIONSCALLBACK, LPVOID, DWORD) PURE;
|
||||
STDMETHOD(GetConnectionSettings)(THIS_ DWORD, LPVOID, LPDWORD) PURE;
|
||||
STDMETHOD(ReceiveLobbyMessage) (THIS_ DWORD, DWORD, LPDWORD, LPVOID, LPDWORD) PURE;
|
||||
STDMETHOD(RunApplication) (THIS_ DWORD, LPDWORD, LPDPLCONNECTION, HANDLE) PURE;
|
||||
STDMETHOD(SendLobbyMessage) (THIS_ DWORD, DWORD, LPVOID, DWORD) PURE;
|
||||
STDMETHOD(SetConnectionSettings)(THIS_ DWORD, DWORD, LPDPLCONNECTION) PURE;
|
||||
STDMETHOD(SetLobbyMessageEvent) (THIS_ DWORD, DWORD, HANDLE) PURE;
|
||||
|
||||
/* IDirectPlayLobby2 Methods */
|
||||
STDMETHOD(CreateCompoundAddress)(THIS_ LPCDPCOMPOUNDADDRESSELEMENT,DWORD,LPVOID,LPDWORD) PURE;
|
||||
};
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* IDirectPlayLobby interface macros
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
|
||||
#define IDirectPlayLobby_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
|
||||
#define IDirectPlayLobby_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirectPlayLobby_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirectPlayLobby_Connect(p,a,b,c) (p)->lpVtbl->Connect(p,a,b,c)
|
||||
#define IDirectPlayLobby_CreateAddress(p,a,b,c,d,e,f) (p)->lpVtbl->CreateAddress(p,a,b,c,d,e,f)
|
||||
#define IDirectPlayLobby_CreateCompoundAddress(p,a,b,c,d) (p)->lpVtbl->CreateCompoundAddress(p,a,b,c,d)
|
||||
#define IDirectPlayLobby_EnumAddress(p,a,b,c,d) (p)->lpVtbl->EnumAddress(p,a,b,c,d)
|
||||
#define IDirectPlayLobby_EnumAddressTypes(p,a,b,c,d) (p)->lpVtbl->EnumAddressTypes(p,a,b,c,d)
|
||||
#define IDirectPlayLobby_EnumLocalApplications(p,a,b,c) (p)->lpVtbl->EnumLocalApplications(p,a,b,c)
|
||||
#define IDirectPlayLobby_GetConnectionSettings(p,a,b,c) (p)->lpVtbl->GetConnectionSettings(p,a,b,c)
|
||||
#define IDirectPlayLobby_ReceiveLobbyMessage(p,a,b,c,d,e) (p)->lpVtbl->ReceiveLobbyMessage(p,a,b,c,d,e)
|
||||
#define IDirectPlayLobby_RunApplication(p,a,b,c,d) (p)->lpVtbl->RunApplication(p,a,b,c,d)
|
||||
#define IDirectPlayLobby_SendLobbyMessage(p,a,b,c,d) (p)->lpVtbl->SendLobbyMessage(p,a,b,c,d)
|
||||
#define IDirectPlayLobby_SetConnectionSettings(p,a,b,c) (p)->lpVtbl->SetConnectionSettings(p,a,b,c)
|
||||
#define IDirectPlayLobby_SetLobbyMessageEvent(p,a,b,c) (p)->lpVtbl->SetLobbyMessageEvent(p,a,b,c)
|
||||
|
||||
#else /* C++ */
|
||||
|
||||
#define IDirectPlayLobby_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
|
||||
#define IDirectPlayLobby_AddRef(p) (p)->AddRef()
|
||||
#define IDirectPlayLobby_Release(p) (p)->Release()
|
||||
#define IDirectPlayLobby_Connect(p,a,b,c) (p)->Connect(a,b,c)
|
||||
#define IDirectPlayLobby_CreateAddress(p,a,b,c,d,e,f) (p)->CreateAddress(a,b,c,d,e,f)
|
||||
#define IDirectPlayLobby_CreateCompoundAddress(p,a,b,c,d) (p)->lpVtbl->CreateCompoundAddress(a,b,c,d)
|
||||
#define IDirectPlayLobby_EnumAddress(p,a,b,c,d) (p)->EnumAddress(a,b,c,d)
|
||||
#define IDirectPlayLobby_EnumAddressTypes(p,a,b,c,d) (p)->EnumAddressTypes(a,b,c,d)
|
||||
#define IDirectPlayLobby_EnumLocalApplications(p,a,b,c) (p)->EnumLocalApplications(a,b,c)
|
||||
#define IDirectPlayLobby_GetConnectionSettings(p,a,b,c) (p)->GetConnectionSettings(a,b,c)
|
||||
#define IDirectPlayLobby_ReceiveLobbyMessage(p,a,b,c,d,e) (p)->ReceiveLobbyMessage(a,b,c,d,e)
|
||||
#define IDirectPlayLobby_RunApplication(p,a,b,c,d) (p)->RunApplication(a,b,c,d)
|
||||
#define IDirectPlayLobby_SendLobbyMessage(p,a,b,c,d) (p)->SendLobbyMessage(a,b,c,d)
|
||||
#define IDirectPlayLobby_SetConnectionSettings(p,a,b,c) (p)->SetConnectionSettings(a,b,c)
|
||||
#define IDirectPlayLobby_SetLobbyMessageEvent(p,a,b,c) (p)->SetLobbyMessageEvent(a,b,c)
|
||||
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* DirectPlayLobby Flags
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* This is a message flag used by ReceiveLobbyMessage. It can be
|
||||
* returned in the dwMessageFlags parameter to indicate a message from
|
||||
* the system.
|
||||
*/
|
||||
#define DPLMSG_SYSTEM 0x00000001
|
||||
|
||||
/*
|
||||
* This is a message flag used by ReceiveLobbyMessage and SendLobbyMessage.
|
||||
* It is used to indicate that the message is a standard lobby message.
|
||||
* DPLMSG_SETPROPERTY, DPLMSG_SETPROPERTYRESPONSE, DPLMSG_GETPROPERTY,
|
||||
* DPLMSG_GETPROPERTYRESPONSE
|
||||
*/
|
||||
#define DPLMSG_STANDARD 0x00000002
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* DirectPlayLobby messages and message data structures
|
||||
*
|
||||
* All system messages have a dwMessageFlags value of DPLMSG_SYSTEM returned
|
||||
* from a call to ReceiveLobbyMessage.
|
||||
*
|
||||
* All standard messages have a dwMessageFlags value of DPLMSG_STANDARD returned
|
||||
* from a call to ReceiveLobbyMessage.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* DPLMSG_GENERIC
|
||||
* Generic message structure used to identify the message type.
|
||||
*/
|
||||
typedef struct _DPLMSG_GENERIC
|
||||
{
|
||||
DWORD dwType; // Message type
|
||||
} DPLMSG_GENERIC, FAR *LPDPLMSG_GENERIC;
|
||||
|
||||
/*
|
||||
* DPLMSG_SETPROPERTY
|
||||
* Standard message sent by an application to a lobby to set a
|
||||
* property
|
||||
*/
|
||||
typedef struct _DPLMSG_SETPROPERTY
|
||||
{
|
||||
DWORD dwType; // Message type
|
||||
DWORD dwRequestID; // Request ID (DPL_NOCONFIRMATION if no confirmation desired)
|
||||
GUID guidPlayer; // Player GUID
|
||||
GUID guidPropertyTag; // Property GUID
|
||||
DWORD dwDataSize; // Size of data
|
||||
DWORD dwPropertyData[1]; // Buffer containing data
|
||||
} DPLMSG_SETPROPERTY, FAR *LPDPLMSG_SETPROPERTY;
|
||||
|
||||
#define DPL_NOCONFIRMATION 0
|
||||
|
||||
/*
|
||||
* DPLMSG_SETPROPERTYRESPONSE
|
||||
* Standard message returned by a lobby to confirm a
|
||||
* DPLMSG_SETPROPERTY message.
|
||||
*/
|
||||
typedef struct _DPLMSG_SETPROPERTYRESPONSE
|
||||
{
|
||||
DWORD dwType; // Message type
|
||||
DWORD dwRequestID; // Request ID
|
||||
GUID guidPlayer; // Player GUID
|
||||
GUID guidPropertyTag; // Property GUID
|
||||
HRESULT hr; // Return Code
|
||||
} DPLMSG_SETPROPERTYRESPONSE, FAR *LPDPLMSG_SETPROPERTYRESPONSE;
|
||||
|
||||
/*
|
||||
* DPLMSG_GETPROPERTY
|
||||
* Standard message sent by an application to a lobby to request
|
||||
* the current value of a property
|
||||
*/
|
||||
typedef struct _DPLMSG_GETPROPERTY
|
||||
{
|
||||
DWORD dwType; // Message type
|
||||
DWORD dwRequestID; // Request ID
|
||||
GUID guidPlayer; // Player GUID
|
||||
GUID guidPropertyTag; // Property GUID
|
||||
} DPLMSG_GETPROPERTY, FAR *LPDPLMSG_GETPROPERTY;
|
||||
|
||||
/*
|
||||
* DPLMSG_GETPROPERTYRESPONSE
|
||||
* Standard message returned by a lobby in response to a
|
||||
* DPLMSG_GETPROPERTY message.
|
||||
*/
|
||||
typedef struct _DPLMSG_GETPROPERTYRESPONSE
|
||||
{
|
||||
DWORD dwType; // Message type
|
||||
DWORD dwRequestID; // Request ID
|
||||
GUID guidPlayer; // Player GUID
|
||||
GUID guidPropertyTag; // Property GUID
|
||||
HRESULT hr; // Return Code
|
||||
DWORD dwDataSize; // Size of data
|
||||
DWORD dwPropertyData[1]; // Buffer containing data
|
||||
} DPLMSG_GETPROPERTYRESPONSE, FAR *LPDPLMSG_GETPROPERTYRESPONSE;
|
||||
|
||||
|
||||
/******************************************
|
||||
*
|
||||
* DirectPlay Lobby message dwType values
|
||||
*
|
||||
*****************************************/
|
||||
|
||||
/*
|
||||
* The application has read the connection settings.
|
||||
* It is now O.K. for the lobby client to release
|
||||
* its IDirectPlayLobby interface.
|
||||
*/
|
||||
#define DPLSYS_CONNECTIONSETTINGSREAD 0x00000001
|
||||
|
||||
/*
|
||||
* The application's call to DirectPlayConnect failed
|
||||
*/
|
||||
#define DPLSYS_DPLAYCONNECTFAILED 0x00000002
|
||||
|
||||
/*
|
||||
* The application has created a DirectPlay session.
|
||||
*/
|
||||
#define DPLSYS_DPLAYCONNECTSUCCEEDED 0x00000003
|
||||
|
||||
/*
|
||||
* The application has terminated.
|
||||
*/
|
||||
#define DPLSYS_APPTERMINATED 0x00000004
|
||||
|
||||
/*
|
||||
* The message is a DPLMSG_SETPROPERTY message.
|
||||
*/
|
||||
#define DPLSYS_SETPROPERTY 0x00000005
|
||||
|
||||
/*
|
||||
* The message is a DPLMSG_SETPROPERTYRESPONSE message.
|
||||
*/
|
||||
#define DPLSYS_SETPROPERTYRESPONSE 0x00000006
|
||||
|
||||
/*
|
||||
* The message is a DPLMSG_GETPROPERTY message.
|
||||
*/
|
||||
#define DPLSYS_GETPROPERTY 0x00000007
|
||||
|
||||
/*
|
||||
* The message is a DPLMSG_GETPROPERTYRESPONSE message.
|
||||
*/
|
||||
#define DPLSYS_GETPROPERTYRESPONSE 0x00000008
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* DirectPlay defined property GUIDs and associated data structures
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* DPLPROPERTY_MessagesSupported
|
||||
*
|
||||
* Request whether the lobby supports standard. Lobby with respond with either
|
||||
* TRUE or FALSE or may not respond at all.
|
||||
*
|
||||
* Property data is a single BOOL with TRUE or FALSE
|
||||
*/
|
||||
// {762CCDA1-D916-11d0-BA39-00C04FD7ED67}
|
||||
DEFINE_GUID(DPLPROPERTY_MessagesSupported,
|
||||
0x762ccda1, 0xd916, 0x11d0, 0xba, 0x39, 0x0, 0xc0, 0x4f, 0xd7, 0xed, 0x67);
|
||||
|
||||
/*
|
||||
* DPLPROPERTY_LobbyGuid
|
||||
*
|
||||
* Request the GUID that identifies the lobby software that the application
|
||||
* is communicating with.
|
||||
*
|
||||
* Property data is a single GUID.
|
||||
*/
|
||||
// {F56920A0-D218-11d0-BA39-00C04FD7ED67}
|
||||
DEFINE_GUID(DPLPROPERTY_LobbyGuid,
|
||||
0xf56920a0, 0xd218, 0x11d0, 0xba, 0x39, 0x0, 0xc0, 0x4f, 0xd7, 0xed, 0x67);
|
||||
|
||||
/*
|
||||
* DPLPROPERTY_PlayerGuid
|
||||
*
|
||||
* Request the GUID that identifies the player on this machine for sending
|
||||
* property data back to the lobby.
|
||||
*
|
||||
* Property data is the DPLDATA_PLAYERDATA structure
|
||||
*/
|
||||
// {B4319322-D20D-11d0-BA39-00C04FD7ED67}
|
||||
DEFINE_GUID(DPLPROPERTY_PlayerGuid,
|
||||
0xb4319322, 0xd20d, 0x11d0, 0xba, 0x39, 0x0, 0xc0, 0x4f, 0xd7, 0xed, 0x67);
|
||||
|
||||
/*
|
||||
* DPLDATA_PLAYERGUID
|
||||
*
|
||||
* Data structure to hold the GUID of the player and player creation flags
|
||||
* from the lobby.
|
||||
*/
|
||||
typedef struct _DPLDATA_PLAYERGUID
|
||||
{
|
||||
GUID guidPlayer;
|
||||
DWORD dwPlayerFlags;
|
||||
} DPLDATA_PLAYERGUID, FAR *LPDPLDATA_PLAYERGUID;
|
||||
|
||||
/*
|
||||
* DPLPROPERTY_PlayerScore
|
||||
*
|
||||
* Used to send an array of long integers to the lobby indicating the
|
||||
* score of a player.
|
||||
*
|
||||
* Property data is the DPLDATA_PLAYERSCORE structure.
|
||||
*/
|
||||
// {48784000-D219-11d0-BA39-00C04FD7ED67}
|
||||
DEFINE_GUID(DPLPROPERTY_PlayerScore,
|
||||
0x48784000, 0xd219, 0x11d0, 0xba, 0x39, 0x0, 0xc0, 0x4f, 0xd7, 0xed, 0x67);
|
||||
|
||||
/*
|
||||
* DPLDATA_PLAYERSCORE
|
||||
*
|
||||
* Data structure to hold an array of long integers representing a player score.
|
||||
* Application must allocate enough memory to hold all the scores.
|
||||
*/
|
||||
typedef struct _DPLDATA_PLAYERSCORE
|
||||
{
|
||||
DWORD dwScoreCount;
|
||||
LONG Score[1];
|
||||
} DPLDATA_PLAYERSCORE, FAR *LPDPLDATA_PLAYERSCORE;
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* DirectPlay Address ID's
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/* DirectPlay Address
|
||||
*
|
||||
* A DirectPlay address consists of multiple chunks of data, each tagged
|
||||
* with a GUID signifying the type of data in the chunk. The chunk also
|
||||
* has a length so that unknown chunk types can be skipped.
|
||||
*
|
||||
* The EnumAddress() function is used to parse these address data chunks.
|
||||
*/
|
||||
|
||||
/*
|
||||
* DPADDRESS
|
||||
*
|
||||
* Header for block of address data elements
|
||||
*/
|
||||
typedef struct _DPADDRESS
|
||||
{
|
||||
GUID guidDataType;
|
||||
DWORD dwDataSize;
|
||||
} DPADDRESS;
|
||||
|
||||
typedef DPADDRESS FAR *LPDPADDRESS;
|
||||
|
||||
/*
|
||||
* DPAID_TotalSize
|
||||
*
|
||||
* Chunk is a DWORD containing size of entire DPADDRESS structure
|
||||
*/
|
||||
|
||||
// {1318F560-912C-11d0-9DAA-00A0C90A43CB}
|
||||
DEFINE_GUID(DPAID_TotalSize,
|
||||
0x1318f560, 0x912c, 0x11d0, 0x9d, 0xaa, 0x0, 0xa0, 0xc9, 0xa, 0x43, 0xcb);
|
||||
|
||||
/*
|
||||
* DPAID_ServiceProvider
|
||||
*
|
||||
* Chunk is a GUID describing the service provider that created the chunk.
|
||||
* All addresses must contain this chunk.
|
||||
*/
|
||||
|
||||
// {07D916C0-E0AF-11cf-9C4E-00A0C905425E}
|
||||
DEFINE_GUID(DPAID_ServiceProvider,
|
||||
0x7d916c0, 0xe0af, 0x11cf, 0x9c, 0x4e, 0x0, 0xa0, 0xc9, 0x5, 0x42, 0x5e);
|
||||
|
||||
/*
|
||||
* DPAID_LobbyProvider
|
||||
*
|
||||
* Chunk is a GUID describing the lobby provider that created the chunk.
|
||||
* All addresses must contain this chunk.
|
||||
*/
|
||||
|
||||
// {59B95640-9667-11d0-A77D-0000F803ABFC}
|
||||
DEFINE_GUID(DPAID_LobbyProvider,
|
||||
0x59b95640, 0x9667, 0x11d0, 0xa7, 0x7d, 0x0, 0x0, 0xf8, 0x3, 0xab, 0xfc);
|
||||
|
||||
/*
|
||||
* DPAID_Phone and DPAID_PhoneW
|
||||
*
|
||||
* Chunk is a string containing a phone number (i.e. "1-800-555-1212")
|
||||
* in ANSI or UNICODE format
|
||||
*/
|
||||
|
||||
// {78EC89A0-E0AF-11cf-9C4E-00A0C905425E}
|
||||
DEFINE_GUID(DPAID_Phone,
|
||||
0x78ec89a0, 0xe0af, 0x11cf, 0x9c, 0x4e, 0x0, 0xa0, 0xc9, 0x5, 0x42, 0x5e);
|
||||
|
||||
// {BA5A7A70-9DBF-11d0-9CC1-00A0C905425E}
|
||||
DEFINE_GUID(DPAID_PhoneW,
|
||||
0xba5a7a70, 0x9dbf, 0x11d0, 0x9c, 0xc1, 0x0, 0xa0, 0xc9, 0x5, 0x42, 0x5e);
|
||||
|
||||
/*
|
||||
* DPAID_Modem and DPAID_ModemW
|
||||
*
|
||||
* Chunk is a string containing a modem name registered with TAPI
|
||||
* in ANSI or UNICODE format
|
||||
*/
|
||||
|
||||
// {F6DCC200-A2FE-11d0-9C4F-00A0C905425E}
|
||||
DEFINE_GUID(DPAID_Modem,
|
||||
0xf6dcc200, 0xa2fe, 0x11d0, 0x9c, 0x4f, 0x0, 0xa0, 0xc9, 0x5, 0x42, 0x5e);
|
||||
|
||||
// {01FD92E0-A2FF-11d0-9C4F-00A0C905425E}
|
||||
DEFINE_GUID(DPAID_ModemW,
|
||||
0x1fd92e0, 0xa2ff, 0x11d0, 0x9c, 0x4f, 0x0, 0xa0, 0xc9, 0x5, 0x42, 0x5e);
|
||||
|
||||
/*
|
||||
* DPAID_Inet and DPAID_InetW
|
||||
*
|
||||
* Chunk is a string containing a TCP/IP host name or an IP address
|
||||
* (i.e. "dplay.microsoft.com" or "137.55.100.173") in ANSI or UNICODE format
|
||||
*/
|
||||
|
||||
// {C4A54DA0-E0AF-11cf-9C4E-00A0C905425E}
|
||||
DEFINE_GUID(DPAID_INet,
|
||||
0xc4a54da0, 0xe0af, 0x11cf, 0x9c, 0x4e, 0x0, 0xa0, 0xc9, 0x5, 0x42, 0x5e);
|
||||
|
||||
// {E63232A0-9DBF-11d0-9CC1-00A0C905425E}
|
||||
DEFINE_GUID(DPAID_INetW,
|
||||
0xe63232a0, 0x9dbf, 0x11d0, 0x9c, 0xc1, 0x0, 0xa0, 0xc9, 0x5, 0x42, 0x5e);
|
||||
|
||||
/*
|
||||
* DPCOMPORTADDRESS
|
||||
*
|
||||
* Used to specify com port settings. The constants that define baud rate,
|
||||
* stop bits and parity are defined in WINBASE.H. The constants for flow
|
||||
* control are given below.
|
||||
*/
|
||||
|
||||
#define DPCPA_NOFLOW 0 // no flow control
|
||||
#define DPCPA_XONXOFFFLOW 1 // software flow control
|
||||
#define DPCPA_RTSFLOW 2 // hardware flow control with RTS
|
||||
#define DPCPA_DTRFLOW 3 // hardware flow control with DTR
|
||||
#define DPCPA_RTSDTRFLOW 4 // hardware flow control with RTS and DTR
|
||||
|
||||
typedef struct _DPCOMPORTADDRESS
|
||||
{
|
||||
DWORD dwComPort; // COM port to use (1-4)
|
||||
DWORD dwBaudRate; // baud rate (100-256k)
|
||||
DWORD dwStopBits; // no. stop bits (1-2)
|
||||
DWORD dwParity; // parity (none, odd, even, mark)
|
||||
DWORD dwFlowControl; // flow control (none, xon/xoff, rts, dtr)
|
||||
} DPCOMPORTADDRESS;
|
||||
|
||||
typedef DPCOMPORTADDRESS FAR *LPDPCOMPORTADDRESS;
|
||||
|
||||
/*
|
||||
* DPAID_ComPort
|
||||
*
|
||||
* Chunk contains a DPCOMPORTADDRESS structure defining the serial port.
|
||||
*/
|
||||
|
||||
// {F2F0CE00-E0AF-11cf-9C4E-00A0C905425E}
|
||||
DEFINE_GUID(DPAID_ComPort,
|
||||
0xf2f0ce00, 0xe0af, 0x11cf, 0x9c, 0x4e, 0x0, 0xa0, 0xc9, 0x5, 0x42, 0x5e);
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* dplobby 1.0 obsolete definitions
|
||||
* Included for compatibility only.
|
||||
*
|
||||
****************************************************************************/
|
||||
#define DPLAD_SYSTEM DPLMSG_SYSTEM
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
};
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* __DPLOBBY_INCLUDED__ */
|
267
3rdparty/dx5/inc/dsetup.h
vendored
Normal file
267
3rdparty/dx5/inc/dsetup.h
vendored
Normal file
|
@ -0,0 +1,267 @@
|
|||
/*==========================================================================
|
||||
*
|
||||
* Copyright (C) 1995-1997 Microsoft Corporation. All Rights Reserved.
|
||||
*
|
||||
* File: dsetup.h
|
||||
* Content: DirectXSetup, error codes and flags
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef __DSETUP_H__
|
||||
#define __DSETUP_H__
|
||||
|
||||
#include <windows.h> // windows stuff
|
||||
|
||||
#ifdef _WIN32
|
||||
#define COM_NO_WINDOWS_H
|
||||
#include <objbase.h>
|
||||
#else
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
// DSETUP Error Codes, must remain compatible with previous setup.
|
||||
#define DSETUPERR_SUCCESS_RESTART 1
|
||||
#define DSETUPERR_SUCCESS 0
|
||||
#define DSETUPERR_BADWINDOWSVERSION -1
|
||||
#define DSETUPERR_SOURCEFILENOTFOUND -2
|
||||
#define DSETUPERR_BADSOURCESIZE -3
|
||||
#define DSETUPERR_BADSOURCETIME -4
|
||||
#define DSETUPERR_NOCOPY -5
|
||||
#define DSETUPERR_OUTOFDISKSPACE -6
|
||||
#define DSETUPERR_CANTFINDINF -7
|
||||
#define DSETUPERR_CANTFINDDIR -8
|
||||
#define DSETUPERR_INTERNAL -9
|
||||
#define DSETUPERR_NTWITHNO3D -10 /* REM: obsolete, you'll never see this */
|
||||
#define DSETUPERR_UNKNOWNOS -11
|
||||
#define DSETUPERR_USERHITCANCEL -12
|
||||
#define DSETUPERR_NOTPREINSTALLEDONNT -13
|
||||
|
||||
// DSETUP flags. DirectX 5.0 apps should use these flags only.
|
||||
#define DSETUP_DDRAWDRV 0x00000008 /* install DirectDraw Drivers */
|
||||
#define DSETUP_DSOUNDDRV 0x00000010 /* install DirectSound Drivers */
|
||||
#define DSETUP_DXCORE 0x00010000 /* install DirectX runtime */
|
||||
#define DSETUP_DIRECTX (DSETUP_DXCORE|DSETUP_DDRAWDRV|DSETUP_DSOUNDDRV)
|
||||
#define DSETUP_TESTINSTALL 0x00020000 /* just test install, don't do anything */
|
||||
|
||||
// These OBSOLETE flags are here for compatibility with pre-DX5 apps only.
|
||||
// They are present to allow DX3 apps to be recompiled with DX5 and still work.
|
||||
// DO NOT USE THEM for DX5. They will go away in future DX releases.
|
||||
#define DSETUP_DDRAW 0x00000001 /* OBSOLETE. install DirectDraw */
|
||||
#define DSETUP_DSOUND 0x00000002 /* OBSOLETE. install DirectSound */
|
||||
#define DSETUP_DPLAY 0x00000004 /* OBSOLETE. install DirectPlay */
|
||||
#define DSETUP_DPLAYSP 0x00000020 /* OBSOLETE. install DirectPlay Providers */
|
||||
#define DSETUP_DVIDEO 0x00000040 /* OBSOLETE. install DirectVideo */
|
||||
#define DSETUP_D3D 0x00000200 /* OBSOLETE. install Direct3D */
|
||||
#define DSETUP_DINPUT 0x00000800 /* OBSOLETE. install DirectInput */
|
||||
#define DSETUP_DIRECTXSETUP 0x00001000 /* OBSOLETE. install DirectXSetup DLL's */
|
||||
#define DSETUP_NOUI 0x00002000 /* OBSOLETE. install DirectX with NO UI */
|
||||
#define DSETUP_PROMPTFORDRIVERS 0x10000000 /* OBSOLETE. prompt when replacing display/audio drivers */
|
||||
#define DSETUP_RESTOREDRIVERS 0x20000000 /* OBSOLETE. restore display/audio drivers */
|
||||
|
||||
|
||||
|
||||
//******************************************************************
|
||||
// DirectX Setup Callback mechanism
|
||||
//******************************************************************
|
||||
|
||||
// DSETUP Message Info Codes, passed to callback as Reason parameter.
|
||||
#define DSETUP_CB_MSG_NOMESSAGE 0
|
||||
#define DSETUP_CB_MSG_CANTINSTALL_UNKNOWNOS 1
|
||||
#define DSETUP_CB_MSG_CANTINSTALL_NT 2
|
||||
#define DSETUP_CB_MSG_CANTINSTALL_BETA 3
|
||||
#define DSETUP_CB_MSG_CANTINSTALL_NOTWIN32 4
|
||||
#define DSETUP_CB_MSG_CANTINSTALL_WRONGLANGUAGE 5
|
||||
#define DSETUP_CB_MSG_CANTINSTALL_WRONGPLATFORM 6
|
||||
#define DSETUP_CB_MSG_PREINSTALL_NT 7
|
||||
#define DSETUP_CB_MSG_NOTPREINSTALLEDONNT 8
|
||||
#define DSETUP_CB_MSG_SETUP_INIT_FAILED 9
|
||||
#define DSETUP_CB_MSG_INTERNAL_ERROR 10
|
||||
#define DSETUP_CB_MSG_CHECK_DRIVER_UPGRADE 11
|
||||
#define DSETUP_CB_MSG_OUTOFDISKSPACE 12
|
||||
#define DSETUP_CB_MSG_BEGIN_INSTALL 13
|
||||
#define DSETUP_CB_MSG_BEGIN_INSTALL_RUNTIME 14
|
||||
#define DSETUP_CB_MSG_BEGIN_INSTALL_DRIVERS 15
|
||||
#define DSETUP_CB_MSG_BEGIN_RESTORE_DRIVERS 16
|
||||
#define DSETUP_CB_MSG_FILECOPYERROR 17
|
||||
|
||||
|
||||
#define DSETUP_CB_UPGRADE_TYPE_MASK 0x000F
|
||||
#define DSETUP_CB_UPGRADE_KEEP 0x0001
|
||||
#define DSETUP_CB_UPGRADE_SAFE 0x0002
|
||||
#define DSETUP_CB_UPGRADE_FORCE 0x0004
|
||||
#define DSETUP_CB_UPGRADE_UNKNOWN 0x0008
|
||||
|
||||
#define DSETUP_CB_UPGRADE_HASWARNINGS 0x0100
|
||||
#define DSETUP_CB_UPGRADE_CANTBACKUP 0x0200
|
||||
|
||||
#define DSETUP_CB_UPGRADE_DEVICE_ACTIVE 0x0800
|
||||
|
||||
#define DSETUP_CB_UPGRADE_DEVICE_DISPLAY 0x1000
|
||||
#define DSETUP_CB_UPGRADE_DEVICE_MEDIA 0x2000
|
||||
|
||||
|
||||
typedef struct _DSETUP_CB_UPGRADEINFO
|
||||
{
|
||||
DWORD UpgradeFlags;
|
||||
} DSETUP_CB_UPGRADEINFO;
|
||||
|
||||
typedef struct _DSETUP_CB_FILECOPYERROR
|
||||
{
|
||||
DWORD dwError;
|
||||
} DSETUP_CB_FILECOPYERROR;
|
||||
|
||||
|
||||
#ifdef _WIN32
|
||||
//
|
||||
// Data Structures
|
||||
//
|
||||
#ifndef UNICODE_ONLY
|
||||
typedef struct _DIRECTXREGISTERAPPA {
|
||||
DWORD dwSize;
|
||||
DWORD dwFlags;
|
||||
LPSTR lpszApplicationName;
|
||||
LPGUID lpGUID;
|
||||
LPSTR lpszFilename;
|
||||
LPSTR lpszCommandLine;
|
||||
LPSTR lpszPath;
|
||||
LPSTR lpszCurrentDirectory;
|
||||
} DIRECTXREGISTERAPPA, *PDIRECTXREGISTERAPPA, *LPDIRECTXREGISTERAPPA;
|
||||
#endif //!UNICODE_ONLY
|
||||
#ifndef ANSI_ONLY
|
||||
typedef struct _DIRECTXREGISTERAPPW {
|
||||
DWORD dwSize;
|
||||
DWORD dwFlags;
|
||||
LPWSTR lpszApplicationName;
|
||||
LPGUID lpGUID;
|
||||
LPWSTR lpszFilename;
|
||||
LPWSTR lpszCommandLine;
|
||||
LPWSTR lpszPath;
|
||||
LPWSTR lpszCurrentDirectory;
|
||||
} DIRECTXREGISTERAPPW, *PDIRECTXREGISTERAPPW, *LPDIRECTXREGISTERAPPW;
|
||||
#endif //!ANSI_ONLY
|
||||
#ifdef UNICODE
|
||||
typedef DIRECTXREGISTERAPPW DIRECTXREGISTERAPP;
|
||||
typedef PDIRECTXREGISTERAPPW PDIRECTXREGISTERAPP;
|
||||
typedef LPDIRECTXREGISTERAPPW LPDIRECTXREGISTERAPP;
|
||||
#else
|
||||
typedef DIRECTXREGISTERAPPA DIRECTXREGISTERAPP;
|
||||
typedef PDIRECTXREGISTERAPPA PDIRECTXREGISTERAPP;
|
||||
typedef LPDIRECTXREGISTERAPPA LPDIRECTXREGISTERAPP;
|
||||
#endif // UNICODE
|
||||
|
||||
|
||||
//
|
||||
// API
|
||||
//
|
||||
#ifndef UNICODE_ONLY
|
||||
INT
|
||||
WINAPI
|
||||
DirectXSetupA(
|
||||
HWND hWnd,
|
||||
LPSTR lpszRootPath,
|
||||
DWORD dwFlags
|
||||
);
|
||||
#endif //!UNICODE_ONLY
|
||||
#ifndef ANSI_ONLY
|
||||
INT
|
||||
WINAPI
|
||||
DirectXSetupW(
|
||||
HWND hWnd,
|
||||
LPWSTR lpszRootPath,
|
||||
DWORD dwFlags
|
||||
);
|
||||
#endif //!ANSI_ONLY
|
||||
#ifdef UNICODE
|
||||
#define DirectXSetup DirectXSetupW
|
||||
#else
|
||||
#define DirectXSetup DirectXSetupA
|
||||
#endif // !UNICODE
|
||||
|
||||
#ifndef UNICODE_ONLY
|
||||
INT
|
||||
WINAPI
|
||||
DirectXDeviceDriverSetupA(
|
||||
HWND hWnd,
|
||||
LPSTR lpszDriverClass,
|
||||
LPSTR lpszDriverPath,
|
||||
DWORD dwFlags
|
||||
);
|
||||
#endif //!UNICODE_ONLY
|
||||
#ifndef ANSI_ONLY
|
||||
INT
|
||||
WINAPI
|
||||
DirectXDeviceDriverSetupW(
|
||||
HWND hWnd,
|
||||
LPWSTR lpszDriverClass,
|
||||
LPWSTR lpszDriverPath,
|
||||
DWORD dwFlags
|
||||
);
|
||||
#endif //!ANSI_ONLY
|
||||
#ifdef UNICODE
|
||||
#define DirectXDeviceDriverSetup DirectXDeviceDriverSetupW
|
||||
#else
|
||||
#define DirectXDeviceDriverSetup DirectXDeviceDriverSetupA
|
||||
#endif // !UNICODE
|
||||
|
||||
#ifndef UNICODE_ONLY
|
||||
INT
|
||||
WINAPI
|
||||
DirectXRegisterApplicationA(
|
||||
HWND hWnd,
|
||||
LPDIRECTXREGISTERAPPA lpDXRegApp
|
||||
);
|
||||
#endif //!UNICODE_ONLY
|
||||
#ifndef ANSI_ONLY
|
||||
INT
|
||||
WINAPI
|
||||
DirectXRegisterApplicationW(
|
||||
HWND hWnd,
|
||||
LPDIRECTXREGISTERAPPW lpDXRegApp
|
||||
);
|
||||
#endif //!ANSI_ONLY
|
||||
#ifdef UNICODE
|
||||
#define DirectXRegisterApplication DirectXRegisterApplicationW
|
||||
#else
|
||||
#define DirectXRegisterApplication DirectXRegisterApplicationA
|
||||
#endif // !UNICODE
|
||||
|
||||
INT
|
||||
WINAPI
|
||||
DirectXUnRegisterApplication(
|
||||
HWND hWnd,
|
||||
LPGUID lpGUID
|
||||
);
|
||||
|
||||
//
|
||||
// Function Pointers
|
||||
//
|
||||
#ifdef UNICODE
|
||||
typedef INT (WINAPI * LPDIRECTXSETUP)(HWND, LPWSTR, DWORD);
|
||||
typedef INT (WINAPI * LPDIRECTXDEVICEDRIVERSETUP)(HWND, LPWSTR, LPSTR, DWORD);
|
||||
typedef INT (WINAPI * LPDIRECTXREGISTERAPPLICATION)(HWND, LPDIRECTXREGISTERAPPW);
|
||||
#else
|
||||
typedef INT (WINAPI * LPDIRECTXSETUP)(HWND, LPSTR, DWORD);
|
||||
typedef INT (WINAPI * LPDIRECTXDEVICEDRIVERSETUP)(HWND, LPSTR, LPSTR, DWORD);
|
||||
typedef INT (WINAPI * LPDIRECTXREGISTERAPPLICATION)(HWND, LPDIRECTXREGISTERAPPA);
|
||||
#endif // UNICODE
|
||||
|
||||
typedef DWORD (FAR PASCAL * DSETUP_CALLBACK)(DWORD Reason,
|
||||
DWORD MsgType, /* Same as flags to MessageBox */
|
||||
LPSTR szMessage,
|
||||
LPSTR szName,
|
||||
void *pInfo);
|
||||
|
||||
INT WINAPI DirectXSetupSetCallback(DSETUP_CALLBACK Callback);
|
||||
INT WINAPI DirectXSetupGetVersion(DWORD *lpdwVersion, DWORD *lpdwMinorVersion);
|
||||
|
||||
#endif // WIN32
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
};
|
||||
#endif
|
||||
|
||||
#endif
|
863
3rdparty/dx5/inc/dsound.h
vendored
Normal file
863
3rdparty/dx5/inc/dsound.h
vendored
Normal file
|
@ -0,0 +1,863 @@
|
|||
/*==========================================================================;
|
||||
*
|
||||
* Copyright (C) 1995,1996 Microsoft Corporation. All Rights Reserved.
|
||||
*
|
||||
* File: dsound.h
|
||||
* Content: DirectSound include file
|
||||
*
|
||||
**************************************************************************/
|
||||
|
||||
#ifndef __DSOUND_INCLUDED__
|
||||
#define __DSOUND_INCLUDED__
|
||||
|
||||
#include <d3dtypes.h>
|
||||
|
||||
#define COM_NO_WINDOWS_H
|
||||
#include <objbase.h>
|
||||
|
||||
#define _FACDS 0x878
|
||||
#define MAKE_DSHRESULT(code) MAKE_HRESULT(1, _FACDS, code)
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif // __cplusplus
|
||||
|
||||
// Direct Sound Component GUID {47D4D946-62E8-11cf-93BC-444553540000}
|
||||
DEFINE_GUID(CLSID_DirectSound, 0x47d4d946, 0x62e8, 0x11cf, 0x93, 0xbc, 0x44, 0x45, 0x53, 0x54, 0x0, 0x0);
|
||||
|
||||
// DirectSound Capture Component GUID {B0210780-89CD-11d0-AF08-00A0C925CD16}
|
||||
DEFINE_GUID(CLSID_DirectSoundCapture, 0xb0210780, 0x89cd, 0x11d0, 0xaf, 0x8, 0x0, 0xa0, 0xc9, 0x25, 0xcd, 0x16);
|
||||
|
||||
//
|
||||
// Structures
|
||||
//
|
||||
|
||||
#ifdef __cplusplus
|
||||
// 'struct' not 'class' per the way DECLARE_INTERFACE_ is defined
|
||||
struct IDirectSound;
|
||||
struct IDirectSoundBuffer;
|
||||
struct IDirectSound3DListener;
|
||||
struct IDirectSound3DBuffer;
|
||||
struct IDirectSoundCapture;
|
||||
struct IDirectSoundCaptureBuffer;
|
||||
struct IDirectSoundNotify;
|
||||
#endif // __cplusplus
|
||||
|
||||
typedef struct IDirectSound *LPDIRECTSOUND;
|
||||
typedef struct IDirectSoundBuffer *LPDIRECTSOUNDBUFFER;
|
||||
typedef struct IDirectSound3DListener *LPDIRECTSOUND3DLISTENER;
|
||||
typedef struct IDirectSound3DBuffer *LPDIRECTSOUND3DBUFFER;
|
||||
typedef struct IDirectSoundCapture *LPDIRECTSOUNDCAPTURE;
|
||||
typedef struct IDirectSoundCaptureBuffer *LPDIRECTSOUNDCAPTUREBUFFER;
|
||||
typedef struct IDirectSoundNotify *LPDIRECTSOUNDNOTIFY;
|
||||
|
||||
typedef struct _DSCAPS
|
||||
{
|
||||
DWORD dwSize;
|
||||
DWORD dwFlags;
|
||||
DWORD dwMinSecondarySampleRate;
|
||||
DWORD dwMaxSecondarySampleRate;
|
||||
DWORD dwPrimaryBuffers;
|
||||
DWORD dwMaxHwMixingAllBuffers;
|
||||
DWORD dwMaxHwMixingStaticBuffers;
|
||||
DWORD dwMaxHwMixingStreamingBuffers;
|
||||
DWORD dwFreeHwMixingAllBuffers;
|
||||
DWORD dwFreeHwMixingStaticBuffers;
|
||||
DWORD dwFreeHwMixingStreamingBuffers;
|
||||
DWORD dwMaxHw3DAllBuffers;
|
||||
DWORD dwMaxHw3DStaticBuffers;
|
||||
DWORD dwMaxHw3DStreamingBuffers;
|
||||
DWORD dwFreeHw3DAllBuffers;
|
||||
DWORD dwFreeHw3DStaticBuffers;
|
||||
DWORD dwFreeHw3DStreamingBuffers;
|
||||
DWORD dwTotalHwMemBytes;
|
||||
DWORD dwFreeHwMemBytes;
|
||||
DWORD dwMaxContigFreeHwMemBytes;
|
||||
DWORD dwUnlockTransferRateHwBuffers;
|
||||
DWORD dwPlayCpuOverheadSwBuffers;
|
||||
DWORD dwReserved1;
|
||||
DWORD dwReserved2;
|
||||
} DSCAPS, *LPDSCAPS;
|
||||
|
||||
typedef const DSCAPS *LPCDSCAPS;
|
||||
|
||||
typedef struct _DSBCAPS
|
||||
{
|
||||
DWORD dwSize;
|
||||
DWORD dwFlags;
|
||||
DWORD dwBufferBytes;
|
||||
DWORD dwUnlockTransferRate;
|
||||
DWORD dwPlayCpuOverhead;
|
||||
} DSBCAPS, *LPDSBCAPS;
|
||||
|
||||
typedef const DSBCAPS *LPCDSBCAPS;
|
||||
|
||||
typedef struct _DSBUFFERDESC
|
||||
{
|
||||
DWORD dwSize;
|
||||
DWORD dwFlags;
|
||||
DWORD dwBufferBytes;
|
||||
DWORD dwReserved;
|
||||
LPWAVEFORMATEX lpwfxFormat;
|
||||
} DSBUFFERDESC, *LPDSBUFFERDESC;
|
||||
|
||||
typedef const DSBUFFERDESC *LPCDSBUFFERDESC;
|
||||
|
||||
typedef struct _DS3DBUFFER
|
||||
{
|
||||
DWORD dwSize;
|
||||
D3DVECTOR vPosition;
|
||||
D3DVECTOR vVelocity;
|
||||
DWORD dwInsideConeAngle;
|
||||
DWORD dwOutsideConeAngle;
|
||||
D3DVECTOR vConeOrientation;
|
||||
LONG lConeOutsideVolume;
|
||||
D3DVALUE flMinDistance;
|
||||
D3DVALUE flMaxDistance;
|
||||
DWORD dwMode;
|
||||
} DS3DBUFFER, *LPDS3DBUFFER;
|
||||
|
||||
typedef const DS3DBUFFER *LPCDS3DBUFFER;
|
||||
|
||||
typedef struct _DS3DLISTENER
|
||||
{
|
||||
DWORD dwSize;
|
||||
D3DVECTOR vPosition;
|
||||
D3DVECTOR vVelocity;
|
||||
D3DVECTOR vOrientFront;
|
||||
D3DVECTOR vOrientTop;
|
||||
D3DVALUE flDistanceFactor;
|
||||
D3DVALUE flRolloffFactor;
|
||||
D3DVALUE flDopplerFactor;
|
||||
} DS3DLISTENER, *LPDS3DLISTENER;
|
||||
|
||||
typedef const DS3DLISTENER *LPCDS3DLISTENER;
|
||||
|
||||
typedef struct _DSCCAPS
|
||||
{
|
||||
DWORD dwSize;
|
||||
DWORD dwFlags;
|
||||
DWORD dwFormats;
|
||||
DWORD dwChannels;
|
||||
} DSCCAPS, *LPDSCCAPS;
|
||||
|
||||
typedef const DSCCAPS *LPCDSCCAPS;
|
||||
|
||||
typedef struct _DSCBUFFERDESC
|
||||
{
|
||||
DWORD dwSize;
|
||||
DWORD dwFlags;
|
||||
DWORD dwBufferBytes;
|
||||
DWORD dwReserved;
|
||||
LPWAVEFORMATEX lpwfxFormat;
|
||||
} DSCBUFFERDESC, *LPDSCBUFFERDESC;
|
||||
|
||||
typedef const DSCBUFFERDESC *LPCDSCBUFFERDESC;
|
||||
|
||||
typedef struct _DSCBCAPS
|
||||
{
|
||||
DWORD dwSize;
|
||||
DWORD dwFlags;
|
||||
DWORD dwBufferBytes;
|
||||
DWORD dwReserved;
|
||||
} DSCBCAPS, *LPDSCBCAPS;
|
||||
|
||||
typedef const DSCBCAPS *LPCDSCBCAPS;
|
||||
|
||||
typedef struct _DSBPOSITIONNOTIFY
|
||||
{
|
||||
DWORD dwOffset;
|
||||
HANDLE hEventNotify;
|
||||
} DSBPOSITIONNOTIFY, *LPDSBPOSITIONNOTIFY;
|
||||
|
||||
typedef const DSBPOSITIONNOTIFY *LPCDSBPOSITIONNOTIFY;
|
||||
|
||||
//
|
||||
// Compatibility typedefs
|
||||
//
|
||||
|
||||
typedef LPDIRECTSOUND *LPLPDIRECTSOUND;
|
||||
typedef LPDIRECTSOUNDBUFFER *LPLPDIRECTSOUNDBUFFER;
|
||||
typedef LPDIRECTSOUND3DLISTENER *LPLPDIRECTSOUND3DLISTENER;
|
||||
typedef LPDIRECTSOUND3DBUFFER *LPLPDIRECTSOUND3DBUFFER;
|
||||
typedef LPDIRECTSOUNDCAPTURE *LPLPDIRECTSOUNDCAPTURE;
|
||||
typedef LPDIRECTSOUNDCAPTUREBUFFER *LPLPDIRECTSOUNDCAPTUREBUFFER;
|
||||
typedef LPDIRECTSOUNDNOTIFY *LPLPDIRECTSOUNDNOTIFY;
|
||||
typedef LPVOID *LPLPVOID;
|
||||
typedef const WAVEFORMATEX *LPCWAVEFORMATEX;
|
||||
|
||||
//
|
||||
// DirectSound API
|
||||
//
|
||||
|
||||
typedef BOOL (CALLBACK *LPDSENUMCALLBACKW)(LPGUID, LPCWSTR, LPCWSTR, LPVOID);
|
||||
typedef BOOL (CALLBACK *LPDSENUMCALLBACKA)(LPGUID, LPCSTR, LPCSTR, LPVOID);
|
||||
|
||||
extern HRESULT WINAPI DirectSoundCreate(LPGUID, LPDIRECTSOUND *, LPUNKNOWN);
|
||||
extern HRESULT WINAPI DirectSoundEnumerateW(LPDSENUMCALLBACKW, LPVOID);
|
||||
extern HRESULT WINAPI DirectSoundEnumerateA(LPDSENUMCALLBACKA, LPVOID);
|
||||
|
||||
extern HRESULT WINAPI DirectSoundCaptureCreate(LPGUID, LPDIRECTSOUNDCAPTURE *, LPUNKNOWN);
|
||||
extern HRESULT WINAPI DirectSoundCaptureEnumerateW(LPDSENUMCALLBACKW, LPVOID);
|
||||
extern HRESULT WINAPI DirectSoundCaptureEnumerateA(LPDSENUMCALLBACKA, LPVOID);
|
||||
|
||||
#ifdef UNICODE
|
||||
#define LPDSENUMCALLBACK LPDSENUMCALLBACKW
|
||||
#define DirectSoundEnumerate DirectSoundEnumerateW
|
||||
#define DirectSoundCaptureEnumerate DirectSoundCaptureEnumerateW
|
||||
#else // UNICODE
|
||||
#define LPDSENUMCALLBACK LPDSENUMCALLBACKA
|
||||
#define DirectSoundEnumerate DirectSoundEnumerateA
|
||||
#define DirectSoundCaptureEnumerate DirectSoundCaptureEnumerateA
|
||||
#endif // UNICODE
|
||||
|
||||
//
|
||||
// IDirectSound
|
||||
//
|
||||
|
||||
DEFINE_GUID(IID_IDirectSound, 0x279AFA83, 0x4981, 0x11CE, 0xA5, 0x21, 0x00, 0x20, 0xAF, 0x0B, 0xE5, 0x60);
|
||||
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirectSound
|
||||
|
||||
DECLARE_INTERFACE_(IDirectSound, IUnknown)
|
||||
{
|
||||
// IUnknown methods
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID FAR *) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
// IDirectSound methods
|
||||
STDMETHOD(CreateSoundBuffer) (THIS_ LPCDSBUFFERDESC, LPDIRECTSOUNDBUFFER *, LPUNKNOWN) PURE;
|
||||
STDMETHOD(GetCaps) (THIS_ LPDSCAPS) PURE;
|
||||
STDMETHOD(DuplicateSoundBuffer) (THIS_ LPDIRECTSOUNDBUFFER, LPDIRECTSOUNDBUFFER *) PURE;
|
||||
STDMETHOD(SetCooperativeLevel) (THIS_ HWND, DWORD) PURE;
|
||||
STDMETHOD(Compact) (THIS) PURE;
|
||||
STDMETHOD(GetSpeakerConfig) (THIS_ LPDWORD) PURE;
|
||||
STDMETHOD(SetSpeakerConfig) (THIS_ DWORD) PURE;
|
||||
STDMETHOD(Initialize) (THIS_ LPGUID) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSound_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
|
||||
#define IDirectSound_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirectSound_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirectSound_CreateSoundBuffer(p,a,b,c) (p)->lpVtbl->CreateSoundBuffer(p,a,b,c)
|
||||
#define IDirectSound_GetCaps(p,a) (p)->lpVtbl->GetCaps(p,a)
|
||||
#define IDirectSound_DuplicateSoundBuffer(p,a,b) (p)->lpVtbl->DuplicateSoundBuffer(p,a,b)
|
||||
#define IDirectSound_SetCooperativeLevel(p,a,b) (p)->lpVtbl->SetCooperativeLevel(p,a,b)
|
||||
#define IDirectSound_Compact(p) (p)->lpVtbl->Compact(p)
|
||||
#define IDirectSound_GetSpeakerConfig(p,a) (p)->lpVtbl->GetSpeakerConfig(p,a)
|
||||
#define IDirectSound_SetSpeakerConfig(p,b) (p)->lpVtbl->SetSpeakerConfig(p,b)
|
||||
#define IDirectSound_Initialize(p,a) (p)->lpVtbl->Initialize(p,a)
|
||||
#else // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSound_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
|
||||
#define IDirectSound_AddRef(p) (p)->AddRef()
|
||||
#define IDirectSound_Release(p) (p)->Release()
|
||||
#define IDirectSound_CreateSoundBuffer(p,a,b,c) (p)->CreateSoundBuffer(a,b,c)
|
||||
#define IDirectSound_GetCaps(p,a) (p)->GetCaps(a)
|
||||
#define IDirectSound_DuplicateSoundBuffer(p,a,b) (p)->DuplicateSoundBuffer(a,b)
|
||||
#define IDirectSound_SetCooperativeLevel(p,a,b) (p)->SetCooperativeLevel(a,b)
|
||||
#define IDirectSound_Compact(p) (p)->Compact()
|
||||
#define IDirectSound_GetSpeakerConfig(p,a) (p)->GetSpeakerConfig(a)
|
||||
#define IDirectSound_SetSpeakerConfig(p,b) (p)->SetSpeakerConfig(b)
|
||||
#define IDirectSound_Initialize(p,a) (p)->Initialize(a)
|
||||
#endif // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
|
||||
//
|
||||
// IDirectSoundBuffer
|
||||
//
|
||||
|
||||
DEFINE_GUID(IID_IDirectSoundBuffer, 0x279AFA85, 0x4981, 0x11CE, 0xA5, 0x21, 0x00, 0x20, 0xAF, 0x0B, 0xE5, 0x60);
|
||||
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirectSoundBuffer
|
||||
|
||||
DECLARE_INTERFACE_(IDirectSoundBuffer, IUnknown)
|
||||
{
|
||||
// IUnknown methods
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID FAR *) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
// IDirectSoundBuffer methods
|
||||
STDMETHOD(GetCaps) (THIS_ LPDSBCAPS) PURE;
|
||||
STDMETHOD(GetCurrentPosition) (THIS_ LPDWORD, LPDWORD) PURE;
|
||||
STDMETHOD(GetFormat) (THIS_ LPWAVEFORMATEX, DWORD, LPDWORD) PURE;
|
||||
STDMETHOD(GetVolume) (THIS_ LPLONG) PURE;
|
||||
STDMETHOD(GetPan) (THIS_ LPLONG) PURE;
|
||||
STDMETHOD(GetFrequency) (THIS_ LPDWORD) PURE;
|
||||
STDMETHOD(GetStatus) (THIS_ LPDWORD) PURE;
|
||||
STDMETHOD(Initialize) (THIS_ LPDIRECTSOUND, LPCDSBUFFERDESC) PURE;
|
||||
STDMETHOD(Lock) (THIS_ DWORD, DWORD, LPVOID *, LPDWORD, LPVOID *, LPDWORD, DWORD) PURE;
|
||||
STDMETHOD(Play) (THIS_ DWORD, DWORD, DWORD) PURE;
|
||||
STDMETHOD(SetCurrentPosition) (THIS_ DWORD) PURE;
|
||||
STDMETHOD(SetFormat) (THIS_ LPCWAVEFORMATEX) PURE;
|
||||
STDMETHOD(SetVolume) (THIS_ LONG) PURE;
|
||||
STDMETHOD(SetPan) (THIS_ LONG) PURE;
|
||||
STDMETHOD(SetFrequency) (THIS_ DWORD) PURE;
|
||||
STDMETHOD(Stop) (THIS) PURE;
|
||||
STDMETHOD(Unlock) (THIS_ LPVOID, DWORD, LPVOID, DWORD) PURE;
|
||||
STDMETHOD(Restore) (THIS) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSoundBuffer_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
|
||||
#define IDirectSoundBuffer_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirectSoundBuffer_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirectSoundBuffer_GetCaps(p,a) (p)->lpVtbl->GetCaps(p,a)
|
||||
#define IDirectSoundBuffer_GetCurrentPosition(p,a,b) (p)->lpVtbl->GetCurrentPosition(p,a,b)
|
||||
#define IDirectSoundBuffer_GetFormat(p,a,b,c) (p)->lpVtbl->GetFormat(p,a,b,c)
|
||||
#define IDirectSoundBuffer_GetVolume(p,a) (p)->lpVtbl->GetVolume(p,a)
|
||||
#define IDirectSoundBuffer_GetPan(p,a) (p)->lpVtbl->GetPan(p,a)
|
||||
#define IDirectSoundBuffer_GetFrequency(p,a) (p)->lpVtbl->GetFrequency(p,a)
|
||||
#define IDirectSoundBuffer_GetStatus(p,a) (p)->lpVtbl->GetStatus(p,a)
|
||||
#define IDirectSoundBuffer_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b)
|
||||
#define IDirectSoundBuffer_Lock(p,a,b,c,d,e,f,g) (p)->lpVtbl->Lock(p,a,b,c,d,e,f,g)
|
||||
#define IDirectSoundBuffer_Play(p,a,b,c) (p)->lpVtbl->Play(p,a,b,c)
|
||||
#define IDirectSoundBuffer_SetCurrentPosition(p,a) (p)->lpVtbl->SetCurrentPosition(p,a)
|
||||
#define IDirectSoundBuffer_SetFormat(p,a) (p)->lpVtbl->SetFormat(p,a)
|
||||
#define IDirectSoundBuffer_SetVolume(p,a) (p)->lpVtbl->SetVolume(p,a)
|
||||
#define IDirectSoundBuffer_SetPan(p,a) (p)->lpVtbl->SetPan(p,a)
|
||||
#define IDirectSoundBuffer_SetFrequency(p,a) (p)->lpVtbl->SetFrequency(p,a)
|
||||
#define IDirectSoundBuffer_Stop(p) (p)->lpVtbl->Stop(p)
|
||||
#define IDirectSoundBuffer_Unlock(p,a,b,c,d) (p)->lpVtbl->Unlock(p,a,b,c,d)
|
||||
#define IDirectSoundBuffer_Restore(p) (p)->lpVtbl->Restore(p)
|
||||
#else // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSoundBuffer_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
|
||||
#define IDirectSoundBuffer_AddRef(p) (p)->AddRef()
|
||||
#define IDirectSoundBuffer_Release(p) (p)->Release()
|
||||
#define IDirectSoundBuffer_GetCaps(p,a) (p)->GetCaps(a)
|
||||
#define IDirectSoundBuffer_GetCurrentPosition(p,a,b) (p)->GetCurrentPosition(a,b)
|
||||
#define IDirectSoundBuffer_GetFormat(p,a,b,c) (p)->GetFormat(a,b,c)
|
||||
#define IDirectSoundBuffer_GetVolume(p,a) (p)->GetVolume(a)
|
||||
#define IDirectSoundBuffer_GetPan(p,a) (p)->GetPan(a)
|
||||
#define IDirectSoundBuffer_GetFrequency(p,a) (p)->GetFrequency(a)
|
||||
#define IDirectSoundBuffer_GetStatus(p,a) (p)->GetStatus(a)
|
||||
#define IDirectSoundBuffer_Initialize(p,a,b) (p)->Initialize(a,b)
|
||||
#define IDirectSoundBuffer_Lock(p,a,b,c,d,e,f,g) (p)->Lock(a,b,c,d,e,f,g)
|
||||
#define IDirectSoundBuffer_Play(p,a,b,c) (p)->Play(a,b,c)
|
||||
#define IDirectSoundBuffer_SetCurrentPosition(p,a) (p)->SetCurrentPosition(a)
|
||||
#define IDirectSoundBuffer_SetFormat(p,a) (p)->SetFormat(a)
|
||||
#define IDirectSoundBuffer_SetVolume(p,a) (p)->SetVolume(a)
|
||||
#define IDirectSoundBuffer_SetPan(p,a) (p)->SetPan(a)
|
||||
#define IDirectSoundBuffer_SetFrequency(p,a) (p)->SetFrequency(a)
|
||||
#define IDirectSoundBuffer_Stop(p) (p)->Stop()
|
||||
#define IDirectSoundBuffer_Unlock(p,a,b,c,d) (p)->Unlock(a,b,c,d)
|
||||
#define IDirectSoundBuffer_Restore(p) (p)->Restore()
|
||||
#endif // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
|
||||
//
|
||||
// IDirectSound3DListener
|
||||
//
|
||||
|
||||
DEFINE_GUID(IID_IDirectSound3DListener, 0x279AFA84, 0x4981, 0x11CE, 0xA5, 0x21, 0x00, 0x20, 0xAF, 0x0B, 0xE5, 0x60);
|
||||
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirectSound3DListener
|
||||
|
||||
DECLARE_INTERFACE_(IDirectSound3DListener, IUnknown)
|
||||
{
|
||||
// IUnknown methods
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID FAR *) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
// IDirectSound3D methods
|
||||
STDMETHOD(GetAllParameters) (THIS_ LPDS3DLISTENER) PURE;
|
||||
STDMETHOD(GetDistanceFactor) (THIS_ LPD3DVALUE) PURE;
|
||||
STDMETHOD(GetDopplerFactor) (THIS_ LPD3DVALUE) PURE;
|
||||
STDMETHOD(GetOrientation) (THIS_ LPD3DVECTOR, LPD3DVECTOR) PURE;
|
||||
STDMETHOD(GetPosition) (THIS_ LPD3DVECTOR) PURE;
|
||||
STDMETHOD(GetRolloffFactor) (THIS_ LPD3DVALUE) PURE;
|
||||
STDMETHOD(GetVelocity) (THIS_ LPD3DVECTOR) PURE;
|
||||
STDMETHOD(SetAllParameters) (THIS_ LPCDS3DLISTENER, DWORD) PURE;
|
||||
STDMETHOD(SetDistanceFactor) (THIS_ D3DVALUE, DWORD) PURE;
|
||||
STDMETHOD(SetDopplerFactor) (THIS_ D3DVALUE, DWORD) PURE;
|
||||
STDMETHOD(SetOrientation) (THIS_ D3DVALUE, D3DVALUE, D3DVALUE, D3DVALUE, D3DVALUE, D3DVALUE, DWORD) PURE;
|
||||
STDMETHOD(SetPosition) (THIS_ D3DVALUE, D3DVALUE, D3DVALUE, DWORD) PURE;
|
||||
STDMETHOD(SetRolloffFactor) (THIS_ D3DVALUE, DWORD) PURE;
|
||||
STDMETHOD(SetVelocity) (THIS_ D3DVALUE, D3DVALUE, D3DVALUE, DWORD) PURE;
|
||||
STDMETHOD(CommitDeferredSettings) (THIS) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSound3DListener_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
|
||||
#define IDirectSound3DListener_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirectSound3DListener_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirectSound3DListener_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a)
|
||||
#define IDirectSound3DListener_GetDistanceFactor(p,a) (p)->lpVtbl->GetDistanceFactor(p,a)
|
||||
#define IDirectSound3DListener_GetDopplerFactor(p,a) (p)->lpVtbl->GetDopplerFactor(p,a)
|
||||
#define IDirectSound3DListener_GetOrientation(p,a,b) (p)->lpVtbl->GetOrientation(p,a,b)
|
||||
#define IDirectSound3DListener_GetPosition(p,a) (p)->lpVtbl->GetPosition(p,a)
|
||||
#define IDirectSound3DListener_GetRolloffFactor(p,a) (p)->lpVtbl->GetRolloffFactor(p,a)
|
||||
#define IDirectSound3DListener_GetVelocity(p,a) (p)->lpVtbl->GetVelocity(p,a)
|
||||
#define IDirectSound3DListener_SetAllParameters(p,a,b) (p)->lpVtbl->SetAllParameters(p,a,b)
|
||||
#define IDirectSound3DListener_SetDistanceFactor(p,a,b) (p)->lpVtbl->SetDistanceFactor(p,a,b)
|
||||
#define IDirectSound3DListener_SetDopplerFactor(p,a,b) (p)->lpVtbl->SetDopplerFactor(p,a,b)
|
||||
#define IDirectSound3DListener_SetOrientation(p,a,b,c,d,e,f,g) (p)->lpVtbl->SetOrientation(p,a,b,c,d,e,f,g)
|
||||
#define IDirectSound3DListener_SetPosition(p,a,b,c,d) (p)->lpVtbl->SetPosition(p,a,b,c,d)
|
||||
#define IDirectSound3DListener_SetRolloffFactor(p,a,b) (p)->lpVtbl->SetRolloffFactor(p,a,b)
|
||||
#define IDirectSound3DListener_SetVelocity(p,a,b,c,d) (p)->lpVtbl->SetVelocity(p,a,b,c,d)
|
||||
#define IDirectSound3DListener_CommitDeferredSettings(p) (p)->lpVtbl->CommitDeferredSettings(p)
|
||||
#else // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSound3DListener_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
|
||||
#define IDirectSound3DListener_AddRef(p) (p)->AddRef()
|
||||
#define IDirectSound3DListener_Release(p) (p)->Release()
|
||||
#define IDirectSound3DListener_GetAllParameters(p,a) (p)->GetAllParameters(a)
|
||||
#define IDirectSound3DListener_GetDistanceFactor(p,a) (p)->GetDistanceFactor(a)
|
||||
#define IDirectSound3DListener_GetDopplerFactor(p,a) (p)->GetDopplerFactor(a)
|
||||
#define IDirectSound3DListener_GetOrientation(p,a,b) (p)->GetOrientation(a,b)
|
||||
#define IDirectSound3DListener_GetPosition(p,a) (p)->GetPosition(a)
|
||||
#define IDirectSound3DListener_GetRolloffFactor(p,a) (p)->GetRolloffFactor(a)
|
||||
#define IDirectSound3DListener_GetVelocity(p,a) (p)->GetVelocity(a)
|
||||
#define IDirectSound3DListener_SetAllParameters(p,a,b) (p)->SetAllParameters(a,b)
|
||||
#define IDirectSound3DListener_SetDistanceFactor(p,a,b) (p)->SetDistanceFactor(a,b)
|
||||
#define IDirectSound3DListener_SetDopplerFactor(p,a,b) (p)->SetDopplerFactor(a,b)
|
||||
#define IDirectSound3DListener_SetOrientation(p,a,b,c,d,e,f,g) (p)->SetOrientation(a,b,c,d,e,f,g)
|
||||
#define IDirectSound3DListener_SetPosition(p,a,b,c,d) (p)->SetPosition(a,b,c,d)
|
||||
#define IDirectSound3DListener_SetRolloffFactor(p,a,b) (p)->SetRolloffFactor(a,b)
|
||||
#define IDirectSound3DListener_SetVelocity(p,a,b,c,d) (p)->SetVelocity(a,b,c,d)
|
||||
#define IDirectSound3DListener_CommitDeferredSettings(p) (p)->CommitDeferredSettings()
|
||||
#endif // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
|
||||
//
|
||||
// IDirectSound3DBuffer
|
||||
//
|
||||
|
||||
DEFINE_GUID(IID_IDirectSound3DBuffer, 0x279AFA86, 0x4981, 0x11CE, 0xA5, 0x21, 0x00, 0x20, 0xAF, 0x0B, 0xE5, 0x60);
|
||||
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirectSound3DBuffer
|
||||
|
||||
DECLARE_INTERFACE_(IDirectSound3DBuffer, IUnknown)
|
||||
{
|
||||
// IUnknown methods
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
// IDirectSoundBuffer3D methods
|
||||
STDMETHOD(GetAllParameters) (THIS_ LPDS3DBUFFER) PURE;
|
||||
STDMETHOD(GetConeAngles) (THIS_ LPDWORD, LPDWORD) PURE;
|
||||
STDMETHOD(GetConeOrientation) (THIS_ LPD3DVECTOR) PURE;
|
||||
STDMETHOD(GetConeOutsideVolume) (THIS_ LPLONG) PURE;
|
||||
STDMETHOD(GetMaxDistance) (THIS_ LPD3DVALUE) PURE;
|
||||
STDMETHOD(GetMinDistance) (THIS_ LPD3DVALUE) PURE;
|
||||
STDMETHOD(GetMode) (THIS_ LPDWORD) PURE;
|
||||
STDMETHOD(GetPosition) (THIS_ LPD3DVECTOR) PURE;
|
||||
STDMETHOD(GetVelocity) (THIS_ LPD3DVECTOR) PURE;
|
||||
STDMETHOD(SetAllParameters) (THIS_ LPCDS3DBUFFER, DWORD) PURE;
|
||||
STDMETHOD(SetConeAngles) (THIS_ DWORD, DWORD, DWORD) PURE;
|
||||
STDMETHOD(SetConeOrientation) (THIS_ D3DVALUE, D3DVALUE, D3DVALUE, DWORD) PURE;
|
||||
STDMETHOD(SetConeOutsideVolume) (THIS_ LONG, DWORD) PURE;
|
||||
STDMETHOD(SetMaxDistance) (THIS_ D3DVALUE, DWORD) PURE;
|
||||
STDMETHOD(SetMinDistance) (THIS_ D3DVALUE, DWORD) PURE;
|
||||
STDMETHOD(SetMode) (THIS_ DWORD, DWORD) PURE;
|
||||
STDMETHOD(SetPosition) (THIS_ D3DVALUE, D3DVALUE, D3DVALUE, DWORD) PURE;
|
||||
STDMETHOD(SetVelocity) (THIS_ D3DVALUE, D3DVALUE, D3DVALUE, DWORD) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSound3DBuffer_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
|
||||
#define IDirectSound3DBuffer_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirectSound3DBuffer_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirectSound3DBuffer_GetAllParameters(p,a) (p)->lpVtbl->GetAllParameters(p,a)
|
||||
#define IDirectSound3DBuffer_GetConeAngles(p,a,b) (p)->lpVtbl->GetConeAngles(p,a,b)
|
||||
#define IDirectSound3DBuffer_GetConeOrientation(p,a) (p)->lpVtbl->GetConeOrientation(p,a)
|
||||
#define IDirectSound3DBuffer_GetConeOutsideVolume(p,a) (p)->lpVtbl->GetConeOutsideVolume(p,a)
|
||||
#define IDirectSound3DBuffer_GetPosition(p,a) (p)->lpVtbl->GetPosition(p,a)
|
||||
#define IDirectSound3DBuffer_GetMinDistance(p,a) (p)->lpVtbl->GetMinDistance(p,a)
|
||||
#define IDirectSound3DBuffer_GetMaxDistance(p,a) (p)->lpVtbl->GetMaxDistance(p,a)
|
||||
#define IDirectSound3DBuffer_GetMode(p,a) (p)->lpVtbl->GetMode(p,a)
|
||||
#define IDirectSound3DBuffer_GetVelocity(p,a) (p)->lpVtbl->GetVelocity(p,a)
|
||||
#define IDirectSound3DBuffer_SetAllParameters(p,a,b) (p)->lpVtbl->SetAllParameters(p,a,b)
|
||||
#define IDirectSound3DBuffer_SetConeAngles(p,a,b,c) (p)->lpVtbl->SetConeAngles(p,a,b,c)
|
||||
#define IDirectSound3DBuffer_SetConeOrientation(p,a,b,c,d) (p)->lpVtbl->SetConeOrientation(p,a,b,c,d)
|
||||
#define IDirectSound3DBuffer_SetConeOutsideVolume(p,a,b)(p)->lpVtbl->SetConeOutsideVolume(p,a,b)
|
||||
#define IDirectSound3DBuffer_SetPosition(p,a,b,c,d) (p)->lpVtbl->SetPosition(p,a,b,c,d)
|
||||
#define IDirectSound3DBuffer_SetMinDistance(p,a,b) (p)->lpVtbl->SetMinDistance(p,a,b)
|
||||
#define IDirectSound3DBuffer_SetMaxDistance(p,a,b) (p)->lpVtbl->SetMaxDistance(p,a,b)
|
||||
#define IDirectSound3DBuffer_SetMode(p,a,b) (p)->lpVtbl->SetMode(p,a,b)
|
||||
#define IDirectSound3DBuffer_SetVelocity(p,a,b,c,d) (p)->lpVtbl->SetVelocity(p,a,b,c,d)
|
||||
#else // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSound3DBuffer_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
|
||||
#define IDirectSound3DBuffer_AddRef(p) (p)->AddRef()
|
||||
#define IDirectSound3DBuffer_Release(p) (p)->Release()
|
||||
#define IDirectSound3DBuffer_GetAllParameters(p,a) (p)->GetAllParameters(a)
|
||||
#define IDirectSound3DBuffer_GetConeAngles(p,a,b) (p)->GetConeAngles(a,b)
|
||||
#define IDirectSound3DBuffer_GetConeOrientation(p,a) (p)->GetConeOrientation(a)
|
||||
#define IDirectSound3DBuffer_GetConeOutsideVolume(p,a) (p)->GetConeOutsideVolume(a)
|
||||
#define IDirectSound3DBuffer_GetPosition(p,a) (p)->GetPosition(a)
|
||||
#define IDirectSound3DBuffer_GetMinDistance(p,a) (p)->GetMinDistance(a)
|
||||
#define IDirectSound3DBuffer_GetMaxDistance(p,a) (p)->GetMaxDistance(a)
|
||||
#define IDirectSound3DBuffer_GetMode(p,a) (p)->GetMode(a)
|
||||
#define IDirectSound3DBuffer_GetVelocity(p,a) (p)->GetVelocity(a)
|
||||
#define IDirectSound3DBuffer_SetAllParameters(p,a,b) (p)->SetAllParameters(a,b)
|
||||
#define IDirectSound3DBuffer_SetConeAngles(p,a,b,c) (p)->SetConeAngles(a,b,c)
|
||||
#define IDirectSound3DBuffer_SetConeOrientation(p,a,b,c,d) (p)->SetConeOrientation(a,b,c,d)
|
||||
#define IDirectSound3DBuffer_SetConeOutsideVolume(p,a,b)(p)->SetConeOutsideVolume(a,b)
|
||||
#define IDirectSound3DBuffer_SetPosition(p,a,b,c,d) (p)->SetPosition(a,b,c,d)
|
||||
#define IDirectSound3DBuffer_SetMinDistance(p,a,b) (p)->SetMinDistance(a,b)
|
||||
#define IDirectSound3DBuffer_SetMaxDistance(p,a,b) (p)->SetMaxDistance(a,b)
|
||||
#define IDirectSound3DBuffer_SetMode(p,a,b) (p)->SetMode(a,b)
|
||||
#define IDirectSound3DBuffer_SetVelocity(p,a,b,c,d) (p)->SetVelocity(a,b,c,d)
|
||||
#endif // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
|
||||
//
|
||||
// IDirectSoundCapture
|
||||
//
|
||||
|
||||
DEFINE_GUID(IID_IDirectSoundCapture, 0xb0210781, 0x89cd, 0x11d0, 0xaf, 0x8, 0x0, 0xa0, 0xc9, 0x25, 0xcd, 0x16);
|
||||
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirectSoundCapture
|
||||
|
||||
DECLARE_INTERFACE_(IDirectSoundCapture, IUnknown)
|
||||
{
|
||||
// IUnknown methods
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
// IDirectSoundCapture methods
|
||||
STDMETHOD(CreateCaptureBuffer) (THIS_ LPCDSCBUFFERDESC, LPDIRECTSOUNDCAPTUREBUFFER *, LPUNKNOWN) PURE;
|
||||
STDMETHOD(GetCaps) (THIS_ LPDSCCAPS ) PURE;
|
||||
STDMETHOD(Initialize) (THIS_ LPGUID) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSoundCapture_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
|
||||
#define IDirectSoundCapture_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirectSoundCapture_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirectSoundCapture_CreateCaptureBuffer(p,a,b,c) (p)->lpVtbl->CreateCaptureBuffer(p,a,b,c)
|
||||
#define IDirectSoundCapture_GetCaps(p,a) (p)->lpVtbl->GetCaps(p,a)
|
||||
#define IDirectSoundCapture_Initialize(p,a) (p)->lpVtbl->Initialize(p,a)
|
||||
#else // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSoundCapture_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
|
||||
#define IDirectSoundCapture_AddRef(p) (p)->AddRef()
|
||||
#define IDirectSoundCapture_Release(p) (p)->Release()
|
||||
#define IDirectSoundCapture_CreateCaptureBuffer(p,a,b,c) (p)->CreateCaptureBuffer(a,b,c)
|
||||
#define IDirectSoundCapture_GetCaps(p,a) (p)->GetCaps(a)
|
||||
#define IDirectSoundCapture_Initialize(p,a) (p)->Initialize(a)
|
||||
#endif // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
|
||||
//
|
||||
// IDirectSoundCaptureBuffer
|
||||
//
|
||||
|
||||
DEFINE_GUID(IID_IDirectSoundCaptureBuffer, 0xb0210782, 0x89cd, 0x11d0, 0xaf, 0x8, 0x0, 0xa0, 0xc9, 0x25, 0xcd, 0x16);
|
||||
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirectSoundCaptureBuffer
|
||||
|
||||
DECLARE_INTERFACE_(IDirectSoundCaptureBuffer, IUnknown)
|
||||
{
|
||||
// IUnknown methods
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
// IDirectSoundCaptureBuffer methods
|
||||
STDMETHOD(GetCaps) (THIS_ LPDSCBCAPS ) PURE;
|
||||
STDMETHOD(GetCurrentPosition) (THIS_ LPDWORD, LPDWORD ) PURE;
|
||||
STDMETHOD(GetFormat) (THIS_ LPWAVEFORMATEX, DWORD, LPDWORD ) PURE;
|
||||
STDMETHOD(GetStatus) (THIS_ LPDWORD ) PURE;
|
||||
STDMETHOD(Initialize) (THIS_ LPDIRECTSOUNDCAPTURE, LPCDSCBUFFERDESC) PURE;
|
||||
STDMETHOD(Lock) (THIS_ DWORD, DWORD, LPVOID *, LPDWORD, LPVOID *, LPDWORD, DWORD) PURE;
|
||||
STDMETHOD(Start) (THIS_ DWORD) PURE;
|
||||
STDMETHOD(Stop) (THIS) PURE;
|
||||
STDMETHOD(Unlock) (THIS_ LPVOID, DWORD, LPVOID, DWORD) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSoundCaptureBuffer_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
|
||||
#define IDirectSoundCaptureBuffer_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirectSoundCaptureBuffer_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirectSoundCaptureBuffer_GetCaps(p,a) (p)->lpVtbl->GetCaps(p,a)
|
||||
#define IDirectSoundCaptureBuffer_GetCurrentPosition(p,a,b) (p)->lpVtbl->GetCurrentPosition(p,a,b)
|
||||
#define IDirectSoundCaptureBuffer_GetFormat(p,a,b,c) (p)->lpVtbl->GetFormat(p,a,b,c)
|
||||
#define IDirectSoundCaptureBuffer_GetStatus(p,a) (p)->lpVtbl->GetStatus(p,a)
|
||||
#define IDirectSoundCaptureBuffer_Initialize(p,a,b) (p)->lpVtbl->Initialize(p,a,b)
|
||||
#define IDirectSoundCaptureBuffer_Lock(p,a,b,c,d,e,f,g) (p)->lpVtbl->Lock(p,a,b,c,d,e,f,g)
|
||||
#define IDirectSoundCaptureBuffer_Start(p,a) (p)->lpVtbl->Start(p,a)
|
||||
#define IDirectSoundCaptureBuffer_Stop(p) (p)->lpVtbl->Stop(p)
|
||||
#define IDirectSoundCaptureBuffer_Unlock(p,a,b,c,d) (p)->lpVtbl->Unlock(p,a,b,c,d)
|
||||
#else // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSoundCaptureBuffer_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
|
||||
#define IDirectSoundCaptureBuffer_AddRef(p) (p)->AddRef()
|
||||
#define IDirectSoundCaptureBuffer_Release(p) (p)->Release()
|
||||
#define IDirectSoundCaptureBuffer_GetCaps(p,a) (p)->GetCaps(a)
|
||||
#define IDirectSoundCaptureBuffer_GetCurrentPosition(p,a,b) (p)->GetCurrentPosition(a,b)
|
||||
#define IDirectSoundCaptureBuffer_GetFormat(p,a,b,c) (p)->GetFormat(a,b,c)
|
||||
#define IDirectSoundCaptureBuffer_GetStatus(p,a) (p)->GetStatus(a)
|
||||
#define IDirectSoundCaptureBuffer_Initialize(p,a,b) (p)->Initialize(a,b)
|
||||
#define IDirectSoundCaptureBuffer_Lock(p,a,b,c,d,e,f,g) (p)->Lock(a,b,c,d,e,f,g)
|
||||
#define IDirectSoundCaptureBuffer_Start(p,a) (p)->Start(a)
|
||||
#define IDirectSoundCaptureBuffer_Stop(p) (p)->Stop()
|
||||
#define IDirectSoundCaptureBuffer_Unlock(p,a,b,c,d) (p)->Unlock(a,b,c,d)
|
||||
#endif // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
|
||||
//
|
||||
// IDirectSoundNotify
|
||||
//
|
||||
|
||||
DEFINE_GUID(IID_IDirectSoundNotify, 0xb0210783, 0x89cd, 0x11d0, 0xaf, 0x8, 0x0, 0xa0, 0xc9, 0x25, 0xcd, 0x16);
|
||||
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirectSoundNotify
|
||||
|
||||
DECLARE_INTERFACE_(IDirectSoundNotify, IUnknown)
|
||||
{
|
||||
// IUnknown methods
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
// IDirectSoundNotify methods
|
||||
STDMETHOD(SetNotificationPositions) (THIS_ DWORD, LPCDSBPOSITIONNOTIFY) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSoundNotify_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
|
||||
#define IDirectSoundNotify_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IDirectSoundNotify_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IDirectSoundNotify_SetNotificationPositions(p,a,b) (p)->lpVtbl->SetNotificationPositions(p,a,b)
|
||||
#else // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IDirectSoundNotify_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
|
||||
#define IDirectSoundNotify_AddRef(p) (p)->AddRef()
|
||||
#define IDirectSoundNotify_Release(p) (p)->Release()
|
||||
#define IDirectSoundNotify_SetNotificationPositions(p,a,b) (p)->SetNotificationPositions(a,b)
|
||||
#endif // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
|
||||
//
|
||||
// IKsPropertySet
|
||||
//
|
||||
|
||||
#ifndef _IKsPropertySet_
|
||||
#define _IKsPropertySet_
|
||||
|
||||
#ifdef __cplusplus
|
||||
// 'struct' not 'class' per the way DECLARE_INTERFACE_ is defined
|
||||
struct IKsPropertySet;
|
||||
#endif // __cplusplus
|
||||
|
||||
typedef struct IKsPropertySet *LPKSPROPERTYSET;
|
||||
|
||||
#define KSPROPERTY_SUPPORT_GET 0x00000001
|
||||
#define KSPROPERTY_SUPPORT_SET 0x00000002
|
||||
|
||||
DEFINE_GUID(IID_IKsPropertySet, 0x31efac30, 0x515c, 0x11d0, 0xa9, 0xaa, 0x00, 0xaa, 0x00, 0x61, 0xbe, 0x93);
|
||||
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IKsPropertySet
|
||||
|
||||
DECLARE_INTERFACE_(IKsPropertySet, IUnknown)
|
||||
{
|
||||
// IUnknown methods
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID, LPVOID *) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
// IKsPropertySet methods
|
||||
STDMETHOD(Get) (THIS_ REFGUID, ULONG, LPVOID, ULONG, LPVOID, ULONG, PULONG) PURE;
|
||||
STDMETHOD(Set) (THIS_ REFGUID, ULONG, LPVOID, ULONG, LPVOID, ULONG) PURE;
|
||||
STDMETHOD(QuerySupport) (THIS_ REFGUID, ULONG, PULONG) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IKsPropertySet_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
|
||||
#define IKsPropertySet_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IKsPropertySet_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IKsPropertySet_Get(p,a,b,c,d,e,f,g) (p)->lpVtbl->Get(p,a,b,c,d,e,f,g)
|
||||
#define IKsPropertySet_Set(p,a,b,c,d,e,f) (p)->lpVtbl->Set(p,a,b,c,d,e,f)
|
||||
#define IKsPropertySet_QuerySupport(p,a,b,c) (p)->lpVtbl->QuerySupport(p,a,b,c)
|
||||
#else // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IKsPropertySet_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
|
||||
#define IKsPropertySet_AddRef(p) (p)->AddRef()
|
||||
#define IKsPropertySet_Release(p) (p)->Release()
|
||||
#define IKsPropertySet_Get(p,a,b,c,d,e,f,g) (p)->Get(a,b,c,d,e,f,g)
|
||||
#define IKsPropertySet_Set(p,a,b,c,d,e,f) (p)->Set(a,b,c,d,e,f)
|
||||
#define IKsPropertySet_QuerySupport(p,a,b,c) (p)->QuerySupport(a,b,c)
|
||||
#endif // !defined(__cplusplus) || defined(CINTERFACE)
|
||||
|
||||
#endif // _IKsPropertySet_
|
||||
|
||||
//
|
||||
// Return Codes
|
||||
//
|
||||
|
||||
#define DS_OK 0
|
||||
|
||||
// The call failed because resources (such as a priority level)
|
||||
// were already being used by another caller.
|
||||
#define DSERR_ALLOCATED MAKE_DSHRESULT(10)
|
||||
|
||||
// The control (vol,pan,etc.) requested by the caller is not available.
|
||||
#define DSERR_CONTROLUNAVAIL MAKE_DSHRESULT(30)
|
||||
|
||||
// An invalid parameter was passed to the returning function
|
||||
#define DSERR_INVALIDPARAM E_INVALIDARG
|
||||
|
||||
// This call is not valid for the current state of this object
|
||||
#define DSERR_INVALIDCALL MAKE_DSHRESULT(50)
|
||||
|
||||
// An undetermined error occured inside the DirectSound subsystem
|
||||
#define DSERR_GENERIC E_FAIL
|
||||
|
||||
// The caller does not have the priority level required for the function to
|
||||
// succeed.
|
||||
#define DSERR_PRIOLEVELNEEDED MAKE_DSHRESULT(70)
|
||||
|
||||
// Not enough free memory is available to complete the operation
|
||||
#define DSERR_OUTOFMEMORY E_OUTOFMEMORY
|
||||
|
||||
// The specified WAVE format is not supported
|
||||
#define DSERR_BADFORMAT MAKE_DSHRESULT(100)
|
||||
|
||||
// The function called is not supported at this time
|
||||
#define DSERR_UNSUPPORTED E_NOTIMPL
|
||||
|
||||
// No sound driver is available for use
|
||||
#define DSERR_NODRIVER MAKE_DSHRESULT(120)
|
||||
|
||||
// This object is already initialized
|
||||
#define DSERR_ALREADYINITIALIZED MAKE_DSHRESULT(130)
|
||||
|
||||
// This object does not support aggregation
|
||||
#define DSERR_NOAGGREGATION CLASS_E_NOAGGREGATION
|
||||
|
||||
// The buffer memory has been lost, and must be restored.
|
||||
#define DSERR_BUFFERLOST MAKE_DSHRESULT(150)
|
||||
|
||||
// Another app has a higher priority level, preventing this call from
|
||||
// succeeding.
|
||||
#define DSERR_OTHERAPPHASPRIO MAKE_DSHRESULT(160)
|
||||
|
||||
// This object has not been initialized
|
||||
#define DSERR_UNINITIALIZED MAKE_DSHRESULT(170)
|
||||
|
||||
// The requested COM interface is not available
|
||||
#define DSERR_NOINTERFACE E_NOINTERFACE
|
||||
|
||||
//
|
||||
// Flags
|
||||
//
|
||||
|
||||
#define DSCAPS_PRIMARYMONO 0x00000001
|
||||
#define DSCAPS_PRIMARYSTEREO 0x00000002
|
||||
#define DSCAPS_PRIMARY8BIT 0x00000004
|
||||
#define DSCAPS_PRIMARY16BIT 0x00000008
|
||||
#define DSCAPS_CONTINUOUSRATE 0x00000010
|
||||
#define DSCAPS_EMULDRIVER 0x00000020
|
||||
#define DSCAPS_CERTIFIED 0x00000040
|
||||
#define DSCAPS_SECONDARYMONO 0x00000100
|
||||
#define DSCAPS_SECONDARYSTEREO 0x00000200
|
||||
#define DSCAPS_SECONDARY8BIT 0x00000400
|
||||
#define DSCAPS_SECONDARY16BIT 0x00000800
|
||||
|
||||
#define DSBPLAY_LOOPING 0x00000001
|
||||
|
||||
#define DSBSTATUS_PLAYING 0x00000001
|
||||
#define DSBSTATUS_BUFFERLOST 0x00000002
|
||||
#define DSBSTATUS_LOOPING 0x00000004
|
||||
|
||||
#define DSBLOCK_FROMWRITECURSOR 0x00000001
|
||||
#define DSBLOCK_ENTIREBUFFER 0x00000002
|
||||
|
||||
#define DSSCL_NORMAL 0x00000001
|
||||
#define DSSCL_PRIORITY 0x00000002
|
||||
#define DSSCL_EXCLUSIVE 0x00000003
|
||||
#define DSSCL_WRITEPRIMARY 0x00000004
|
||||
|
||||
#define DS3DMODE_NORMAL 0x00000000
|
||||
#define DS3DMODE_HEADRELATIVE 0x00000001
|
||||
#define DS3DMODE_DISABLE 0x00000002
|
||||
|
||||
#define DS3D_IMMEDIATE 0x00000000
|
||||
#define DS3D_DEFERRED 0x00000001
|
||||
|
||||
#define DS3D_MINDISTANCEFACTOR 0.0f
|
||||
#define DS3D_MAXDISTANCEFACTOR 10.0f
|
||||
#define DS3D_DEFAULTDISTANCEFACTOR 1.0f
|
||||
|
||||
#define DS3D_MINROLLOFFFACTOR 0.0f
|
||||
#define DS3D_MAXROLLOFFFACTOR 10.0f
|
||||
#define DS3D_DEFAULTROLLOFFFACTOR 1.0f
|
||||
|
||||
#define DS3D_MINDOPPLERFACTOR 0.0f
|
||||
#define DS3D_MAXDOPPLERFACTOR 10.0f
|
||||
#define DS3D_DEFAULTDOPPLERFACTOR 1.0f
|
||||
|
||||
#define DS3D_DEFAULTMINDISTANCE 1.0f
|
||||
#define DS3D_DEFAULTMAXDISTANCE 1000000000.0f
|
||||
|
||||
#define DS3D_MINCONEANGLE 0
|
||||
#define DS3D_MAXCONEANGLE 360
|
||||
#define DS3D_DEFAULTCONEANGLE 360
|
||||
|
||||
#define DS3D_DEFAULTCONEOUTSIDEVOLUME 0
|
||||
|
||||
#define DSBCAPS_PRIMARYBUFFER 0x00000001
|
||||
#define DSBCAPS_STATIC 0x00000002
|
||||
#define DSBCAPS_LOCHARDWARE 0x00000004
|
||||
#define DSBCAPS_LOCSOFTWARE 0x00000008
|
||||
#define DSBCAPS_CTRL3D 0x00000010
|
||||
#define DSBCAPS_CTRLFREQUENCY 0x00000020
|
||||
#define DSBCAPS_CTRLPAN 0x00000040
|
||||
#define DSBCAPS_CTRLVOLUME 0x00000080
|
||||
#define DSBCAPS_CTRLPOSITIONNOTIFY 0x00000100
|
||||
#define DSBCAPS_CTRLDEFAULT 0x000000E0
|
||||
#define DSBCAPS_CTRLALL 0x000001F0
|
||||
#define DSBCAPS_STICKYFOCUS 0x00004000
|
||||
#define DSBCAPS_GLOBALFOCUS 0x00008000
|
||||
#define DSBCAPS_GETCURRENTPOSITION2 0x00010000
|
||||
#define DSBCAPS_MUTE3DATMAXDISTANCE 0x00020000
|
||||
|
||||
#define DSCBCAPS_WAVEMAPPED 0x80000000
|
||||
|
||||
#define DSSPEAKER_HEADPHONE 0x00000001
|
||||
#define DSSPEAKER_MONO 0x00000002
|
||||
#define DSSPEAKER_QUAD 0x00000003
|
||||
#define DSSPEAKER_STEREO 0x00000004
|
||||
#define DSSPEAKER_SURROUND 0x00000005
|
||||
|
||||
#define DSSPEAKER_GEOMETRY_MIN 0x00000005 // 5 degrees
|
||||
#define DSSPEAKER_GEOMETRY_NARROW 0x0000000A // 10 degrees
|
||||
#define DSSPEAKER_GEOMETRY_WIDE 0x00000014 // 20 degrees
|
||||
#define DSSPEAKER_GEOMETRY_MAX 0x000000B4 // 180 degrees
|
||||
|
||||
#define DSSPEAKER_COMBINED(c, g) ((DWORD)(((BYTE)(c)) | ((DWORD)((BYTE)(g))) << 16))
|
||||
#define DSSPEAKER_CONFIG(a) ((BYTE)(a))
|
||||
#define DSSPEAKER_GEOMETRY(a) ((BYTE)(((DWORD)(a) >> 16) & 0x00FF))
|
||||
|
||||
#define DSCCAPS_EMULDRIVER 0x00000020
|
||||
|
||||
#define DSCBLOCK_ENTIREBUFFER 0x00000001
|
||||
|
||||
#define DSCBSTATUS_CAPTURING 0x00000001
|
||||
#define DSCBSTATUS_LOOPING 0x00000002
|
||||
|
||||
#define DSCBSTART_LOOPING 0x00000001
|
||||
|
||||
#define DSBFREQUENCY_MIN 100
|
||||
#define DSBFREQUENCY_MAX 100000
|
||||
#define DSBFREQUENCY_ORIGINAL 0
|
||||
|
||||
#define DSBPAN_LEFT -10000
|
||||
#define DSBPAN_CENTER 0
|
||||
#define DSBPAN_RIGHT 10000
|
||||
|
||||
#define DSBVOLUME_MIN -10000
|
||||
#define DSBVOLUME_MAX 0
|
||||
|
||||
#define DSBSIZE_MIN 4
|
||||
#define DSBSIZE_MAX 0x0FFFFFFF
|
||||
|
||||
#define DSBPN_OFFSETSTOP 0xFFFFFFFF
|
||||
|
||||
#ifdef __cplusplus
|
||||
};
|
||||
#endif // __cplusplus
|
||||
|
||||
#endif // __DSOUND_INCLUDED__
|
831
3rdparty/dx5/inc/dvp.h
vendored
Normal file
831
3rdparty/dx5/inc/dvp.h
vendored
Normal file
|
@ -0,0 +1,831 @@
|
|||
/*==========================================================================;
|
||||
*
|
||||
* Copyright (C) 1996-1997 Microsoft Corporation. All Rights Reserved.
|
||||
*
|
||||
* File: dvp.h
|
||||
* Content: DirectDrawVideoPort include file
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef __DVP_INCLUDED__
|
||||
#define __DVP_INCLUDED__
|
||||
#if defined( _WIN32 ) && !defined( _NO_COM )
|
||||
#define COM_NO_WINDOWS_H
|
||||
#include <objbase.h>
|
||||
#else
|
||||
#define IUnknown void
|
||||
#undef CO_E_NOTINITIALIZED
|
||||
#define CO_E_NOTINITIALIZED 0x800401F0L
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
* GUIDS used by DirectDrawVideoPort objects
|
||||
*/
|
||||
#if defined( _WIN32 ) && !defined( _NO_COM )
|
||||
DEFINE_GUID( IID_IDDVideoPortContainer, 0x6C142760,0xA733,0x11CE,0xA5,0x21,0x00,0x20,0xAF,0x0B,0xE5,0x60 );
|
||||
DEFINE_GUID( IID_IDirectDrawVideoPort, 0xB36D93E0,0x2B43,0x11CF,0xA2,0xDE,0x00,0xAA,0x00,0xB9,0x33,0x56 );
|
||||
|
||||
DEFINE_GUID( DDVPTYPE_E_HREFH_VREFH, 0x54F39980L,0xDA60,0x11CF,0x9B,0x06,0x00,0xA0,0xC9,0x03,0xA3,0xB8);
|
||||
DEFINE_GUID( DDVPTYPE_E_HREFH_VREFL, 0x92783220L,0xDA60,0x11CF,0x9B,0x06,0x00,0xA0,0xC9,0x03,0xA3,0xB8);
|
||||
DEFINE_GUID( DDVPTYPE_E_HREFL_VREFH, 0xA07A02E0L,0xDA60,0x11CF,0x9B,0x06,0x00,0xA0,0xC9,0x03,0xA3,0xB8);
|
||||
DEFINE_GUID( DDVPTYPE_E_HREFL_VREFL, 0xE09C77E0L,0xDA60,0x11CF,0x9B,0x06,0x00,0xA0,0xC9,0x03,0xA3,0xB8);
|
||||
DEFINE_GUID( DDVPTYPE_CCIR656, 0xFCA326A0L,0xDA60,0x11CF,0x9B,0x06,0x00,0xA0,0xC9,0x03,0xA3,0xB8);
|
||||
DEFINE_GUID( DDVPTYPE_BROOKTREE, 0x1352A560L,0xDA61,0x11CF,0x9B,0x06,0x00,0xA0,0xC9,0x03,0xA3,0xB8);
|
||||
DEFINE_GUID( DDVPTYPE_PHILIPS, 0x332CF160L,0xDA61,0x11CF,0x9B,0x06,0x00,0xA0,0xC9,0x03,0xA3,0xB8);
|
||||
|
||||
/*
|
||||
* GUIDS used to describe connections
|
||||
*/
|
||||
|
||||
#endif
|
||||
|
||||
/*============================================================================
|
||||
*
|
||||
* DirectDraw Structures
|
||||
*
|
||||
* Various structures used to invoke DirectDraw.
|
||||
*
|
||||
*==========================================================================*/
|
||||
|
||||
struct IDirectDraw;
|
||||
struct IDirectDrawSurface;
|
||||
struct IDirectDrawPalette;
|
||||
struct IDirectDrawClipper;
|
||||
|
||||
typedef struct IDDVideoPortContainer FAR *LPDDVIDEOPORTCONTAINER;
|
||||
typedef struct IDirectDrawVideoPort FAR *LPDIRECTDRAWVIDEOPORT;
|
||||
|
||||
typedef struct _DDVIDEOPORTCONNECT FAR *LPDDVIDEOPORTCONNECT;
|
||||
typedef struct _DDVIDEOPORTCAPS FAR *LPDDVIDEOPORTCAPS;
|
||||
typedef struct _DDVIDEOPORTDESC FAR *LPDDVIDEOPORTDESC;
|
||||
typedef struct _DDVIDEOPORTINFO FAR *LPDDVIDEOPORTINFO;
|
||||
typedef struct _DDVIDEOPORTBANDWIDTH FAR *LPDDVIDEOPORTBANDWIDTH;
|
||||
typedef struct _DDVIDEOPORTSTATUS FAR *LPDDVIDEOPORTSTATUS;
|
||||
|
||||
typedef struct IDDVideoPortContainerVtbl DDVIDEOPORTCONTAINERCALLBACKS;
|
||||
typedef struct IDirectDrawVideoPortVtbl DIRECTDRAWVIDEOPORTCALLBACKS;
|
||||
|
||||
|
||||
/*
|
||||
* API's
|
||||
*/
|
||||
typedef HRESULT (FAR PASCAL * LPDDENUMVIDEOCALLBACK)(LPDDVIDEOPORTCAPS, LPVOID);
|
||||
|
||||
|
||||
/*
|
||||
* INTERACES FOLLOW:
|
||||
* IDirectDrawVideoPort
|
||||
* IVideoPort
|
||||
*/
|
||||
|
||||
/*
|
||||
* IDirectDrawVideoPortContainer
|
||||
*/
|
||||
#if defined( _WIN32 ) && !defined( _NO_COM )
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDDVideoPortContainer
|
||||
DECLARE_INTERFACE_( IDDVideoPortContainer, IUnknown )
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
/*** IDirectDrawVideoPort methods ***/
|
||||
STDMETHOD(CreateVideoPort)(THIS_ DWORD, LPDDVIDEOPORTDESC, LPDIRECTDRAWVIDEOPORT FAR *, IUnknown FAR *) PURE;
|
||||
STDMETHOD(EnumVideoPorts)(THIS_ DWORD, LPDDVIDEOPORTCAPS, LPVOID,LPDDENUMVIDEOCALLBACK ) PURE;
|
||||
STDMETHOD(GetVideoPortConnectInfo)(THIS_ DWORD, LPDWORD, LPDDVIDEOPORTCONNECT ) PURE;
|
||||
STDMETHOD(QueryVideoPortStatus)(THIS_ DWORD, LPDDVIDEOPORTSTATUS ) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IVideoPortContainer_QueryInterface(p, a, b) (p)->lpVtbl->QueryInterface(p, a, b)
|
||||
#define IVideoPortContainer_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IVideoPortContainer_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IVideoPortContainer_CreateVideoPort(p, a, b, c, d) (p)->lpVtbl->CreateVideoPort(p, a, b, c, d)
|
||||
#define IVideoPortContainer_EnumVideoPorts(p, a, b, c, d) (p)->lpVtbl->EnumVideoPorts(p, a, b, c, d)
|
||||
#define IVideoPortContainer_GetVideoPortConnectInfo(p, a, b, c) (p)->lpVtbl->GetVideoPortConnectInfo(p, a, b, c)
|
||||
#define IVideoPortContainer_QueryVideoPortStatus(p, a, b) (p)->lpVtbl->QueryVideoPortStatus(p, a, b)
|
||||
#else
|
||||
#define IVideoPortContainer_QueryInterface(p, a, b) (p)->QueryInterface(a, b)
|
||||
#define IVideoPortContainer_AddRef(p) (p)->AddRef()
|
||||
#define IVideoPortContainer_Release(p) (p)->Release()
|
||||
#define IVideoPortContainer_CreateVideoPort(p, a, b, c, d) (p)->CreateVideoPort(a, b, c, d)
|
||||
#define IVideoPortContainer_EnumVideoPorts(p, a, b, c, d) (p)->EnumVideoPorts(a, b, c, d)
|
||||
#define IVideoPortContainer_GetVideoPortConnectInfo(p, a, b, c) (p)->GetVideoPortConnectInfo(a, b, c)
|
||||
#define IVideoPortContainer_QueryVideoPortStatus(p, a, b) (p)->QueryVideoPortStatus(a, b)
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
* IDirectDrawVideoPort
|
||||
*/
|
||||
#if defined( _WIN32 ) && !defined( _NO_COM )
|
||||
#undef INTERFACE
|
||||
#define INTERFACE IDirectDrawVideoPort
|
||||
DECLARE_INTERFACE_( IDirectDrawVideoPort, IUnknown )
|
||||
{
|
||||
/*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID FAR * ppvObj) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
/*** IVideoPort methods ***/
|
||||
STDMETHOD(Flip)(THIS_ LPDIRECTDRAWSURFACE, DWORD) PURE;
|
||||
STDMETHOD(GetBandwidthInfo)(THIS_ LPDDPIXELFORMAT, DWORD, DWORD, DWORD, LPDDVIDEOPORTBANDWIDTH) PURE;
|
||||
STDMETHOD(GetColorControls)(THIS_ LPDDCOLORCONTROL) PURE;
|
||||
STDMETHOD(GetInputFormats)(THIS_ LPDWORD, LPDDPIXELFORMAT, DWORD) PURE;
|
||||
STDMETHOD(GetOutputFormats)(THIS_ LPDDPIXELFORMAT, LPDWORD, LPDDPIXELFORMAT, DWORD) PURE;
|
||||
STDMETHOD(GetFieldPolarity)(THIS_ LPBOOL) PURE;
|
||||
STDMETHOD(GetVideoLine)(THIS_ LPDWORD) PURE;
|
||||
STDMETHOD(GetVideoSignalStatus)(THIS_ LPDWORD) PURE;
|
||||
STDMETHOD(SetColorControls)(THIS_ LPDDCOLORCONTROL) PURE;
|
||||
STDMETHOD(SetTargetSurface)(THIS_ LPDIRECTDRAWSURFACE, DWORD) PURE;
|
||||
STDMETHOD(StartVideo)(THIS_ LPDDVIDEOPORTINFO) PURE;
|
||||
STDMETHOD(StopVideo)(THIS) PURE;
|
||||
STDMETHOD(UpdateVideo)(THIS_ LPDDVIDEOPORTINFO) PURE;
|
||||
STDMETHOD(WaitForSync)(THIS_ DWORD, DWORD, DWORD) PURE;
|
||||
};
|
||||
|
||||
#if !defined(__cplusplus) || defined(CINTERFACE)
|
||||
#define IVideoPort_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
|
||||
#define IVideoPort_AddRef(p) (p)->lpVtbl->AddRef(p)
|
||||
#define IVideoPort_Release(p) (p)->lpVtbl->Release(p)
|
||||
#define IVideoPort_SetTargetSurface(p,a,b) (p)->lpVtbl->SetTargetSurface(p,a,b)
|
||||
#define IVideoPort_Flip(p,a,b) (p)->lpVtbl->Flip(p,a,b)
|
||||
#define IVideoPort_GetBandwidthInfo(p,a,b,c,d,e) (p)->lpVtbl->GetBandwidthInfo(p,a,b,c,d,e)
|
||||
#define IVideoPort_GetColorControls(p,a) (p)->lpVtbl->GetColorControls(p,a)
|
||||
#define IVideoPort_GetInputFormats(p,a,b,c) (p)->lpVtbl->GetInputFormats(p,a,b,c)
|
||||
#define IVideoPort_GetOutputFormats(p,a,b,c,d) (p)->lpVtbl->GetOutputFormats(p,a,b,c,d)
|
||||
#define IVideoPort_GetFieldPolarity(p,a) (p)->lpVtbl->GetFieldPolarity(p,a)
|
||||
#define IVideoPort_GetVideoLine(p,a) (p)->lpVtbl->GetVideoLine(p,a)
|
||||
#define IVideoPort_GetVideoSignalStatus(p,a) (p)->lpVtbl->GetVideoSignalStatus(p,a)
|
||||
#define IVideoPort_SetColorControls(p,a) (p)->lpVtbl->SetColorControls(p,a)
|
||||
#define IVideoPort_StartVideo(p,a) (p)->lpVtbl->StartVideo(p,a)
|
||||
#define IVideoPort_StopVideo(p) (p)->lpVtbl->StopVideo(p)
|
||||
#define IVideoPort_UpdateVideo(p,a) (p)->lpVtbl->UpdateVideo(p,a)
|
||||
#define IVideoPort_WaitForSync(p,a,b,c) (p)->lpVtbl->WaitForSync(p,a,b,c)
|
||||
#else
|
||||
#define IVideoPort_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
|
||||
#define IVideoPort_AddRef(p) (p)->AddRef()
|
||||
#define IVideoPort_Release(p) (p)->Release()
|
||||
#define IVideoPort_SetTargetSurface(p,a,b) (p)->SetTargetSurface(a,b)
|
||||
#define IVideoPort_Flip(p,a,b) (p)->Flip(a,b)
|
||||
#define IVideoPort_GetBandwidthInfo(p,a,b,c,d,e) (p)->GetBandwidthInfo(a,b,c,d,e)
|
||||
#define IVideoPort_GetColorControls(p,a) (p)->GetColorControls(a)
|
||||
#define IVideoPort_GetInputFormats(p,a,b,c) (p)->GetInputFormats(a,b,c)
|
||||
#define IVideoPort_GetOutputFormats(p,a,b,c,d) (p)->GetOutputFormats(a,b,c,d)
|
||||
#define IVideoPort_GetFieldPolarity(p,a) (p)->GetFieldPolarity(a)
|
||||
#define IVideoPort_GetVideoLine(p,a) (p)->GetVideoLine(a)
|
||||
#define IVideoPort_GetVideoSignalStatus(p,a) (p)->GetVideoSignalStatus(a)
|
||||
#define IVideoPort_SetColorControls(p,a) (p)->SetColorControls(a)
|
||||
#define IVideoPort_StartVideo(p,a) (p)->StartVideo(a)
|
||||
#define IVideoPort_StopVideo(p) (p)->StopVideo()
|
||||
#define IVideoPort_UpdateVideo(p,a) (p)->UpdateVideo(a)
|
||||
#define IVideoPort_WaitForSync(p,a,b,c) (p)->WaitForSync(a,b,c)
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
* DDVIDEOPORTCONNECT
|
||||
*/
|
||||
typedef struct _DDVIDEOPORTCONNECT
|
||||
{
|
||||
DWORD dwSize; // size of the DDVIDEOPORTCONNECT structure
|
||||
DWORD dwPortWidth; // Width of the video port
|
||||
GUID guidTypeID; // Description of video port connection
|
||||
DWORD dwFlags; // Connection flags
|
||||
DWORD dwReserved1; // Reserved, set to zero.
|
||||
} DDVIDEOPORTCONNECT;
|
||||
|
||||
|
||||
/*
|
||||
* DDVIDEOPORTCAPS
|
||||
*/
|
||||
typedef struct _DDVIDEOPORTCAPS
|
||||
{
|
||||
DWORD dwSize; // size of the DDVIDEOPORTCAPS structure
|
||||
DWORD dwFlags; // indicates which fields contain data
|
||||
DWORD dwMaxWidth; // max width of the video port field
|
||||
DWORD dwMaxVBIWidth; // max width of the VBI data
|
||||
DWORD dwMaxHeight; // max height of the video port field
|
||||
DWORD dwVideoPortID; // Video port ID (0 - (dwMaxVideoPorts -1))
|
||||
DWORD dwCaps; // Video port capabilities
|
||||
DWORD dwFX; // More video port capabilities
|
||||
DWORD dwNumAutoFlipSurfaces; // Number of autoflippable surfaces
|
||||
DWORD dwAlignVideoPortBoundary; // Byte restriction of placement within the surface
|
||||
DWORD dwAlignVideoPortPrescaleWidth;// Byte restriction of width after prescaling
|
||||
DWORD dwAlignVideoPortCropBoundary; // Byte restriction of left cropping
|
||||
DWORD dwAlignVideoPortCropWidth; // Byte restriction of cropping width
|
||||
DWORD dwPreshrinkXStep; // Width can be shrunk in steps of 1/x
|
||||
DWORD dwPreshrinkYStep; // Height can be shrunk in steps of 1/x
|
||||
DWORD dwNumVBIAutoFlipSurfaces; // Number of VBI autoflippable surfaces
|
||||
DWORD dwReserved1; // Reserved for future use
|
||||
DWORD dwReserved2; // Reserved for future use
|
||||
} DDVIDEOPORTCAPS;
|
||||
|
||||
/*
|
||||
* The dwMaxWidth and dwMaxVBIWidth members are valid
|
||||
*/
|
||||
#define DDVPD_WIDTH 0x00000001l
|
||||
|
||||
/*
|
||||
* The dwMaxHeight member is valid
|
||||
*/
|
||||
#define DDVPD_HEIGHT 0x00000002l
|
||||
|
||||
/*
|
||||
* The dwVideoPortID member is valid
|
||||
*/
|
||||
#define DDVPD_ID 0x00000004l
|
||||
|
||||
/*
|
||||
* The dwCaps member is valid
|
||||
*/
|
||||
#define DDVPD_CAPS 0x00000008l
|
||||
|
||||
/*
|
||||
* The dwFX member is valid
|
||||
*/
|
||||
#define DDVPD_FX 0x00000010l
|
||||
|
||||
/*
|
||||
* The dwNumAutoFlipSurfaces member is valid
|
||||
*/
|
||||
#define DDVPD_AUTOFLIP 0x00000020l
|
||||
|
||||
/*
|
||||
* All of the alignment members are valid
|
||||
*/
|
||||
#define DDVPD_ALIGN 0x00000040l
|
||||
|
||||
|
||||
/*
|
||||
* DDVIDEOPORTDESC
|
||||
*/
|
||||
typedef struct _DDVIDEOPORTDESC
|
||||
{
|
||||
DWORD dwSize; // size of the DDVIDEOPORTDESC structure
|
||||
DWORD dwFieldWidth; // width of the video port field
|
||||
DWORD dwVBIWidth; // width of the VBI data
|
||||
DWORD dwFieldHeight; // height of the video port field
|
||||
DWORD dwMicrosecondsPerField; // Microseconds per video field
|
||||
DWORD dwMaxPixelsPerSecond; // Maximum pixel rate per second
|
||||
DWORD dwVideoPortID; // Video port ID (0 - (dwMaxVideoPorts -1))
|
||||
DWORD dwReserved1; // Reserved for future use - set to zero
|
||||
DDVIDEOPORTCONNECT VideoPortType; // Description of video port connection
|
||||
DWORD dwReserved2; // Reserved for future use - set to zero
|
||||
DWORD dwReserved3; // Reserved for future use - set to zero
|
||||
} DDVIDEOPORTDESC;
|
||||
|
||||
|
||||
/*
|
||||
* DDVIDEOPORTINFO
|
||||
*/
|
||||
typedef struct _DDVIDEOPORTINFO
|
||||
{
|
||||
DWORD dwSize; // Size of the structure
|
||||
DWORD dwOriginX; // Placement of the video data within the surface.
|
||||
DWORD dwOriginY; // Placement of the video data within the surface.
|
||||
DWORD dwVPFlags; // Video port options
|
||||
RECT rCrop; // Cropping rectangle (optional).
|
||||
DWORD dwPrescaleWidth; // Determines pre-scaling/zooming in the X direction (optional).
|
||||
DWORD dwPrescaleHeight; // Determines pre-scaling/zooming in the Y direction (optional).
|
||||
LPDDPIXELFORMAT lpddpfInputFormat; // Video format written to the video port
|
||||
LPDDPIXELFORMAT lpddpfVBIInputFormat; // Input format of the VBI data
|
||||
LPDDPIXELFORMAT lpddpfVBIOutputFormat;// Output format of the data
|
||||
DWORD dwVBIHeight; // Specifies the number of lines of data within the vertical blanking interval.
|
||||
DWORD dwReserved1; // Reserved for future use - set to zero
|
||||
DWORD dwReserved2; // Reserved for future use - set to zero
|
||||
} DDVIDEOPORTINFO;
|
||||
|
||||
|
||||
/*
|
||||
* DDVIDEOPORTBANDWIDTH
|
||||
*/
|
||||
typedef struct _DDVIDEOPORTBANDWIDTH
|
||||
{
|
||||
DWORD dwSize; // Size of the structure
|
||||
DWORD dwCaps;
|
||||
DWORD dwOverlay; // Zoom factor at which overlay is supported
|
||||
DWORD dwColorkey; // Zoom factor at which overlay w/ colorkey is supported
|
||||
DWORD dwYInterpolate; // Zoom factor at which overlay w/ Y interpolation is supported
|
||||
DWORD dwYInterpAndColorkey; // Zoom factor at which ovelray w/ Y interpolation and colorkeying is supported
|
||||
DWORD dwReserved1; // Reserved for future use - set to zero
|
||||
DWORD dwReserved2; // Reserved for future use - set to zero
|
||||
} DDVIDEOPORTBANDWIDTH;
|
||||
|
||||
|
||||
/*
|
||||
* DDVIDEOPORTSTATUS
|
||||
*/
|
||||
typedef struct _DDVIDEOPORTSTATUS
|
||||
{
|
||||
DWORD dwSize; // Size of the structure
|
||||
BOOL bInUse; // TRUE if video port is currently being used
|
||||
DWORD dwFlags; // Currently not used
|
||||
DWORD dwReserved1; // Reserved for future use
|
||||
DDVIDEOPORTCONNECT VideoPortType; // Information about the connection
|
||||
DWORD dwReserved2; // Reserved for future use
|
||||
DWORD dwReserved3; // Reserved for future use
|
||||
} DDVIDEOPORTSTATUS;
|
||||
|
||||
/*============================================================================
|
||||
*
|
||||
* Video Port Flags
|
||||
*
|
||||
* All flags are bit flags.
|
||||
*
|
||||
*==========================================================================*/
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* VIDEOPORT DDVIDEOPORTCONNECT FLAGS
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* When this is set by the driver and passed to the client, this
|
||||
* indicates that the video port is capable of double clocking the data.
|
||||
* When this is set by the client, this indicates that the video port
|
||||
* should enable double clocking. This flag is only valid with external
|
||||
* syncs.
|
||||
*/
|
||||
#define DDVPCONNECT_DOUBLECLOCK 0x00000001l
|
||||
|
||||
/*
|
||||
* When this is set by the driver and passed to the client, this
|
||||
* indicates that the video port is capable of using an external VACT
|
||||
* signal. When this is set by the client, this indicates that the
|
||||
* video port should use the external VACT signal.
|
||||
*/
|
||||
#define DDVPCONNECT_VACT 0x00000002l
|
||||
|
||||
/*
|
||||
* When this is set by the driver and passed to the client, this
|
||||
* indicates that the video port is capable of treating even fields
|
||||
* like odd fields and visa versa. When this is set by the client,
|
||||
* this indicates that the video port should treat even fields like odd
|
||||
* fields.
|
||||
*/
|
||||
#define DDVPCONNECT_INVERTPOLARITY 0x00000004l
|
||||
|
||||
/*
|
||||
* Indicates that any data written to the video port during the VREF
|
||||
* period will not be written into the frame buffer. This flag is read only.
|
||||
*/
|
||||
#define DDVPCONNECT_DISCARDSVREFDATA 0x00000008l
|
||||
|
||||
/*
|
||||
* Device will write half lines into the frame buffer, sometimes causing
|
||||
* the data to not be displayed correctly.
|
||||
*/
|
||||
#define DDVPCONNECT_HALFLINE 0x00000010l
|
||||
|
||||
/*
|
||||
* Indicates that the signal is interlaced. This flag is only
|
||||
* set by the client.
|
||||
*/
|
||||
#define DDVPCONNECT_INTERLACED 0x00000020l
|
||||
|
||||
/*
|
||||
* Indicates that video port is shareable and that this video port
|
||||
* will use the even fields. This flag is only set by the client.
|
||||
*/
|
||||
#define DDVPCONNECT_SHAREEVEN 0x00000040l
|
||||
|
||||
/*
|
||||
* Indicates that video port is shareable and that this video port
|
||||
* will use the odd fields. This flag is only set by the client.
|
||||
*/
|
||||
#define DDVPCONNECT_SHAREODD 0x00000080l
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* VIDEOPORT DDVIDEOPORTDESC CAPS
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* Flip can be performed automatically to avoid tearing.
|
||||
*/
|
||||
#define DDVPCAPS_AUTOFLIP 0x00000001l
|
||||
|
||||
/*
|
||||
* Supports interlaced video
|
||||
*/
|
||||
#define DDVPCAPS_INTERLACED 0x00000002l
|
||||
|
||||
/*
|
||||
* Supports non-interlaced video
|
||||
*/
|
||||
#define DDVPCAPS_NONINTERLACED 0x00000004l
|
||||
|
||||
/*
|
||||
* Indicates that the device can return whether the current field
|
||||
* of an interlaced signal is even or odd.
|
||||
*/
|
||||
#define DDVPCAPS_READBACKFIELD 0x00000008l
|
||||
|
||||
/*
|
||||
* Indicates that the device can return the current line of video
|
||||
* being written into the frame buffer.
|
||||
*/
|
||||
#define DDVPCAPS_READBACKLINE 0x00000010l
|
||||
|
||||
/*
|
||||
* Allows two gen-locked video streams to share a single video port,
|
||||
* where one stream uses the even fields and the other uses the odd
|
||||
* fields. Separate parameters (including address, scaling,
|
||||
* cropping, etc.) are maintained for both fields.)
|
||||
*/
|
||||
#define DDVPCAPS_SHAREABLE 0x00000020l
|
||||
|
||||
/*
|
||||
* Even fields of video can be automatically discarded.
|
||||
*/
|
||||
#define DDVPCAPS_SKIPEVENFIELDS 0x00000040l
|
||||
|
||||
/*
|
||||
* Odd fields of video can be automatically discarded.
|
||||
*/
|
||||
#define DDVPCAPS_SKIPODDFIELDS 0x00000080l
|
||||
|
||||
/*
|
||||
* Indicates that the device is capable of driving the graphics
|
||||
* VSYNC with the video port VSYNC.
|
||||
*/
|
||||
#define DDVPCAPS_SYNCMASTER 0x00000100l
|
||||
|
||||
/*
|
||||
* Indicates that data within the vertical blanking interval can
|
||||
* be written to a different surface.
|
||||
*/
|
||||
#define DDVPCAPS_VBISURFACE 0x00000200l
|
||||
|
||||
/*
|
||||
* Indicates that the video port can perform color operations
|
||||
* on the incoming data before it is written to the frame buffer.
|
||||
*/
|
||||
#define DDVPCAPS_COLORCONTROL 0x00000400l
|
||||
|
||||
/*
|
||||
* Indicates that the video port can accept VBI data in a different
|
||||
* width or format than the regular video data.
|
||||
*/
|
||||
#define DDVPCAPS_OVERSAMPLEDVBI 0x00000800l
|
||||
|
||||
/*
|
||||
* Indicates that the video port can write data directly to system memory
|
||||
*/
|
||||
#define DDVPCAPS_SYSTEMMEMORY 0x00001000l
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* VIDEOPORT DDVIDEOPORTDESC FX
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* Limited cropping is available to crop out the vertical interval data.
|
||||
*/
|
||||
#define DDVPFX_CROPTOPDATA 0x00000001l
|
||||
|
||||
/*
|
||||
* Incoming data can be cropped in the X direction before it is written
|
||||
* to the surface.
|
||||
*/
|
||||
#define DDVPFX_CROPX 0x00000002l
|
||||
|
||||
/*
|
||||
* Incoming data can be cropped in the Y direction before it is written
|
||||
* to the surface.
|
||||
*/
|
||||
#define DDVPFX_CROPY 0x00000004l
|
||||
|
||||
/*
|
||||
* Supports interleaving interlaced fields in memory.
|
||||
*/
|
||||
#define DDVPFX_INTERLEAVE 0x00000008l
|
||||
|
||||
/*
|
||||
* Supports mirroring left to right as the video data is written
|
||||
* into the frame buffer.
|
||||
*/
|
||||
#define DDVPFX_MIRRORLEFTRIGHT 0x00000010l
|
||||
|
||||
/*
|
||||
* Supports mirroring top to bottom as the video data is written
|
||||
* into the frame buffer.
|
||||
*/
|
||||
#define DDVPFX_MIRRORUPDOWN 0x00000020l
|
||||
|
||||
/*
|
||||
* Data can be arbitrarily shrunk in the X direction before it
|
||||
* is written to the surface.
|
||||
*/
|
||||
#define DDVPFX_PRESHRINKX 0x00000040l
|
||||
|
||||
/*
|
||||
* Data can be arbitrarily shrunk in the Y direction before it
|
||||
* is written to the surface.
|
||||
*/
|
||||
#define DDVPFX_PRESHRINKY 0x00000080l
|
||||
|
||||
/*
|
||||
* Data can be binary shrunk (1/2, 1/4, 1/8, etc.) in the X
|
||||
* direction before it is written to the surface.
|
||||
*/
|
||||
#define DDVPFX_PRESHRINKXB 0x00000100l
|
||||
|
||||
/*
|
||||
* Data can be binary shrunk (1/2, 1/4, 1/8, etc.) in the Y
|
||||
* direction before it is written to the surface.
|
||||
*/
|
||||
#define DDVPFX_PRESHRINKYB 0x00000200l
|
||||
|
||||
/*
|
||||
* Data can be shrunk in increments of 1/x in the X direction
|
||||
* (where X is specified in the DDVIDEOPORTCAPS.dwPreshrinkXStep)
|
||||
* before it is written to the surface.
|
||||
*/
|
||||
#define DDVPFX_PRESHRINKXS 0x00000400l
|
||||
|
||||
/*
|
||||
* Data can be shrunk in increments of 1/x in the Y direction
|
||||
* (where X is specified in the DDVIDEOPORTCAPS.dwPreshrinkYStep)
|
||||
* before it is written to the surface.
|
||||
*/
|
||||
#define DDVPFX_PRESHRINKYS 0x00000800l
|
||||
|
||||
/*
|
||||
* Data can be arbitrarily stretched in the X direction before
|
||||
* it is written to the surface.
|
||||
*/
|
||||
#define DDVPFX_PRESTRETCHX 0x00001000l
|
||||
|
||||
/*
|
||||
* Data can be arbitrarily stretched in the Y direction before
|
||||
* it is written to the surface.
|
||||
*/
|
||||
#define DDVPFX_PRESTRETCHY 0x00002000l
|
||||
|
||||
/*
|
||||
* Data can be integer stretched in the X direction before it is
|
||||
* written to the surface.
|
||||
*/
|
||||
#define DDVPFX_PRESTRETCHXN 0x00004000l
|
||||
|
||||
/*
|
||||
* Data can be integer stretched in the Y direction before it is
|
||||
* written to the surface.
|
||||
*/
|
||||
#define DDVPFX_PRESTRETCHYN 0x00008000l
|
||||
|
||||
/*
|
||||
* Indicates that data within the vertical blanking interval can
|
||||
* be converted independently of the remaining video data.
|
||||
*/
|
||||
#define DDVPFX_VBICONVERT 0x00010000l
|
||||
|
||||
/*
|
||||
* Indicates that scaling can be disabled for data within the
|
||||
* vertical blanking interval.
|
||||
*/
|
||||
#define DDVPFX_VBINOSCALE 0x00020000l
|
||||
|
||||
/*
|
||||
* Indicates that the video data can ignore the left and right
|
||||
* cropping coordinates when cropping oversampled VBI data.
|
||||
*/
|
||||
#define DDVPFX_IGNOREVBIXCROP 0x00040000l
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* VIDEOPORT DDVIDEOPORTINFO FLAGS
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* Perform automatic flipping. Auto-flipping is performed between
|
||||
* the overlay surface that was attached to the video port using
|
||||
* IDirectDrawVideoPort::AttachSurface and the overlay surfaces that
|
||||
* are attached to the surface via the IDirectDrawSurface::AttachSurface
|
||||
* method. The flip order is the order in which the overlay surfaces
|
||||
* were. attached.
|
||||
*/
|
||||
#define DDVP_AUTOFLIP 0x00000001l
|
||||
|
||||
/*
|
||||
* Perform conversion using the ddpfOutputFormat information.
|
||||
*/
|
||||
#define DDVP_CONVERT 0x00000002l
|
||||
|
||||
/*
|
||||
* Perform cropping using the specified rectangle.
|
||||
*/
|
||||
#define DDVP_CROP 0x00000004l
|
||||
|
||||
/*
|
||||
* Indicates that interlaced fields should be interleaved in memory.
|
||||
*/
|
||||
#define DDVP_INTERLEAVE 0x00000008l
|
||||
|
||||
/*
|
||||
* Indicates that the data should be mirrored left to right as it's
|
||||
* written into the frame buffer.
|
||||
*/
|
||||
#define DDVP_MIRRORLEFTRIGHT 0x00000010l
|
||||
|
||||
/*
|
||||
* Indicates that the data should be mirrored top to bottom as it's
|
||||
* written into the frame buffer.
|
||||
*/
|
||||
#define DDVP_MIRRORUPDOWN 0x00000020l
|
||||
|
||||
/*
|
||||
* Perform pre-scaling/zooming based on the pre-scale parameters.
|
||||
*/
|
||||
#define DDVP_PRESCALE 0x00000040l
|
||||
|
||||
/*
|
||||
* Ignore input of even fields.
|
||||
*/
|
||||
#define DDVP_SKIPEVENFIELDS 0x00000080l
|
||||
|
||||
/*
|
||||
* Ignore input of odd fields.
|
||||
*/
|
||||
#define DDVP_SKIPODDFIELDS 0x00000100l
|
||||
|
||||
/*
|
||||
* Drive the graphics VSYNCs using the video port VYSNCs.
|
||||
*/
|
||||
#define DDVP_SYNCMASTER 0x00000200l
|
||||
|
||||
/*
|
||||
* The ddpfVBIOutputFormatFormat member contains data that should be used
|
||||
* to convert the data within the vertical blanking interval.
|
||||
*/
|
||||
#define DDVP_VBICONVERT 0x00000400l
|
||||
|
||||
/*
|
||||
* Indicates that data within the vertical blanking interval
|
||||
* should not be scaled.
|
||||
*/
|
||||
#define DDVP_VBINOSCALE 0x00000800l
|
||||
|
||||
/*
|
||||
* Indicates that these bob/weave decisions should not be
|
||||
* overriden by other interfaces.
|
||||
*/
|
||||
#define DDVP_OVERRIDEBOBWEAVE 0x00001000l
|
||||
|
||||
/*
|
||||
* Indicates that the video data should ignore the left and right
|
||||
* cropping coordinates when cropping the VBI data.
|
||||
*/
|
||||
#define DDVP_IGNOREVBIXCROP 0x00002000l
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* DIRIRECTDRAWVIDEOPORT GETINPUTFORMAT/GETOUTPUTFORMAT FLAGS
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* Return formats for the video data
|
||||
*/
|
||||
#define DDVPFORMAT_VIDEO 0x00000001l
|
||||
|
||||
/*
|
||||
* Return formats for the VBI data
|
||||
*/
|
||||
#define DDVPFORMAT_VBI 0x00000002l
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* DIRIRECTDRAWVIDEOPORT SETTARGETSURFACE FLAGS
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* Surface should receive video data (and VBI data if a surface
|
||||
* is not explicitly attached for that purpose)
|
||||
*/
|
||||
#define DDVPTARGET_VIDEO 0x00000001l
|
||||
|
||||
/*
|
||||
* Surface should receive VBI data
|
||||
*/
|
||||
#define DDVPTARGET_VBI 0x00000002l
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* DIRIRECTDRAWVIDEOPORT WAITFORSYNC FLAGS
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* Waits until the beginning of the next VSYNC
|
||||
*/
|
||||
#define DDVPWAIT_BEGIN 0x00000001l
|
||||
|
||||
/*
|
||||
* Waits until the end of the next/current VSYNC
|
||||
*/
|
||||
#define DDVPWAIT_END 0x00000002l
|
||||
|
||||
/*
|
||||
* Waits until the beginning of the specified line
|
||||
*/
|
||||
#define DDVPWAIT_LINE 0x00000003l
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* DIRECTDRAWVIDEOPORT FLIP FLAGS
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* Flips the normal video surface
|
||||
*/
|
||||
#define DDVPFLIP_VIDEO 0x00000001l
|
||||
|
||||
/*
|
||||
* Flips the VBI surface
|
||||
*/
|
||||
#define DDVPFLIP_VBI 0x00000002l
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* DIRIRECTDRAWVIDEOPORT GETVIDEOSIGNALSTATUS VALUES
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* No video signal is present at the video port
|
||||
*/
|
||||
#define DDVPSQ_NOSIGNAL 0x00000001l
|
||||
|
||||
/*
|
||||
* A valid video signal is present at the video port
|
||||
*/
|
||||
#define DDVPSQ_SIGNALOK 0x00000002l
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* VIDEOPORTBANDWIDTH Flags
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* The specified height/width refer to the size of the video port data
|
||||
* written into memory, after prescaling has occured.
|
||||
*/
|
||||
#define DDVPB_VIDEOPORT 0x00000001l
|
||||
|
||||
/*
|
||||
* The specified height/width refer to the source size of the overlay.
|
||||
*/
|
||||
#define DDVPB_OVERLAY 0x00000002l
|
||||
|
||||
/*
|
||||
* This is a query for the device to return which caps this device requires.
|
||||
*/
|
||||
#define DDVPB_TYPE 0x00000004l
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* VIDEOPORTBANDWIDTH Caps
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* The bandwidth for this device is dependant on the overlay source size.
|
||||
*/
|
||||
#define DDVPBCAPS_SOURCE 0x00000001l
|
||||
|
||||
/*
|
||||
* The bandwidth for this device is dependant on the overlay destination
|
||||
* size.
|
||||
*/
|
||||
#define DDVPBCAPS_DESTINATION 0x00000002l
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
};
|
||||
#endif
|
||||
|
||||
#endif
|
24
3rdparty/dx5/inc/fastfile.h
vendored
Normal file
24
3rdparty/dx5/inc/fastfile.h
vendored
Normal file
|
@ -0,0 +1,24 @@
|
|||
/*==========================================================================
|
||||
*
|
||||
* Copyright (C) 1995-1997 Microsoft Corporation. All Rights Reserved.
|
||||
*
|
||||
* File: fastfile.h
|
||||
* Content: Definitions for fastfile access.
|
||||
*
|
||||
* THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND,
|
||||
* EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED
|
||||
* WARRANTIES OF MERCHANTBILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
typedef LPVOID HFASTFILE;
|
||||
|
||||
extern BOOL FastFileInit( LPSTR fname, int max_handles );
|
||||
extern void FastFileFini( void );
|
||||
extern HFASTFILE FastFileOpen( LPSTR name );
|
||||
extern BOOL FastFileClose( HFASTFILE pfe );
|
||||
extern BOOL FastFileRead( HFASTFILE pfh, LPVOID ptr, int size );
|
||||
extern BOOL FastFileSeek( HFASTFILE pfe, int off, int how );
|
||||
extern long FastFileTell( HFASTFILE pfe );
|
||||
extern LPVOID FastFileLock( HFASTFILE pfe, int off, int len );
|
||||
extern BOOL FastFileUnlock( HFASTFILE pfe, int off, int len );
|
BIN
3rdparty/dx5/lib/d3drm.lib
vendored
Normal file
BIN
3rdparty/dx5/lib/d3drm.lib
vendored
Normal file
Binary file not shown.
BIN
3rdparty/dx5/lib/ddraw.lbw
vendored
Normal file
BIN
3rdparty/dx5/lib/ddraw.lbw
vendored
Normal file
Binary file not shown.
BIN
3rdparty/dx5/lib/ddraw.lib
vendored
Normal file
BIN
3rdparty/dx5/lib/ddraw.lib
vendored
Normal file
Binary file not shown.
BIN
3rdparty/dx5/lib/dinput.lib
vendored
Normal file
BIN
3rdparty/dx5/lib/dinput.lib
vendored
Normal file
Binary file not shown.
BIN
3rdparty/dx5/lib/dplayx.lib
vendored
Normal file
BIN
3rdparty/dx5/lib/dplayx.lib
vendored
Normal file
Binary file not shown.
BIN
3rdparty/dx5/lib/dsetup.lib
vendored
Normal file
BIN
3rdparty/dx5/lib/dsetup.lib
vendored
Normal file
Binary file not shown.
BIN
3rdparty/dx5/lib/dsound.lbw
vendored
Normal file
BIN
3rdparty/dx5/lib/dsound.lbw
vendored
Normal file
Binary file not shown.
BIN
3rdparty/dx5/lib/dsound.lib
vendored
Normal file
BIN
3rdparty/dx5/lib/dsound.lib
vendored
Normal file
Binary file not shown.
BIN
3rdparty/dx5/lib/dxguid.lib
vendored
Normal file
BIN
3rdparty/dx5/lib/dxguid.lib
vendored
Normal file
Binary file not shown.
BIN
3rdparty/dx5/lib/fastfile.lbw
vendored
Normal file
BIN
3rdparty/dx5/lib/fastfile.lbw
vendored
Normal file
Binary file not shown.
BIN
3rdparty/dx5/lib/fastfile.lib
vendored
Normal file
BIN
3rdparty/dx5/lib/fastfile.lib
vendored
Normal file
Binary file not shown.
|
@ -4,6 +4,7 @@ project(isle CXX)
|
|||
|
||||
option(ISLE_BUILD_APP "Build ISLE.EXE application" ON)
|
||||
option(ISLE_USE_SMARTHEAP "Build with SmartHeap" ${MSVC})
|
||||
option(ISLE_USE_DX5 "Build with internal DirectX 5 SDK" ON)
|
||||
|
||||
add_library(lego1 SHARED
|
||||
LEGO1/act1state.cpp
|
||||
|
@ -195,6 +196,12 @@ if (ISLE_USE_SMARTHEAP)
|
|||
target_link_libraries(lego1 PRIVATE SmartHeap::SmartHeap)
|
||||
endif()
|
||||
|
||||
# Use internal DirectX 5 if required
|
||||
if (ISLE_USE_DX5)
|
||||
target_include_directories(lego1 PRIVATE "${CMAKE_SOURCE_DIR}/3rdparty/dx5/inc")
|
||||
target_link_directories(lego1 PRIVATE "${CMAKE_SOURCE_DIR}/3rdparty/dx5/lib")
|
||||
endif()
|
||||
|
||||
# Link libraries
|
||||
target_link_libraries(lego1 PRIVATE ddraw dsound winmm)
|
||||
|
||||
|
@ -212,6 +219,12 @@ if (ISLE_BUILD_APP)
|
|||
# Include LEGO1 headers in ISLE
|
||||
target_include_directories(isle PRIVATE "${CMAKE_SOURCE_DIR}/LEGO1")
|
||||
|
||||
# Use internal DirectX 5 if required
|
||||
if (ISLE_USE_DX5)
|
||||
target_include_directories(isle PRIVATE "${CMAKE_SOURCE_DIR}/3rdparty/dx5/inc")
|
||||
target_link_directories(isle PRIVATE "${CMAKE_SOURCE_DIR}/3rdparty/dx5/lib")
|
||||
endif()
|
||||
|
||||
if (ISLE_USE_SMARTHEAP)
|
||||
target_link_libraries(isle PRIVATE SmartHeap::SmartHeap)
|
||||
endif()
|
||||
|
|
|
@ -24,10 +24,9 @@ These instructions will outline how to compile this repository into an accurate
|
|||
You will need the following software installed:
|
||||
|
||||
- Microsoft Visual C++ 4.2. This can be found on many abandonware sites, but the installer can be a little iffy on modern versions of Windows. For convenience, I made a [portable version](https://github.com/itsmattkc/msvc420) that can be downloaded and used quickly instead.
|
||||
- DirectX 5 SDK. Similarly, this can be found on many abandonware sites.
|
||||
- [CMake](https://cmake.org/). A copy is often included with the "Desktop development with C++" workload in newer versions of Visual Studio, however it can also be installed as a standalone app.
|
||||
|
||||
#### Compiling From Command Line
|
||||
#### Compiling
|
||||
|
||||
1. Open a Command Prompt (`cmd`).
|
||||
1. From Visual C++ 4.2, run `BIN/VCVARS32.BAT x86` to populate the path and other environment variables for compiling with MSVC.
|
||||
|
@ -37,6 +36,7 @@ You will need the following software installed:
|
|||
```
|
||||
cmake <path-to-source> -G "NMake Makefiles" -DCMAKE_BUILD_TYPE=RelWithDebInfo
|
||||
```
|
||||
- **Visual C++ 4.2 has issues with paths containing spaces**. If you get configure or build errors, make sure neither CMake, the repository, nor Visual C++ 4.2 is in a path that contains spaces.
|
||||
- Replace `<path-to-source>` with the source repository. Can be `..` if your build folder is inside the source repository.
|
||||
- `RelWithDebInfo` is recommended because it will produce debug symbols useful for further decompilation work. However, you can change this to `Release` if you don't need them. `Debug` builds are not recommended because they are unlikely to be compatible with the retail `LEGO1.DLL`, which is currently the only way to really use this decomp.
|
||||
- `NMake Makefiles` is most recommended because it will be immediately compatible with Visual C++ 4.2. For faster builds, you can use `Ninja` (if you have it installed), however due to limitations in Visual C++ 4.2, you can only build `Release` builds this way (debug symbols cannot be generated with `Ninja`).
|
||||
|
|
|
@ -1,34 +0,0 @@
|
|||
[InstallShield Silent]
|
||||
Version=v5.00.000
|
||||
File=Response File
|
||||
[DlgOrder]
|
||||
Dlg0=SdWelcome-0
|
||||
Count=7
|
||||
Dlg1=SdLicense-0
|
||||
Dlg2=SdSetupTypeEx-0
|
||||
Dlg3=SdAskDestPath-0
|
||||
Dlg4=SdSelectFolder-0
|
||||
Dlg5=SdStartCopy-0
|
||||
Dlg6=SdFinish-0
|
||||
[SdWelcome-0]
|
||||
Result=1
|
||||
[SdLicense-0]
|
||||
Result=1
|
||||
[SdSetupTypeEx-0]
|
||||
Result=Compact
|
||||
[SdAskDestPath-0]
|
||||
szDir=C:\dxsdk
|
||||
Result=1
|
||||
[SdSelectFolder-0]
|
||||
szFolder=Microsoft DirectX 5 SDK
|
||||
Result=1
|
||||
[SdStartCopy-0]
|
||||
Result=1
|
||||
[Application]
|
||||
Name=the Microsoft DirectX 5 SDK
|
||||
Version=5
|
||||
Company=Microsoft
|
||||
[SdFinish-0]
|
||||
Result=1
|
||||
bOpt1=0
|
||||
bOpt2=0
|
Loading…
Reference in a new issue