libretro / RetroArch

Cross-platform, sophisticated frontend for the libretro API. Licensed GPLv3.
http://www.libretro.com
GNU General Public License v3.0
10.06k stars 1.81k forks source link

[Windows Bug] Windowed Fullscreen does not compose as expected #5345

Closed brianblakely closed 4 years ago

brianblakely commented 7 years ago

Description

Windowed Fullscreen does not allow system overlays to render (such as the system volume meter). It also has a problem with windows from some other desktop apps (such as the Steam on-screen keyboard). Alt-Tab works well, although there is flicker.

My config: retroarch.cfg.zip

Expected behavior

RetroArch should compose exactly as it does in windowed mode.

Actual behavior

While it appears to work somewhat like a typical "borderless fullscreen" mode, it has some quirks.

Steps to reproduce the bug

  1. video_windowed_fullscreen = "true"
  2. video_fullscreen = "true"
  3. Change volume while RetroArch is running.
  4. System volume meter does not display.

Bisect Results

Always the case, as far as I am aware.

Version/Commit

Environment information

andres-asm commented 7 years ago

The volume meter works fine for me

On Aug 19, 2017 12:28 PM, "Brian Blakely" notifications@github.com wrote:

Description

Windowed Fullscreen does not allow system overlays to render (such as the system volume meter). It also has a problem with windows from some other desktop apps (such as the Steam on-screen keyboard). Alt-Tab works well, although there is flicker.

My config: retroarch.cfg.zip https://github.com/libretro/RetroArch/files/1236526/retroarch.cfg.zip Expected behavior

RetroArch should compose exactly as it does in windowed mode. Actual behavior

While it appears to work somewhat like a typical "borderless fullscreen" mode, it has some quirks. Steps to reproduce the bug

  1. video_windowed_fullscreen = "true"
  2. video_fullscreen = "true"
  3. Change volume while RetroArch is running.
  4. System volume meter does not display.

Bisect Results

Always the case, as far as I am aware. Version/Commit

Environment information

  • OS: Windows 10

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/libretro/RetroArch/issues/5345, or mute the thread https://github.com/notifications/unsubscribe-auth/ABpC0G6cQOzYbl5nltoNQz5B4U4DkAwxks5sZxsrgaJpZM4O8ZLg .

brianblakely commented 7 years ago

Surprising, because I know that I am not the only person with this issue. Is there any other information I could provide that would shed light on this?

Awakened0 commented 7 years ago

Win10's little volume thing in the top left is hidden for me too when running RA in Windowed fullscreen.

I've always thought RA's windowed fullscreen was weird. It has the same swap interval 2 bug (https://github.com/libretro/RetroArch/issues/2193) that true fullscreen has and it doesn't have the mGBA juddering bug that windowed mode has (https://github.com/libretro/libretro-meta/issues/22). So regarding those two issues it basically acts like true fullscreen. But, it doesn't reset my ICC profile (stupid fullscreen bug in Creator's update) like true fullscreen does, so it doesn't fully act like true fullscreen. It also has the advantage true fullscreen has in that it "recovers" (stops stuttering) from fast forwarding much quicker than windowed mode does.

andres-asm commented 7 years ago

Ah not, it seems you're right it's not showing up. Have your tried with other GL applications? does it happen with the D3D driver too?

On Sat, Aug 19, 2017 at 7:11 PM, Awakened0 notifications@github.com wrote:

Win10's little volume thing in the top left is hidden for me too when running RA in Windowed fullscreen.

I've always thought RA's windowed fullscreen was weird. It has the same swap interval 2 bug (#2193 https://github.com/libretro/RetroArch/issues/2193) that true fullscreen has and it doesn't have the mGBA juddering bug that windowed mode has ( libretro/libretro-meta#22 https://github.com/libretro/libretro-meta/issues/22). So regarding those two issues it basically acts like true fullscreen. But, it doesn't reset my ICC profile (stupid fullscreen bug in Creator's update) like true fullscreen does, so it doesn't fully act like true fullscreen. It also has the advantage true fullscreen has in that it "recovers" (stops stuttering) from fast forwarding much quicker than windowed mode does.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/libretro/RetroArch/issues/5345#issuecomment-323555061, or mute the thread https://github.com/notifications/unsubscribe-auth/ABpC0E5WtW-x4ld1XNLJ5tuE7BQg0sjeks5sZ3nKgaJpZM4O8ZLg .

Awakened0 commented 7 years ago

I feel like it's a crapshoot with GL games that support borderless window. Some show the volume bar, others don't. I can't think of any specific examples ATM.

I can't get RA to launch with D3D. I tried disabling my GLSL shader and setting the menu driver to RGUI in my config. The verbose console says:

[INFO] Environ SET_PIXEL_FORMAT: RGB565.
[INFO] Redirecting save file to ".\Saves\.srm".
[INFO] Redirecting savestate to ".\States\.state".
[INFO] Version of libretro API: 1
[INFO] Compiled against API: 1
[INFO] [Audio]: Set audio input rate to: 29970.03 Hz.
[INFO] Found shader "F:\Blue\Emulation\Emulators\RetroArch\shaders\crt-easymode-halation.glslp"
[INFO] Found shader "F:\Blue\Emulation\Emulators\RetroArch\shaders\pixellate.glslp"
[INFO] [Video]: Video @ fullscreen
[INFO] [D3D]: Monitor size: 1920x1080.
[WARN] [D3D]: Failed to init device with hardware vertex processing (code: 0x8876086c). Trying to fall back to software vertex processing.
[ERROR] [D3D]: Failed to initialize device.
[ERROR] [D3D]: Failed to init D3D.
[ERROR] [Video]: Cannot open video driver ... Exiting ...
[ERROR] Fatal error received in: "init_video()"
[ERROR] This core requires a content file.
inactive123 commented 7 years ago

It is trying to load GLSL shaders. This won't work with D3D9. The only shader backend implemented for D3D9 is Cg, so if you want to use shaders, make sure they are Cg shaders.

brianblakely commented 7 years ago

The gl and vulkan drivers both exhibit this issue. The d3d driver does not, but it does exhibit this one: 20170819222706_1

Someone else reported this problem here: https://www.reddit.com/r/RetroArch/comments/56s9ud/black_screen_when_starting_retroarch/

inactive123 commented 7 years ago

There is a bounty open for this. The menu display driver for D3D is not complete enough to display MaterialUI and/or XMB properly.

So for now, you can only use RGUI with Direct3D.

We have several bounties open for these. You can view them here -

https://www.bountysource.com/activity/bounties

Quite a few are dedicated to improving Direct3D.

brianblakely commented 7 years ago

Just tried standalone Dolphin with borderless fullscreen and OGL -- same issue as in OP. D3D works fine in that case as well.

Awakened0 commented 7 years ago

@twinaphex actually, it's swap interval 2 that was causing the crash. If I set that to 1 I can use d3d.

Here's the log output when it crashes when I try to switch to swap interval 2 in RGUI: https://hastebin.com/bewaloviqo.md

And a GDB backtrace: https://hastebin.com/mivofupide.php

klepp0906 commented 4 years ago

not sure if its related. but fullscreen is giving some users issues as well. https://github.com/libretro/RetroArch/issues/7430#issuecomment-544740698

I came across https://bugs.freedesktop.org/show_bug.cgi?id=96766 which mentions custom resolutions. I do have issues with nvfbc capture due to it wanting to pick up my 4k display as a different resolution due to windows scaling. Nvfbc is now deprecated due to the aforementioned among other things, however if retroarch picks up the reported desktop resolution in a similar fashion and reports something under the hood other than the native resolution, i wonder if windows scaling is interacting somehow and borking FSE and in this case, causing windowed rendering issues.

brianblakely commented 4 years ago

This is an issue with any fullscreen app using OGL or Vulkan. Closing out.

klepp0906 commented 4 years ago

its your issue to close, and that may or may not be true depending on what your referencing but as far as full screen exclusive and RA goes - even the directx backend behaves the same. They all render as borderless windowed. There is no locking of the mouse to the game window. There is no alt tabbing. and other apps dependent on full screen do not pick it up.

still, considering the date of this - and the date of the issue reporting the FSE problems, its been a thing for awhile. I just check in from time to time when I hack away at trying to find a way around it. The issues it creates with various frontend features and remote gameplay hurt my soul ;p

EDIT I just fired up Doom real quick which is vulkan, set it to fullscreen, and i get alt tab behavior as expected. Retroarch, no bueno. It just stays there. /shrug

brianblakely commented 4 years ago

This bug wasn't about exclusive fullscreen, it was about RA not playing well with Windows and Steam overlays.

As it turns out, the fix was to use DirectX, so this bug was fixed when the DirectX video driver was added.

klepp0906 commented 4 years ago

yea, your correct. I got carried way. I think all the rendering/ui bugs are likely tied together in some fashion, but a bug report should certainly be limited in scope to what it was about.

I know the fullscreen exclusive mode (or lack thereof) in this case can also be demonstrated via how things like overlays interact with true fullscreen etc. Hence my referencing the other post.

glad things are sorted for you on your end with the dx driver though :)