X-Mozilla-Status: 0001
X-Mozilla-Status2: 00000000
X-Mozilla-Keys:                                                                                 
Delivered-To: anshul.ffmpeg@gmail.com
Received: by 10.58.226.133 with SMTP id rs5csp120996vec;
        Mon, 10 Mar 2014 03:56:53 -0700 (PDT)
X-Received: by 10.204.168.206 with SMTP id v14mr998960bky.26.1394449013200;
        Mon, 10 Mar 2014 03:56:53 -0700 (PDT)
Return-Path: <ffmpeg-devel-bounces@ffmpeg.org>
Received: from avserver.banki.hu (avserver.banki.hu. [192.190.173.45])
        by mx.google.com with ESMTP id cr8si7426423bkc.308.2014.03.10.03.56.52
        for <multiple recipients>;
        Mon, 10 Mar 2014 03:56:53 -0700 (PDT)
Received-SPF: neutral (google.com: 192.190.173.45 is neither permitted nor denied by best guess record for domain of ffmpeg-devel-bounces@ffmpeg.org) client-ip=192.190.173.45;
Authentication-Results: mx.google.com;
       spf=neutral (google.com: 192.190.173.45 is neither permitted nor denied by best guess record for domain of ffmpeg-devel-bounces@ffmpeg.org) smtp.mail=ffmpeg-devel-bounces@ffmpeg.org
Received: from avserver.banki.hu (localhost [127.0.0.1])
	by avserver.banki.hu (Postfix) with ESMTP id E37B426309B;
	Mon, 10 Mar 2014 11:56:49 +0100 (CET)
X-Original-To: ffmpeg-devel@ffmpeg.org
Delivered-To: ffmpeg-devel@ffmpeg.org
X-Grey-ng: OK (suspect=0, ip=129.199.96.40) reason: DNSWL=127.0.11.1
Received: from nef2.ens.fr (nef2.ens.fr [129.199.96.40])
	by avserver.banki.hu (Postfix) with ESMTP id C037A2628A4
	for <ffmpeg-devel@ffmpeg.org>; Mon, 10 Mar 2014 11:56:48 +0100 (CET)
Received: from phare.normalesup.org (phare.normalesup.org [129.199.129.80])
	by nef2.ens.fr (8.13.6/1.01.28121999) with ESMTP id s2AAum1x039991
	for <ffmpeg-devel@ffmpeg.org>; Mon, 10 Mar 2014 11:56:49 +0100 (CET)
X-Envelope-To: <ffmpeg-devel@ffmpeg.org>
Received: by phare.normalesup.org (Postfix, from userid 1001)
	id E4FD448002; Mon, 10 Mar 2014 11:56:48 +0100 (CET)
From: Nicolas George <george@nsup.org>
To: ffmpeg-devel@ffmpeg.org
Date: Mon, 10 Mar 2014 11:56:46 +0100
Message-Id: <1394449007-17575-1-git-send-email-george@nsup.org>
X-Mailer: git-send-email 1.9.0
In-Reply-To: <531D5EAD.60803@gmail.com>
References: <531D5EAD.60803@gmail.com>
X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.1.4
	(nef2.ens.fr [129.199.96.32]);
	Mon, 10 Mar 2014 11:56:49 +0100 (CET)
Subject: [FFmpeg-devel] [PATCH 1/2] lavc: add CEA-708 codec id.
X-BeenThere: ffmpeg-devel@ffmpeg.org
X-Mailman-Version: 2.1.14
Precedence: list
Reply-To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org>
List-Id: FFmpeg development discussions and patches <ffmpeg-devel.ffmpeg.org>
List-Unsubscribe: <http://ffmpeg.org/mailman/options/ffmpeg-devel>,
	<mailto:ffmpeg-devel-request@ffmpeg.org?subject=unsubscribe>
List-Archive: <http://ffmpeg.org/pipermail/ffmpeg-devel>
List-Post: <mailto:ffmpeg-devel@ffmpeg.org>
List-Help: <mailto:ffmpeg-devel-request@ffmpeg.org?subject=help>
List-Subscribe: <http://ffmpeg.org/mailman/listinfo/ffmpeg-devel>,
	<mailto:ffmpeg-devel-request@ffmpeg.org?subject=subscribe>
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Errors-To: ffmpeg-devel-bounces@ffmpeg.org
Sender: ffmpeg-devel-bounces@ffmpeg.org

Signed-off-by: Nicolas George <george@nsup.org>
---
 libavcodec/avcodec.h    | 1 +
 libavcodec/codec_desc.c | 6 ++++++
 2 files changed, 7 insertions(+)


I am not entirely sure about that, all these industrials standards are a
maze of twisted documents all alike. IIUC, the CEA-708 packets can
themselves contain either EIA-608 data or something else. The sample Anshul
provided shows examples of the former, I do not know a sample with the
latter.


diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
index 5df717c..3e0bd38 100644
--- a/libavcodec/avcodec.h
+++ b/libavcodec/avcodec.h
@@ -493,6 +493,7 @@ enum AVCodecID {
     AV_CODEC_ID_SRT,
     AV_CODEC_ID_MICRODVD   = MKBETAG('m','D','V','D'),
     AV_CODEC_ID_EIA_608    = MKBETAG('c','6','0','8'),
+    AV_CODEC_ID_CEA_708    = MKBETAG('c','7','0','8'),
     AV_CODEC_ID_JACOSUB    = MKBETAG('J','S','U','B'),
     AV_CODEC_ID_SAMI       = MKBETAG('S','A','M','I'),
     AV_CODEC_ID_REALTEXT   = MKBETAG('R','T','X','T'),
diff --git a/libavcodec/codec_desc.c b/libavcodec/codec_desc.c
index a217d35..126a710 100644
--- a/libavcodec/codec_desc.c
+++ b/libavcodec/codec_desc.c
@@ -2541,6 +2541,12 @@ static const AVCodecDescriptor codec_descriptors[] = {
         .long_name = NULL_IF_CONFIG_SMALL("EIA-608 closed captions"),
     },
     {
+        .id        = AV_CODEC_ID_CEA_708,
+        .type      = AVMEDIA_TYPE_SUBTITLE,
+        .name      = "cea_708",
+        .long_name = NULL_IF_CONFIG_SMALL("CEA-708 closed captions"),
+    },
+    {
         .id        = AV_CODEC_ID_JACOSUB,
         .type      = AVMEDIA_TYPE_SUBTITLE,
         .name      = "jacosub",
-- 
1.9.0

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


