Re: [Cellar] Last call on FLAC specification

Martijn van Beurden <mvanb1@gmail.com> Thu, 29 September 2022 17:45 UTC

Return-Path: <mvanb1@gmail.com>
X-Original-To: cellar@ietfa.amsl.com
Delivered-To: cellar@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 5844BC14CE28 for <cellar@ietfa.amsl.com>; Thu, 29 Sep 2022 10:45:19 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.858
X-Spam-Level:
X-Spam-Status: No, score=-1.858 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id elW1MMvM8V97 for <cellar@ietfa.amsl.com>; Thu, 29 Sep 2022 10:45:18 -0700 (PDT)
Received: from mail-yw1-x1130.google.com (mail-yw1-x1130.google.com [IPv6:2607:f8b0:4864:20::1130]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id A80E4C14CF04 for <cellar@ietf.org>; Thu, 29 Sep 2022 10:45:18 -0700 (PDT)
Received: by mail-yw1-x1130.google.com with SMTP id 00721157ae682-353fbfa727cso22072267b3.4 for <cellar@ietf.org>; Thu, 29 Sep 2022 10:45:18 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date; bh=BOzZJwpkY1fwuipFTslJj1OnSBrlp3GJ8lNCQZSdrWM=; b=D2otod4u32DeW/gDBqGSkPjEQwEm6t/knIFN0YpAUVo/mabZRlmeqSqsejBlNRrPXh gTrWQkFy3+B/OUKyYawinuD5egb/yNESoYzpx/C3M1utORC3V2JZwiUyZthHJNaPy2Ls WqmqeGIDE7UQrefrxJ15VXCX+lo1CfITXrr9ktV+1N5R0Y/JD8Z6uj2pgNfTq8+LbcgN sCtxCrtddpyVkqz8uUhGVuuMbYrtxa27K3B0nCCzVIQLU3aCaRUVwojsq7SCsVo2HMYi 6pZRJC6SeP449SaLA2felQ+H3kQQdDKabWrlacBStD/QmDavUV8rfHaCBxpkZCeH0gmm ctUw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date; bh=BOzZJwpkY1fwuipFTslJj1OnSBrlp3GJ8lNCQZSdrWM=; b=rg5MM44S0uEm8H8vxTY2yPXTISy+SabLItc3GVz4m2YpjkUDinM/SztU93LfbNKCIX UnHA0ud43GGoPaRZpdjQJNlcciNTsZEgM6zN0wBS9B1IJU2e9w4DG8NLzp7qT1t4IXcn ny5tcQWz5hkILKnnB1kogX7WUl+R3p4nZTwV7VgRir7FMKTecIEE3GusjZWamlIypXbv WviptL/z8LFvYwn6IinD2yIWu9+TuLOdhPw5byXJamv8gnnZc+VZtjnKy9XGlnxReBQL 1DsQae60WgWBOWCxoVIs+OYBMS2cmJzEkbAfnYwI065KJO741ZD99kU/byRokJbkdjWd nhGg==
X-Gm-Message-State: ACrzQf0ErVdoRIXOXxdVw/vewkb9nYC6lWrLriXKDNmio1OGeuALSB5A 5Vbf1+HYfecFWaO3eSpEjyEKu9gkdEzi2s72f9SiBMcJwxQ=
X-Google-Smtp-Source: AMsMyM64UEYE2G1dQmD0pWCpskiIkB9pgy3rChkfKavsnQp8ZNaHodh1nYQa5KExPZty6EjW31fepANhThC06S349zk=
X-Received: by 2002:a81:7c45:0:b0:349:bc24:9591 with SMTP id x66-20020a817c45000000b00349bc249591mr4564341ywc.211.1664473517398; Thu, 29 Sep 2022 10:45:17 -0700 (PDT)
MIME-Version: 1.0
References: <CAAzqGd_Acroiu0ngUhvPTJHno=-vyccs-i9WYPLzeQ+Eba843g@mail.gmail.com>
In-Reply-To: <CAAzqGd_Acroiu0ngUhvPTJHno=-vyccs-i9WYPLzeQ+Eba843g@mail.gmail.com>
From: Martijn van Beurden <mvanb1@gmail.com>
Date: Thu, 29 Sep 2022 19:45:02 +0200
Message-ID: <CADQbU6-88CreFOy3LpzuXSz4yY75omx+8-m5u_Guf79Y7L9VaQ@mail.gmail.com>
To: Martin Leese <martin.leese@stanfordalumni.org>
Cc: cellar@ietf.org
Content-Type: multipart/alternative; boundary="000000000000be20f505e9d47056"
Archived-At: <https://mailarchive.ietf.org/arch/msg/cellar/PyADHmBYGgtMaxI2tc-KD9ExCGY>
Subject: Re: [Cellar] Last call on FLAC specification
X-BeenThere: cellar@ietf.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: Codec Encoding for LossLess Archiving and Realtime transmission <cellar.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/cellar>, <mailto:cellar-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/cellar/>
List-Post: <mailto:cellar@ietf.org>
List-Help: <mailto:cellar-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/cellar>, <mailto:cellar-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 29 Sep 2022 17:45:19 -0000

Op do 29 sep. 2022 om 17:42 schreef Martin Leese <
martin.leese@stanfordalumni.org>:
>
> 1.  Section 9.6.2, Page 22, the line:
>     WAVEFORMATEXTENSIBLE_CHANNEL_MASK=0x12004.
>
>     should read:
>     WAVEFORMATEXTENSIBLE_CHANNEL_MASK=0x12104.

Thanks!

>
> 2.  Section 9.6.2, Table 7, Page 20.  FLAC files do not
>     necessarily contain speaker feeds.  Examples of such
>     files are a collection of audio stems or an Ambisonic
>     B-Format recording.  Could we therefore please include
>     a Channel description of SPEAKER_NONE with:
>     WAVEFORMATEXTENSIBLE_CHANNEL_MASK=0x0
>
>     Given the way Table 7 is organised, It is not immediately
>     clear to me how to include this.


I don't know what the FLAC reference implementation or ffmpeg do in this
regard, but the channel mask is copied directly from Microsoft's
WAVEFORMATEXTENSIBLE structure. See here:
https://learn.microsoft.com/en-us/previous-versions/windows/hardware/design/dn653308(v=vs.85)

It says

> If, for example in a multi-channel audio authoring application,
> no speaker location is desired on any of the mono streams, the
> dwChannelMask should explicitly be set to 0. A dwChannelMask of
> 0 tells the audio device to render the first channel to the
> first port on the device, the second channel to the second port
> on the device, and so on. This also means that if the device
> doesn't know how to process the raw audio streams, it should
> not accept the multi-channel stream with a dwChannelMask of
> 0. A device like a digital mixer or a digital audio storage
> device (hard disk, ADAT, and so on) might want to accept
> formats without particular speaker locations.

Perhaps this and other comments about the channel mask should be added to
the FLAC specification, rephrased.

Seeing how much ambiguity was in the original RIFF/WAV specification, it is
nice to see these details are very well defined actually.