![]() |
![]() |
![]() |
LibRhythmCat Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Signals |
#include <rclib-album.h> struct RCLibAlbum; struct RCLibAlbumClass; enum RCLibAlbumType; void rclib_album_exit (); gboolean rclib_album_get_album_data (RCLibAlbumType *type
,gpointer *data
); GObject * rclib_album_get_instance (); void rclib_album_init (); gboolean rclib_album_save_file (const gchar *filename
); gulong rclib_album_signal_connect (const gchar *name
,GCallback callback
,gpointer data
); void rclib_album_signal_disconnect (gulong handler_id
);
The RCLibAlbum is a class which processes the album image. It can read album image from image files, or get the data from the metadata, and then send signals so that anyone who connected to the class can get the data.
struct RCLibAlbum;
The album processor. The contents of the RCLibAlbum structure are private and should only be accessed via the provided API.
typedef enum { RCLIB_ALBUM_TYPE_FILENAME, RCLIB_ALBUM_TYPE_BUFFER } RCLibAlbumType;
The enum type for the album data type.
the data is a filename (string) | |
the data is in GstBuffer type |
gboolean rclib_album_get_album_data (RCLibAlbumType *type
,gpointer *data
);
Get the album data.
|
the album data type. [out][allow-none] |
|
the album data. [out][allow-none] |
Returns : |
Whether the album data is set. |
GObject * rclib_album_get_instance ();
Get the running RCLibAlbum instance.
Returns : |
The running instance. [transfer none] |
gboolean rclib_album_save_file (const gchar *filename
);
Save the album image to a new image file.
|
the filename for the new album image |
Returns : |
Whether the operation is successful. |
gulong rclib_album_signal_connect (const gchar *name
,GCallback callback
,gpointer data
);
Connect the GCallback function to the given signal for the running instance of RCLibAlbum object.
|
the name of the signal |
|
the the GCallback to connect. [scope call] |
|
the user data |
Returns : |
The handler ID. |
void rclib_album_signal_disconnect (gulong handler_id
);
Disconnects a handler from the running RCLibAlbum instance so it will not be called during any future or currently ongoing emissions of the signal it has been connected to. The handler_id becomes invalid and may be reused.
|
handler id of the handler to be disconnected |
"album-found"
signalgboolean user_function (RCLibAlbum *album,
guint type,
gpointer album_data,
gpointer user_data) : Run Last
The ::album-found signal is emitted when the album file or data is found.
|
the RCLibAlbum that received the signal |
|
the data type |
|
the album data (filename or GstBuffer) |
|
user data set when the signal handler was connected. |
Returns : |
Whether the album data can be used, if not, the album data will not be saved in the player. |
"album-none"
signalvoid user_function (RCLibAlbum *album,
gpointer user_data) : Run First
The ::album-found signal is emitted if no album image file or data is found.
|
the RCLibAlbum that received the signal |
|
user data set when the signal handler was connected. |