From patchwork Wed Apr 26 08:29:19 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yunke Cao X-Patchwork-Id: 677448 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id AF287C77B60 for ; Wed, 26 Apr 2023 08:30:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240118AbjDZIax (ORCPT ); Wed, 26 Apr 2023 04:30:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49888 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230008AbjDZIav (ORCPT ); Wed, 26 Apr 2023 04:30:51 -0400 Received: from mail-yb1-xb4a.google.com (mail-yb1-xb4a.google.com [IPv6:2607:f8b0:4864:20::b4a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 232CA3AAF for ; Wed, 26 Apr 2023 01:30:51 -0700 (PDT) Received: by mail-yb1-xb4a.google.com with SMTP id 3f1490d57ef6-b99f5daf7c5so3367881276.1 for ; Wed, 26 Apr 2023 01:30:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20221208; t=1682497850; x=1685089850; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:from:to:cc:subject:date:message-id:reply-to; bh=lebKifv5lt6ag6XdjNWl3IyrPv7ib44asZSlE3CJHVM=; b=rejQ50owTpS6LrLGWbrnbFD3lm7s9qF9YK82F07kRwLBWWfsmtUZ1gy/J6eV87eB// ezGBCu4na7UOpH/FTDWSL9ghKFmRbpYfFo56f6n1ouhpWRAK+jgV0hUBcI6HefkeyXUP gnj+94CIlXObzns1RRtmTfXOrCBznQEHHk0xybiGzEz1s/a8bYaGnU0wyhDPbQAevGB7 b8dk76AFQyHgvlNre0TMLdcaUEZTElJ0pATF7Kg+2HKMfJ/V4OF/2WP0N9J2ej0PLGCV x9U4xSfirauTQNO1cj6th+dhq/VJ6k+xOdHl6a2ZnMZp8YPVlvHmh9Y1hSQKJshUW2lL TdOw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682497850; x=1685089850; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=lebKifv5lt6ag6XdjNWl3IyrPv7ib44asZSlE3CJHVM=; b=JhQab3VtTGc8EScv/eKZC2eUQud0NiUcKxP2ruc2KQ59WOrRdY3O9nytkzZMFNePFe gtPwwOzF9UIeArbTXzBWoJFTs3cbEqVIsclWFnoF7nbf3rEx58pufMuU85plS1o3pna8 X8dyf1TBP/d5lYzC16nID1yC9+k8Ip6AZXEX+s7F2xGjqFkLaS2q54stCMoaPdkIUJFG erGEBbz0MLqp4xHAiGYLbv+PeDGUgSVokk2PrA9jq1UaynboefDCxlWek1EmQDW8BtCW 6zOXlRGwwN+M5VHOoFaErqIjxjeyOkO9gviaZSb5cy3m01d3Ljg26qfDnISDnrce+t/T FHqQ== X-Gm-Message-State: AC+VfDxAk+XJ82n3uBK2Y2Cr4tvReAcUlFswBTBviW/W+43mYvAHpynR 4IvM2BF/fDpcCGRmznwamxCl0hUwvQg= X-Google-Smtp-Source: ACHHUZ7FH+b1J5qlY8+3uCEQycjqZLnE3fMCa0FvIiZNcOpy6YQ4O4n7//4VipGYFbLVRkVN5rU4OVf4cec= X-Received: from yunkec1.tok.corp.google.com ([2401:fa00:8f:203:1f4e:598b:ed:99bd]) (user=yunkec job=sendgmr) by 2002:a25:d790:0:b0:b99:f202:db79 with SMTP id o138-20020a25d790000000b00b99f202db79mr3231106ybg.12.1682497850402; Wed, 26 Apr 2023 01:30:50 -0700 (PDT) Date: Wed, 26 Apr 2023 17:29:19 +0900 In-Reply-To: <20230426082923.132909-1-yunkec@google.com> Mime-Version: 1.0 References: <20230426082923.132909-1-yunkec@google.com> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog Message-ID: <20230426082923.132909-8-yunkec@google.com> Subject: [PATCH v11 07/11] media: v4l2: document the usage of min/max for V4L2_CTRL_TYPE_RECT From: Yunke Cao To: Hans Verkuil , Laurent Pinchart , Daniel Scally Cc: Tomasz Figa , Sergey Senozhatsky , Ricardo Ribalda , linux-media@vger.kernel.org, Yunke Cao Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Document the default implementation of min/max for rectangle controls. Reviewed-by: Daniel Scally Signed-off-by: Yunke Cao --- Changelog since v10: - Added Reviewed-by from Daniel. Changelog since v9: - No change. Changelog since v8: - New patch. Documentation/userspace-api/media/v4l/vidioc-queryctrl.rst | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Documentation/userspace-api/media/v4l/vidioc-queryctrl.rst b/Documentation/userspace-api/media/v4l/vidioc-queryctrl.rst index 58982cd382e3..efa07428ba7a 100644 --- a/Documentation/userspace-api/media/v4l/vidioc-queryctrl.rst +++ b/Documentation/userspace-api/media/v4l/vidioc-queryctrl.rst @@ -447,7 +447,11 @@ See also the examples in :ref:`control`. - n/a - A struct :c:type:`v4l2_rect`, containing a rectangle described by the position of its top-left corner, the width and the height. Units - depend on the use case. + depend on the use case. Use ``V4L2_CTRL_WHICH_MIN_VAL`` and + ``V4L2_CTRL_WHICH_MAX_VAL`` to query the range of rectangle sizes. The + top-left corner of the minimum and maximum rectangles should be the + same. For example, a control can have a minimum rectangle of 1x1@0x0 and + a maximum of 640x480@0x0. * - ``V4L2_CTRL_TYPE_H264_SPS`` - n/a - n/a