Libdaisy is a toolkit for parsing and playing Daisy Digital Talking Books (DTB).
Go to the source code of this file.
Typedefs | |
typedef void * | daisyplayer_t |
This will need to be initialized and passed along to the daisy functions. | |
Enumerations | |
enum | daisy_status { DAISY_ERROR_UNKNOWN = 0x0000, DAISY_ERROR_AUDIO_NOT_INITIALIZED = 0x0200, DAISY_ERROR_AUDIO_CREATE_MMAP = 0x0201, DAISY_ERROR_AUDIO_FSTAT = 0x0202, DAISY_ERROR_AUDIO_OPEN = 0x0203, DAISY_ERROR_AUDIO_FREE_MMAP = 0x0204, DAISY_ERROR_AUDIO_INITIATE_DATA = 0x0205, DAISY_ERROR_AUDIO_NOT_PLAYING = 0x0206, DAISY_ERROR_AUDIO_NOT_STOPPED = 0x0207, DAISY_ERROR_AUDIO_DATA_IS_NULL = 0x0208, DAISY_ERROR_AUDIO_MALLOC = 0x0209, DAISY_ERROR_AUDIO_PAUSED_WHILE_NOT_PLAYING = 0x0210, DAISY_ERROR_AUDIO_STOPPED_WHILE_NOT_PLAYING = 0x0211, DAISY_ERROR_PLAYBACK_NO_TEXT_IN_SEGMENT = 0x0301, DAISY_ERROR_PLAYBACK_NO_AUDIO_IN_SEGMENT = 0x0302, DAISY_ERROR_PLAYBACK_NO_DTB_LOADED = 0x0303, DAISY_ERROR_PLAYBACK_SEEK_FAILED = 0x0304, DAISY_ERROR_MISC_INIT_MUTEX = 0x0400, DAISY_END_OF_BOOK = 0x1100 } |
The different sort of status messages libdaisy might return. More... | |
enum | daisy_seek_option { DAISY_SEEK_PREV_CHAPTER = 1, DAISY_SEEK_PREV_PASSAGE = 2, DAISY_SEEK_NEXT_CHAPTER = 3, DAISY_SEEK_NEXT_PASSAGE = 4, DAISY_SEEK_TO_BEGINNING = 5 } |
The different seek operations supported by the engine. More... | |
enum | daisy_bookinfo_option { DAISY_BOOKINFO_TITLETEXT = 1, DAISY_BOOKINFO_TITLEIMAGE = 2, DAISY_BOOKINFO_TOTALTIME = 3 } |
The different types of book information. More... | |
enum | daisy_chapter_info { DAISY_CHAPTER_TITLE = 1, DAISY_CHAPTER_WEIGHT = 2 } |
The different types of chapter information. More... | |
Functions | |
daisyplayer_t | daisy_init (void *data, void(*l_cb_daisy_audio_done)(void *), void(*l_cb_daisy_audio_next)(void *, unsigned long int), void(*l_cb_daisy_text)(void *, void *), void(*l_cb_daisy_id)(void *, void *), void(*l_cb_daisy_error)(void *, enum daisy_status, const char *daisy_status_msg), void(*l_cb_daisy_progress)(void *, long int)) |
Initializes the daisy library. | |
void | daisy_term (daisyplayer_t daisy) |
Terminates the daisy library and frees memory used by it. | |
int | daisy_load (daisyplayer_t daisy, char *path) |
Loads a new daisy book. | |
int | daisy_play (daisyplayer_t daisy) |
Starts playback if a book is loaded. | |
int | daisy_seek (daisyplayer_t daisy, int seek_option) |
Seek operations which can be performed when a book is loaded. | |
daisy_position * | daisy_get_position (daisyplayer_t daisy) |
Retrieves the current playback position. | |
int | daisy_goto_position (daisyplayer_t daisy, daisy_position *position) |
Seeks to a playback position (bookmark) and continue playback from there. | |
int | daisy_stop (daisyplayer_t daisy) |
Stops playback. | |
int | daisy_pause (daisyplayer_t daisy) |
Toggle pause. | |
char * | daisy_get_info (daisyplayer_t daisy, int value) |
Retrieves book meta information. | |
int | daisy_get_chapter_count (daisyplayer_t daisy) |
Retrieves the number of chapters in in the loaded Daisy DTB. | |
char * | daisy_get_chapter_info (daisyplayer_t daisy, int num, int option) |
Retrieves information about a given chapter. |
|
This will need to be initialized and passed along to the daisy functions.
|
|
The different types of book information.
|
|
The different types of chapter information.
|
|
The different seek operations supported by the engine.
|
|
|
Retrieves the number of chapters in in the loaded Daisy DTB.
|
|
Retrieves information about a given chapter.
|
|
Retrieves book meta information.
|
|
Retrieves the current playback position.
|
|
Seeks to a playback position (bookmark) and continue playback from there.
|
|
Initializes the daisy library. It should be called before any attempt to use the daisy functionality.
|
|
Loads a new daisy book.
|
|
Toggle pause. Pauses playback if state is playing and continues playing of state is paused.
|
|
Starts playback if a book is loaded.
|
|
Seek operations which can be performed when a book is loaded.
|
|
Stops playback.
|
|
Terminates the daisy library and frees memory used by it. It should be called when daisy are no longer needed.
|