On 16/07/2020 13:43, Ezequiel Garcia wrote: > On Thu, 2020-07-16 at 09:23 +0200, Hans Verkuil wrote: >> On 15/07/2020 22:22, Ezequiel Garcia wrote: >>> Commit 0b0393d59eb4a ("media: uapi: h264: clarify >>> expected scaling_list_4x4/8x8 order") improved the >>> documentation on H264 scaling lists order. >>> >>> This commit improves the documentation by clarifying >>> that the lists themselves are expected in matrix order. >> >> "matrix order" is not a well defined term. Especially since different >> programming languages lay out matrices differently (e.g. fortran uses >> column-major order). Perhaps something like this is more unambiguous: >> > > Agreed, "matrix order" is perhaps not a proper choice of words. > >> "The values on each scaling list are in row-major order." >> >> BTW, why not be explicit and use: >> >> __u8 scaling_list_4x4[6][4][4]; >> __u8 scaling_list_8x8[6][8][8]; >> >> That makes it explicit and the order is just that of what the C language >> uses. >> > > I am not sure if that'll go in clearer direction. > > I'm thinking we just need to clarify the coefficients > are in raster scan order, as opposed to a zig-zag scan > order, which is a part of the decoding process. > > How about we simply say "raster scan order" and keep the patch as is? That works for me. Regards, Hans > > Thanks, > Ezequiel > > >> Regards, >> >> Hans >> >>> Signed-off-by: Ezequiel Garcia <ezequiel@xxxxxxxxxxxxx> >>> --- >>> Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst | 6 ++++-- >>> 1 file changed, 4 insertions(+), 2 deletions(-) >>> >>> diff --git a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst >>> index c2e17c02f77e..16bfc98ab2f6 100644 >>> --- a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst >>> +++ b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst >>> @@ -1725,12 +1725,14 @@ enum v4l2_mpeg_video_h264_hierarchical_coding_type - >>> - ``scaling_list_4x4[6][16]`` >>> - Scaling matrix after applying the inverse scanning process. >>> Expected list order is Intra Y, Intra Cb, Intra Cr, Inter Y, >>> - Inter Cb, Inter Cr. >>> + Inter Cb, Inter Cr. The values on each scaling list are >>> + expected in matrix order. >>> * - __u8 >>> - ``scaling_list_8x8[6][64]`` >>> - Scaling matrix after applying the inverse scanning process. >>> Expected list order is Intra Y, Inter Y, Intra Cb, Inter Cb, >>> - Intra Cr, Inter Cr. >>> + Intra Cr, Inter Cr. The values on each scaling list are >>> + expected in matrix order. >>> >>> ``V4L2_CID_MPEG_VIDEO_H264_SLICE_PARAMS (struct)`` >>> Specifies the slice parameters (as extracted from the bitstream) >>> > >