ShaderGlass icon indicating copy to clipboard operation
ShaderGlass copied to clipboard

Remove yellow border from full-screen window

Open somatronicon opened this issue 3 years ago • 19 comments

First off, great project! Absolutely love it. Until people figure out there is a market for poly lenses that emulate CRTs for LED monitors (akin to this: https://hackaday.com/2021/06/16/fit-your-lcds-with-lenses-for-that-vintage-crt-look/), I'm using ShaderGlass 👍

As I'm trying to immerse myself in the past, I'm a bit distracted by the yellow border that appears around the full-screen window. My configuration can be seen below:

ProfileVersion "1.0"
PixelSize "1"
AspectRatio "1"
ShaderCategory "crt"
ShaderName "crt-lottes-multipass"
FrameSkip "2"
OutputScale "100"
FlipH "0"
FlipV "0"
Clone "0"
CaptureCursor "1"
Transparent "1"

And the screenshot:

image

somatronicon avatar Jun 30 '21 03:06 somatronicon

Sorry, just noticed that the screenshot above doesn't show the shaders being applied. However, you can still see the yellow border around the ShaderGlass main window.

somatronicon avatar Jun 30 '21 03:06 somatronicon

Hey, thanks for the feedback. Yes the yellow border is unfortunate but it's a security feature of Windows Capture API and cannot be removed (OBS etc. also has this problem). The only way to avoid it is to use clone mode (either capture the other monitor if you have multiple, or capture just the window of your game/app and put ShaderGlass in front of it), please try setting up your content that way.

rohatsu avatar Jun 30 '21 03:06 rohatsu

Very interesting... Totally understandable then as it's a limitation of the API used to capture. I'll give clone a shot and see what happens. Unfortunately I only have a single monitor, and am after retro-izing my entire desktop... So, I might just have to live with the yellow border for now.

somatronicon avatar Jun 30 '21 18:06 somatronicon

BTW, I just stumbled onto this; maybe useful?:

https://www.gitmemory.com/issue/microsoft/Windows.UI.Composition-Win32-Samples/46/829032545

somatronicon avatar Jun 30 '21 18:06 somatronicon

Also, just for some context, I traced that snippet back to the following github issue; unfortunately, I can't tell if it'd be applicable in this case judging from the API docs:

https://github.com/microsoft/Windows.UI.Composition-Win32-Samples/issues/46

somatronicon avatar Jun 30 '21 18:06 somatronicon

So I was going through some Windows documentation, and found that this page now references a borderless capture requests.

Maybe this can help solve this issue? I'll drop it here just in case.

https://docs.microsoft.com/en-us/uwp/api/windows.graphics.capture.graphicscapturesession.isborderrequired?view=winrt-20348#Windows_Graphics_Capture_GraphicsCaptureSession_IsBorderRequired

trebory6 avatar Aug 24 '21 02:08 trebory6

Great find @trebory6 , I will test this out!

rohatsu avatar Aug 25 '21 12:08 rohatsu

No problem @rohatsu! I was actually searching how to disable it universally via the registry or something(My media center is mainly offline so not worried about rogue screen capture).

This was where I found out about the borderless capture request, and apparently that reply mentioning this document is relatively new as that response was posted only 10 days ago, so this seems like a relatively new development that I hope helps with this project!

Thanks again for this project by the way. This is EXACTLY what I've been looking for for my Retro media center project for years! Let me know if you have a patreon or paypal, I'd love to throw some coffee money your way for this.

trebory6 avatar Aug 25 '21 17:08 trebory6

The good news is removing yellow border works, the bad news is that at the moment only on Windows 11. Hopefully Microsoft will include this in an upcoming Windows 10 update (21H2 perhaps? I haven't tried the preview yet). On the latest released Windows 10 21H1 (build 19043.1165) it does not work unfortunately.

Feel free to give it a shot, the 0.5 beta will attempt to disable the border if the OS reports support for it. https://github.com/rohatsu/ShaderGlass/releases/tag/v0.5-beta

Edit: confirmed still not possible on latest Windows 10 21H2 preview (19044.1200), we'll have to wait longer to have this feature on Windows 10 it seems.

rohatsu avatar Aug 27 '21 10:08 rohatsu

Hi.

Was hoping to write a full screen LUT shader for reasons, stumbled headlong into this issue "yet again", just popping a note here to say I'd love to see it solved.

Otherwise, thanks for your application; it's been a trip down memory lane testing it against old game footage. I've not felt this young in... well, my age minus about 8 years ;)

greysondn avatar Jan 07 '23 17:01 greysondn

obs does not have this problem

shinra358 avatar May 18 '23 20:05 shinra358

True, I think this is the relevant portion: https://github.com/obsproject/obs-studio/pull/4070

ner00 avatar May 18 '23 20:05 ner00

obs does not have this problem

It does if you use the "Window 10 (1903 and up)" display capture method.

Hey avatar May 23 '23 14:05 Hey

Any updates on this issue?

nakami avatar Jun 20 '23 13:06 nakami

I am not able to reproduce yellow border on latest Windows 11 (22H2), I've added steps to confirm ShaderGlass has Windows' permission to suppress it to the FAQ but in my testing they get enabled by default. If anyone is on latest Windows 11 and those steps don't make yellow border disappear, please post here.

mausimus avatar Jun 21 '23 07:06 mausimus

Still an issue on Microsoft Windows 10 Enterprise 10.0.19045 N/A Build 19045

with ShaderGlass-0.9-win-x64

QUAKEULUS avatar Apr 09 '24 07:04 QUAKEULUS