orx  1.14
Portable Game Engine
OrxTexture

Macros

#define orxTEXTURE_KZ_LOCALE_GROUP   "Texture"
 
#define orxTEXTURE_KZ_PIXEL   "pixel"
 
#define orxTEXTURE_KZ_RESOURCE_GROUP   "Texture"
 
#define orxTEXTURE_KZ_SCREEN   "screen"
 
#define orxTEXTURE_KZ_TRANSPARENT   "transparent"
 

Typedefs

typedef struct __orxTEXTURE_t orxTEXTURE
 

Enumerations

enum  orxTEXTURE_EVENT {
  orxTEXTURE_EVENT_CREATE = 0, orxTEXTURE_EVENT_DELETE, orxTEXTURE_EVENT_LOAD, orxTEXTURE_EVENT_NUMBER,
  orxTEXTURE_EVENT_NONE = orxENUM_NONE
}
 

Functions

orxDLLAPI orxSTATUS orxFASTCALL orxTexture_ClearCache ()
 
orxDLLAPI orxTEXTURE *orxFASTCALL orxTexture_Create ()
 
orxDLLAPI orxSTATUS orxFASTCALL orxTexture_Delete (orxTEXTURE *_pstTexture)
 
orxDLLAPI void orxFASTCALL orxTexture_Exit ()
 
orxDLLAPI orxTEXTURE *orxFASTCALL orxTexture_Get (const orxSTRING _zName)
 
orxDLLAPI orxBITMAP *orxFASTCALL orxTexture_GetBitmap (const orxTEXTURE *_pstTexture)
 
orxDLLAPI orxU32 orxFASTCALL orxTexture_GetLoadCount ()
 
orxDLLAPI const orxSTRING orxFASTCALL orxTexture_GetName (const orxTEXTURE *_pstTexture)
 
orxDLLAPI orxTEXTURE *orxFASTCALL orxTexture_GetScreenTexture ()
 
orxDLLAPI orxSTATUS orxFASTCALL orxTexture_GetSize (const orxTEXTURE *_pstTexture, orxFLOAT *_pfWidth, orxFLOAT *_pfHeight)
 
orxDLLAPI orxSTATUS orxFASTCALL orxTexture_Init ()
 
orxDLLAPI orxSTATUS orxFASTCALL orxTexture_LinkBitmap (orxTEXTURE *_pstTexture, const orxBITMAP *_pstBitmap, const orxSTRING _zDataName, orxBOOL _bTransferOwnership)
 
orxDLLAPI orxTEXTURE *orxFASTCALL orxTexture_Load (const orxSTRING _zFileName, orxBOOL _bKeepInCache)
 
orxDLLAPI void orxFASTCALL orxTexture_Setup ()
 
orxDLLAPI orxSTATUS orxFASTCALL orxTexture_UnlinkBitmap (orxTEXTURE *_pstTexture)
 

Detailed Description

Texture module Module that handles textures

Macro Definition Documentation

#define orxTEXTURE_KZ_LOCALE_GROUP   "Texture"

Definition at line 55 of file orxTexture.h.

#define orxTEXTURE_KZ_PIXEL   "pixel"

Definition at line 58 of file orxTexture.h.

#define orxTEXTURE_KZ_RESOURCE_GROUP   "Texture"

Defines

Definition at line 54 of file orxTexture.h.

#define orxTEXTURE_KZ_SCREEN   "screen"

Definition at line 57 of file orxTexture.h.

#define orxTEXTURE_KZ_TRANSPARENT   "transparent"

Definition at line 59 of file orxTexture.h.

Typedef Documentation

typedef struct __orxTEXTURE_t orxTEXTURE

Internal texture structure

Definition at line 78 of file orxTexture.h.

Enumeration Type Documentation

Event enum

Enumerator
orxTEXTURE_EVENT_CREATE 
orxTEXTURE_EVENT_DELETE 
orxTEXTURE_EVENT_LOAD 
orxTEXTURE_EVENT_NUMBER 
orxTEXTURE_EVENT_NONE 

Definition at line 64 of file orxTexture.h.

Function Documentation

orxDLLAPI orxSTATUS orxFASTCALL orxTexture_ClearCache ( )

Clears cache (if any texture is still in active use, it'll remain in memory until not referenced anymore)

Returns
orxSTATUS_SUCCESS / orxSTATUS_FAILURE
orxDLLAPI orxTEXTURE* orxFASTCALL orxTexture_Create ( )

Creates an empty texture

Returns
orxTEXTURE / orxNULL
orxDLLAPI orxSTATUS orxFASTCALL orxTexture_Delete ( orxTEXTURE _pstTexture)

Deletes a texture (and its referenced bitmap)

Parameters
[in]_pstTextureConcerned texture
Returns
orxSTATUS_SUCCESS / orxSTATUS_FAILURE
orxDLLAPI void orxFASTCALL orxTexture_Exit ( )

Exits from the texture module

orxDLLAPI orxTEXTURE* orxFASTCALL orxTexture_Get ( const orxSTRING  _zName)

Gets texture given its name

Parameters
[in]_zNameTexture name
Returns
orxTEXTURE / orxNULL
orxDLLAPI orxBITMAP* orxFASTCALL orxTexture_GetBitmap ( const orxTEXTURE _pstTexture)

Gets texture bitmap

Parameters
[in]_pstTextureConcerned texture
Returns
orxBITMAP / orxNULL
orxDLLAPI orxU32 orxFASTCALL orxTexture_GetLoadCount ( )

Gets pending load count

Returns
Pending load count
orxDLLAPI const orxSTRING orxFASTCALL orxTexture_GetName ( const orxTEXTURE _pstTexture)

Gets texture name

Parameters
[in]_pstTextureConcerned texture
Returns
Texture name / orxSTRING_EMPTY
orxDLLAPI orxTEXTURE* orxFASTCALL orxTexture_GetScreenTexture ( )

Gets screen texture

Returns
Screen texture / orxNULL
orxDLLAPI orxSTATUS orxFASTCALL orxTexture_GetSize ( const orxTEXTURE _pstTexture,
orxFLOAT *  _pfWidth,
orxFLOAT *  _pfHeight 
)

Gets texture size

Parameters
[in]_pstTextureConcerned texture
[out]_pfWidthTexture's width
[out]_pfHeightTexture's height
Returns
orxSTATUS_SUCCESS / orxSTATUS_FAILURE
orxDLLAPI orxSTATUS orxFASTCALL orxTexture_Init ( )

Inits the texture module

Returns
orxSTATUS_SUCCESS / orxSTATUS_FAILURE
orxDLLAPI orxSTATUS orxFASTCALL orxTexture_LinkBitmap ( orxTEXTURE _pstTexture,
const orxBITMAP _pstBitmap,
const orxSTRING  _zDataName,
orxBOOL  _bTransferOwnership 
)

Links a bitmap

Parameters
[in]_pstTextureConcerned texture
[in]_pstBitmapBitmap to link
[in]_zDataNameName associated with the bitmap (usually filename)
[in]_bTransferOwnershipIf set to true, the texture will become the bitmap's owner and will have it deleted upon its own deletion
Returns
orxSTATUS_SUCCESS / orxSTATUS_FAILURE
orxDLLAPI orxTEXTURE* orxFASTCALL orxTexture_Load ( const orxSTRING  _zFileName,
orxBOOL  _bKeepInCache 
)

Loads a texture from a bitmap file

Parameters
[in]_zFileNameName of the bitmap
[in]_bKeepInCacheShould be kept in cache after no more references exist?
Returns
orxTEXTURE / orxNULL
orxDLLAPI void orxFASTCALL orxTexture_Setup ( )

Setups the texture module

orxDLLAPI orxSTATUS orxFASTCALL orxTexture_UnlinkBitmap ( orxTEXTURE _pstTexture)

Unlinks (and deletes if not used anymore) a bitmap

Parameters
[in]_pstTextureConcerned texture
Returns
orxSTATUS_SUCCESS / orxSTATUS_FAILURE

Generated for orx by doxygen 1.8.11