Re: [Cellar] Matroska Elements to support frame side data

Jerome Martinez <> Mon, 05 November 2018 11:20 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 683CC128DFD for <>; Mon, 5 Nov 2018 03:20:13 -0800 (PST)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -1.899
X-Spam-Status: No, score=-1.899 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id D1zGcxLdUFqi for <>; Mon, 5 Nov 2018 03:20:11 -0800 (PST)
Received: from ( []) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 9F660127133 for <>; Mon, 5 Nov 2018 03:20:11 -0800 (PST)
Received: from (unknown []) by (Postfix) with ESMTP id 9EBB31E70F4 for <>; Mon, 5 Nov 2018 12:20:09 +0100 (CET)
Received: from ( []) (Authenticated sender: by (Postfix) with ESMTPSA id 60E045400AA for <>; Mon, 5 Nov 2018 12:20:08 +0100 (CET)
References: <> <> <> <>
From: Jerome Martinez <>
Message-ID: <>
Date: Mon, 5 Nov 2018 12:20:09 +0100
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1
MIME-Version: 1.0
In-Reply-To: <>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
Content-Language: en-US
X-Ovh-Tracer-Id: 2839801043706908817
X-VR-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedtkedrjeehgddvkecutefuodetggdotefrodftvfcurfhrohhfihhlvgemucfqggfjpdevjffgvefmvefgnecuuegrihhlohhuthemucehtddtnecu
Archived-At: <>
Subject: Re: [Cellar] Matroska Elements to support frame side data
X-Mailman-Version: 2.1.29
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, 05 Nov 2018 11:20:13 -0000

On 05/11/2018 10:29, Moritz Bunkus wrote:
> Hey,
>> In other thoughts on this suggestion, I think it could make it difficult
>> to easily understand if a file has a particular type of side data. For
>> instance if only a few Clusters somewhere in the Segment contain a
>> certain type of side data, it would require parsing every Cluster to know
>> what types of side data are available. This uncertainly wouldn’t be the
>> same issue if the side data was itself a Track.
> It's not entirely necessary to use a full track for side data. We can simply
> signal the presence of side data in the track headers and refer to it from
> the side data in the block groups. This would also mean we only have to
> store the string identifying the side data type once (in the track headers)
> instead of in each block.

It would permit more efficient storage, but IMO it should be optional 
only, because if we do real time transcoding to MKV we don't have always 
all sidecar info. I have in mind some A/V content with ancillary data 
coming only after few minutes, without any change in A/V part.

> (I'll use "BlockMetadata" as the basis for all element names
> here. Initially I proposed "FrameMetadata", but "BlockMetadata" is fine
> with me, too.)

I prefer also "BlockMetadata" due to here is located the element.

> For example:
> Tracks
> +- TrackEntry
>   +- TrackBlockMetadata (Master)
>    +- TrackBlockMetadataType (String, required)
>    +- TrackBlockMetadataID (Unsigned Integer, required)

Please add:
  +- TrackBlockMetadataPrivate (Binary, optional)

Would have the same usage as CodecPrivate but for metadata.

> …
> Cluster
> +- BlockGroup
>   +- BlockMetadata (Master)
>    +- BlockMetadataID (Unsigned Integer, required, refers to existing
>       TrackBlockMetadataID in track headers)

Here I suggest to keep something like current PR "BlockMetadataName" and 
the restriction that  that exactly one of (BlockMetadataID ,
BlockMetadataName) must exist.

This would be even more complex but IMO more versatile.

> [...]