From patchwork Mon Oct 6 16:54:41 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 512 Return-Path: X-Original-To: u-boot-concept@u-boot.org Delivered-To: u-boot-concept@u-boot.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1759769737; bh=2eZsB8ATwDmjUm7JkqFpg1AX3BeBVD3j0TY6ii1y1Ok=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=flyobdMN75HYqvpz8I9gF1zBf633mG7LNauWk/5RVTxhLfEwtJVpeKjeKHzIShRwJ HGeREQGUG9wxstp8zJOanW3pMYdf5I/ENylSpITek428mSbAkulDYaWHZWrZbXhs97 qPVnfqk1otU9Ift/CQgvHZyTxnFZf6/XZQSTrkbUFnvGHVDv78/M49IvnODQasyFeG kb8Kc7fb8gx5mR9QoS8/bjLhuqwkXpFgNZQE99dMJNKvcCAoQz9aVgBUAJk5NbNHwe j4jpFADwi7r2J8JpKhRANYNW4l/9JnW2hYAsAQ2qiwJ3G+GN2yedims2Wipe8mgryD F9z06JBDQClbQ== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 459DA67F8B for ; Mon, 6 Oct 2025 10:55:37 -0600 (MDT) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10024) with ESMTP id Cc0HCRMqR0h6 for ; Mon, 6 Oct 2025 10:55:37 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1759769737; bh=2eZsB8ATwDmjUm7JkqFpg1AX3BeBVD3j0TY6ii1y1Ok=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=flyobdMN75HYqvpz8I9gF1zBf633mG7LNauWk/5RVTxhLfEwtJVpeKjeKHzIShRwJ HGeREQGUG9wxstp8zJOanW3pMYdf5I/ENylSpITek428mSbAkulDYaWHZWrZbXhs97 qPVnfqk1otU9Ift/CQgvHZyTxnFZf6/XZQSTrkbUFnvGHVDv78/M49IvnODQasyFeG kb8Kc7fb8gx5mR9QoS8/bjLhuqwkXpFgNZQE99dMJNKvcCAoQz9aVgBUAJk5NbNHwe j4jpFADwi7r2J8JpKhRANYNW4l/9JnW2hYAsAQ2qiwJ3G+GN2yedims2Wipe8mgryD F9z06JBDQClbQ== Received: from mail.u-boot.org (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 3483267F03 for ; Mon, 6 Oct 2025 10:55:37 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1759769734; bh=cAW8epNOsRlYaluECPP9I3OZTER1ncEavqQ7fDIOqFk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=hF3skmIHvQw2pa2l4v1EkwgFbq2evMAeRMvkGhpVqOuHmd2iQlYXcn1K12vjLdZGE KE7T7Pg9NZxeNCX9RAgNS+XxMuUH4S0U1umVpTQYBmrqA0L8rZ2E0m4fWQUXDIkFqs xPfSjdEdXez5wHse+bllWbgkHCODRC4FeXH6UcvMy5PDURIuBzSGj4z1oVtWysLHb1 YJG+JP7g1PS07SY1ZKxVSFMy1dnBXFEcnDsDhD29T8xncsRCouCaQ1tiIa0H4H9NdO 3iOxU3wdUPCirhemgN9MvgBHiB0gv3uLGwiTtRWJT6Pf6aPjy3yZ19588QRP8r6psQ LJH/9VcrDprcA== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id D65AC67ECE; Mon, 6 Oct 2025 10:55:34 -0600 (MDT) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10026) with ESMTP id 2zjTdYwRS3Jd; Mon, 6 Oct 2025 10:55:34 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1759769730; bh=vc5AFEkzwNkK2yDTpSV8BDfYi53tP0w8msWOgzPtkNM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=fTqShe+fqMejqATyfegi8UuzfhYSpzSw1nhPBPDdSI6KzIqshHloHffupfT7Xnu9V wBlkfhl2UE7fLVhZ3iUlYjal0tB+er7GajIsbawvaE/v7CMW2W1qFRTNZrCzbOgeRd xfsqnEceLRA8foJb/tXOOcEpKEKPx5yoSEx8t4WrieBMyu2ur0pEpFWI1ZmasoAIOy 4AfoET47i648GlzdPMBC2bqCqp19FK1k3aK7OCG5jE0lZB/bNxvJ7tG7fXjbSW2glz oLQlRNb1JqugFNLd7za5wsrsPlHLDsBRdknwLQmPKKPzuSAAQrfosB/2ZzZN2gSAd0 KVPlz4HJ4bjjg== Received: from u-boot.org (unknown [73.34.74.121]) by mail.u-boot.org (Postfix) with ESMTPSA id 82EDD67EE4; Mon, 6 Oct 2025 10:55:30 -0600 (MDT) From: Simon Glass To: U-Boot Concept Date: Mon, 6 Oct 2025 10:54:41 -0600 Message-ID: <20251006165452.1675349-10-sjg@u-boot.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20251006165452.1675349-1-sjg@u-boot.org> References: <20251006165452.1675349-1-sjg@u-boot.org> MIME-Version: 1.0 Message-ID-Hash: QX6SRBZI63YGRGHHCMIZXQ3CUBS24MHC X-Message-ID-Hash: QX6SRBZI63YGRGHHCMIZXQ3CUBS24MHC X-MailFrom: sjg@u-boot.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Heinrich Schuchardt , Simon Glass X-Mailman-Version: 3.3.10 Precedence: list Subject: [Concept] [PATCH 09/14] expo: Drop struct scene_obj_bbox in favour of vid_bbox List-Id: Discussion and patches related to U-Boot Concept Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Simon Glass Replace the scene_obj_bbox with the common vid_bbox structure to avoid having the same structs with different names. Signed-off-by: Simon Glass --- boot/scene.c | 4 ++-- include/expo.h | 19 ++----------------- 2 files changed, 4 insertions(+), 19 deletions(-) diff --git a/boot/scene.c b/boot/scene.c index 96130f160fc..a451ee1d325 100644 --- a/boot/scene.c +++ b/boot/scene.c @@ -386,7 +386,7 @@ int scene_obj_flag_clrset(struct scene *scn, uint id, uint clr, uint set) static void handle_alignment(enum scene_obj_align horiz, enum scene_obj_align vert, - struct scene_obj_bbox *bbox, + struct vid_bbox *bbox, struct scene_obj_dims *dims, int xsize, int ysize, struct scene_obj_offset *offset) @@ -555,7 +555,7 @@ static int scene_txt_render(struct expo *exp, struct udevice *dev, struct vidconsole_colour old; enum colour_idx fore, back; struct scene_obj_dims dims; - struct scene_obj_bbox bbox; + struct vid_bbox bbox; const char *str; int ret; diff --git a/include/expo.h b/include/expo.h index 622088f395b..a6e6b2b780b 100644 --- a/include/expo.h +++ b/include/expo.h @@ -234,21 +234,6 @@ enum scene_obj_t { SCENEOBJT_TEXTLINE, }; -/** - * struct scene_obj_bbox - Dimensions of an object - * - * @x0: x position, in pixels from left side - * @y0: y position, in pixels from top - * @x1: x position of right size - * @y1: y position of bottom - */ -struct scene_obj_bbox { - int x0; - int y0; - int x1; - int y1; -}; - /** * struct scene_obj_offset - Offsets for drawing the object * @@ -367,8 +352,8 @@ struct scene_obj { char *name; uint id; enum scene_obj_t type; - struct scene_obj_bbox req_bbox; - struct scene_obj_bbox bbox; + struct vid_bbox req_bbox; + struct vid_bbox bbox; struct scene_obj_offset ofs; struct scene_obj_dims dims; enum scene_obj_align horiz;