/* I. Common queries to access_demux and demux */
/* POSITION double between 0.0 and 1.0 */
DEMUX_GET_POSITION, /* arg1= double * res= */
- DEMUX_SET_POSITION, /* arg1= double res=can fail */
+ DEMUX_SET_POSITION, /* arg1= double arg2= bool b_precise res=can fail */
/* LENGTH/TIME in microsecond, 0 if unknown */
DEMUX_GET_LENGTH, /* arg1= int64_t * res= */
DEMUX_GET_TIME, /* arg1= int64_t * res= */
- DEMUX_SET_TIME, /* arg1= int64_t res=can fail */
+ DEMUX_SET_TIME, /* arg1= int64_t arg2= bool b_precise res=can fail */
/* TITLE_INFO only if more than 1 title or 1 chapter */
DEMUX_GET_TITLE_INFO, /* arg1=input_title_t*** arg2=int*
/* Attachments */
DEMUX_GET_ATTACHMENTS, /* arg1=input_attachment_t***, int* res=can fail */
- /* RECORD you should accept it only if the stream can be recorded without
+ /* RECORD you are ensured that it is never called twice with the same state
+ * you should accept it only if the stream can be recorded without
* any modification or header addition. */
DEMUX_CAN_RECORD, /* arg1=bool* res=can fail(assume false) */
DEMUX_SET_RECORD_STATE, /* arg1=bool res=can fail */
/* II. Specific access_demux queries */
+ /* PAUSE you are ensured that it is never called twice with the same state */
DEMUX_CAN_PAUSE = 0x1000, /* arg1= bool* can fail (assume false)*/
DEMUX_SET_PAUSE_STATE, /* arg1= bool can fail */
#define DEMUX_INIT_COMMON() do { \
p_demux->pf_control = Control; \
p_demux->pf_demux = Demux; \
- p_demux->p_sys = malloc( sizeof( demux_sys_t ) ); \
+ p_demux->p_sys = calloc( 1, sizeof( demux_sys_t ) ); \
if( !p_demux->p_sys ) return VLC_ENOMEM;\
- memset( p_demux->p_sys, 0, sizeof( demux_sys_t ) ); } while(0)
+ } while(0)
/**
* @}