CAST II Game Engine |
|||||||||||||||
![]() |
DESCRIPTION | ![]() |
FEATURES | ![]() |
SCREENSHOTS | ![]() |
FORUMS | ![]() |
DOCUMENTATION | ![]() |
DOWNLOADS | ![]() |
CONTACTS | ![]() |
|
type TResource = class(TItem)
TItem > TBaseItem![]() | constructor Create(AManager: TItemsManager); override; |
![]() | destructor Destroy; override; |
![]() | procedure AddProperties(const Result: Props.TProperties); override; |
![]() | procedure Allocate(ASize: Integer); |
![]() | function Convert(OldFormat, NewFormat: Integer): Boolean; virtual; |
![]() | function GetElementSize: Integer; virtual; |
![]() | function GetItemSize(CountChilds: Boolean): Integer; override; |
![]() | class function IsAbstract: Boolean; override; |
![]() | function Load(Stream: Basics.TStream): Boolean; override; |
![]() | function LoadData(Stream: Basics.TStream): Boolean; virtual; |
![]() | function Save(Stream: Basics.TStream): Boolean; override; |
![]() | procedure SetAllocated(ASize: Integer; AData: Pointer); |
![]() | procedure SetFormat(const Value: Integer); |
![]() | procedure SetLoaded(Value: Boolean); virtual; |
![]() | procedure SetProperties(Properties: Props.TProperties); override; |
![]() | procedure UnloadData; virtual; |
![]() | constructor Create(AManager: TItemsManager); override; |
![]() | destructor Destroy; override; |
![]() | procedure AddProperties(const Result: Props.TProperties); override; |
![]() | procedure Allocate(ASize: Integer); |
Allocates an empty data buffer or changes allocated size of an existing one
![]() | function Convert(OldFormat, NewFormat: Integer): Boolean; virtual; |
Should perform actual conversion from old format to a new one and return True if the conversion is possible and successful
![]() | function GetElementSize: Integer; virtual; |
Returns size of each element in resource
![]() | function GetItemSize(CountChilds: Boolean): Integer; override; |
![]() | class function IsAbstract: Boolean; override; |
![]() | function Load(Stream: Basics.TStream): Boolean; override; |
Loads the resource from a stream
![]() | function LoadData(Stream: Basics.TStream): Boolean; virtual; |
Read resource's data from the specified stream
![]() | function Save(Stream: Basics.TStream): Boolean; override; |
Saves the resource to a stream
![]() | procedure SetAllocated(ASize: Integer; AData: Pointer); |
Sets already allocated and probably ready to use data
![]() | procedure SetFormat(const Value: Integer); |
Calls Convert() and if it returns True sets the new format
![]() | procedure SetLoaded(Value: Boolean); virtual; |
Not used yet
![]() | procedure SetProperties(Properties: Props.TProperties); override; |
![]() | procedure UnloadData; virtual; |
Not used yet
![]() | property Data: Pointer; |
![]() | property DataSize: Integer; |
![]() | property Format: Integer; |
![]() | property Loaded: Boolean; |
![]() | property TotalElements: Integer; |
![]() | property Data: Pointer; |
Pointer to the resource's data
![]() | property DataSize: Integer; |
Data size on bytes
![]() | property Format: Integer; |
Resource format
![]() | property Loaded: Boolean; |
Determines if the resource is loaded completely including its data
![]() | property TotalElements: Integer; |
Number of elements in the resource
|
Last modified: 4 Jul, 2008 |