Common data types.
More...
Common data types.
|
enum | TLN_TileFlags {
FLAG_NONE = 0,
FLAG_FLIPX = BITVAL(15),
FLAG_FLIPY = BITVAL(14),
FLAG_ROTATE = BITVAL(13),
FLAG_PRIORITY = BITVAL(12),
FLAG_MASKED = BITVAL(11),
FLAG_TILESET = (7 << 8),
FLAG_PALETTE = (7 << 5)
} |
|
enum | TLN_Blend {
BLEND_NONE,
BLEND_MIX25,
BLEND_MIX50,
BLEND_MIX75,
BLEND_ADD,
BLEND_SUB,
BLEND_MOD,
BLEND_CUSTOM
} |
|
enum | TLN_LayerType { LAYER_NONE,
LAYER_TILE,
LAYER_OBJECT,
LAYER_BITMAP
} |
|
enum | TLN_CRT { TLN_CRT_SLOT,
TLN_CRT_APERTURE,
TLN_CRT_SHADOW
} |
|
enum | TLN_Player { PLAYER1,
PLAYER2,
PLAYER3,
PLAYER4
} |
|
enum | TLN_Input {
INPUT_NONE,
INPUT_UP,
INPUT_DOWN,
INPUT_LEFT,
INPUT_RIGHT,
INPUT_BUTTON1,
INPUT_BUTTON2,
INPUT_BUTTON3,
INPUT_BUTTON4,
INPUT_BUTTON5,
INPUT_BUTTON6,
INPUT_START,
INPUT_QUIT,
INPUT_CRT,
INPUT_P1 = (PLAYER1 << 5),
INPUT_P2 = (PLAYER2 << 5),
INPUT_P3 = (PLAYER3 << 5),
INPUT_P4 = (PLAYER4 << 5)
} |
|
enum | {
CWF_FULLSCREEN = (1 << 0),
CWF_VSYNC = (1 << 1),
CWF_S1 = (1 << 2),
CWF_S2 = (2 << 2),
CWF_S3 = (3 << 2),
CWF_S4 = (4 << 2),
CWF_S5 = (5 << 2)
} |
|
enum | TLN_Error {
TLN_ERR_OK,
TLN_ERR_OUT_OF_MEMORY,
TLN_ERR_IDX_LAYER,
TLN_ERR_IDX_SPRITE,
TLN_ERR_IDX_ANIMATION,
TLN_ERR_IDX_PICTURE,
TLN_ERR_REF_TILESET,
TLN_ERR_REF_TILEMAP,
TLN_ERR_REF_SPRITESET,
TLN_ERR_REF_PALETTE,
TLN_ERR_REF_SEQUENCE,
TLN_ERR_REF_SEQPACK,
TLN_ERR_REF_BITMAP,
TLN_ERR_NULL_POINTER,
TLN_ERR_FILE_NOT_FOUND,
TLN_ERR_WRONG_FORMAT,
TLN_ERR_WRONG_SIZE,
TLN_ERR_UNSUPPORTED,
TLN_ERR_REF_LIST,
TLN_ERR_IDX_PALETTE
} |
|
enum | TLN_LogLevel { TLN_LOG_NONE,
TLN_LOG_ERRORS,
TLN_LOG_VERBOSE
} |
|
◆ TLN_Engine
◆ TLN_Tileset
◆ TLN_Tilemap
◆ TLN_Palette
◆ TLN_Spriteset
Opaque sspriteset reference
◆ TLN_Sequence
Opaque sequence reference
◆ TLN_SequencePack
Opaque sequence pack reference
◆ TLN_Bitmap
◆ TLN_ObjectList
Opaque object list reference
◆ TLN_TileFlags
tile/sprite flags. Can be none or a combination of the following:
Enumerator |
---|
FLAG_NONE | no flags
|
FLAG_FLIPX | horizontal flip
|
FLAG_FLIPY | vertical flip
|
FLAG_ROTATE | row/column flip (unsupported, Tiled compatibility)
|
FLAG_PRIORITY | tile goes in front of sprite layer
|
FLAG_MASKED | sprite won't be drawn inside masked region
|
FLAG_TILESET | tileset index (0 - 7)
|
FLAG_PALETTE | palette index (0 - 7)
|
◆ TLN_Blend
layer blend modes. Must be one of these and are mutually exclusive:
Enumerator |
---|
BLEND_NONE | blending disabled
|
BLEND_MIX25 | color averaging 1
|
BLEND_MIX50 | color averaging 2
|
BLEND_MIX75 | color averaging 3
|
BLEND_ADD | color is always brighter (simulate light effects)
|
BLEND_SUB | color is always darker (simulate shadow effects)
|
BLEND_MOD | color is always darker (simulate shadow effects)
|
BLEND_CUSTOM | user provided blend function with TLN_SetCustomBlendFunction()
|
◆ TLN_LayerType
layer type retrieved by TLN_GetLayerType
Enumerator |
---|
LAYER_NONE | undefined
|
LAYER_TILE | tilemap-based layer
|
LAYER_OBJECT | objects layer
|
LAYER_BITMAP | bitmapped layer
|
◆ TLN_CRT
types of built-in CRT effect for TLN_ConfigCRTEffect
Enumerator |
---|
TLN_CRT_SLOT | slot mask without scanlines, similar to legacy effect
|
TLN_CRT_APERTURE | aperture grille with scanlines (matrix-like dot arrangement)
|
TLN_CRT_SHADOW | shadow mask with scanlines, diagonal subpixel arrangement
|
◆ TLN_Player
Player index for input assignment functions
Enumerator |
---|
PLAYER1 | Player 1
|
PLAYER2 | Player 2
|
PLAYER3 | Player 3
|
PLAYER4 | Player 4
|
◆ TLN_Input
Standard inputs query for TLN_GetInput()
Enumerator |
---|
INPUT_NONE | no input
|
INPUT_UP | up direction
|
INPUT_DOWN | down direction
|
INPUT_LEFT | left direction
|
INPUT_RIGHT | right direction
|
INPUT_BUTTON1 | 1st action button
|
INPUT_BUTTON2 | 2nd action button
|
INPUT_BUTTON3 | 3th action button
|
INPUT_BUTTON4 | 4th action button
|
INPUT_BUTTON5 | 5th action button
|
INPUT_BUTTON6 | 6th action button
|
INPUT_START | Start button
|
INPUT_QUIT | Window close (only Player 1 keyboard)
|
INPUT_CRT | CRT toggle (only Player 1 keyboard)
|
INPUT_P1 | request player 1 input (default)
|
INPUT_P2 | request player 2 input
|
INPUT_P3 | request player 3 input
|
INPUT_P4 | request player 4 input
|
◆ anonymous enum
CreateWindow flags. Can be none or a combination of the following:
Enumerator |
---|
CWF_FULLSCREEN | create a fullscreen window
|
CWF_VSYNC | sync frame updates with vertical retrace
|
CWF_S1 | create a window the same size as the framebuffer
|
CWF_S2 | create a window 2x the size the framebuffer
|
CWF_S3 | create a window 3x the size the framebuffer
|
CWF_S4 | create a window 4x the size the framebuffer
|
CWF_S5 | create a window 5x the size the framebuffer
|
◆ TLN_Error
Error codes
Enumerator |
---|
TLN_ERR_OK | No error
|
TLN_ERR_OUT_OF_MEMORY | Not enough memory
|
TLN_ERR_IDX_LAYER | Layer index out of range
|
TLN_ERR_IDX_SPRITE | Sprite index out of range
|
TLN_ERR_IDX_ANIMATION | Animation index out of range
|
TLN_ERR_IDX_PICTURE | Picture or tile index out of range
|
TLN_ERR_REF_TILESET | Invalid TLN_Tileset reference
|
TLN_ERR_REF_TILEMAP | Invalid TLN_Tilemap reference
|
TLN_ERR_REF_SPRITESET | Invalid TLN_Spriteset reference
|
TLN_ERR_REF_PALETTE | Invalid TLN_Palette reference
|
TLN_ERR_REF_SEQUENCE | Invalid TLN_Sequence reference
|
TLN_ERR_REF_SEQPACK | Invalid TLN_SequencePack reference
|
TLN_ERR_REF_BITMAP | Invalid TLN_Bitmap reference
|
TLN_ERR_NULL_POINTER | Null pointer as argument
|
TLN_ERR_FILE_NOT_FOUND | Resource file not found
|
TLN_ERR_WRONG_FORMAT | Resource file has invalid format
|
TLN_ERR_WRONG_SIZE | A width or height parameter is invalid
|
TLN_ERR_UNSUPPORTED | Unsupported function
|
TLN_ERR_REF_LIST | Invalid TLN_ObjectList reference
|
TLN_ERR_IDX_PALETTE | Palette index out of range
|
◆ TLN_LogLevel
Debug level
Enumerator |
---|
TLN_LOG_NONE | Don't print anything (default)
|
TLN_LOG_ERRORS | Print only runtime errors
|
TLN_LOG_VERBOSE | Print everything
|