2.15.1
Functions
Sequencepack

Sequence pack manager for grouping and finding sequences. More...

Description

Sequence pack manager for grouping and finding sequences.

Functions

TLN_SequencePack TLN_CreateSequencePack (void)
 Creates a new collection of sequences. More...
 
TLN_SequencePack TLN_LoadSequencePack (const char *filename)
 Loads a sqx file containing one or more sequences. More...
 
TLN_Sequence TLN_GetSequence (TLN_SequencePack sp, int index)
 Returns the nth sequence inside a sequence pack. More...
 
TLN_Sequence TLN_FindSequence (TLN_SequencePack sp, const char *name)
 Finds a sequence inside a sequence pack. More...
 
int TLN_GetSequencePackCount (TLN_SequencePack sp)
 Returns the number of sequences inside a sequence pack. More...
 
bool TLN_AddSequenceToPack (TLN_SequencePack sp, TLN_Sequence sequence)
 Adds a sequence to a sequence pack. More...
 
bool TLN_DeleteSequencePack (TLN_SequencePack sp)
 Deletes the specified sequence pack and frees memory. More...
 

Function Documentation

◆ TLN_CreateSequencePack()

TLN_SequencePack TLN_CreateSequencePack ( void  )

Creates a new collection of sequences.

Returns
Reference to the created pack or NULL if error
See also
TLN_AddSequenceToPack(), TLN_CreateSequence()

◆ TLN_LoadSequencePack()

TLN_SequencePack TLN_LoadSequencePack ( const char *  filename)

Loads a sqx file containing one or more sequences.

Parameters
filenameSQX filename with the sequences to load
Returns
Reference to the newly created TLN_SequencePack() or NULL if error
Remarks
A SQX file can contain many sequences. This function loads all of them inside a single TLN_SequencePack(). Individual sequences can be later queried with TLN_FindSequence()
See also
TLN_FindSequence()

◆ TLN_GetSequence()

TLN_Sequence TLN_GetSequence ( TLN_SequencePack  sp,
int  index 
)

Returns the nth sequence inside a sequence pack.

Parameters
spReference to the sequence pack containing the sequence to find
indexSequence number to return [0, num_sequences - 1]
See also
TLN_LoadSequencePack(), TLN_GetSequencePackCount()

◆ TLN_FindSequence()

TLN_Sequence TLN_FindSequence ( TLN_SequencePack  sp,
const char *  name 
)

Finds a sequence inside a sequence pack.

Parameters
spReference to the sequence pack containing the sequence to find
nameName of the sequence to find
Returns
Reference to the sequence with the specified name, or NULL if not found
See also
TLN_LoadSequencePack()

◆ TLN_GetSequencePackCount()

int TLN_GetSequencePackCount ( TLN_SequencePack  sp)

Returns the number of sequences inside a sequence pack.

Parameters
spReference to the sequence pack to query

◆ TLN_AddSequenceToPack()

bool TLN_AddSequenceToPack ( TLN_SequencePack  sp,
TLN_Sequence  sequence 
)

Adds a sequence to a sequence pack.

Parameters
spReference to the sequence pack
sequenceReference to the sequence to attach
Remarks
Write remarks for TLN_AddSequenceToPack here.
See also
TLN_CreateSequencePack(), TLN_CreateSequence()

◆ TLN_DeleteSequencePack()

bool TLN_DeleteSequencePack ( TLN_SequencePack  sp)

Deletes the specified sequence pack and frees memory.

Parameters
spReference to the sequence pack to delete
Remarks
Don't delete a sequence pack that has sequences currently attached to animations! The attached sequences are also deleted, so they haven't to be deleted externally.
See also
TLN_LoadSequencePack()