Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 2274930 - GTK4 apps render badly on VirtualBox with 3D acceleration passthrough enabled
Summary: GTK4 apps render badly on VirtualBox with 3D acceleration passthrough enabled
Keywords:
Status: NEW
Alias: None
Product: Fedora
Classification: Fedora
Component: gtk4
Version: 40
Hardware: All
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: GNOME SIG Unassigned
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: AcceptedFreezeException https://discu...
Depends On:
Blocks: F40FinalFreezeException, FinalFreezeException
TreeView+ depends on / blocked
 
Reported: 2024-04-13 19:09 UTC by Adam Williamson
Modified: 2024-04-19 11:40 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed:
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
GNOME Gitlab GNOME gtk issues 6542 0 None opened ngl: Apps are displaying glitchy on VirtualBox and VMware 2024-04-13 19:11:21 UTC
freedesktop.org Gitlab mesa mesa issues 11008 0 None opened Issues rendering gtk4 windows on VirtualBox with 3D acceleration on Fedora-40/mesa-24.0.5 2024-04-13 19:11:21 UTC

Description Adam Williamson 2024-04-13 19:09:11 UTC
As tracked upstream at https://gitlab.gnome.org/GNOME/gtk/-/issues/6542 and https://gitlab.freedesktop.org/mesa/mesa/-/issues/11008 , when booted in VirtualBox (possibly only on Windows?) with 3D passthrough enabled, Fedora 40 Workstation looks pretty bad, there are obvious rendering errors in the desktop itself and in GTK4-based apps. This is related to the new NGL renderer.

It is pretty common to try out or run Fedora on VirtualBox, so it'd be great if we could do something about this for release, even if it's some kind of "fall back to the old renderer" workaround. Marking as accepted FE as this is split from https://bugzilla.redhat.com/show_bug.cgi?id=2274566 where we were tracking both VMWare and VirtualBox cases, and that was accepted FE. In my testing VMware is fixed with mesa 24.0.5 but VirtualBox is not, hence the need to split the bug.

Requested data from mesa and gtk4 folks:

`inxi -GSC -xx` output:

```
System:
  Host: localhost-live Kernel: 6.8.4-300.fc40.x86_64 arch: x86_64 bits: 64
    compiler: gcc v: 2.41-34.fc40
  Desktop: GNOME v: 46.0 tk: GTK v: 3.24.41 wm: gnome-shell dm: GDM
    Distro: Fedora Linux 40 (Workstation Edition)
CPU:
  Info: dual core model: Intel Core i5-9400T bits: 64 type: MCP
    arch: Coffee Lake rev: A cache: L1: 128 KiB L2: 512 KiB L3: 18 MiB
  Speed (MHz): avg: 1800 min/max: N/A cores: 1: 1800 2: 1800 bogomips: 7200
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3
Graphics:
  Device-1: VMware SVGA II Adapter driver: vmwgfx v: 2.20.0.0 ports:
    active: Virtual-1 empty: Virtual-2, Virtual-3, Virtual-4, Virtual-5,
    Virtual-6, Virtual-7, Virtual-8 bus-ID: 00:02.0 chip-ID: 15ad:0405
  Display: wayland server: X.Org v: 23.2.4 with: Xwayland v: 23.2.4
    compositor: gnome-shell driver: dri: vmwgfx gpu: vmwgfx display-ID: :0
    screens: 1
  Screen-1: 0 s-res: 800x600 s-dpi: 96
  Monitor-1: Virtual-1 res: 800x600 size: N/A
  API: EGL v: 1.5 platforms: device: 0 egl: 1.4 drv: vmwgfx device: 1
    drv: swrast gbm: egl: 1.4 drv: vmwgfx surfaceless: egl: 1.4 drv: vmwgfx
    wayland: egl: 1.4 drv: vmwgfx x11: egl: 1.4 drv: vmwgfx
  API: OpenGL v: 4.5 compat-v: 4.1 vendor: vmware mesa v: 24.0.5 glx-v: 1.4
    direct-render: yes renderer: SVGA3D; build: RELEASE; LLVM;
    device-ID: 15ad:0405
```

`GDK_DEBUG=opengl nautilus` output (requested by GTK devs in downstream bug, figured it might be useful here too):

```
** Message: 15:01:36.241: Connecting to org.freedesktop.Tracker3.Miner.Files
EGL API version 1.4 found
 - Vendor: Mesa Project
 - Version: 1.4
 - Device: /dev/dri/renderD128, 226 128
 - Client APIs: OpenGL OpenGL_ES 
 - Extensions:
	EGL_ANDROID_blob_cache
	EGL_ANDROID_native_fence_sync
	EGL_EXT_buffer_age
	EGL_EXT_image_dma_buf_import
	EGL_EXT_image_dma_buf_import_modifiers
	EGL_EXT_pixel_format_float
	EGL_EXT_present_opaque
	EGL_EXT_swap_buffers_with_damage
	EGL_KHR_cl_event2
	EGL_KHR_config_attribs
	EGL_KHR_context_flush_control
	EGL_KHR_create_context
	EGL_KHR_create_context_no_error
	EGL_KHR_fence_sync
	EGL_KHR_get_all_proc_addresses
	EGL_KHR_gl_colorspace
	EGL_KHR_gl_renderbuffer_image
	EGL_KHR_gl_texture_2D_image
	EGL_KHR_gl_texture_3D_image
	EGL_KHR_gl_texture_cubemap_image
	EGL_KHR_image_base
	EGL_KHR_no_config_context
	EGL_KHR_reusable_sync
	EGL_KHR_surfaceless_context
	EGL_KHR_swap_buffers_with_damage
	EGL_KHR_wait_sync
	EGL_MESA_configless_context
	EGL_MESA_drm_image
	EGL_MESA_gl_interop
	EGL_MESA_image_dma_buf_export
	EGL_MESA_query_driver
	EGL_WL_bind_wayland_display
	EGL_WL_create_wayland_buffer_from_image
 - Selected fbconfig: R8G8B8A8, depth 0, stencil 0
          high depth: none
Creating EGL context version 2.0 (debug:no, forward:no, legacy:no, es:yes)
Created EGL context[0x55fe17b603e0]
Using OpenGL backend EGL
OpenGL ES version: 3.0 (core)
* GLSL version: OpenGL ES GLSL ES 3.00
* Max texture size: 16384

Enabled features (use GDK_GL_DISABLE env var to disable):
    debug: YES
    unpack-subimage: YES
    half-float: YES
    sync: YES
    base-instance: YES
    buffer-storage: not supported
Creating EGL context version 3.0 (debug:no, forward:no, legacy:no, es:yes)
Created EGL context[0x55fe17d80e10]
OpenGL ES version: 3.0 (core)
* GLSL version: OpenGL ES GLSL ES 3.00
* Max texture size: 16384

Enabled features (use GDK_GL_DISABLE env var to disable):
    debug: YES
    unpack-subimage: YES
    half-float: YES
    sync: YES
    base-instance: YES
    buffer-storage: not supported
Using fractional scale 1 for EGL window (800 568 => 800 568)
Destroying EGL context
```

GDK_DEBUG=gl-prefer-gl nautilus does not fix the bug. GSK_RENDERER=gl nautilus does, so it is definitely related to the new renderer.


Note You need to log in before you can comment on or make changes to this bug.