Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Unsupported HiDPI mode" error with Windows "System (Enhanced)" DPI scaling #12

Open
s0u7h opened this issue Aug 4, 2023 · 2 comments

Comments

@s0u7h
Copy link

s0u7h commented Aug 4, 2023

Running any ReaImGui script in 0.8.2 or higher, with these two DPI settings, fails with the following ReaImGui backend error message:

Unsupported HiDPI mode: select "Multimonitor aware v2" in Preferences > General > Adavanced UI/system settings.

On my Windows 11 system with two mixed resolution monitors (2160p/1440p), the only settings that scale both REAPERs interface, extensions like HeDa Track Inspector, and VST plugins, is to set the REAPER.exe DPI compatibility to "System (Enhanced)" and REAPERs own HDPI mode in Advanced UI settings to "Multimonitor aware (recommended)". Setting this to "V2 (experimental)" as the error message suggests does cure the ReaImGui issue but reintroduces scaling problems elsewhere in REAPER.

Rolling back to version 0.8.1 solves this issue, so it looks related to this change made in 0.8.2:

  • Windows: temporarily disable usage under non-multimonitor aware HiDPI modes [p=2629558]

I'm not sure if this is blocking the "multi-monitor (recommended)" setting inadvertently or if there is a necessity for v2 to run newer ReaImGui.

Cheers!

@cfillion
Copy link
Owner

cfillion commented Aug 4, 2023

ReaImGui should accept both "Multimonitor aware (recommended)" and "Multimonitor aware v2 (experimental)". Perhaps changing reaper.exe compatibility settings overrides the setting in REAPER preferences or affects it in some way? Does the issue still happen with default .exe compatibility settings?

I will have access to my Windows machine in about a week to check this & see what can be done.

(P.S. It's not a crash if it shows a proper error message and reaper.exe does not unexpectedly quits, losing unsaved data.)
(P.S.2 Make sure to restart REAPER after changing its HiDPI mode in Adavanced UI/system settings for the new mode to take effect.)

@cfillion cfillion changed the title Crash when "Multimonitor aware (recommended)" option used with Windows "System (Enhanced)" DPI scaling "Unsupported HiDPI mode" error with Windows "System (Enhanced)" DPI scaling Aug 4, 2023
@s0u7h
Copy link
Author

s0u7h commented Aug 4, 2023

Thanks - indeed not a crash but a Reascript error, sorry for that. It only happens when System (Enhanced) is enabled (with REAPER on the Multimonitor (recommended) setting), and I did try restarting both REAPER and Windows after making changes, with no luck.

Tried with OpenGL and Direct3D backends, which made no difference. Occurs in both 7.0pre2 and 6.75 portable.

The specific errors I'm getting include "...\FX Inspector\fx_inspector_libraries/gui.lua:12: ImGui_PushFont: frame initialization failed", and "...75 dev\Scripts\ReaTeam Extensions\API\ReaImGui_Demo.lua:300: ImGui_SetNextWindowPos: frame initialization failed" in case that's relevant.

cfillion added a commit that referenced this issue Mar 23, 2024
Stack trace of the ~1s hang on the second call to GDKOpenGL::render:

    #0  0x00007ffff7a080bf in __GI___poll
        (fds=fds@entry=0x7fffffffc388, nfds=nfds@entry=1, timeout=timeout@entry=-1)
        at ../sysdeps/unix/sysv/linux/poll.c:29
    #1  0x00007ffff76d620b in poll (__timeout=-1, __nfds=1, __fds=0x7fffffffc388)
        at /usr/include/bits/poll2.h:39
    #2  _xcb_conn_wait
        (c=c@entry=0x11c0140, vector=vector@entry=0x0, count=count@entry=0x0, cond=<optimized out>)
        at /usr/src/debug/libxcb/libxcb-1.16.1/src/xcb_conn.c:510
    #3  0x00007ffff76d829b in _xcb_conn_wait
        (count=0x0, vector=0x0, cond=<optimized out>, c=0x11c0140)
        at /usr/src/debug/libxcb/libxcb-1.16.1/src/xcb_conn.c:476
    #4  xcb_wait_for_special_event (c=0x11c0140, se=0x35bca30)
        at /usr/src/debug/libxcb/libxcb-1.16.1/src/xcb_in.c:806
    #5  0x00007ffff5dad3bf in dri3_wait_for_event_locked ()
        at ../mesa-24.0.3/src/loader/loader_dri3_helper.c:591
    #6  dri3_wait_for_event_locked () at ../mesa-24.0.3/src/loader/loader_dri3_helper.c:572
    #7  0x00007ffff5dada12 in loader_dri3_wait_for_sbc ()
        at ../mesa-24.0.3/src/loader/loader_dri3_helper.c:664
    #8  loader_dri3_swapbuffer_barrier () at ../mesa-24.0.3/src/loader/loader_dri3_helper.c:2343
    #9  0x00007fffc48308da in dri_st_framebuffer_flush_swapbuffers ()
        at ../mesa-24.0.3/src/gallium/frontends/dri/dri_drawable.c:143
    #10 0x00007fffc48f6a99 in st_manager_flush_swapbuffers ()
        at ../mesa-24.0.3/src/mesa/state_tracker/st_manager.c:1270
    #11 st_finish () at ../mesa-24.0.3/src/mesa/state_tracker/st_cb_flush.c:85
    #12 0x00007fffc4a36421 in st_glFinish ()
        at ../mesa-24.0.3/src/mesa/state_tracker/st_cb_flush.c:109
    #13 _mesa_Finish () at ../mesa-24.0.3/src/mesa/main/context.c:1660
    #14 0x00007ffff6de8e8c in gdk_x11_gl_context_end_frame
        (context=0x32f8650 [GdkX11GLContext], painted=0x372ee50, damage=<optimized out>)
        at ../gtk/gdk/x11/gdkglcontext-x11.c:263
    #15 0x00007ffff6da4f6d in gdk_gl_context_end_frame
        (damage=0x0, painted=0x372ee50, context=0x32f8650 [GdkX11GLContext])
        at ../gtk/gdk/gdkglcontext.c:396
    #16 gdk_window_end_paint_internal (window=window@entry=0x3037a50 [GdkX11Window])
        at ../gtk/gdk/gdkwindow.c:3072
    #17 0x00007ffff6da50f7 in gdk_window_end_draw_frame
        (context=0x35bde50 [GdkDrawingContext], window=0x3037a50 [GdkX11Window])
        at ../gtk/gdk/gdkwindow.c:3311
    #18 gdk_window_end_draw_frame
        (window=0x3037a50 [GdkX11Window], context=0x35bde50 [GdkDrawingContext])
        at ../gtk/gdk/gdkwindow.c:3294
    #19 0x00007fffd782938e in GDKOpenGL::render (this=0x30134b0, userData=0x0)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants