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

Class TTextures

Unit

C2Render

Declaration

type TTextures = class

Description

 

Fields

 NameDescription
ProtectedFTextures 
ProtectedRenderer 

Methods

Overview

Publicdestructor Destroy; override;
Protectedfunction APICreateTexture(Index: Integer): Boolean; virtual; abstract;
Publicprocedure Apply(Stage, Index: Integer); virtual; abstract;
Publicprocedure Delete(Index: Integer); virtual;
Protectedprocedure FreeAll;
Publicprocedure HandleMessage(const Msg: TMessage);
Protectedfunction IsEmpty(const Element: TTexture): Boolean;
Publicfunction Load(Index: Integer): Boolean;
Publicfunction Lock(AIndex, AMipLevel: Integer; const ARect: BaseTypes.PRect; out LockRectData: TLockedRectData; LockFlags: TLockFlags): Boolean; virtual; abstract;
Publicfunction NewProceduralTexture(AFormat: Cardinal; AWidth, AHeight, ADepth, ALevels: Integer; Options: TTextureOptions): Integer;
Publicfunction NewTexture(Resource: TImageResource; Options: TTextureOptions): Integer;
Publicfunction Read(Index: Integer; Dest: Pointer; Rect: BaseTypes.PRect3D): Boolean; virtual; abstract;
Publicfunction Resolve(Pass: TRenderPass; StageIndex: Integer): Boolean;
Publicprocedure Unload(Index: Integer); virtual; abstract;
Publicprocedure UnLock(AIndex, AMipLevel: Integer); virtual; abstract;
Publicfunction Update(Index: Integer; Src: Pointer; Rect: BaseTypes.PRect3D): Boolean; virtual; abstract;

Description

Publicdestructor Destroy; override;

 

Protectedfunction APICreateTexture(Index: Integer): Boolean; virtual; abstract;

Calls an API to create API-specific texture object

Publicprocedure Apply(Stage, Index: Integer); virtual; abstract;

Applies texture with the specified index to the specified API stage

Publicprocedure Delete(Index: Integer); virtual;

Removes the specified texture

Protectedprocedure FreeAll;

Deletes all textures

Publicprocedure HandleMessage(const Msg: TMessage);

Handles some related messages

Protectedfunction IsEmpty(const Element: TTexture): Boolean;

Returns True if the specified texture is not initialized

Publicfunction Load(Index: Integer): Boolean;

Loads the specified by index texture from its associated resource. Returns True if success.

Publicfunction Lock(AIndex, AMipLevel: Integer; const ARect: BaseTypes.PRect; out LockRectData: TLockedRectData; LockFlags: TLockFlags): Boolean; virtual; abstract;

Locks the specified area of the specified level of the specified texture. This call should be accompanied by a corresponding UnLock call.

Publicfunction NewProceduralTexture(AFormat: Cardinal; AWidth, AHeight, ADepth, ALevels: Integer; Options: TTextureOptions): Integer;

Adds a new procedural texture entry. Does not create any API-specific objects.

Publicfunction NewTexture(Resource: TImageResource; Options: TTextureOptions): Integer;

Adds a new texture entry. Does not create any API-specific objects.

Publicfunction Read(Index: Integer; Dest: Pointer; Rect: BaseTypes.PRect3D): Boolean; virtual; abstract;

Reads the specified rectangle of the specified by index texture in API to the given pointer. Returns True if success. Currently not implemented.

Publicfunction Resolve(Pass: TRenderPass; StageIndex: Integer): Boolean;

Resolves a texture for the given pass. Used internally.

Publicprocedure Unload(Index: Integer); virtual; abstract;

Unloads the specified by index texture from API. Currently not implemented.

Publicprocedure UnLock(AIndex, AMipLevel: Integer); virtual; abstract;

Unlocks previously locked texture

Publicfunction Update(Index: Integer; Src: Pointer; Rect: BaseTypes.PRect3D): Boolean; virtual; abstract;

Updates the specified rectangle of the specified by index texture in API from the given pointer. Returns True if success.

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