Mega Bezel Reflection Shader! - Feedback and Updates

Perfect! Thanks, I can reproduce this problem here so I can fix it.

5 Likes

FYI Update

I’ve got everything fixed except for Royale which is being a real bear (when I put in the same fix as the others - setting some scaling values - the whole thing just turns black or gives garbage, I think it’s some sort of backend resource bug.)

There should be a fixed release coming in the next couple days.

Thanks to @Tromzy & @Telmo who took the time to show the Clipping Glow problem.

7 Likes

to

1 Like

Hi HSM, firstly this stuff looks great, I am super keen to use this in my project. I have screened through a lot of this thread for an answer, but yet to find. So my first question is what settings do i tweak to increase game screen size?

from

whoops, I approved those posts in the wrong order. Sorry bout that.

2 Likes

You can increase the non-integer screen scale, or turn on integer scale (in the shader) and increase the integer scale multiple.

1 Like

Hmmm, 100% GPU usage on a GTX 1060. Is this normal?

There’s also a missing option from the previous version that configures this:

I was using it to remove this line completely by reducing it to zero. It was a “BEZEL” option.

Edit: Another issue i found is that when i reduce the CRT black level a bit fof the scanlines to appear in black color, i’m getting this moire:

Ah you noticed I removed that parameter! If you’re using it I’ll put it back :slight_smile:

The black level thing I think is probably a symptom of the clipping that telmo and tromzy found, so hopefully should go away in the next update.

2 Likes

Yeah, if you put a niche option in there chances are im going to use it :stuck_out_tongue:

3 Likes

thanks :slight_smile: now what do i adjust to eliminate the halo effect and the black offset around edge of game image?

1 Like

By Halo effect, do you mean the reflection on the bezel? If so set [REFLECTION GLOBAL] Global Amount to 0

To remove the black line set [TUBE] Black Edge Thickness to 0, or a negative number

1 Like

DOS batch for updating presets

Maybe this is helpful for one or another. I wrote a little batch file that updates my already created presets to the most recent version. HSM reflection is under heavy development, and every other day there’s a new version with great new features. Unfortunately, in most cases old presets are not compatible with the new version. The shader chain is different and the biggest problem: some parameters are being dropped and new ones added.

It’s a pain in the a… to either a) manually create your presets from scratch again or b) copy & paste every parameter into a newly created preset.

As of today I had already created ~ 30 presets. So I decided to write a small, helping dos batch which does a very simple job:

It creates a new shader preset file for all existing shader presets in the same directory and saves them into a newly created subfolder _new _\ .

The batch file inserts the new shader chain (first part of the preset), and then it appends all parameters from the old presets. For me this works pretty well.

Here’s how to use it:

  1. start retroarch
  2. load HSM’s new preset for the kind of shaders presets you want to update (i.e. “hsm-mega-bezel-reflection-crt-guest-dr-venom.slangp”)
  3. Apply changes. Retroarch automatically creates a new preset file with default parameters. You can find it here: [retroarch root]\shaders\retroarch.slangp
  4. Now create a new folder, for example “HSM Preset Update” on your desktop (or whereever you want)
  5. copy retroarch.slangp to this new folder and rename “retroarch.slangp” to “template.txt”
  6. now copy all your existing presets that are based on the same preset (in this example it’s “hsm-mega-bezel-reflection-crt-guest-dr-venom.slangp”) to the newly created “HSM Preset Update” directory (if you want to create updated files, of course)
  7. Now create a new txt file in the same directory and rename it to “HSM_preset_updater.bat”
  8. Copy the following code into that batch-file:

HSM_prest_update.bat:

@echo off
setlocal EnableDelayedExpansion
set template=template.txt
if exist _new_ (
	echo Folder _new_ already exists
	echo Please delete folder _new_ and restart updater. Thx.
	pause
	exit
)
mkdir _new_
for %%a in ("*.slangp") do (
	set shader=%%~na.slangp
	set new_shader=.\_new_\!shader!
	echo.>!new_shader!
	set params=false
	for /f "tokens=*" %%a in (%template%) do (
		set Line=%%a
		set Anfang=!Line:~0,10!
		if !params! EQU false echo !Line!>>!new_shader!
		if !Anfang! EQU parameters set params=true
	)
	for /f "tokens=*" %%a in (!shader!) do (
		set Line=%%a
		set Anfang=!Line:~0,10!
		if !params! EQU false echo !Line!>>!new_shader!
		if !Anfang! EQU parameters set params=false
	)
	echo !new_shader! created
)
pause

Now you can execute the batch file. It will create a subfolder called _new _ and will create an updated version of each file with the extension “slangp”. That’s it.

You can now use your newly generated, updated presets.

What else? Maybe you should know this:

  • If you had manually added shaders to the original presets chain, you have to add them to the new presets again manually, obviously. The chains change, so this cannot be automated. You have to do it by yourself
  • Some parameters from the old preset won’t exist in the new preset anymore, but still are copied by the batch to the new preset file. That’s no problem: they will be ignored, and the next time you apply changes or save your shader, they will automatically be eliminated.
  • Same for newly added parameters, that didn’t exist before: they will of course be missing in first place after the creation, but once you use the new preset, they will automatically be filled with the default values - and once you save or apply changes, they will show up in your preset file.

An remember, like always: use at your own risk :wink:

7 Likes

You are a star, will be using this for sure.

:vulcan_salute:

1 Like

Thx. I hope it will work for you. If not: just ask. I’m happy to help.

1 Like

Nice @frenki! thanks for your effort on this.

I’m hoping to start on a project soon which will get Retroarch to only save the changed parameters when you save in the UI, we’ll see how that goes :wink:

3 Likes

Nah, i mean the circles that look like rings in a tree stump.

1 Like

Hey! I have started a thread of my own for the graphics I am creating for this shader.

https://forums.libretro.com/t/duimon-hsm-reflection-shader-graphics-feedback-and-updates/28146

Links to the files and updates will be confined to that thread.

6 Likes

Nice! Feel free to cross link when you have cool updates (although I’m going to follow it myself anyway)

4 Likes

Hi, the moire artifacts you’re seeing could be because of a couple of issues, the latest release has some degradation of the screen image which will be fixed in the next update.

At that resolution I wouldn’t expect a lot of moire.

The base cause of the moire artifact is the curvature, if you set the curvature to 0 the moire should go away

1 Like

lol. Will do once I figure out how.

1 Like