Re: [Cellar] AV1 mapping Matroska

Moritz Bunkus <> Mon, 02 July 2018 07:48 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 32A4A130E41 for <>; Mon, 2 Jul 2018 00:48:03 -0700 (PDT)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -2.001
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, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: (amavisd-new); dkim=pass (4096-bit key)
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id AoyMN0XN8ZLL for <>; Mon, 2 Jul 2018 00:48:02 -0700 (PDT)
Received: from ( []) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by (Postfix) with ESMTPS id AFAD2130DC4 for <>; Mon, 2 Jul 2018 00:48:01 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;; s=mail2017070101; h=Content-Transfer-Encoding:Content-Type:MIME-Version:Message-ID:Date:In-reply-to:Subject:Cc:To:From:References; bh=hNk2TRCHGDzp/GWU2mrV2n4qRqH0U8VAnq4NABRyyZE=; b=ofEhxdGRCYa/P3acNmDAbT0bMWA68+K3DT0PHHxPnUHZqZxZFOcEZ/j0ePnXQPKidbY1eiLWOLxBf4inXO9rAi7w8DtmCh4S9HBdEShhwE+UyaVoBUPuUpZ3N1fTr8ydaCi3tJjl+g/BQMWi0Wh24ZhFJ6BoKb+dS4RGXB+HzLFxB8gRu0zoj5ZmOmtQIgulwTBu8iCja9iW7sKBaIKRHyfX/xdkjS/O1GiREtaZrviOYW9uU8qLFRrP555q4wLjnTbFT6yWE7aC0+eWPPqH5spvbbBa2h/OgUE3J9CGVACsL7FWxNXgQSzP5e8NzEhoAQC1I56/W1XiJt8xZZt7aDsg5I6pNVOMdKq23r6KhSlrc8PnDueWxmqaB2ZYxxxv/xDoXp2aU00ilnhLZBp45/1Npr3oWJOMWGu+J4QQLuPOF7ZtmZorgltE4LAv9UobTHz2k4SSY9GhAHlyMDVFiSHLoIgy4Rbs+5OrnsFZMQ22ucIlWQkaTHt3XjaNLYXUwI8byHZcaN1C7Hbcfj2Nev7aFUet8o/GtRR5h3JovgQt87gQP7fqxN/ywua13Up+mr0X2RmLwN7HBE3HhQR5EzNv3TW1amYUiTYZoVw+s1hXqB+n67B8gcNLOxBC9Ws9FeMPN8vysPMbypHMjd5PhfOk9Ho8bC7xcSvQWhTC7vs=;
Received: from ([2a01:4f8:190:8147::105:1]:36698) by with esmtps (TLSv1.2:DHE-RSA-AES256-GCM-SHA384:256) (Exim 4.82_1-5b7a7c0-XX) (envelope-from <>) id 1fZtYu-0002p5-1z for; Mon, 02 Jul 2018 09:47:52 +0200
X-Virus-Scanned: amavisd-new at
Received: from sweet-chili.local (unknown []) by (Postfix) with ESMTPS id 4EC3165411B1 for <>; Mon, 2 Jul 2018 09:47:46 +0200 (CEST)
Received: from sweet-chili (localhost [IPv6:::1]) by sweet-chili.local (Postfix) with ESMTP id 8BB383BFCE48 for <>; Mon, 2 Jul 2018 09:47:45 +0200 (CEST)
References: <> <> <> <>
User-agent: mu4e 1.0; emacs 26.1
From: Moritz Bunkus <>
To: Codec Encoding for LossLess Archiving and Realtime transmission <>
In-reply-to: <>
Date: Mon, 02 Jul 2018 09:47:45 +0200
Message-ID: <>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
Archived-At: <>
Subject: Re: [Cellar] AV1 mapping Matroska
X-Mailman-Version: 2.1.26
Precedence: list
List-Id: Codec Encoding for LossLess Archiving and Realtime transmission <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Mon, 02 Jul 2018 07:48:04 -0000


> Looking at the term "coded video sequence" (CVS) in other codecs (H.264
> and H.265) it seems it's a common term. And for those codec one Segment
> correspond to one CVS, with the parameters of that CVS stored in the
> CodecPrivate (SPS + PPS for H.264 for example). So we should probably go
> in that simple way.

I have quite a lot of h.264 samples here, mainly M2TS from DVB, where
SPS/PPS change mid-stream, often multiple times. For such files the first
occurrences of SPS/PPS make up the AvcC in CodecPrivate, but all key frames
are still prefixed with the currently active SPS/PPS — because that's the
only way to signal that stuff has actually changed.

Requiring a new segment each time those parameters change would make for
quite a bad experience, mainly due to two reasons:

1. There's no index listing where each segment starts making seeking inside
   multi-segment files all but impossible.
2. Software support for multi-segment files is pretty much non-existent.

I'm very pessimistic 2 would ever change, even if we mandated it in the AV1