libvlc_core
[libvlc]

Collaboration diagram for libvlc_core:
LibVLC Core. More...


Modules

 libvlc_exception
 LibVLC Exceptions handling.
 libvlc_error
 LibVLC error handling.
 libvlc_event
 LibVLC Events.
 libvlc_log
 LibVLC Message Logging.
 libvlc_time
 LibVLC Time support in libvlc.

Functions

libvlc_instance_tlibvlc_new (int, const char *const *, libvlc_exception_t *)
 Create and initialize a libvlc instance.
void libvlc_release (libvlc_instance_t *)
 Decrement the reference count of a libvlc instance, and destroy it if it reaches zero.
void libvlc_retain (libvlc_instance_t *)
 Increments the reference count of a libvlc instance.
int libvlc_add_intf (libvlc_instance_t *p_instance, const char *name, libvlc_exception_t *p_exception)
 Try to start a user interface for the libvlc instance.
void libvlc_wait (libvlc_instance_t *p_instance)
 Waits until an interface causes the instance to exit.
const char * libvlc_get_version (void)
 Retrieve libvlc version.
const char * libvlc_get_compiler (void)
 Retrieve libvlc compiler version.
const char * libvlc_get_changeset (void)
 Retrieve libvlc changeset.
struct vlc_object_tlibvlc_get_vlc_instance (libvlc_instance_t *p_instance)
 Get the internal main VLC object.
void libvlc_free (void *ptr)
 Frees an heap allocation (char *) returned by a LibVLC API.

Detailed Description

LibVLC Core.


Function Documentation

int libvlc_add_intf ( libvlc_instance_t p_instance,
const char *  name,
libvlc_exception_t p_exception 
)

Try to start a user interface for the libvlc instance.

Parameters:
p_instance the instance
name interface name, or NULL for default
p_exception an initialized exception pointer
Returns:
0 on success, -1 on error.

References libvlc_exception_raise(), libvlc_InternalAddIntf(), libvlc_printerr(), and libvlc_instance_t::p_libvlc_int.

void libvlc_free ( void *  ptr  ) 

Frees an heap allocation (char *) returned by a LibVLC API.

If you know you're using the same underlying C run-time as the LibVLC implementation, then you can call ANSI C free() directly instead.

Parameters:
ptr the pointer

const char* libvlc_get_changeset ( void   ) 

Retrieve libvlc changeset.

Example: "aa9bce0bc4"

Returns:
a string containing the libvlc changeset

const char* libvlc_get_compiler ( void   ) 

Retrieve libvlc compiler version.

Example: "gcc version 4.2.3 (Ubuntu 4.2.3-2ubuntu6)"

Returns:
a string containing the libvlc compiler version

References VLC_Compiler().

const char* libvlc_get_version ( void   ) 

Retrieve libvlc version.

Example: "0.9.0-git Grishenko"

Returns:
a string containing the libvlc version

References VLC_Version().

struct vlc_object_t* libvlc_get_vlc_instance ( libvlc_instance_t p_instance  )  [read]

Get the internal main VLC object.

Use of this function is usually a hack and should be avoided.

Note:
You will need to link with libvlccore to make any use of the underlying VLC object. The libvlccore programming and binary interfaces are not stable.
Warning:
Remember to release the object with vlc_object_release().
Parameters:
p_instance the libvlc instance
Returns:
a VLC object of type "libvlc"

References libvlc_instance_t::p_libvlc_int, and vlc_object_hold.

libvlc_instance_t* libvlc_new ( int  ,
const char *const *  ,
libvlc_exception_t  
)

Create and initialize a libvlc instance.

Parameters:
argc the number of arguments
argv command-line-type arguments. argv[0] must be the path of the calling program.
p_e an initialized exception pointer
Returns:
the libvlc instance

Todo:
Look for interface settings. If we don't have any, add -I dummy

References i, libvlc_instance_t::instance_lock, libvlc_deinit_threads(), libvlc_init_threads(), libvlc_InternalCreate(), libvlc_InternalDestroy(), libvlc_InternalInit(), libvlc_instance_t::libvlc_vlm, libvlc_instance_t::p_callback_list, libvlc_vlm_t::p_event_manager, libvlc_instance_t::p_libvlc_int, libvlc_vlm_t::p_vlm, libvlc_vlm_t::pf_release, RAISENULL, libvlc_instance_t::ref_count, libvlc_instance_t::verbosity, VLC_EEXITSUCCESS, and vlc_mutex_init().

Referenced by mediacontrol_new().

void libvlc_release ( libvlc_instance_t  ) 

void libvlc_retain ( libvlc_instance_t  ) 

Increments the reference count of a libvlc instance.

The initial reference count is 1 after libvlc_new() returns.

Parameters:
p_instance the instance to reference

References libvlc_instance_t::instance_lock, libvlc_instance_t::ref_count, vlc_mutex_lock(), and vlc_mutex_unlock().

Referenced by libvlc_event_manager_new(), libvlc_log_open(), and libvlc_media_list_player_new().

void libvlc_wait ( libvlc_instance_t p_instance  ) 

Waits until an interface causes the instance to exit.

You should start at least one interface first, using libvlc_add_intf().

Parameters:
p_instance the instance

References libvlc_InternalWait(), and libvlc_instance_t::p_libvlc_int.


Generated on Fri Nov 20 08:05:49 2009 for VLC by  doxygen 1.5.6