Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp370324pxa; Fri, 14 Aug 2020 06:40:14 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzBhCd+FXmT/GLBSNxm3zYmVMm31YpYYxEBp8f/+d/kQqwlYifdOHWKOUER+oPMVFWLW1JL X-Received: by 2002:a17:907:385:: with SMTP id ss5mr2354807ejb.496.1597412414610; Fri, 14 Aug 2020 06:40:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597412414; cv=none; d=google.com; s=arc-20160816; b=WVJOxICzaiaENKl2fKBVLOMKR2heZhvqQ5QpLPbxPpDGCbSY8gHJFxt+pL+IaLZ+A3 3wLzq+VflbPXTYtYgTZziS7bp0jYHHojDNInPcPP7qu7ruB6if3f+I7o9n9hNEUfOkIS vhCzn+82Bz7l2U1DaXQZIJzfAd7M8P9TEGzncZkMx4Lt/j76lhitXxdB3IbqsJVNUyHB OgnPQQavkosPnmG4cHxzT3AamZuD8h30eVpKwz65FTbHQ+S/3FJc80B15QJE6iwyXYQb L5TOOpXkIhCpMLpaFX6aOWBt1b8d51GOzN7wuYM36kTvOVzQpLaaINueU9+bECgRKFtu xnRg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=hM4J+pM6nfK5L1RyFjN1bk96rbqAbIZw0aVxAD6JARA=; b=abcf0OS3evSU+Ldl80MLrCfw30GQ3cQvE9wjYJ/Yi01eW1KiOLRMgaBGVV3F82qi6l nbnJoAdrajQ5QmYF404BiWtFfEEqidbURiCHAJSH3A+m7qmlLdLuxr7KIM6AhKK8Hfmh SqpCu8bvLVZFoafSH9J4nSx7RFRARBV9+kHkJu6bMyTSPFkeTlhu54VA/XngYPdqij1m nEXWOtar67VbPR8Na6TNUs8rVxk8usz3mNDTRXBQFB4oMx2KGAoxYClWdAGkLCpryl63 ouq9XtOrMGRlGGCWFhgQ6l7QVx36i9/kQSsmglq/qzdUP068BjQyiALE91J6HyUWt4d9 Q49A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id j8si5130569edk.610.2020.08.14.06.39.50; Fri, 14 Aug 2020 06:40:14 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728846AbgHNNhg (ORCPT + 99 others); Fri, 14 Aug 2020 09:37:36 -0400 Received: from bhuna.collabora.co.uk ([46.235.227.227]:43328 "EHLO bhuna.collabora.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728828AbgHNNhf (ORCPT ); Fri, 14 Aug 2020 09:37:35 -0400 Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: ezequiel) with ESMTPSA id 1BE2529A83F From: Ezequiel Garcia To: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Tomasz Figa , kernel@collabora.com, Jonas Karlman , Hans Verkuil , Alexandre Courbot , Jeffrey Kardatzke , Nicolas Dufresne , Philipp Zabel , Maxime Ripard , Paul Kocialkowski , Jernej Skrabec , Ezequiel Garcia Subject: [PATCH v3 11/19] media: uapi: h264: Rename and clarify PPS_FLAG_SCALING_MATRIX_PRESENT Date: Fri, 14 Aug 2020 10:36:26 -0300 Message-Id: <20200814133634.95665-12-ezequiel@collabora.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200814133634.95665-1-ezequiel@collabora.com> References: <20200814133634.95665-1-ezequiel@collabora.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Applications are expected to fill V4L2_CID_MPEG_VIDEO_H264_SCALING_MATRIX if a non-flat scaling matrix applies to the picture. This is the case if SPS scaling_matrix_present_flag or PPS pic_scaling_matrix_present_flag are set, and should be handled by applications. On one hand, the PPS bitstream syntax element signals the presence of a Picture scaling matrix modifying the Sequence (SPS) scaling matrix. On the other hand, our flag should indicate if the scaling matrix V4L2 control is applicable to this request. Rename the flag from PPS_FLAG_PIC_SCALING_MATRIX_PRESENT to PPS_FLAG_SCALING_MATRIX_PRESENT, to avoid mixing this flag with bitstream syntax element pic_scaling_matrix_present_flag, and clarify the meaning of our flag. Signed-off-by: Ezequiel Garcia --- Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst | 5 +++-- include/media/h264-ctrls.h | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst index 69dd3961b99b..03ce87aa5488 100644 --- a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst +++ b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst @@ -1695,9 +1695,10 @@ enum v4l2_mpeg_video_h264_hierarchical_coding_type - * - ``V4L2_H264_PPS_FLAG_TRANSFORM_8X8_MODE`` - 0x00000040 - - * - ``V4L2_H264_PPS_FLAG_PIC_SCALING_MATRIX_PRESENT`` + * - ``V4L2_H264_PPS_FLAG_SCALING_MATRIX_PRESENT`` - 0x00000080 - - + - Indicates that ``V4L2_CID_MPEG_VIDEO_H264_SCALING_MATRIX`` + must be used for this picture. ``V4L2_CID_MPEG_VIDEO_H264_SCALING_MATRIX (struct)`` Specifies the scaling matrix (as extracted from the bitstream) for diff --git a/include/media/h264-ctrls.h b/include/media/h264-ctrls.h index 1217b706128e..070b9499d7bc 100644 --- a/include/media/h264-ctrls.h +++ b/include/media/h264-ctrls.h @@ -99,7 +99,7 @@ struct v4l2_ctrl_h264_sps { #define V4L2_H264_PPS_FLAG_CONSTRAINED_INTRA_PRED 0x0010 #define V4L2_H264_PPS_FLAG_REDUNDANT_PIC_CNT_PRESENT 0x0020 #define V4L2_H264_PPS_FLAG_TRANSFORM_8X8_MODE 0x0040 -#define V4L2_H264_PPS_FLAG_PIC_SCALING_MATRIX_PRESENT 0x0080 +#define V4L2_H264_PPS_FLAG_SCALING_MATRIX_PRESENT 0x0080 struct v4l2_ctrl_h264_pps { __u8 pic_parameter_set_id; -- 2.27.0