[vlc-devel] [sout developers] VLC streaming violation of MPEG-TS discontinuity flag

Ilkka Ollakka ileoo at videolan.org
Fri Sep 25 08:15:03 CEST 2015


On Mon, Sep 21, 2015 at 06:24:12PM +0300, Ilkka Ollakka wrote:
> On Mon, Sep 21, 2015 at 10:54:01AM +0200, Francois Cartegnie wrote:
> > Hi Ilkka,

Hi again,


> > Can you confirm your own understanding of 2.4.3.5, especially towards
> > the end, because "after a continuity counter discontinuity" is not clear.

> If you refer to TS spec, no, I don't think I have that in hand
> currently or if I tought of that any more when cooked the patch.

Thanks for the specs that people pointed. After briefly reading that
section I think I have following understanding. Not sure if it's
actually the issue you are asking about, and following is quite a lot
just flow of thoughts when trying to create mental image of the thing:

- If we have discontinuity indicator on in non-PCR pid, we can just not
  care about continuity counter. So we can't know packet drops or others
  using that counter when discontinuity is signaled.
- For PCR pid continuity counter should always be running correctly.
- Every non-PCR pid should have at max 2 packets in row with
  discontinuity_indicator set on

- After continuity counter discontinuity next packet should be start of
  new video sequence/avc access unit/audio frame. This doesn't actually
  clearly mention that packet with discontinuity signaled should be such
  packet. Assuming if random_access_indicator is set then the same
  packet also contains new frame/block/video/* start.
  
  When reading that random_access_indicator description, I interpret it
  in a way that discontinuity signaled packet contains the start of new
  frame.
  
  But it's little puzzling on page 23 second last chapter to talk
  about after continuity counter discontinuity there should be start of
  new frame in packet.
  
  So based on previous assumptions I made in this mail, I assume that it
  means when pcr pid gets discontinuity signaled it means that same
  packet that signals it, contains start of new frame with new
  timestamps and we reset discontinuity counter checking.


> > Seems also the ts demux discontinuity flag on PCR must be handled
> > differently :/

Looks like I need lots of paper and pens with different colors to try to
get my head around that.

-- 
Ilkka Ollakka
Catharsis is something I associate with pornography and crossword puzzles.
		-- Howard Chaykin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20150925/a4f00aa8/attachment.sig>


More information about the vlc-devel mailing list