[Ffmpeg-devel] STREAM_TYPE_PRIVATE_DATA support in mpegts

Andy Parkins andyparkins
Thu May 4 15:05:54 CEST 2006


Please find attached a patch to enable arbitrary data stream support in mpegts 

 * Added CODEC_TYPE_DATA support; fairly simple - dealt with just as
   subtitle packets are - i.e. never buffered, always sent instantly

 * Added CODEC_TYPE_DATA support; but it's done in a roundabout fashion.
   mpegtsenc.c::mpegts_write_pmt() writes all non-video, non-audio
   streams as STREAM_TYPE_PRIVATE_DATA transport PES types.
   mpegts.c::pmt_cb() on the other hand silently dropped any
   STREAM_TYPE_PRIVATE_DATA streams; it doesn't any more, they are now
   treated just like STREAM_TYPE_SUBTITLE_DVB streams. i.e.
   new_pes_av_stream() is called to create a corresponding AVStream
   instance.  However, new_pes_av_stream() would treat
   STREAM_TYPE_PRIVATE_DATA streams as if they were some special MPEG
   stream. Now, STREAM_TYPE_PRIVATE_DATA sets
   codec_type to CODEC_TYPE_DATA and codec_id to CODEC_ID_NONE.

I'm not sure how acceptable it is to set a codec as explicitly CODEC_ID_NONE; 
but I'm sure you'll all tell me :-)

Dr Andy Parkins, M Eng (hons), AMIEE
andyparkins at gmail.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ffmpeg-patch-060504.diff
Type: text/x-diff
Size: 1500 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20060504/8ebeb35c/attachment.diff>

More information about the ffmpeg-devel mailing list