gmerlin-avdecoder
Data Structures | Functions
Device description

Device description. More...

Data Structures

struct  bgav_device_info_t
 Info structure for a device. More...
 

Functions

BGAV_PUBLIC bgav_device_info_tbgav_find_devices_vcd ()
 Scan for VCD capable devices. More...
 
BGAV_PUBLIC int bgav_check_device_vcd (const char *device, char **name)
 Test if a device is VCD capable. More...
 
BGAV_PUBLIC bgav_device_info_tbgav_find_devices_dvd ()
 Scan for DVD capable devices. More...
 
BGAV_PUBLIC int bgav_check_device_dvd (const char *device, char **name)
 Test if a device is DVD capable. More...
 
BGAV_PUBLIC bgav_device_info_tbgav_find_devices_dvb ()
 Scan for DVB capable devices. More...
 
BGAV_PUBLIC int bgav_check_device_dvb (const char *device, char **name)
 Test if a device is DVB capable. More...
 
BGAV_PUBLIC void bgav_device_info_destroy (bgav_device_info_t *arr)
 Destroy a device info array. More...
 
BGAV_PUBLIC int bgav_eject_disc (const char *device)
 Eject a disc. More...
 
BGAV_PUBLIC const char * bgav_get_disc_name (bgav_t *bgav)
 Get the name of a disc. More...
 

Detailed Description

Device description.

The input modules, which access special hardware devices (e.g. CD drives), have autoscanning functionality built in. You can call one of the bgav_find_devices_* functions to get a list of supported devices (see bgav_device_info_t). The created list must be freed with bgav_device_info_destroy when it's no longer used.

Function Documentation

BGAV_PUBLIC bgav_device_info_t* bgav_find_devices_vcd ( )

Scan for VCD capable devices.

Returns
A bgav_device_info_t array or NULL

Free the returned array with bgav_device_info_destroy

BGAV_PUBLIC int bgav_check_device_vcd ( const char *  device,
char **  name 
)

Test if a device is VCD capable.

Parameters
deviceThe device node name
nameReturns a human readable decription in a newly allocated string or NULL
Returns
1 if the device can play VCDs, 0 else.
BGAV_PUBLIC bgav_device_info_t* bgav_find_devices_dvd ( )

Scan for DVD capable devices.

Returns
A bgav_device_info_t array or NULL

Free the returned array with bgav_device_info_destroy

BGAV_PUBLIC int bgav_check_device_dvd ( const char *  device,
char **  name 
)

Test if a device is DVD capable.

Parameters
deviceThe device node name
nameReturns a human readable decription in a newly allocated string or NULL
Returns
1 if the device can play DVDs, 0 else.
BGAV_PUBLIC bgav_device_info_t* bgav_find_devices_dvb ( )

Scan for DVB capable devices.

Returns
A bgav_device_info_t array or NULL

Free the returned array with bgav_device_info_destroy

BGAV_PUBLIC int bgav_check_device_dvb ( const char *  device,
char **  name 
)

Test if a device is DVB capable.

Parameters
deviceThe directory (e.g. /dev/dvb/adaptor0)
nameReturns a human readable decription in a newly allocated string or NULL
Returns
1 if the device is ready to receive DVB streams, 0 else.
BGAV_PUBLIC void bgav_device_info_destroy ( bgav_device_info_t arr)

Destroy a device info array.

Parameters
arrA device info returned by bgav_find_devices_dvd, bgav_find_devices_dvb or bgav_find_devices_dvd
BGAV_PUBLIC int bgav_eject_disc ( const char *  device)

Eject a disc.

Parameters
deviceDevice name
Returns
1 if the disc could be ejected, 0 else
BGAV_PUBLIC const char* bgav_get_disc_name ( bgav_t bgav)

Get the name of a disc.

Parameters
bgavA decoder instance
Returns
The name of the disc, or NULL if it's not known or irrelevant