On Mon, 23 Feb 2015, Luca Barbato wrote:

On 23/02/15 15:52, Martin Storsjö wrote:
From: Gilles Chanteperdrix <[email protected]>

Map this to AV_CODEC_ID_TEXT.
---
  Changelog             | 1 +
  libavformat/rtpdec.c  | 7 +++++++
  libavformat/version.h | 2 +-
  3 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/Changelog b/Changelog
index a658005..e4df595 100644
--- a/Changelog
+++ b/Changelog
@@ -20,6 +20,7 @@ version <next>:
- RTP depacketizer for loss tolerant payload format for MP3 audio (RFC
5219)
  - RTP depacketizer for DV (RFC 6469)
  - Canopus HQX decoder
+- RTP depacketization of T.140 text (RFC 4103)


  version 11:
diff --git a/libavformat/rtpdec.c b/libavformat/rtpdec.c
index 8858b13..bb3096c 100644
--- a/libavformat/rtpdec.c
+++ b/libavformat/rtpdec.c
@@ -50,6 +50,12 @@ static RTPDynamicProtocolHandler opus_dynamic_handler =
{
      .codec_id   = AV_CODEC_ID_OPUS,
  };

+static RTPDynamicProtocolHandler t140_dynamic_handler = { /* RFC 4103 */
+    .enc_name   = "t140",
+    .codec_type = AVMEDIA_TYPE_SUBTITLE,

t140 from what I can see is used for text-chat, marking it as subtitle sounds wrong or I'm reading the wrong pdf?

You're probably right - I'll repost the patches with it marked as AVMEDIA_TYPE_DATA instead - that'll let apps choose how they want to handle it themselves. If there's some extra metadata for signaling subtitles-in-t140 that could of course also be used to choose other media types, but lacking that, AVMEDIA_TYPE_DATA is probably the best compromise.

// Martin
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to