From nobody Mon Feb 9 17:25:09 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1610706923; cv=none; d=zohomail.com; s=zohoarc; b=cRp3j42P23YmGtjzYYcZoYneG1QbbyjUz2k5iXkqyAz3OInfa2x0ZukS8R5U1a74yhJOtYeGm4fwwDjRLQwhUEyI9Hr9caaJWrOegl3F4VomdoYoWyroinQ72u+x4UNqelSyd9/3lXEC9wBlCxfVD+AeDsH0yANL1D8WAY6fQtg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1610706923; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=k0RZJ0aw4Oxsx9G/xx++q/L9Bmqlnx71U7H+bnB6fns=; b=J8uSWqJmrcWIRO9jzitYu8bSkFAQYgmzK5HvuG70MYM/DFpAEZUR371X3iGTJKNHJLx5D+WSy0/syYCtOKU8YzQOk8rxJGO4KUMfgmwlx6S0BM77jILpRlm7e6WE29fq8JsW03qcgxisAS6wt9ff8rALEpnxxtiRjBoOCMypYac= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1610706923481527.4078605006298; Fri, 15 Jan 2021 02:35:23 -0800 (PST) Received: from localhost ([::1]:33326 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1l0MRu-0007Gv-8s for importer@patchew.org; Fri, 15 Jan 2021 05:35:22 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:57450) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l0MHX-00032z-Ur for qemu-devel@nongnu.org; Fri, 15 Jan 2021 05:24:39 -0500 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:54239) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.90_1) (envelope-from ) id 1l0MHW-0007v6-8H for qemu-devel@nongnu.org; Fri, 15 Jan 2021 05:24:39 -0500 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-225-a_hzYqMPM7-MHPZX2jmxuw-1; Fri, 15 Jan 2021 05:24:34 -0500 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id DB1F41005D4D; Fri, 15 Jan 2021 10:24:33 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-112-182.ams2.redhat.com [10.36.112.182]) by smtp.corp.redhat.com (Postfix) with ESMTPS id AF3C46F7ED; Fri, 15 Jan 2021 10:24:30 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id B1D58180063A; Fri, 15 Jan 2021 11:24:24 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1610706277; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=k0RZJ0aw4Oxsx9G/xx++q/L9Bmqlnx71U7H+bnB6fns=; b=Mw/lAq2vZmYNIvaR9cQrOnFlhbn3b2ab+Kp01lQd6Ezo5ilgM1+yHr1gKy84TdZwb5Ui/o oUl86e7X7frdNb232lwX6RIArqgm7jJawzkv3Sg+VhJVMpagWjbG2W2XyRg9CexlirH2sR UOGF+K//8aTFdkx36ybo8JmfgTmircg= X-MC-Unique: a_hzYqMPM7-MHPZX2jmxuw-1 From: Gerd Hoffmann To: qemu-devel@nongnu.org Subject: [PULL 05/11] ui/gtk: update monitor interval on egl displays Date: Fri, 15 Jan 2021 11:24:18 +0100 Message-Id: <20210115102424.1360437-6-kraxel@redhat.com> In-Reply-To: <20210115102424.1360437-1-kraxel@redhat.com> References: <20210115102424.1360437-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=kraxel@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=216.205.24.124; envelope-from=kraxel@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -29 X-Spam_score: -3.0 X-Spam_bar: --- X-Spam_report: (-3.0 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.248, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Gerd Hoffmann , Nikola Pavlica Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" From: Nikola Pavlica When running QEMU's GTK UI without EGL or OGL, the gd_monitor_update_interval function gets executed and the display refresh rate gets updated accordingly. However, when using EGL or just regular OGL, the function never gets executed. Which is why I decided that the function should be in gd_egl_refresh where the display output gets updated, in the same vain as how it's done for normal GTK UIs (aka. those without EGL) - in it's display refresh function. Since the gd_monitor_update_interval function now is exposed, we are going to use it to update the refresh rate. Signed-off-by: Nikola Pavlica Message-Id: <20210114140153.301473-3-pavlica.nikola@gmail.com> Signed-off-by: Gerd Hoffmann --- ui/gtk-egl.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ui/gtk-egl.c b/ui/gtk-egl.c index 99231a3597f5..71c3d698b400 100644 --- a/ui/gtk-egl.c +++ b/ui/gtk-egl.c @@ -113,6 +113,9 @@ void gd_egl_refresh(DisplayChangeListener *dcl) { VirtualConsole *vc =3D container_of(dcl, VirtualConsole, gfx.dcl); =20 + vc->gfx.dcl.update_interval =3D gd_monitor_update_interval( + vc->window ? vc->window : vc->gfx.drawing_area); + if (!vc->gfx.esurface) { gd_egl_init(vc); if (!vc->gfx.esurface) { --=20 2.29.2