[Ffmpeg-devel] [Ffmpeg-devel-old] rtp mpeg4 packetize problem
Martin Boehme
boehme
Wed Jul 20 12:23:44 CEST 2005
Zoltan NAGY wrote:
> Martin Boehme wrote:
>> Zoltan NAGY wrote:
>>> how can I get a frame out of an mpeg4 video file? I mean, I suspected
>>> av_read_frame(), but that gives back an AVPacket, and that's only 52
>>> bytes
>>> (according to sizeof(AVPacket) )...
>>> so, how can I get one frame out of a video using libavcodec?
>>
>> The AVPacket doesn't contain the actual data -- that's in a buffer
>> pointed to by the "data" element of AVPacket. The length of the buffer
>> is given in "size".
>
> oh, thanks!
>
> now, another problem rises:
> video packet size: 5978
> video packet size: 5924
> video packet size: 6849
> video packet size: 5995
> video packet size: 6067
> video packet size: 6167
>
> how should I put it into RTP packets of 1300 bytes? well, for example,
> if the size is
> 6067 bytes, then it fits into 5 packets, the first 4 consits of 1300
> bytes data, but the last's
> payload is only 867 bytes. can I indicate it in the header?
I'm not familiar with RTP... but I guess Luca will be able to answer this.
Martin
--
Martin B?hme
Inst. f. Neuro- and Bioinformatics
Ratzeburger Allee 160, D-23538 Luebeck
Phone: +49 451 500 5514
Fax: +49 451 500 5502
boehme at inb.uni-luebeck.de
More information about the ffmpeg-devel
mailing list