Commit 2a227b41 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont
Browse files

libvlc_run_interface: start and wait for an interface

parent debfaaa1
......@@ -145,6 +145,18 @@ VLC_PUBLIC_API void libvlc_release( libvlc_instance_t * );
*/
VLC_PUBLIC_API void libvlc_retain( libvlc_instance_t * );
/**
* Try to start a user interface for the libvlc instance, and wait until the
* user exits.
*
* \param p_instance the instance
* \param name interface name, or NULL for default
* \param p_exception an initialized exception pointer
*/
VLC_PUBLIC_API
void libvlc_run_interface( libvlc_instance_t *p_instance, const char *name,
libvlc_exception_t *p_exception );
/**
* Retrieve libvlc version.
*
......
......@@ -170,6 +170,13 @@ void libvlc_release( libvlc_instance_t *p_instance )
}
}
void libvlc_run_interface( libvlc_instance_t *p_i, const char *name,
libvlc_exception_t *p_e )
{
if( libvlc_InternalAddIntf( p_i->p_libvlc_int, name, true, true, 0, NULL ) )
RAISEVOID( "Interface initialization failed" );
}
int libvlc_get_vlc_id( libvlc_instance_t *p_instance )
{
return p_instance->p_libvlc_int->i_object_id;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment