Browse Source

Commit bis des modifications concernant l'initialisation du continuity


			
			
				pull/2/head
			
			
		
Benoit Steiner 27 years ago
parent
commit
eee67fceef
  1. 10
      src/input/input.c
  2. 2
      src/input/input_ctrl.c
  3. 1
      src/input/input_psi.c

10
src/input/input.c

@ -705,6 +705,16 @@ static __inline__ void input_DemuxTS( input_thread_t *p_input,
intf_DbgMsg("Duplicate packet received by TS demux\n");
b_trash = 1;
}
else if( p_es_descriptor->i_continuity_counter == 0xFF )
{
/* This means that the packet is the first one we receive for this
ES since the continuity counter ranges between 0 and 0x0F
excepts when it has been initialized by the input: Init the
counter to the correct value. */
intf_DbgMsg("First packet for PID %d received by TS demux\n",
p_es_descriptor->i_id);
p_es_descriptor->i_continuity_counter = (p[3] & 0x0f);
}
else
{
/* This can indicate that we missed a packet or that the

2
src/input/input_ctrl.c

@ -135,7 +135,7 @@ int input_AddPgrmElem( input_thread_t *p_input, int i_current_id )
/* Initialise the demux */
p_input->p_es[i_es_loop].p_pes_packet = NULL;
p_input->p_es[i_es_loop].i_continuity_counter = 0;
p_input->p_es[i_es_loop].i_continuity_counter = 0xFF;
p_input->p_es[i_es_loop].b_random = 0;
/* Mark stream to be demultiplexed. */

1
src/input/input_psi.c

@ -1253,6 +1253,7 @@ static es_descriptor_t* AddESDescr(input_thread_t* p_input,
p_es->i_type = 0; /* ??? */
p_es->b_psi = 0;
p_es->b_pcr = 0;
p_es->i_continuity_counter = 0xFF;
p_es->p_pes_packet = NULL;
// p_es->p_next_pes_packet = NULL;

Loading…
Cancel
Save