[FFmpeg-devel] [PATCH] Cleanup the usage of AVRtpPayloadTypes in RT(S)P

Luca Abeni lucabe72
Thu Nov 15 10:45:56 CET 2007


Hi all,

the current rtp/rtsp code assumes that "AVRtpPayloadTypes[i].pt == i",
so it contains things like
if (!strcmp(AVRtpPayloadTypes[payload_type].enc_name, "MP2T"))
and similar.

To support MPEG2 video over RTP, I will need to add an entry like
{32, "MPV",        CODEC_TYPE_VIDEO,   CODEC_ID_MPEG2VIDEO, 90000, -1},
in AVRtpPayloadTypes. So, the table will contain two entries with the
same pt values (in RTP, MPEG1 video and MPEG2 video have the same
payload type), breaking the assumption quoted above.

So, I propose to modify all the code relying on such assumption, as
done by the attached patch. Since it modifies the RTP demuxer and
the RTSP code, I'd like to have an explicit hack from the maintainer
before committing the patch.

Of course, if someone thinks a better solution I'll be happy to
implement it.


			Thanks,
				Luca
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: cleanup_avrtppt_usage-2.diff
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20071115/60cd3a61/attachment.txt>



More information about the ffmpeg-devel mailing list