FFmpeg
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
avdevice.c File Reference
#include "libavutil/avassert.h"
#include "avdevice.h"
#include "config.h"

Go to the source code of this file.

Macros

#define LICENSE_PREFIX   "libavdevice license: "
 

Functions

unsigned avdevice_version (void)
 Return the LIBAVDEVICE_VERSION_INT constant.
 
const char * avdevice_configuration (void)
 Return the libavdevice build-time configuration.
 
const char * avdevice_license (void)
 Return the libavdevice license.
 
int avdevice_app_to_dev_control_message (struct AVFormatContext *s, enum AVAppToDevMessageType type, void *data, size_t data_size)
 Send control message from application to device.
 
int avdevice_dev_to_app_control_message (struct AVFormatContext *s, enum AVDevToAppMessageType type, void *data, size_t data_size)
 Send control message from device to application.
 
int avdevice_list_devices (AVFormatContext *s, AVDeviceInfoList **device_list)
 List devices.
 
void avdevice_free_list_devices (AVDeviceInfoList **device_list)
 Convinient function to free result of avdevice_list_devices().
 

Macro Definition Documentation

#define LICENSE_PREFIX   "libavdevice license: "

Function Documentation

unsigned avdevice_version ( void  )

Return the LIBAVDEVICE_VERSION_INT constant.

Definition at line 23 of file avdevice.c.

const char* avdevice_configuration ( void  )

Return the libavdevice build-time configuration.

Definition at line 29 of file avdevice.c.

const char* avdevice_license ( void  )

Return the libavdevice license.

Definition at line 34 of file avdevice.c.

int avdevice_app_to_dev_control_message ( struct AVFormatContext s,
enum AVAppToDevMessageType  type,
void data,
size_t  data_size 
)

Send control message from application to device.

Parameters
sdevice context.
typemessage type.
datamessage data. Exact type depends on message type.
data_sizesize of message data.
Returns
>= 0 on success, negative on error. AVERROR(ENOSYS) when device doesn't implement handler of the message.

Definition at line 40 of file avdevice.c.

int avdevice_dev_to_app_control_message ( struct AVFormatContext s,
enum AVDevToAppMessageType  type,
void data,
size_t  data_size 
)

Send control message from device to application.

Parameters
sdevice context.
typemessage type.
datamessage data. Can be NULL.
data_sizesize of message data.
Returns
>= 0 on success, negative on error. AVERROR(ENOSYS) when application doesn't implement handler of the message.

Definition at line 48 of file avdevice.c.

Referenced by opengl_create_window(), opengl_draw(), opengl_release_window(), opengl_resize(), opengl_write_header(), and opengl_write_trailer().

int avdevice_list_devices ( struct AVFormatContext s,
AVDeviceInfoList **  device_list 
)

List devices.

Returns available device names and their parameters.

Note
: Some devices may accept system-dependent device names that cannot be autodetected. The list returned by this function cannot be assumed to be always completed.
Parameters
sdevice context.
[out]device_listlist of autodetected devices.
Returns
count of autodetected devices, negative on error.

Definition at line 56 of file avdevice.c.

void avdevice_free_list_devices ( AVDeviceInfoList **  device_list)

Convinient function to free result of avdevice_list_devices().

Parameters
devicesdevice list to be freed.

Definition at line 74 of file avdevice.c.