![]() |
![]() |
![]() |
libunicapgtk Reference Manual | ![]() |
---|---|---|---|---|
enum UnicapgtkDeviceStateFlags; gchar* unicapgtk_get_user_config_path (void); GKeyFile* unicapgtk_save_device_state (unicap_handle_t handle, UnicapgtkDeviceStateFlags flags); gboolean unicapgtk_load_device_state (unicap_handle_t handle, GKeyFile *keyfile, UnicapgtkDeviceStateFlags flags); unicap_status_t unicapgtk_check_version (unsigned int major, unsigned int minor, unsigned int micro);
typedef enum { UNICAPGTK_DEVICE_STATE_VIDEO_FORMAT = 1 << 0, UNICAPGTK_DEVICE_STATE_PROPERTIES = 1 << 1, }UnicapgtkDeviceStateFlags;
gchar* unicapgtk_get_user_config_path (void);
Get path to the directory containing the configuration files
Returns : |
Path to configuration directory |
GKeyFile* unicapgtk_save_device_state (unicap_handle_t handle, UnicapgtkDeviceStateFlags flags);
Saves the current device state. If UNICAPGTK_DEVICE_STATE_VIDEO_FORMAT is set in the flags
field, a section containing information about
the current video format is added to the configuration file. If UNICAPGTK_DEVICE_STATE_PROPERTIES is set, a section containing the current
state of the device properties is added to the configuration file.
|
unicap handle |
|
flags |
Returns : |
A newly allocated GKeyfile. Must be freed with g_key_file_free() by the application.
|
gboolean unicapgtk_load_device_state (unicap_handle_t handle, GKeyFile *keyfile, UnicapgtkDeviceStateFlags flags);
|
handle of the device |
|
GKeyFile to load the device state information from |
|
UnicapgtkDeviceStateFlags specifying what parts to configure Reads device state information from a key-file and sets the parameters of a device accordingly. |
Returns : |
unicap_status_t unicapgtk_check_version (unsigned int major, unsigned int minor, unsigned int micro);
Checks whether the installed library version is newer or equal to the given version
|
Major version to check |
|
Minor version to check |
|
Micro version to check |
Returns : |
STATUS_INCOMPATIBLE_MAJOR_VERSION if the given major version is too old STATUS_INCOMPATIBLE_MINOR_VERSION if the given minor version is too old STATUS_INCOMPATIBLE_MACRO_VERSION if the given macro version is too old STATUS_SUCCESS if the version is compatible |