Commit 969f38cb authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

mpeg mux: missing const

parent dffd8461
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
* header in bytes. * header in bytes.
*/ */
static inline int PESHeader( uint8_t *p_hdr, mtime_t i_pts, mtime_t i_dts, static inline int PESHeader( uint8_t *p_hdr, mtime_t i_pts, mtime_t i_dts,
int i_es_size, es_format_t *p_fmt, int i_es_size, const es_format_t *p_fmt,
int i_stream_id, bool b_mpeg2, int i_stream_id, bool b_mpeg2,
bool b_data_alignment, int i_header_size ) bool b_data_alignment, int i_header_size )
{ {
...@@ -317,7 +317,7 @@ static inline int PESHeader( uint8_t *p_hdr, mtime_t i_pts, mtime_t i_dts, ...@@ -317,7 +317,7 @@ static inline int PESHeader( uint8_t *p_hdr, mtime_t i_pts, mtime_t i_dts,
* VIDEO_ES, set to INT_MAX. * VIDEO_ES, set to INT_MAX.
*/ */
void EStoPES ( block_t **pp_pes, void EStoPES ( block_t **pp_pes,
es_format_t *p_fmt, int i_stream_id, const es_format_t *p_fmt, int i_stream_id,
int b_mpeg2, int b_data_alignment, int i_header_size, int b_mpeg2, int b_data_alignment, int i_header_size,
int i_max_pes_size, mtime_t ts_offset ) int i_max_pes_size, mtime_t ts_offset )
{ {
......
...@@ -36,6 +36,6 @@ ...@@ -36,6 +36,6 @@
#define PES_PAYLOAD_SIZE_MAX 65500 #define PES_PAYLOAD_SIZE_MAX 65500
void EStoPES ( block_t **pp_pes, void EStoPES ( block_t **pp_pes,
es_format_t *p_fmt, int i_stream_id, const es_format_t *p_fmt, int i_stream_id,
int b_mpeg2, int b_data_alignment, int i_header_size, int b_mpeg2, int b_data_alignment, int i_header_size,
int i_max_pes_size, mtime_t ts_offset ); int i_max_pes_size, mtime_t ts_offset );
...@@ -460,7 +460,7 @@ static int DelStream( sout_mux_t *, sout_input_t * ); ...@@ -460,7 +460,7 @@ static int DelStream( sout_mux_t *, sout_input_t * );
static int Mux ( sout_mux_t * ); static int Mux ( sout_mux_t * );
static block_t *FixPES( sout_mux_t *p_mux, block_fifo_t *p_fifo ); static block_t *FixPES( sout_mux_t *p_mux, block_fifo_t *p_fifo );
static block_t *Add_ADTS( block_t *, es_format_t * ); static block_t *Add_ADTS( block_t *, const es_format_t * );
static void TSSchedule ( sout_mux_t *p_mux, sout_buffer_chain_t *p_chain_ts, static void TSSchedule ( sout_mux_t *p_mux, sout_buffer_chain_t *p_chain_ts,
mtime_t i_pcr_length, mtime_t i_pcr_dts ); mtime_t i_pcr_length, mtime_t i_pcr_dts );
static void TSDate ( sout_mux_t *p_mux, sout_buffer_chain_t *p_chain_ts, static void TSDate ( sout_mux_t *p_mux, sout_buffer_chain_t *p_chain_ts,
...@@ -1080,7 +1080,7 @@ static int AddStream( sout_mux_t *p_mux, sout_input_t *p_input ) ...@@ -1080,7 +1080,7 @@ static int AddStream( sout_mux_t *p_mux, sout_input_t *p_input )
else else
{ {
/* Copy extra data (VOL for MPEG-4 and extra BitMapInfoHeader for VFW */ /* Copy extra data (VOL for MPEG-4 and extra BitMapInfoHeader for VFW */
es_format_t *fmt = p_input->p_fmt; const es_format_t *fmt = p_input->p_fmt;
if( fmt->i_extra > 0 ) if( fmt->i_extra > 0 )
{ {
p_stream->pes.i_extra = fmt->i_extra; p_stream->pes.i_extra = fmt->i_extra;
...@@ -1667,11 +1667,11 @@ static block_t *FixPES( sout_mux_t *p_mux, block_fifo_t *p_fifo ) ...@@ -1667,11 +1667,11 @@ static block_t *FixPES( sout_mux_t *p_mux, block_fifo_t *p_fifo )
} }
} }
static block_t *Add_ADTS( block_t *p_data, es_format_t *p_fmt ) static block_t *Add_ADTS( block_t *p_data, const es_format_t *p_fmt )
{ {
#define ADTS_HEADER_SIZE 7 /* CRC needs 2 more bytes */ #define ADTS_HEADER_SIZE 7 /* CRC needs 2 more bytes */
uint8_t *p_extra = p_fmt->p_extra; const uint8_t *p_extra = p_fmt->p_extra;
if( !p_data || p_fmt->i_extra < 2 || !p_extra ) if( !p_data || p_fmt->i_extra < 2 || !p_extra )
return p_data; /* no data to construct the headers */ return p_data; /* no data to construct the headers */
......
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