Re: [AVTCORE] [Technical Errata Reported] RFC2435 (4095)

Magnus Westerlund <magnus.westerlund@ericsson.com> Thu, 29 January 2015 13:00 UTC

Return-Path: <magnus.westerlund@ericsson.com>
X-Original-To: avt@ietfa.amsl.com
Delivered-To: avt@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 9E9401A0364 for <avt@ietfa.amsl.com>; Thu, 29 Jan 2015 05:00:42 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -4.201
X-Spam-Level:
X-Spam-Status: No, score=-4.201 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, SPF_PASS=-0.001] autolearn=ham
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id P2KjzkpG2u2O for <avt@ietfa.amsl.com>; Thu, 29 Jan 2015 05:00:39 -0800 (PST)
Received: from sessmg22.ericsson.net (sessmg22.ericsson.net [193.180.251.58]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id C46631A0362 for <avt@ietf.org>; Thu, 29 Jan 2015 05:00:37 -0800 (PST)
X-AuditID: c1b4fb3a-f79116d000000fec-93-54ca2ef36556
Received: from ESESSHC011.ericsson.se (Unknown_Domain [153.88.253.124]) by sessmg22.ericsson.net (Symantec Mail Security) with SMTP id 3D.1C.04076.3FE2AC45; Thu, 29 Jan 2015 14:00:36 +0100 (CET)
Received: from [127.0.0.1] (153.88.183.153) by smtp.internal.ericsson.com (153.88.183.53) with Microsoft SMTP Server id 14.3.195.1; Thu, 29 Jan 2015 14:00:35 +0100
Message-ID: <54CA2EF3.2000108@ericsson.com>
Date: Thu, 29 Jan 2015 14:00:35 +0100
From: Magnus Westerlund <magnus.westerlund@ericsson.com>
User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:31.0) Gecko/20100101 Thunderbird/31.4.0
MIME-Version: 1.0
To: alissa@cooperw.in
References: <20140904145250.52B7118047E@rfc-editor.org>
In-Reply-To: <20140904145250.52B7118047E@rfc-editor.org>
Content-Type: text/plain; charset="windows-1252"
Content-Transfer-Encoding: 8bit
X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrPLMWRmVeSWpSXmKPExsUyM+Jvje4XvVMhBrt/M1lMP/OX0eJlz0p2 i+MnmpgdmD2+PHnJ5LFz1l12jyVLfjIFMEdx2aSk5mSWpRbp2yVwZUz+9IO14LtPxbXug4wN jE3aXYycHBICJhLPd3UwQthiEhfurWfrYuTiEBI4wigxf+pEVghnOaNE26v9bCBVvALaEjtv /GcFsVkEVCVmtVxmBrHZBCwkbv5oBKsRFQiWWPz8KStEvaDEyZlPWEBsEQFxiZWNW8BsZgE9 iZ33m9hBbGEBR4kFMz8BzeEAWmYucfmmE0iYE2jkjXtbGSHKDSSOLJrDCmHLSzRvnQ22Vgjo nIamDtYJjIKzkGybhaRlFpKWBYzMqxhFi1OLi3PTjYz0Uosyk4uL8/P08lJLNjECQ/jglt9W OxgPPnc8xCjAwajEw2uw6GSIEGtiWXFl7iFGaQ4WJXFeO+NDIUIC6YklqdmpqQWpRfFFpTmp xYcYmTg4pRoYV4a8uezHGckYdmFyy8wpXV96Ncqs3TZ+kT9hIG7Z4DG7wWzHvfNW3jv2Pm7Z yszas6TOQHKvXM6FnUXVq2P+aWkqTPkRtf5oW6qd0uUJ87yk1pzvdvjv7ibwwHxB483w6r+u RTG/76s9z/CPq5G4zXJC94p4K1PXEVEb/rebK868Vpk8NYFHiaU4I9FQi7moOBEA4YVhMkIC AAA=
Archived-At: <http://mailarchive.ietf.org/arch/msg/avt/SmuwwJBq9oyEkUbPthziAYm8lTA>
Cc: juliusfriedman@gmail.com, avt@ietf.org
Subject: Re: [AVTCORE] [Technical Errata Reported] RFC2435 (4095)
X-BeenThere: avt@ietf.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: Audio/Video Transport Core Maintenance <avt.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/avt>, <mailto:avt-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/avt/>
List-Post: <mailto:avt@ietf.org>
List-Help: <mailto:avt-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/avt>, <mailto:avt-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 29 Jan 2015 13:00:42 -0000

WG,

I would like to have your feedback on this errata.

It appears to me that the code is hard coded for three components. That
should be pretty evident for anyone reading the comments.

So from that perspective Julius is correct that the code was not taking
single component images into account. However, it is difficult to
determine the intention here.

I also wonder if the change is correct, especially why the first
occurrence of this line:

*p++ = 3;               /* number of components */

Is still equals to 3.

So WG is this Held for update or Reject.

Cheers

Magnus

On 2014-09-04 16:52, RFC Errata System wrote:
> The following errata report has been submitted for RFC2435,
> "RTP Payload Format for JPEG-compressed Video".
> 
> --------------------------------------
> You may review the report below and at:
> http://www.rfc-editor.org/errata_search.php?rfc=2435&eid=4095
> 
> --------------------------------------
> Type: Technical
> Reported by: Julius Richard Friedman <juliusfriedman@gmail.com>
> 
> Section: Appendix B
> 
> Original Text
> -------------
> int MakeHeaders(u_char *p, int type, int w, int h, u_char *lqt,
>                 u_char *cqt, u_short dri)
> {
>         u_char *start = p;
> 
>         /* convert from blocks to pixels */
>         w <<= 3;
>         h <<= 3;
> 
> 
> 
> Berc, et. al.               Standards Track                    [Page 19]
>  
> RFC 2435              RTP Payload Format for JPEG           October 1998
> 
> 
>         *p++ = 0xff;
>         *p++ = 0xd8;            /* SOI */
> 
>         p = MakeQuantHeader(p, lqt, 0);
>         p = MakeQuantHeader(p, cqt, 1);
> 
>         if (dri != 0)
>                 p = MakeDRIHeader(p, dri);
> 
>         *p++ = 0xff;
>         *p++ = 0xc0;            /* SOF */
>         *p++ = 0;               /* length msb */
>         *p++ = 17;              /* length lsb */
>         *p++ = 8;               /* 8-bit precision */
>         *p++ = h >> 8;          /* height msb */
>         *p++ = h;               /* height lsb */
>         *p++ = w >> 8;          /* width msb */
>         *p++ = w;               /* wudth lsb */
>         *p++ = 3;               /* number of components */
>         *p++ = 0;               /* comp 0 */
>         if (type == 0)
>                 *p++ = 0x21;    /* hsamp = 2, vsamp = 1 */
>         else
>                 *p++ = 0x22;    /* hsamp = 2, vsamp = 2 */
>         *p++ = 0;               /* quant table 0 */
>         *p++ = 1;               /* comp 1 */
>         *p++ = 0x11;            /* hsamp = 1, vsamp = 1 */
>         *p++ = 1;               /* quant table 1 */
>         *p++ = 2;               /* comp 2 */
>         *p++ = 0x11;            /* hsamp = 1, vsamp = 1 */
>         *p++ = 1;               /* quant table 1 */
>         p = MakeHuffmanHeader(p, lum_dc_codelens,
>                               sizeof(lum_dc_codelens),
>                               lum_dc_symbols,
>                               sizeof(lum_dc_symbols), 0, 0);
>         p = MakeHuffmanHeader(p, lum_ac_codelens,
>                               sizeof(lum_ac_codelens),
>                               lum_ac_symbols,
>                               sizeof(lum_ac_symbols), 0, 1);
>         p = MakeHuffmanHeader(p, chm_dc_codelens,
>                               sizeof(chm_dc_codelens),
>                               chm_dc_symbols,
>                               sizeof(chm_dc_symbols), 1, 0);
>         p = MakeHuffmanHeader(p, chm_ac_codelens,
>                               sizeof(chm_ac_codelens),
>                               chm_ac_symbols,
>                               sizeof(chm_ac_symbols), 1, 1);
> 
> 
> 
> 
> Berc, et. al.               Standards Track                    [Page 20]
>  
> RFC 2435              RTP Payload Format for JPEG           October 1998
> 
> 
>         *p++ = 0xff;
>         *p++ = 0xda;            /* SOS */
>         *p++ = 0;               /* length msb */
>         *p++ = 12;              /* length lsb */
>         *p++ = 3;               /* 3 components */
>         *p++ = 0;               /* comp 0 */
>         *p++ = 0;               /* huffman table 0 */
>         *p++ = 1;               /* comp 1 */
>         *p++ = 0x11;            /* huffman table 1 */
>         *p++ = 2;               /* comp 2 */
>         *p++ = 0x11;            /* huffman table 1 */
>         *p++ = 0;               /* first DCT coeff */
>         *p++ = 63;              /* last DCT coeff */
>         *p++ = 0;               /* sucessive approx. */
> 
>         return (p - start);
> };
> 
> 
> Corrected Text
> --------------
> int MakeHeaders(u_char *p, int type, int w, int h, u_char *lqt,
>                 u_char *cqt, u_short dri)
> {
>         u_char *start = p;
> 
>         /* convert from blocks to pixels */
>         w <<= 3;
>         h <<= 3;
>         *p++ = 0xff;
>         *p++ = 0xd8;            /* SOI */
> 
>         p = MakeQuantHeader(p, lqt, 0);
>         if(cqt != NULL) p = MakeQuantHeader(p, cqt, 1);
> 
>         if (dri != 0)
>                 p = MakeDRIHeader(p, dri);
> 
>         *p++ = 0xff;
>         *p++ = 0xc0;            /* SOF */
>         *p++ = 0;               /* length msb */
>         *p++ = 17;              /* length lsb */
>         *p++ = 8;               /* 8-bit precision */
>         *p++ = h >> 8;          /* height msb */
>         *p++ = h;               /* height lsb */
>         *p++ = w >> 8;          /* width msb */
>         *p++ = w;               /* wudth lsb */
>         *p++ = 3;               /* number of components */
>         *p++ = 1;               /* comp 1 */
>         if (type == 0)
>                 *p++ = 0x21;    /* hsamp = 2, vsamp = 1 */
>         else
>                 *p++ = 0x22;    /* hsamp = 2, vsamp = 2 */
>         *p++ = 0;               /* quant table 0 */
>         *p++ = 1;               /* comp 1 */
>         *p++ = 0x11;            /* hsamp = 1, vsamp = 1 */
>         *p++ = 1;               /* quant table 1 */
>         *p++ = 2;               /* comp 2 */
>         *p++ = 0x11;            /* hsamp = 1, vsamp = 1 */
>         *p++ = 1;               /* quant table 1 */
>         p = MakeHuffmanHeader(p, lum_dc_codelens,
>                               sizeof(lum_dc_codelens),
>                               lum_dc_symbols,
>                               sizeof(lum_dc_symbols), 0, 0);
>         p = MakeHuffmanHeader(p, lum_ac_codelens,
>                               sizeof(lum_ac_codelens),
>                               lum_ac_symbols,
>                               sizeof(lum_ac_symbols), 0, 1);
>         if(cqt != NULL)
>         {
>         p = MakeHuffmanHeader(p, chm_dc_codelens,
>                               sizeof(chm_dc_codelens),
>                               chm_dc_symbols,
>                               sizeof(chm_dc_symbols), 1, 0);
>         p = MakeHuffmanHeader(p, chm_ac_codelens,
>                               sizeof(chm_ac_codelens),
>                               chm_ac_symbols,
>                               sizeof(chm_ac_symbols), 1, 1);
>        }
> 
> 
> 
> 
> Berc, et. al.               Standards Track                    [Page 20]
>  
> RFC 2435              RTP Payload Format for JPEG           October 1998
> 
> 
>         *p++ = 0xff;
>         *p++ = 0xda;            /* SOS */
>         *p++ = 0;               /* length msb */
>         *p++ = cqt != NULL ? 0x12 : 0x0b;/* length lsb */
>         *p++ = cqt != NULL ? 0x03 : 0x01;/* 3 components */
>         *p++ = 0;               /* comp 0 */
>         *p++ = 0;               /* huffman table 0 */
>         *p++ = 0x01;               /* comp 1 */
>         *p++ = cqt != NULL ? 0x11 : 0x00;/* huffman table 1 */
>         if(cqt != NULL) *p++ = 2;/* comp 2 */
>         *p++ = cqt != NULL ? 0x11 : 0x00;/* huffman table 1 */
>         *p++ = 0;               /* first DCT coeff */
>         *p++ = 63;              /* last DCT coeff */
>         *p++ = 0;               /* sucessive approx. */
> 
>         return (p - start);
> };
> 
> 
> Notes
> -----
> Did not take into account cases with only 1 component was used.
> 
> Instructions:
> -------------
> This erratum is currently posted as "Reported". If necessary, please
> use "Reply All" to discuss whether it should be verified or
> rejected. When a decision is reached, the verifying party (IESG)
> can log in to change the status and edit the report, if necessary. 
> 
> --------------------------------------
> RFC2435 (no draft string recorded)
> --------------------------------------
> Title               : RTP Payload Format for JPEG-compressed Video
> Publication Date    : October 1998
> Author(s)           : L. Berc, W. Fenner, R. Frederick, S. McCanne, P. Stewart
> Category            : PROPOSED STANDARD
> Source              : Audio/Video Transport
> Area                : Real-time Applications and Infrastructure
> Stream              : IETF
> Verifying Party     : IESG
> 
> _______________________________________________
> Audio/Video Transport Core Maintenance
> avt@ietf.org
> https://www.ietf.org/mailman/listinfo/avt
> 


-- 

Magnus Westerlund

----------------------------------------------------------------------
Services, Media and Network features, Ericsson Research EAB/TXM
----------------------------------------------------------------------
Ericsson AB                 | Phone  +46 10 7148287
Färögatan 6                 | Mobile +46 73 0949079
SE-164 80 Stockholm, Sweden | mailto: magnus.westerlund@ericsson.com
----------------------------------------------------------------------