Re: [codec] draft-ietf-codec-oggopus: R128_TRACK_GAIN units

Calvin Walton <calvin.walton@kepstin.ca> Thu, 11 September 2014 16:01 UTC

Return-Path: <calvin.walton@kepstin.ca>
X-Original-To: codec@ietfa.amsl.com
Delivered-To: codec@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id F2E971A8990 for <codec@ietfa.amsl.com>; Thu, 11 Sep 2014 09:01:03 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.001
X-Spam-Level:
X-Spam-Status: No, score=-2.001 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, 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 9QxObxJeLv9T for <codec@ietfa.amsl.com>; Thu, 11 Sep 2014 09:01:01 -0700 (PDT)
Received: from mail-ie0-x22c.google.com (mail-ie0-x22c.google.com [IPv6:2607:f8b0:4001:c03::22c]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id A312F1A0672 for <codec@ietf.org>; Thu, 11 Sep 2014 09:00:55 -0700 (PDT)
Received: by mail-ie0-f172.google.com with SMTP id tr6so7521447ieb.3 for <codec@ietf.org>; Thu, 11 Sep 2014 09:00:55 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kepstin.ca; s=google; h=message-id:subject:from:to:cc:date:in-reply-to:references :content-type:mime-version:content-transfer-encoding; bh=MkfUiP9wGzuv4O/euus1t6XtJL0oEN5fR59c9BD7+yA=; b=vg605Q8Ho+zdN8p/lKyIbUQ9ei66XT0fjn9hf78pqU5EdmWhsPxinYK/EXKWZamtJJ EOSN12lLIT5sZFd4bzoFugLWz8SRArOCVkE9/+yUdq6orobNHNK7lWcwyivbVNg64HDD 4RYrVzBQsNXAaiLSKhcYuUcA9ormR4nNk0AF8=
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:content-type:mime-version:content-transfer-encoding; bh=MkfUiP9wGzuv4O/euus1t6XtJL0oEN5fR59c9BD7+yA=; b=XgSlyjaZu7r+ecLZlzqYvpyCBSPB6WTmDx9T3OM1VFesQpZoYFAIMlYaAhCaPjbNRk jwQlpMiBDqoTBVPH+B1Y4LE7owq5UG8lM1RhH3sHYQeZ1djpKF9ZbHnpHa+FjFvwUSnW GfOaxPVL1JbnBnZQxBEG3eFcltYWUxjUcTozpPPYkRlZKeAaC1kjR1lq8GCbd+Jumh6F JysPZzH6dryr99DJ+D5nHTdvdxLo4p49Cp7gcaMXUV1T7wXrJahNV9noUwRlvTXrgIs6 oznnBEErjrB9FLQ1rZVMpsKE4ASQJPIZsmFWUd5tna9lcO+WOXfZGcuCo0RkHJUYmviB oFKA==
X-Gm-Message-State: ALoCoQnalIwk3xAWYOXK+rFoMUzNnOwjE57X33M7FRmM46OgWOOJaeRGxYg8Nk9chPGE0CAZsdrQ
X-Received: by 10.50.62.50 with SMTP id v18mr8966011igr.21.1410451254827; Thu, 11 Sep 2014 09:00:54 -0700 (PDT)
Received: from sasami.ottawa.blindsidenetworks.com (OTWAON23-1242490325.sdsl.bell.ca. [74.14.229.213]) by mx.google.com with ESMTPSA id lp8sm5063391igb.9.2014.09.11.09.00.53 for <multiple recipients> (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 11 Sep 2014 09:00:53 -0700 (PDT)
Message-ID: <1410451239.8774.3.camel@kepstin.ca>
From: Calvin Walton <calvin.walton@kepstin.ca>
To: "Timothy B. Terriberry" <tterribe@xiph.org>
Date: Thu, 11 Sep 2014 12:00:39 -0400
In-Reply-To: <540E0D59.50500@xiph.org>
References: <CAMdZqKGW7QvHwfKFyY1xNPJ0R=Roi0-_KPmm8oLZC2U4GY_NQA@mail.gmail.com> <540E0D59.50500@xiph.org>
Content-Type: text/plain; charset="UTF-8"
X-Mailer: Evolution 3.13.5
Mime-Version: 1.0
Content-Transfer-Encoding: 7bit
Archived-At: http://mailarchive.ietf.org/arch/msg/codec/34AFrzbum6ZCVhfy8ff223Mv29g
Cc: "codec@ietf.org" <codec@ietf.org>
Subject: Re: [codec] draft-ietf-codec-oggopus: R128_TRACK_GAIN units
X-BeenThere: codec@ietf.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: Codec WG <codec.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/codec>, <mailto:codec-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/codec/>
List-Post: <mailto:codec@ietf.org>
List-Help: <mailto:codec-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/codec>, <mailto:codec-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 11 Sep 2014 16:01:04 -0000

On Mon, 2014-09-08 at 13:11 -0700, Timothy B. Terriberry wrote:
> As an individual...
> 
> Mark Harris wrote:
> >  output gain field of the Ogg Opus header.  Is it expected that 
> > these
> >  units would be adopted by other codecs?
> 
> I can't speak for anyone else, but if _I_ were making a new codec, I
> wouldn't see a need to innovate here. This design has the lessons of
> doing this for 15+ years baked into it.
> 
> >  concerned that if Ogg Opus uses 1/256 LU units, and another 
> > format or
> >  codec uses the much more obvious LU (dB) units, then someone may 
> > be in
> 
> Then they should pick a different tag name.
> 

Just to comment on this:

The format of the "vorbiscomment" fields is very similar between at 
least Ogg Vorbis, FLAC, and Ogg Opus. As a result, the tags are often 
copied verbatim between the three formats during transcoding, and the 
interpretation of tag meaning based on name is usually shared between 
all three codecs in parsing code.


As a result, without explicit code in the parser to e.g. reject or 
interpret differently this tag between different formats, a player 
that implements the R128_*_GAIN fields will as a side-effect add 
support for the same tag in FLAC and Ogg Vorbis.

(This is the same reason that some players - at least gstreamer-based 
players, rockbox, and foobar2000 - currently accept and use 
REPLAY_GAIN tags in Ogg Opus files)

Since this tag format is defined/specified in the Ogg Opus 
specification, it might make sense to use a prefix on the tag name - 
e.g. OPUS_R128_TRACK_GAIN - if the intent is that this tag is to be 
used only in the Ogg Opus format. This would reduce the likelihood of 
conflicts in the mostly-unregulated vorbiscomment namespace.

If the intent is that the R128 tags are intended to be used also in 
FLAC and Ogg Vorbis then I think it would be best for it to be defined 
outside of the Opus specification, somewhere that developers can 
reference independently. In particular, care would be needed to 
describe interactions with the REPLAY_GAIN tags that are still used in 
these other formats.

-- 
Calvin Walton <calvin.walton@kepstin.ca>