Starshatter_Open
Open source Starshatter engine
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
VideoDX9.cpp File Reference
#include "MemDebug.h"
#include "VideoDX9.h"
#include "VideoDX9Enum.h"
#include "VideoDX9VertexBuffer.h"
#include "TexDX9.h"
#include "TexCubeDX9.h"
#include "Camera.h"
#include "Color.h"
#include "DataLoader.h"
#include "Polygon.h"
#include "Light.h"
#include "Solid.h"

Go to the source code of this file.

Classes

class  VideoDX9SurfaceData
class  VideoDX9SegmentData
struct  VideoDX9ScreenVertex
struct  VideoDX9NormalVertex
struct  VideoDX9SolidVertex
struct  VideoDX9LuminousVertex
struct  VideoDX9DetailVertex
struct  VideoDX9LineVertex

Macros

#define RELEASE(x)   if (x) { x->Release(); x=NULL; }
#define F2DW(x)   (*(DWORD*)(&x))
#define DW2I(x)   (*(int*)(&x))

Typedefs

typedef HRESULT(WINAPI * LPDDCE )(GUID FAR *, LPVOID *, REFIID, IUnknown FAR *)

Enumerations

enum  {
  DX9_STRATEGY_NONE, DX9_STRATEGY_SIMPLE, DX9_STRATEGY_GLOW, DX9_STRATEGY_SPECMAP,
  DX9_STRATEGY_EMISSIVE, DX9_STRATEGY_SPEC_EMISSIVE, DX9_STRATEGY_BLEND, DX9_STRATEGY_BLEND_DETAIL
}

Functions

void Print (const char *msg,...)
char * D3DErrStr (HRESULT dderr)
void VideoDX9Error (const char *msg, HRESULT dderr)
WORD RampValue (UINT i, double recip_gamma, double fade)
float ReciprocalGamma (UINT i)
float GammaValue (UINT i)

Variables

int VD3D_describe_things
List< Modelmodel_clients
D3DVERTEXELEMENT9 videoDX9NormalVertexElements []

Macro Definition Documentation

#define DW2I (   x)    (*(int*)(&x))

Definition at line 54 of file VideoDX9.cpp.

#define F2DW (   x)    (*(DWORD*)(&x))

Definition at line 50 of file VideoDX9.cpp.

#define RELEASE (   x)    if (x) { x->Release(); x=NULL; }

Definition at line 46 of file VideoDX9.cpp.


Typedef Documentation

typedef HRESULT(WINAPI * LPDDCE)(GUID FAR *, LPVOID *, REFIID, IUnknown FAR *)

Definition at line 59 of file VideoDX9.cpp.


Enumeration Type Documentation

anonymous enum
Enumerator:
DX9_STRATEGY_NONE 
DX9_STRATEGY_SIMPLE 
DX9_STRATEGY_GLOW 
DX9_STRATEGY_SPECMAP 
DX9_STRATEGY_EMISSIVE 
DX9_STRATEGY_SPEC_EMISSIVE 
DX9_STRATEGY_BLEND 
DX9_STRATEGY_BLEND_DETAIL 

Definition at line 229 of file VideoDX9.cpp.


Function Documentation

char * D3DErrStr ( HRESULT  dderr)

Definition at line 3530 of file VideoDX9.cpp.

float GammaValue ( UINT  i)
inline

Definition at line 852 of file VideoDX9.cpp.

void Print ( const char *  msg,
  ... 
)

Definition at line 1520 of file Game.cpp.

WORD RampValue ( UINT  i,
double  recip_gamma,
double  fade 
)
inline

Definition at line 830 of file VideoDX9.cpp.

float ReciprocalGamma ( UINT  i)
inline

Definition at line 841 of file VideoDX9.cpp.

void VideoDX9Error ( const char *  msg,
HRESULT  dderr 
)

Definition at line 3525 of file VideoDX9.cpp.


Variable Documentation

List<Model> model_clients

Definition at line 70 of file VideoDX9.cpp.

int VD3D_describe_things

Definition at line 25 of file VideoDX9Enum.cpp.

D3DVERTEXELEMENT9 videoDX9NormalVertexElements[]
Initial value:
{
{ 0, 0, D3DDECLTYPE_FLOAT3, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0 },
{ 0, 12, D3DDECLTYPE_FLOAT3, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_NORMAL, 0 },
{ 0, 24, D3DDECLTYPE_FLOAT2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_TEXCOORD, 0 },
{ 0, 32, D3DDECLTYPE_FLOAT2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_TEXCOORD, 1 },
{ 0, 40, D3DDECLTYPE_FLOAT3, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_TANGENT, 2 },
{ 0, 52, D3DDECLTYPE_FLOAT3, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_BINORMAL, 3 },
}

Definition at line 163 of file VideoDX9.cpp.