VLC  3.0.0-git
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Modules | Files | Data Structures | Macros | Functions
VLC objects
Collaboration diagram for VLC objects:


 VLC object variables and callbacks.


file  vlc_objects.h
 Common VLC object defintions.

Data Structures

struct  vlc_object_t
 The main vlc_object_t structure. More...


#define OBJECT_FLAGS_QUIET   0x0002
#define vlc_object_get_name(o)   vlc_object_get_name(VLC_OBJECT(o))
#define vlc_object_create(a, b)   vlc_object_create( VLC_OBJECT(a), b )
#define vlc_object_find_name(a, b)   vlc_object_find_name( VLC_OBJECT(a),b)
#define vlc_object_hold(a)   vlc_object_hold( VLC_OBJECT(a) )
#define vlc_object_release(a)   vlc_object_release( VLC_OBJECT(a) )
#define vlc_list_children(a)   vlc_list_children( VLC_OBJECT(a) )


void * vlc_object_create (vlc_object_t *, size_t)
 Allocates and initializes a vlc object. More...
vlc_object_tvlc_object_find_name (vlc_object_t *, const char *)
 Finds a named object and increment its reference count. More...
void * vlc_object_hold (vlc_object_t *)
 Increment an object reference counter. More...
void vlc_object_release (vlc_object_t *)
 Drops a reference to an object (decrements the reference count). More...
vlc_list_tvlc_list_children (vlc_object_t *)
 Gets the list of children of an object, and increment their reference count. More...
void vlc_list_release (vlc_list_t *)
char * vlc_object_get_name (const vlc_object_t *)

Detailed Description

Macro Definition Documentation

#define OBJECT_FLAGS_QUIET   0x0002

Referenced by Create(), and vlc_vaLog().

#define vlc_list_children (   a)    vlc_list_children( VLC_OBJECT(a) )
#define vlc_object_create (   a,
)    vlc_object_create( VLC_OBJECT(a), b )

Referenced by vlm_MediaInstanceNew().

#define vlc_object_find_name (   a,
)    vlc_object_find_name( VLC_OBJECT(a),b)
#define vlc_object_get_name (   o)    vlc_object_get_name(VLC_OBJECT(o))
#define vlc_object_hold (   a)    vlc_object_hold( VLC_OBJECT(a) )
#define vlc_object_release (   a)    vlc_object_release( VLC_OBJECT(a) )

Referenced by access_New(), addons_manager_WriteCatalog(), aout_Destroy(), aout_FiltersPipelineDestroy(), aout_New(), aout_volume_Delete(), AppendFilter(), Create(), CreateDecoder(), CreateFilter(), DecoderProcessFlush(), DecoderProcessSpu(), DeleteDecoder(), DeleteEncoder(), DeleteFilter(), demux_Delete(), demux_NewAdvanced(), demux_PacketizerDestroy(), demux_PacketizerNew(), dialog_ExtensionUpdate(), dialog_Login(), dialog_ProgressCreate(), dialog_Question(), dialog_VFatal(), FetchMeta(), filter_chain_AppendFilter(), filter_chain_DeleteFilter(), filter_DeleteBlend(), FilterRelease(), FindArt(), FinderThread(), fingerprinter_Create(), fingerprinter_Destroy(), httpd_HostCreate(), httpd_HostDelete(), input_AddSubtitleOSD(), input_Close(), input_CreateAndStart(), input_GetVout(), input_item_WriteMeta(), input_Read(), InputSourceDestroy(), InputSourceMeta(), InputSourceNew(), installOrRemoveAddon(), intf_Create(), intf_DestroyAll(), libvlc_InternalDestroy(), LoadLocalStorage(), PlayItem(), playlist_Destroy(), playlist_EnableAudioFilter(), playlist_Export(), playlist_MuteGet(), playlist_MuteSet(), playlist_VolumeGet(), playlist_VolumeSet(), playlist_VolumeUp(), sout_AccessOutDelete(), sout_AccessOutNew(), sout_DeleteInstance(), sout_InputNew(), sout_MuxDelete(), sout_MuxNew(), sout_NewInstance(), sout_StreamDelete(), spu_Destroy(), spu_new_buffer(), str_format_meta(), stream_CommonDelete(), video_splitter_Delete(), vlc_access_Delete(), vlc_gl_Create(), vlc_gl_Destroy(), vlc_inhibit_Create(), vlc_inhibit_Destroy(), vlc_LogDeinit(), vlc_probe(), vlc_sd_Destroy(), vlc_tls_ClientCreate(), vlc_tls_Delete(), vlc_tls_ServerCreate(), vlc_tls_SessionCreate(), vlc_tls_SessionDelete(), vlm_ControlMediaAdd(), vlm_Delete(), vlm_MediaInstanceDelete(), vlm_New(), vout_CloseAndRelease(), vout_display_Delete(), vout_display_New(), vout_window_Delete(), vout_window_New(), VoutCreate(), xml_Create(), xml_Delete(), xml_ReaderCreate(), xml_ReaderDelete(), and xml_ReaderReset().

Function Documentation

vlc_list_t* vlc_list_children ( vlc_object_t obj)

Gets the list of children of an object, and increment their reference count.

a list (possibly empty) or NULL in case of error.

References count, vlc_list_t::i_count, vlc_object_internals::next, vlc_value_t::p_address, vlc_list_t::p_values, unlikely, vlc_externals, vlc_internals, vlc_mutex_lock(), vlc_mutex_unlock(), and vlc_object_hold().

void vlc_list_release ( vlc_list_t )
void* vlc_object_create ( vlc_object_t p_this,
size_t  i_size 

Allocates and initializes a vlc object.

i_sizeobject byte size
the new object, or NULL on error.

References vlc_custom_create().

vlc_object_t* vlc_object_find_name ( vlc_object_t p_this,
const char *  psz_name 

Finds a named object and increment its reference count.

Beware that objects found in this manner can be "owned" by another thread, be of any type, and be attached to any module (if any). With such an object reference, you can set or get object variables, emit log messages, and read write-once object parameters (psz_object_type, etc). You CANNOT cast the object to a more specific object type, and you definitely cannot invoke object type-specific callbacks with this.

p_thisobject to search from
psz_namename of the object to search for
a matching object (must be released by the caller), or NULL on error.

References FindName(), msg_Err, name_lock, vlc_mutex_lock(), and vlc_mutex_unlock().

char* vlc_object_get_name ( const vlc_object_t )
void* vlc_object_hold ( vlc_object_t )

Increment an object reference counter.

References atomic_fetch_add, vlc_object_internals::refs, and vlc_internals.

Referenced by FindName(), ObjectExists(), VarsCommand(), vlc_custom_create(), and vlc_list_children().

void vlc_object_release ( vlc_object_t obj)