Subject: [Cellar] Mapping of MOV clean aperture values to Matroska

From: Kieran O Leary <[email-masked]>
Date: Fri, 23 Nov 2018 09:56:36 +0000

Hi,

Would I be correct in saying that ideally, Clean Aperture values in a
MOV/MPEG-4 file should map to the PixelCrop element in Matroska?

I'm asking about this in regards to this ffmpeg ticket -
https://trac.ffmpeg.org/ticket/7437
As it appears that FFmpeg does not currently read the values in the
clap atom and it also does not map them to Matorksa files when
remuxing. It seems to make the most sense to map them to PixelCrop,
but I'd like to hear it from folks more knowledgable than me.

Another associated issue with the display of these kinds of values is
with VLC as it appears that

1) PixelCrop values in Matroska are not supported by VLC at the moment
- https://trac.videolan.org/vlc/ticket/21192
2) Clean aperture values are not supported by VLC at the moment
https://trac.videolan.org/vlc/ticket/21179

Best,

Kieran O'Leary
Irish Film Institute

---

From: Dave Rice <[email-masked]>
Date: Sun, 25 Nov 2018 15:19:58 -0500

Hi Kieran,

> On Nov 23, 2018, at 4:56 AM, Kieran O Leary <[email-masked]> wrote:
> 
> Hi,
> 

Yes, they conceptually do the same thing but I’m a little confused about how to use the vert/horiz offset fractions of the clap atom to convert to the pixel crop atom. I tried in both QuickTime 7 and X, and while QuickTime X uses the cleanAperature w/h fractions to present a cropped image, QuickTime 7 doesn’t but appears to adjust the aspect ratio according to those values. QuickTime X does seem impacted by non-zero offset values not in a way that I consider coherent. Do you have any examples of un-centered aperatures? I was hoping that IMX files would, does the ones I have don’t use any aperature.

> but I'd like to hear it from folks more knowledgable than me.

Seems reasonable to me, but I’m not exactly certain what the mapping would be.

> https://trac.videolan.org/vlc/ticket/21179

Sounds like these tickets are in my priority order as well.
Dave Rice

---

From: Kieran O Leary <[email-masked]>
Date: Tue, 27 Nov 2018 17:43:51 +0000

Hey,

Thanks for replying:

On Sun, 25 Nov 2018, 20:20 Dave Rice <[email-masked] wrote:

> Yes, they conceptually do the same thing but I’m a little confused about
> how to use the vert/horiz offset fractions of the clap atom to convert to
> the pixel crop atom. I tried in both QuickTime 7 and X, and while QuickTime
> X uses the cleanAperature w/h fractions to present a cropped image,
> QuickTime 7 doesn’t but appears to adjust the aspect ratio according to
> those values. QuickTime X does seem impacted by non-zero offset values not
> in a way that I consider coherent. Do you have any examples of un-centered
> aperatures? I was hoping that IMX files would, does the ones I have don’t
> use any aperature.
>

I don't think I've ever seen non-centered.. but it sounds like Matroska is
capable of a mapping,but the actual quicktime implementation sounds
inconsistent? I guess this could be specified explicitly by an archivist
who will hopefully be able to determine the intended rendering of the
original QuickTime file..
Also it looks like here's yet another related ticket:
https://trac.ffmpeg.org/ticket/4489

> Seems reasonable to me, but I’m not exactly certain what the mapping would

I was considering  doing some experiments with some common PAL scenarios (
crop to 703x576 with a PAR of 59:54, or crop to 704x576 with PAR of 12:11)
and using mkvpropedit to insert the metadata. I'll have to look beyond VLC
to other players that can display these crops and aspect ratio conversions
for the moment.

> Sounds like these tickets are in my priority order as well.

Cheers,

Kieran O'Leary,

Irish Film Institute