VLC
3.0.15
|
Macros | |
#define | SLAVE_ADD_NOFLAG 0 |
#define | SLAVE_ADD_FORCED (1<<0) |
#define | SLAVE_ADD_CANFAIL (1<<1) |
#define | SLAVE_ADD_SET_TIME (1<<2) |
#define | INIT_COUNTER(c, compute) |
#define | EXIT_COUNTER(c) |
#define | CL_CO(c) |
#define | I(c) stats_Update( input_priv(p_input)->counters.c, i_delta, NULL ) |
Functions | |
static void * | Run (void *) |
static void * | Preparse (void *) |
static input_thread_t * | Create (vlc_object_t *, input_item_t *, const char *, bool, input_resource_t *, vlc_renderer_item_t *) |
static int | Init (input_thread_t *p_input) |
static void | End (input_thread_t *p_input) |
static void | MainLoop (input_thread_t *p_input, bool b_interactive) |
MainLoop The main input loop. More... | |
static int | ControlPop (input_thread_t *, int *, vlc_value_t *, mtime_t i_deadline, bool b_postpone_seek) |
static void | ControlRelease (int i_type, vlc_value_t val) |
static bool | ControlIsSeekRequest (int i_type) |
static bool | Control (input_thread_t *, int, vlc_value_t) |
static void | ControlPause (input_thread_t *, mtime_t) |
static int | UpdateTitleSeekpointFromDemux (input_thread_t *) |
static void | UpdateGenericFromDemux (input_thread_t *) |
static void | UpdateTitleListfromDemux (input_thread_t *) |
static void | MRLSections (const char *, int *, int *, int *, int *) |
static input_source_t * | InputSourceNew (input_thread_t *, const char *, const char *psz_forced_demux, bool b_in_can_fail) |
static void | InputSourceDestroy (input_source_t *) |
static void | InputSourceMeta (input_thread_t *, input_source_t *, vlc_meta_t *) |
static void | SlaveDemux (input_thread_t *p_input) |
static void | SlaveSeek (input_thread_t *p_input) |
static void | InputMetaUser (input_thread_t *p_input, vlc_meta_t *p_meta) |
static void | InputUpdateMeta (input_thread_t *p_input, demux_t *p_demux) |
static void | InputGetExtraFiles (input_thread_t *p_input, int *pi_list, char ***pppsz_list, const char **psz_access, const char *psz_path) |
static void | AppendAttachment (int *pi_attachment, input_attachment_t ***ppp_attachment, const demux_t ***ppp_attachment_demux, int i_new, input_attachment_t **pp_new, const demux_t *p_demux) |
static int | input_SlaveSourceAdd (input_thread_t *, enum slave_type, const char *, unsigned) |
static char * | input_SubtitleFile2Uri (input_thread_t *, const char *) |
static void | input_ChangeState (input_thread_t *p_input, int i_state) |
input_thread_t * | input_Create (vlc_object_t *p_parent, input_item_t *p_item, const char *psz_log, input_resource_t *p_resource, vlc_renderer_item_t *p_renderer) |
Create a new input_thread_t. More... | |
int | input_Read (vlc_object_t *p_parent, input_item_t *p_item) |
Initialize an input thread and run it until it stops by itself. More... | |
input_thread_t * | input_CreatePreparser (vlc_object_t *parent, input_item_t *item) |
Creates an item preparser. More... | |
int | input_Start (input_thread_t *p_input) |
Start a input_thread_t created by input_Create. More... | |
void | input_Stop (input_thread_t *p_input) |
Request a running input thread to stop and die. More... | |
void | input_Close (input_thread_t *p_input) |
Close an input. More... | |
static void | input_Destructor (vlc_object_t *obj) |
Input destructor (called when the object's refcount reaches 0). More... | |
input_item_t * | input_GetItem (input_thread_t *p_input) |
Get the item from an input thread FIXME it does not increase ref count of the item. More... | |
bool | input_Stopped (input_thread_t *input) |
static void | MainLoopDemux (input_thread_t *p_input, bool *pb_changed) |
MainLoopDemux It asks the demuxer to demux some data. More... | |
static int | MainLoopTryRepeat (input_thread_t *p_input) |
static void | MainLoopStatistics (input_thread_t *p_input) |
Update timing infos and statistics. More... | |
static void | InitStatistics (input_thread_t *p_input) |
static void | InitTitle (input_thread_t *p_input) |
static void | StartTitle (input_thread_t *p_input) |
static int | SlaveCompare (const void *a, const void *b) |
static bool | SlaveExists (input_item_slave_t **pp_slaves, int i_slaves, const char *psz_uri) |
static void | SetSubtitlesOptions (input_thread_t *p_input) |
static void | GetVarSlaves (input_thread_t *p_input, input_item_slave_t ***ppp_slaves, int *p_slaves) |
static void | LoadSlaves (input_thread_t *p_input) |
static void | UpdatePtsDelay (input_thread_t *p_input) |
static void | InitPrograms (input_thread_t *p_input) |
void | input_ControlPush (input_thread_t *p_input, int i_type, vlc_value_t *p_val) |
static int | ControlGetReducedIndexLocked (input_thread_t *p_input) |
static void | ControlUnpause (input_thread_t *p_input, mtime_t i_control_date) |
static void | ViewpointApply (input_thread_t *p_input) |
static void | ControlNavDisplayVolume (vout_thread_t *p_vout, float vol) |
static void | ControlNavDisplayPosition (vout_thread_t *p_vout, input_thread_t *p_input) |
static void | ControlNav (input_thread_t *p_input, int i_type) |
static void | ControlInsertDemuxFilter (input_thread_t *p_input, const char *psz_demux_chain) |
static int | UpdateTitleSeekpoint (input_thread_t *p_input, int i_title, int i_seekpoint) |
static int | InputStreamHandleAnchor (input_source_t *source, stream_t **stream, char const *anchor) |
static demux_t * | InputDemuxNew (input_thread_t *p_input, input_source_t *p_source, const char *psz_access, const char *psz_demux, const char *psz_path, const char *psz_anchor) |
static void | InputGetExtraFilesPattern (input_thread_t *p_input, int *pi_list, char ***pppsz_list, const char *psz_path, const char *psz_match, const char *psz_format, int i_start, int i_stop) |
void | input_SplitMRL (const char **access, const char **demux, const char **path, const char **anchor, char *buf) |
static const char * | MRLSeekPoint (const char *str, int *title, int *chapter) |
void | input_UpdateStatistic (input_thread_t *p_input, input_statistic_t i_type, int i_delta) |
It will update internal input statistics from external sources. More... | |
char * | input_CreateFilename (input_thread_t *input, const char *dir, const char *filenamefmt, const char *ext) |
This function creates a sane filename path. More... | |
#define CL_CO | ( | c | ) |
#define EXIT_COUNTER | ( | c | ) |
#define I | ( | c | ) | stats_Update( input_priv(p_input)->counters.c, i_delta, NULL ) |
#define INIT_COUNTER | ( | c, | |
compute | |||
) |
#define SLAVE_ADD_CANFAIL (1<<1) |
#define SLAVE_ADD_FORCED (1<<0) |
#define SLAVE_ADD_NOFLAG 0 |
#define SLAVE_ADD_SET_TIME (1<<2) |
|
static |
References EnsureUTF8(), psz_name, var_GetNonEmptyString, and vlc_meta_Set().
|
static |
< No error
Referenced by MainLoop().
|
static |
|
static |
|
static |
Referenced by MainLoop().
|
static |
References vout_OSDMessage(), and VOUT_SPU_CHANNEL_OSD.
|
static |
References _, vout_FlushSubpictureChannel(), vout_OSDMessage(), and VOUT_SPU_CHANNEL_OSD.
|
static |
|
static |
Referenced by MainLoop().
|
inlinestatic |
|
static |
Referenced by input_Destructor(), and input_Stop().
|
static |
|
static |
References atof(), input_thread_private_t::attachment, input_thread_private_t::attachment_demux, input_thread_private_t::b_can_pace_control, input_thread_private_t::b_out_pace_control, input_item_t::b_preparse_interact, input_thread_private_t::b_preparsing, input_thread_private_t::b_recording, input_thread_private_t::bookmark, CLOCK_FREQ, input_thread_private_t::counters, input_thread_private_t::counters_lock, vlc_common_members::flags, vlc_common_members::header, input_thread_private_t::i_attachment, input_thread_private_t::i_bookmark, input_thread_private_t::i_control, input_item_t::i_preparse_depth, input_thread_private_t::i_rate, input_thread_private_t::i_seekpoint_offset, input_thread_private_t::i_slave, input_thread_private_t::i_start, input_thread_private_t::i_state, input_thread_private_t::i_stop, input_thread_private_t::i_time, seekpoint_t::i_time_offset, input_thread_private_t::i_title, input_thread_private_t::i_title_offset, INIT_S, input_thread_private_t::input, INPUT_ADD_BOOKMARK, input_ConfigVarInit(), input_Control(), input_ControlVarInit(), input_Destructor(), input_EsOutNew(), input_item_ApplyOptions(), input_item_GetName(), input_item_Hold(), input_item_SetESNowPlaying(), input_item_SetNowPlaying(), input_priv(), INPUT_RATE_DEFAULT, input_resource_Hold(), input_resource_New(), input_resource_SetInput(), input_SendEventMeta(), input_thread_private_t::interrupt, input_thread_private_t::is_running, input_thread_private_t::is_stopped, input_item_t::lock, input_thread_private_t::lock_control, input_thread_private_t::master, msg_Dbg, input_thread_t::obj, OBJECT_FLAGS_NOINTERACT, OBJECT_FLAGS_QUIET, input_thread_private_t::p_es_out, input_thread_private_t::p_es_out_display, input_thread_private_t::p_item, input_thread_private_t::p_renderer, input_thread_private_t::p_resource, input_thread_private_t::p_resource_private, input_thread_private_t::p_sout, input_item_t::p_stats, input_thread_private_t::pp_bookmark, seekpoint_t::psz_name, psz_name, input_thread_private_t::slave, stats_NewInputStats(), strcasecmp(), strdup(), TAB_INIT, input_thread_private_t::title, unlikely, var_GetNonEmptyString, var_InheritAddress, var_InheritBool, var_InheritString, input_thread_private_t::viewpoint, input_thread_private_t::viewpoint_changed, vlc_cond_init(), vlc_custom_create, vlc_interrupt_init(), vlc_mutex_init(), vlc_mutex_lock(), vlc_mutex_unlock(), VLC_OBJECT, vlc_object_set_destructor, vlc_renderer_item_hold(), vlc_seekpoint_Delete(), vlc_seekpoint_New(), vlc_viewpoint_init(), and input_thread_private_t::wait_control.
Referenced by input_Create(), input_CreatePreparser(), and input_Read().
|
static |
Referenced by input_Read(), and Run().
|
static |
< No error
|
static |
|
static |
|
static |
|
static |
|
static |
References InputGetExtraFilesPattern().
Referenced by input_Start(), and MainLoopDemux().
void input_Close | ( | input_thread_t * | p_input | ) |
Close an input.
It does not call input_Stop itself.
References input_priv(), thread, vlc_interrupt_deinit(), vlc_join(), and vlc_object_release.
Referenced by PreparserCloseInput().
void input_ControlPush | ( | input_thread_t * | p_input, |
int | i_type, | ||
vlc_value_t * | p_val | ||
) |
Referenced by BookmarkCallback(), FrameNextCallback(), input_vaControl(), PositionCallback(), RateCallback(), RecordCallback(), and TitleCallback().
input_thread_t* input_Create | ( | vlc_object_t * | p_parent, |
input_item_t * | p_item, | ||
const char * | psz_log, | ||
input_resource_t * | p_resource, | ||
vlc_renderer_item_t * | p_renderer | ||
) |
Create a new input_thread_t.
You need to call input_Start on it when you are done adding callback on the variables/events you want to monitor.
p_parent | a vlc_object |
p_item | an input item |
psz_log | an optional prefix for this input logs |
p_resource | an optional input ressource |
References Create().
char* input_CreateFilename | ( | input_thread_t * | input, |
const char * | dir, | ||
const char * | filenamefmt, | ||
const char * | ext | ||
) |
This function creates a sane filename path.
References input_priv(), input_thread_private_t::p_sout_send_bitrate, input_thread_private_t::p_sout_sent_bytes, and stats_Update().
input_thread_t* input_CreatePreparser | ( | vlc_object_t * | obj, |
input_item_t * | item | ||
) |
Creates an item preparser.
Creates an input thread to preparse an item. The input needs to be started with input_Start() afterwards.
obj | parent object |
item | input item to preparse |
References Create().
|
static |
Input destructor (called when the object's refcount reaches 0).
References input_thread_private_t::control, ControlRelease(), input_thread_private_t::counters, input_thread_private_t::counters_lock, es_out_Delete(), input_thread_private_t::i_control, input_control_t::i_type, input_item_GetName(), input_item_Release(), input_priv(), input_resource_Release(), input_thread_private_t::lock_control, msg_Dbg, input_thread_private_t::p_es_out_display, input_thread_private_t::p_item, input_thread_private_t::p_renderer, input_thread_private_t::p_resource, input_thread_private_t::p_resource_private, psz_name, input_control_t::val, vlc_cond_destroy(), vlc_mutex_destroy(), vlc_renderer_item_release(), and input_thread_private_t::wait_control.
Referenced by Create().
input_item_t* input_GetItem | ( | input_thread_t * | p_input | ) |
Get the item from an input thread FIXME it does not increase ref count of the item.
Get the input item for an input thread.
if it is used after p_input is destroyed nothing prevent it from being freed.
References input_priv(), and input_thread_private_t::p_item.
int input_Read | ( | vlc_object_t * | p_parent, |
input_item_t * | p_item | ||
) |
Initialize an input thread and run it until it stops by itself.
p_parent | a vlc_object |
p_item | an input item |
< Unspecified error
< No error
References Create(), End(), Init(), MainLoop(), VLC_EGENERIC, vlc_object_release, and VLC_SUCCESS.
|
static |
< Unspecified error
< Unspecified error
< Unspecified error
< No error
< No error
< No error
void input_SplitMRL | ( | const char ** | access, |
const char ** | demux, | ||
const char ** | path, | ||
const char ** | anchor, | ||
char * | buf | ||
) |
int input_Start | ( | input_thread_t * | p_input | ) |
Start a input_thread_t created by input_Create.
You must not start an already running input_thread_t.
the | input thread to start |
< Unspecified error
< No error
References input_thread_private_t::b_preparsing, ERROR_S, input_ChangeState(), input_priv(), input_thread_private_t::is_running, msg_Err, Preparse(), Run(), input_thread_private_t::thread, vlc_clone(), VLC_EGENERIC, VLC_SUCCESS, and VLC_THREAD_PRIORITY_INPUT.
Referenced by PlayItem().
void input_Stop | ( | input_thread_t * | p_input | ) |
Request a running input thread to stop and die.
p_input | the input thread to stop |
References input_thread_private_t::control, ControlRelease(), input_thread_private_t::i_control, input_control_t::i_type, input_priv(), input_thread_private_t::interrupt, input_thread_private_t::is_stopped, input_thread_private_t::lock_control, input_control_t::val, vlc_cond_signal(), vlc_interrupt_kill(), vlc_mutex_lock(), vlc_mutex_unlock(), and input_thread_private_t::wait_control.
Referenced by PreparserCloseInput().
bool input_Stopped | ( | input_thread_t * | input | ) |
Referenced by MainLoop().
|
static |
References count, es_out_Control(), ES_OUT_SET_ES_BY_ID, ES_OUT_SET_ES_DEFAULT_BY_ID, input_priv(), and list.
void input_UpdateStatistic | ( | input_thread_t * | , |
input_statistic_t | , | ||
int | i_delta | ||
) |
It will update internal input statistics from external sources.
XXX For now, the only one allowed to do it is stream_out and input core.
References msg_Dbg.
|
static |
|
static |
|
static |
Referenced by input_ChangeState().
|
static |
|
static |
|
static |
|
static |
|
static |
< Unspecified error
< No error
|
static |
|
static |
< No error
< No error
< No error
|
static |
MainLoop The main input loop.
References input_source_t::b_eof, Control(), ControlIsSeekRequest(), ControlPause(), ControlPop(), ERROR_S, es_out_GetBuffering(), es_out_GetEmpty(), es_out_GetWakeup(), vlc_value_t::i_int, input_thread_private_t::i_state, i_type, INPUT_CONTROL_SET_STATE, INPUT_IDLE_SLEEP, input_priv(), input_Stopped(), MainLoopDemux(), MainLoopStatistics(), MainLoopTryRepeat(), input_thread_private_t::master, mdate(), msg_Dbg, input_source_t::p_demux, PAUSE_S, demux_t::pf_demux, and var_InheritBool.
Referenced by input_Read(), and Run().
|
static |
MainLoopDemux It asks the demuxer to demux some data.
References input_source_t::b_eof, input_source_t::b_title_demux, demux_Control(), demux_Demux(), DEMUX_GET_TIME, demux_TestAndClearFlags(), ERROR_S, es_out_Eos(), input_thread_private_t::i_stop, input_thread_private_t::i_time, input_ChangeState(), input_priv(), INPUT_UPDATE_TITLE_LIST, input_thread_private_t::master, msg_Dbg, input_source_t::p_demux, input_thread_private_t::p_es_out, UpdateGenericFromDemux(), UpdateTitleListfromDemux(), UpdateTitleSeekpointFromDemux(), VLC_DEMUXER_EGENERIC, VLC_DEMUXER_EOF, and VLC_DEMUXER_SUCCESS.
Referenced by MainLoop().
|
static |
Update timing infos and statistics.
References input_thread_private_t::bookmark, demux_Control(), DEMUX_GET_LENGTH, DEMUX_GET_POSITION, DEMUX_GET_TIME, es_out_SetTimes(), input_thread_private_t::i_time, seekpoint_t::i_time_offset, input_priv(), input_SendEventStatistics(), stats_ComputeInputStats(), vlc_mutex_lock(), and vlc_mutex_unlock().
Referenced by MainLoop().
|
static |
|
static |
|
static |
|
static |
Referenced by input_Start().
|
static |
References input_thread_private_t::b_can_pace_control, input_thread_private_t::b_out_pace_control, End(), Init(), input_thread_private_t::input, input_SendEventDead(), input_thread_private_t::interrupt, MainLoop(), input_thread_private_t::thread, vlc_interrupt_set(), vlc_set_priority(), and VLC_THREAD_PRIORITY_LOW.
Referenced by input_Start().
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
Referenced by MainLoopDemux().
|
static |
|
static |
Referenced by MainLoopDemux().
|
static |
|
static |
Referenced by MainLoopDemux().
|
static |