CAST II Game Engine

   MAIN       FEATURES       SCREENSHOTS       FORUMS       MANUAL       DOWNLOADS       CONTACTS   
Units
Class Hierarchy
Classes, Interfaces and Objects
Types
Enumerations
Variables
Constants
Functions and Procedures
Identifiers

Unit C2DX8Render

Description

CAST Engine DirectX 8 render unit

(C) 2006 George "Mirage" Bakhtadze. www.casteng.com
The source code may be used under either MPL 1.1 or LGPL 2.1 license. See included license.txt file
Unit contains DirectX 8-based renderer implementation classes

Classes, Interfaces and Objects

NameDescription
Class TDX8BuffersDirect X 8 implementation of vertex and index buffers management class
Class TDX8Renderer 
Class TDX8StateWrapper 
Class TDX8Textures 

Functions and Procedures

Overview

function FVFToVertexFormat(FVF: Cardinal): Cardinal;
function HResultToStr(Res: HResult): string;

Description

function FVFToVertexFormat(FVF: Cardinal): Cardinal;

 

function HResultToStr(Res: HResult): string;

 

Types

Overview

PDX8VertexDeclaration = ^TDX8VertexDeclaration;
TDX8IndexBuffer = record BufferSize: Integer; Static: Boolean; Buffer: IDirect3DIndexBuffer8; end;
TDX8VertexBuffer = record VertexSize, BufferSize: Integer; Static: Boolean; Buffer: IDirect3DVertexBuffer8; end;
TDX8VertexDeclaration = array[0..$FFFF] of Cardinal;

Description

PDX8VertexDeclaration = ^TDX8VertexDeclaration;

 

TDX8IndexBuffer = record BufferSize: Integer; Static: Boolean; Buffer: IDirect3DIndexBuffer8; end;

 

TDX8VertexBuffer = record VertexSize, BufferSize: Integer; Static: Boolean; Buffer: IDirect3DVertexBuffer8; end;

 

TDX8VertexDeclaration = array[0..$FFFF] of Cardinal;

D3DVSDT_UBYTE4, D3DVSDT_FLOAT1, D3DVSDT_FLOAT2); // Unsupported by DX8

Constants

Overview

BufferLockFlags : array[Boolean, Boolean] of Cardinal = ((D3DLOCK_NOOVERWRITE*1 or 0*D3DLOCK_DISCARD or 0*D3DLOCK_NOSYSLOCK, D3DLOCK_DISCARD*1 or 0*D3DLOCK_NOSYSLOCK), (D3DLOCK_NOOVERWRITE*0, 1*D3DLOCK_DISCARD));
BufferPool : array[Boolean] of TD3DPool = (D3DPOOL_DEFAULT, D3DPOOL_SYSTEMMEM);
BufferUsage : array[Boolean] of Cardinal = (D3DUSAGE_DYNAMIC or D3DUSAGE_WRITEONLY, D3DUSAGE_WRITEONLY);
DeviceTypesEnum = 'Hardware\&Reference\&Software';
dtHAL = 0;
dtREF = 1;
dtSW = 2;
FullScreenWindowStyle = WS_POPUP or WS_VISIBLE;
VertexDataTypeToD3DVSDT : array[vdtFloat1..vdtInt16_4] of Cardinal = (D3DVSDT_FLOAT1, D3DVSDT_FLOAT2, D3DVSDT_FLOAT3, D3DVSDT_FLOAT4, D3DVSDT_D3DCOLOR, D3DVSDT_UBYTE4, D3DVSDT_SHORT2, D3DVSDT_SHORT4);

Description

BufferLockFlags : array[Boolean, Boolean] of Cardinal = ((D3DLOCK_NOOVERWRITE*1 or 0*D3DLOCK_DISCARD or 0*D3DLOCK_NOSYSLOCK, D3DLOCK_DISCARD*1 or 0*D3DLOCK_NOSYSLOCK), (D3DLOCK_NOOVERWRITE*0, 1*D3DLOCK_DISCARD));

Flags for dynamic and static vertex buffers lock with keeping contents or without

BufferPool : array[Boolean] of TD3DPool = (D3DPOOL_DEFAULT, D3DPOOL_SYSTEMMEM);

Pool flags for vertex buffers with fully hardware vertex processing and hardware T&L with software shader emulation

BufferUsage : array[Boolean] of Cardinal = (D3DUSAGE_DYNAMIC or D3DUSAGE_WRITEONLY, D3DUSAGE_WRITEONLY);

Usage flags for dynamic and static vertex buffers

DeviceTypesEnum = 'Hardware\&Reference\&Software';

Device types string enumeration

dtHAL = 0;

Hardware accelerated layer

dtREF = 1;

Reference software rasterizer

dtSW = 2;

Software rasterizer

FullScreenWindowStyle = WS_POPUP or WS_VISIBLE;

 

VertexDataTypeToD3DVSDT : array[vdtFloat1..vdtInt16_4] of Cardinal = (D3DVSDT_FLOAT1, D3DVSDT_FLOAT2, D3DVSDT_FLOAT3, D3DVSDT_FLOAT4, D3DVSDT_D3DCOLOR, D3DVSDT_UBYTE4, D3DVSDT_SHORT2, D3DVSDT_SHORT4);

Static non-discard and discard lock

Last modified: Jan 6, 2010
Copyright (C) 2006-2010, casteng.com