VLC 4.0.0-dev
|
Demultiplexers (file format parsers) More...
Modules | |
Chained demultiplexer | |
Demultiplexers wrapped by another demultiplexer. | |
Files | |
file | vlc_demux.h |
Demultiplexer modules interface. | |
Data Structures | |
struct | demux_meta_t |
Macros | |
#define | VLC_DEMUXER_EOF 0 |
#define | VLC_DEMUXER_EGENERIC -1 |
#define | VLC_DEMUXER_SUCCESS 1 |
#define | INPUT_UPDATE_TITLE 0x0010 |
#define | INPUT_UPDATE_SEEKPOINT 0x0020 |
#define | INPUT_UPDATE_META 0x0040 |
#define | INPUT_UPDATE_TITLE_LIST 0x0100 |
#define | add_file_extension(ext) add_shortcut("ext-" ext) |
#define | demux_UpdateTitleFromStream(demux) |
#define | DEMUX_INIT_COMMON() |
Typedefs | |
typedef struct demux_meta_t | demux_meta_t |
Functions | |
demux_t * | demux_New (vlc_object_t *p_obj, const char *module_name, const char *url, stream_t *s, es_out_t *out) |
static void | demux_Delete (demux_t *demux) |
int | demux_vaControlHelper (stream_t *, int64_t i_start, int64_t i_end, int64_t i_bitrate, int i_align, int i_query, va_list args) |
int | demux_Demux (demux_t *p_demux) |
int | demux_vaControl (demux_t *p_demux, int i_query, va_list args) |
static int | demux_Control (demux_t *p_demux, int i_query,...) |
static bool | vlc_demux_CanSeek (demux_t *demux) |
static bool | vlc_demux_CanPause (demux_t *demux) |
static bool | vlc_demux_CanPace (demux_t *demux) |
static bool | vlc_demux_CanRate (demux_t *demux) |
static bool | vlc_demux_CanRecord (demux_t *demux) |
static bool | vlc_demux_HasUnsupportedMeta (demux_t *demux) |
static int | vlc_demux_GetPtsDelay (demux_t *demux, vlc_tick_t *pts_delay) |
static int | vlc_demux_GetSeekpoint (demux_t *demux, int *seekpoint) |
static int | vlc_demux_GetSignal (demux_t *demux, double *quality, double *strength) |
static int | vlc_demux_GetTitle (demux_t *demux, int *title) |
static int | vlc_demux_GetMeta (demux_t *demux, vlc_meta_t *meta) |
static int | vlc_demux_GetType (demux_t *demux, int *type) |
static int | vlc_demux_GetTitleInfo (demux_t *demux, input_title_t ***title_info, int *size, int *pi_title_offset, int *pi_seekpoint_offset) |
static int | vlc_demux_GetPosition (demux_t *demux, double *position) |
static int | vlc_demux_GetLength (demux_t *demux, vlc_tick_t *length) |
static int | vlc_demux_GetTime (demux_t *demux, vlc_tick_t *time) |
static int | vlc_demux_GetNormalTime (demux_t *demux, vlc_tick_t *normal_time) |
static int | vlc_demux_GetFPS (demux_t *demux, double *fps) |
static int | vlc_demux_GetAttachments (demux_t *demux, input_attachment_t ***attachments) |
static int | vlc_demux_SetPauseState (demux_t *demux, bool pause_state) |
static int | vlc_demux_SetSeekPoint (demux_t *demux, int seekpoint) |
static int | vlc_demux_SetTitle (demux_t *demux, int title) |
static int | vlc_demux_SetRate (demux_t *demux, float rate) |
static int | vlc_demux_SetRecordState (demux_t *demux, bool record_state, const char *dir_path, const char *ext) |
static int | vlc_demux_NavActivate (demux_t *demux) |
static int | vlc_demux_NavUp (demux_t *demux) |
static int | vlc_demux_NavDown (demux_t *demux) |
static int | vlc_demux_NavLeft (demux_t *demux) |
static int | vlc_demux_NavRight (demux_t *demux) |
static int | vlc_demux_NavPopup (demux_t *demux) |
static int | vlc_demux_NavMenu (demux_t *demux) |
static int | vlc_demux_FilterEnable (demux_t *demux) |
static int | vlc_demux_FilterDisable (demux_t *demux) |
static void | demux_UpdateTitleFromStream (demux_t *demux, int *restrict titlep, int *restrict seekpointp, unsigned *restrict updatep) |
static bool | demux_IsPathExtension (demux_t *p_demux, const char *psz_extension) |
static bool | demux_IsContentType (demux_t *demux, const char *type) |
static bool | demux_IsForced (demux_t *p_demux, const char *psz_name) |
static int | demux_SetPosition (demux_t *p_demux, double pos, bool precise) |
static int | demux_SetTime (demux_t *p_demux, vlc_tick_t time, bool precise) |
decoder_t * | demux_PacketizerNew (vlc_object_t *p_demux, es_format_t *p_fmt, const char *psz_msg) |
This function will create a packetizer suitable for a demuxer that parses elementary stream. | |
void | demux_PacketizerDestroy (decoder_t *p_packetizer) |
This function will destroy a packetizer create by demux_PacketizerNew. | |
Demultiplexers (file format parsers)
#define add_file_extension | ( | ext | ) | add_shortcut("ext-" ext) |
#define DEMUX_INIT_COMMON | ( | ) |
#define demux_UpdateTitleFromStream | ( | demux | ) |
#define INPUT_UPDATE_META 0x0040 |
#define INPUT_UPDATE_SEEKPOINT 0x0020 |
#define INPUT_UPDATE_TITLE 0x0010 |
#define INPUT_UPDATE_TITLE_LIST 0x0100 |
#define VLC_DEMUXER_EGENERIC -1 |
#define VLC_DEMUXER_EOF 0 |
#define VLC_DEMUXER_SUCCESS 1 |
typedef struct demux_meta_t demux_meta_t |
enum demux_query_e |
Control query identifiers for use with demux_t.pf_control.
In the individual identifier description, the input stream refers to demux_t.s if non-NULL, and the output refers to demux_t.out.
A demuxer is synchronous if it only accesses its input stream and the output from within its demux_t callbacks, i.e. demux.pf_demux and demux_t.pf_control.
A demuxer is threaded if it accesses either or both input and output asynchronously.
An access-demuxer is a demuxer without input, i.e. demux_t.s == NULL).
Enumerator | |
---|---|
DEMUX_CAN_SEEK | Checks whether the stream supports seeking. Can fail if seeking is not supported (same as returning false).
arg1 = bool * |
DEMUX_CAN_PAUSE | Checks whether (long) pause then stream resumption is supported. Can fail only if synchronous and not an access-demuxer. The underlying input stream then determines if pause is supported.
arg1= bool * |
DEMUX_CAN_CONTROL_PACE | Whether the stream can be read at an arbitrary pace. Cannot fail. arg1= bool * |
DEMUX_GET_PTS_DELAY | Retrieves the PTS delay (roughly the default buffer duration). Can fail only if synchronous and not an access-demuxer. The underlying input stream then determines the PTS delay. arg1= vlc_tick_t * |
DEMUX_GET_META | Retrieves stream meta-data. Should fail if no meta-data were retrieved. arg1= vlc_meta_t * |
DEMUX_GET_SIGNAL | Retrieves an estimate of signal quality and strength. Can fail. arg1=double *quality, arg2=double *strength |
DEMUX_GET_TYPE | Retrieves the demuxed content type Can fail if the control is not implemented. arg1= int* |
DEMUX_SET_PAUSE_STATE | Sets the paused or playing/resumed state. Streams are initially in playing state. The control always specifies a change from paused to playing (false) or from playing to paused (true) and streams are initially playing; a no-op cannot be requested. The control is never used if DEMUX_CAN_PAUSE fails. Can fail. arg1= bool |
DEMUX_SET_TITLE | Seeks to the beginning of a title. The control is never used if DEMUX_GET_TITLE_INFO fails. Can fail. arg1= int |
DEMUX_SET_SEEKPOINT | Seeks to the beginning of a chapter of the current title. The control is never used if DEMUX_GET_TITLE_INFO fails. Can fail. arg1= int |
DEMUX_TEST_AND_CLEAR_FLAGS | Check which INPUT_UPDATE_XXX flag is set and reset the ones set. The unsigned* argument is set with the flags needed to be checked, on return it contains the values that were reset during the call arg1= unsigned * |
DEMUX_GET_TITLE | Read the title number currently playing. Can fail. arg1= int * |
DEMUX_GET_SEEKPOINT | |
DEMUX_GET_POSITION | |
DEMUX_SET_POSITION | |
DEMUX_GET_LENGTH | |
DEMUX_GET_TIME | |
DEMUX_SET_TIME | |
DEMUX_GET_NORMAL_TIME | |
DEMUX_GET_TITLE_INFO |
Can fail, meaning there is only one title and one chapter. arg1= input_title_t ***, arg2=int *, arg3=int *pi_title_offset(0), arg4= int *pi_seekpoint_offset(0) |
DEMUX_SET_GROUP_DEFAULT | |
DEMUX_SET_GROUP_ALL | |
DEMUX_SET_GROUP_LIST | |
DEMUX_SET_ES | |
DEMUX_SET_ES_LIST | |
DEMUX_SET_NEXT_DEMUX_TIME | |
DEMUX_GET_FPS | |
DEMUX_HAS_UNSUPPORTED_META | |
DEMUX_GET_ATTACHMENTS | |
DEMUX_CAN_RECORD | |
DEMUX_SET_RECORD_STATE |
The control is never used if DEMUX_CAN_RECORD fails or returns false. Can fail. arg1= bool arg2= string |
DEMUX_CAN_CONTROL_RATE | |
DEMUX_SET_RATE | |
DEMUX_NAV_ACTIVATE | Activate the navigation item selected. Can fail |
DEMUX_NAV_UP | Use the up arrow to select a navigation item above. Can fail |
DEMUX_NAV_DOWN | Use the down arrow to select a navigation item under. Can fail |
DEMUX_NAV_LEFT | Use the left arrow to select a navigation item on the left. Can fail |
DEMUX_NAV_RIGHT | Use the right arrow to select a navigation item on the right. Can fail |
DEMUX_NAV_POPUP | Activate the popup Menu (for BD). Can fail |
DEMUX_NAV_MENU | Activate disc Root Menu. Can fail |
DEMUX_FILTER_ENABLE | Enable/Disable a demux filter.
|
DEMUX_FILTER_DISABLE |
|
inlinestatic |
References demux_vaControl().
Referenced by Control(), ControlNav(), ControlPause(), ControlSetEsList(), ControlUnpause(), demux_filter_enable_disable(), demux_GetSeekpoint(), demux_GetTitle(), demux_SetPosition(), demux_SetTime(), demux_TestAndClearFlags(), InitPrograms(), InitProperties(), input_SlaveSourceAdd(), InputSourceGetLength(), InputSourceInit(), InputSourceMeta(), InputSourceStatistics(), InputUpdateMeta(), MainLoopDemux(), SlaveDemux(), SlaveSeek(), UpdateGenericFromDemux(), UpdateTitleListfromDemux(), vlc_demux_CanPace(), vlc_demux_CanPause(), vlc_demux_CanRate(), vlc_demux_CanRecord(), vlc_demux_CanSeek(), vlc_demux_chained_Thread(), vlc_demux_FilterDisable(), vlc_demux_FilterEnable(), vlc_demux_GetAttachments(), vlc_demux_GetFPS(), vlc_demux_GetLength(), vlc_demux_GetMeta(), vlc_demux_GetNormalTime(), vlc_demux_GetPosition(), vlc_demux_GetPtsDelay(), vlc_demux_GetSeekpoint(), vlc_demux_GetSignal(), vlc_demux_GetTime(), vlc_demux_GetTitle(), vlc_demux_GetTitleInfo(), vlc_demux_GetType(), vlc_demux_HasUnsupportedMeta(), vlc_demux_NavActivate(), vlc_demux_NavDown(), vlc_demux_NavLeft(), vlc_demux_NavMenu(), vlc_demux_NavPopup(), vlc_demux_NavRight(), vlc_demux_NavUp(), vlc_demux_SetPauseState(), vlc_demux_SetRate(), vlc_demux_SetRecordState(), vlc_demux_SetSeekPoint(), and vlc_demux_SetTitle().
|
inlinestatic |
References vlc_stream_Delete().
Referenced by InputSourceDestroy(), and vlc_demux_chained_Thread().
int demux_Demux | ( | demux_t * | p_demux | ) |
References vlc_stream_operations::demux, demux_ReadDir(), es_out_Control(), ES_OUT_POST_SUBNODE, input_item_node_Create(), input_item_node_Delete(), stream_t::ops, stream_t::out, stream_t::p_input_item, stream_t::pf_demux, stream_t::pf_readdir, unlikely, VLC_DEMUXER_EGENERIC, VLC_DEMUXER_EOF, and VLC_DEMUXER_SUCCESS.
Referenced by MainLoopDemux(), SlaveDemux(), and vlc_demux_chained_Thread().
|
inlinestatic |
References stream_t::s, and stream_IsMimeType().
|
inlinestatic |
References stream_t::psz_name, and psz_name.
|
inlinestatic |
References name, psz_ext, stream_t::psz_filepath, stream_t::psz_location, and strcasecmp().
demux_t * demux_New | ( | vlc_object_t * | p_obj, |
const char * | module_name, | ||
const char * | url, | ||
stream_t * | s, | ||
es_out_t * | out | ||
) |
References demux_NewAdvanced().
Referenced by vlc_demux_chained_Thread().
void demux_PacketizerDestroy | ( | decoder_t * | p_packetizer | ) |
This function will destroy a packetizer create by demux_PacketizerNew.
References container_of, es_format_Clean(), packetizer_owner::fmt_in, decoder_t::fmt_out, module_unneed, decoder_t::p_description, decoder_t::p_module, packetizer_owner::packetizer, vlc_meta_Delete(), and vlc_object_delete.
Referenced by rtp_h264_destroy(), and rtp_h265_destroy().
decoder_t * demux_PacketizerNew | ( | vlc_object_t * | p_demux, |
es_format_t * | p_fmt, | ||
const char * | psz_msg | ||
) |
This function will create a packetizer suitable for a demuxer that parses elementary stream.
The provided es_format_t will be cleaned on error or by demux_PacketizerDestroy.
References es_format_t::b_packetized, es_format_Clean(), es_format_Init(), decoder_t::fmt_in, packetizer_owner::fmt_in, decoder_t::fmt_out, es_format_t::i_cat, module_need, msg_Err, decoder_t::p_module, packetizer_owner::packetizer, decoder_t::pf_decode, decoder_t::pf_packetize, vlc_custom_create, and vlc_object_delete.
Referenced by rtp_h264_init(), and rtp_h265_init().
|
inlinestatic |
References demux_Control(), and DEMUX_SET_POSITION.
Referenced by Control().
|
inlinestatic |
References demux_Control(), and DEMUX_SET_TIME.
Referenced by Control().
|
inlinestatic |
int demux_vaControl | ( | demux_t * | p_demux, |
int | i_query, | ||
va_list | args | ||
) |
References vlc_stream_operations::can_control_pace, vlc_stream_operations::can_pause, vlc_stream_operations::can_seek, vlc_stream_operations::demux, DEMUX_CAN_CONTROL_PACE, DEMUX_CAN_CONTROL_RATE, DEMUX_CAN_PAUSE, DEMUX_CAN_RECORD, DEMUX_CAN_SEEK, DEMUX_FILTER_DISABLE, DEMUX_FILTER_ENABLE, DEMUX_GET_ATTACHMENTS, DEMUX_GET_FPS, DEMUX_GET_LENGTH, DEMUX_GET_META, DEMUX_GET_NORMAL_TIME, DEMUX_GET_POSITION, DEMUX_GET_PTS_DELAY, DEMUX_GET_SEEKPOINT, DEMUX_GET_SIGNAL, DEMUX_GET_TIME, DEMUX_GET_TITLE, DEMUX_GET_TITLE_INFO, DEMUX_GET_TYPE, DEMUX_HAS_UNSUPPORTED_META, DEMUX_NAV_ACTIVATE, DEMUX_NAV_DOWN, DEMUX_NAV_LEFT, DEMUX_NAV_MENU, DEMUX_NAV_POPUP, DEMUX_NAV_RIGHT, DEMUX_NAV_UP, DEMUX_SET_ES, DEMUX_SET_ES_LIST, DEMUX_SET_GROUP_ALL, DEMUX_SET_GROUP_DEFAULT, DEMUX_SET_GROUP_LIST, DEMUX_SET_NEXT_DEMUX_TIME, DEMUX_SET_PAUSE_STATE, DEMUX_SET_POSITION, DEMUX_SET_RATE, DEMUX_SET_RECORD_STATE, DEMUX_SET_SEEKPOINT, DEMUX_SET_TIME, DEMUX_SET_TITLE, DEMUX_TEST_AND_CLEAR_FLAGS, vlc_stream_operations::get_meta, vlc_stream_operations::get_signal, vlc_stream_operations::get_type, stream_t::ops, stream_t::pf_control, vlc_stream_operations::set_pause_state, vlc_stream_operations::set_seek_point, vlc_stream_operations::set_title, vlc_assert_unreachable, VLC_EGENERIC, and VLC_SUCCESS.
Referenced by demux_Control().
int demux_vaControlHelper | ( | stream_t * | s, |
int64_t | i_start, | ||
int64_t | i_end, | ||
int64_t | i_bitrate, | ||
int | i_align, | ||
int | i_query, | ||
va_list | args | ||
) |
References DEMUX_CAN_CONTROL_PACE, DEMUX_CAN_PAUSE, DEMUX_CAN_RECORD, DEMUX_CAN_SEEK, DEMUX_FILTER_DISABLE, DEMUX_FILTER_ENABLE, DEMUX_GET_ATTACHMENTS, DEMUX_GET_FPS, DEMUX_GET_LENGTH, DEMUX_GET_META, DEMUX_GET_NORMAL_TIME, DEMUX_GET_POSITION, DEMUX_GET_PTS_DELAY, DEMUX_GET_SEEKPOINT, DEMUX_GET_SIGNAL, DEMUX_GET_TIME, DEMUX_GET_TITLE, DEMUX_GET_TITLE_INFO, DEMUX_GET_TYPE, DEMUX_HAS_UNSUPPORTED_META, DEMUX_NAV_ACTIVATE, DEMUX_NAV_DOWN, DEMUX_NAV_LEFT, DEMUX_NAV_MENU, DEMUX_NAV_POPUP, DEMUX_NAV_RIGHT, DEMUX_NAV_UP, DEMUX_SET_ES, DEMUX_SET_ES_LIST, DEMUX_SET_GROUP_ALL, DEMUX_SET_GROUP_DEFAULT, DEMUX_SET_GROUP_LIST, DEMUX_SET_NEXT_DEMUX_TIME, DEMUX_SET_PAUSE_STATE, DEMUX_SET_POSITION, DEMUX_SET_RECORD_STATE, DEMUX_SET_SEEKPOINT, DEMUX_SET_TIME, DEMUX_SET_TITLE, DEMUX_TEST_AND_CLEAR_FLAGS, msg_Err, samples_from_vlc_tick(), static_control_match, STREAM_CAN_SEEK, stream_Size(), VLC_EGENERIC, vlc_stream_Control(), vlc_stream_Seek(), vlc_stream_Tell(), vlc_stream_vaControl(), VLC_SUCCESS, and vlc_tick_from_samples().
|
inlinestatic |
References DEMUX_CAN_CONTROL_PACE, and demux_Control().
|
inlinestatic |
References DEMUX_CAN_PAUSE, and demux_Control().
|
inlinestatic |
References DEMUX_CAN_CONTROL_RATE, and demux_Control().
|
inlinestatic |
References DEMUX_CAN_RECORD, and demux_Control().
|
inlinestatic |
References DEMUX_CAN_SEEK, and demux_Control().
|
inlinestatic |
References demux_Control(), and DEMUX_FILTER_DISABLE.
|
inlinestatic |
References demux_Control(), and DEMUX_FILTER_ENABLE.
|
inlinestatic |
References demux_Control(), and DEMUX_GET_ATTACHMENTS.
|
inlinestatic |
References demux_Control(), and DEMUX_GET_FPS.
|
inlinestatic |
References demux_Control(), and DEMUX_GET_LENGTH.
|
inlinestatic |
References demux_Control(), and DEMUX_GET_META.
|
inlinestatic |
References demux_Control(), and DEMUX_GET_NORMAL_TIME.
|
inlinestatic |
References demux_Control(), and DEMUX_GET_POSITION.
|
inlinestatic |
References demux_Control(), and DEMUX_GET_PTS_DELAY.
|
inlinestatic |
References demux_Control(), and DEMUX_GET_SEEKPOINT.
|
inlinestatic |
References demux_Control(), and DEMUX_GET_SIGNAL.
|
inlinestatic |
References demux_Control(), and DEMUX_GET_TIME.
|
inlinestatic |
References demux_Control(), and DEMUX_GET_TITLE.
|
inlinestatic |
References demux_Control(), and DEMUX_GET_TITLE_INFO.
|
inlinestatic |
References demux_Control(), and DEMUX_GET_TYPE.
|
inlinestatic |
References demux_Control(), and DEMUX_HAS_UNSUPPORTED_META.
|
inlinestatic |
References demux_Control(), and DEMUX_NAV_ACTIVATE.
|
inlinestatic |
References demux_Control(), and DEMUX_NAV_DOWN.
|
inlinestatic |
References demux_Control(), and DEMUX_NAV_LEFT.
|
inlinestatic |
References demux_Control(), and DEMUX_NAV_MENU.
|
inlinestatic |
References demux_Control(), and DEMUX_NAV_POPUP.
|
inlinestatic |
References demux_Control(), and DEMUX_NAV_RIGHT.
|
inlinestatic |
References demux_Control(), and DEMUX_NAV_UP.
|
inlinestatic |
References demux_Control(), and DEMUX_SET_PAUSE_STATE.
|
inlinestatic |
References demux_Control(), and DEMUX_SET_RATE.
|
inlinestatic |
References demux_Control(), and DEMUX_SET_RECORD_STATE.
|
inlinestatic |
References demux_Control(), and DEMUX_SET_SEEKPOINT.
|
inlinestatic |
References demux_Control(), and DEMUX_SET_TITLE.