Where is the support for NV12 with 64x32 tiling is added ?
Nicolas Dufresne
nicolas.dufresne at gmail.com
Mon May 2 13:22:46 UTC 2016
Le lundi 02 mai 2016 à 00:12 -0700, ssshukla26 a écrit :
> Hi,
>
> Thanks. I also studied this link
> <http://linuxtv.org/downloads/v4l-dvb-apis/re36.html> . Can you
> please
> clarify two more things.
>
> Suppose am looking at a frame of resolution *1280x720* of "NV12 64x32
> Tile"
> format.
>
> What will be size of each tile ? (as per my understanding its 2048)
>
> How to determine number of Horizontal tiles & Vertical tiles per
> frame ?
Tiles are fixed size, 64x32 bytes (2048 bytes). That also means, 64x32
pixels for the Y plane, and 32x32 for the UV interleaved plane. Because
of the Z flip Z pattern, the number of rows must be a multiple of 2
(you must have flip Z after a Z). So you can figure-out the minimum
required column by doing round_up_128 (width) /64. The number of column
will be the same for the UV plane (just like for the stride in NV12).
A driver may require allocating a larger amount of column. For this
reason, we extrapolate the number of columns using the provided stride.
We expect the provided stride to be a multiple of 128 and to be the
representation of the stride if the buffer was de-tiled keeping the
padding bytes.
For the number of rows, it's going to be round_up (32) / 32 Y plane,
and half this (rounded up) for the UV plane. Again, driver may require
more rows, this is extrapolated from the plane size. The layout is
affected by extra rows.
For 720p, you minimally need:
Y Plane: 10 x 23
UV Plane: 10 x 12
Nicolas
More information about the gstreamer-devel
mailing list