[asterisk-dev] why no sequence numbers with video frames over IAX ?

Luigi Rizzo rizzo at icir.org
Tue Oct 30 10:52:02 CDT 2007


On Tue, Oct 30, 2007 at 10:26:02AM -0500, Kevin P. Fleming wrote:
> Luigi Rizzo wrote:
> 
> > ok thanks for the clarification.
> > The absence of sequence number makes it slightly difficult to detect
> > missing frames though... 
>
> Not really... sequence numbers (especially in the video media world)
> aren't a reliable way to order packets and check for missing packets
> anyway, as sequence numbers can be 'consumed' by non-media frames in
> some situations, and IIRC there are also video formats where multiple
> frames can be sent with the same sequence number.
> 
> Using the timestamps and duration of the frames allows the receiver to
> determine if any time period is missing media.

I am a bit unclear on the following case:

i encode a video frame (say an I-frame) and the result is a large
chunk of data that needs to be transmitted over multiple UDP packets
(containing in turn RTP or IAX frames).
Now, for this video frame i have only one timestamp (in IAX they have
1ms resolution), and maybe 50+ packets.
The timestamp for the next video frame is say 30 ms later.

The only thing i can do here is send the individual IAX packets with
the same timestamp, because i don't have enough different values before
the next video frame.
But then how can i detect missing or reordered fragments ?

Surely if the fragmentation is done correctly i can leave it to
the decoding code, which has more info (in the bitstream).

Perhaps i should just forget about doing those checks in my code
and leave it to the decoder.

cheers
luigi



More information about the asterisk-dev mailing list