Mega Bezel Reflection Shader! - Feedback and Updates

How is it with other shaders like crt-royale?

Other shaders work fine.

The HSM shader will crash if I load it while Mario 64 is on the title screen, but if I wait until the save select screen is loaded, the shader will load, but the game will stutter.

This is on 4x upscaling, 2x works fine and doesn’t crash

1 Like

It’s not a problem with the shader, must be something else, I’m running Parallel at 4x resolution, and I’m using the shader.

Although I’m using 4x downsampling to 240p in Parallel64, I made sure to disable downsampling to test it at “pure” 4x upscaled, works just fine. Screenshots below

I’m no expert but I think that your GTX 1050 is lacking VRAM to handle it. I have a 1080ti with 11GB VRAM.

Edit: Parallel64 at 4x with HSM Bezel is consuming 2,7 GB of VRAM for me. image


Most likely, been meaning to pick up a new GPU for a long time, just haven’t found a good enough deal on a 1060/580.


Got it working - chose the shader again and it appeared. Looking good, thanks for this!

1 Like

Thanks for the latest updates :slight_smile:

I’ve become a fan of Dogway’s grade shader and would like to try it in combination with your preset that only has the 2D and 3D screen curving options, the “hsm-screen-scale-crt-guest-dr-venom.slangp” preset from your folder.

The grade shader does everything needed for grading - custom CRT gamuts, CRT Gamma, whitepoint and all thinkable color adjustments. It’s different from the default CRT options in guest-dr-venom, and IMO adds value over those. You may or may not be familiar with it, but here’s the thread discussing the ins and outs:

Inserting grade.slang in the default guest-dr-venom shader is done by removing the first two passes “LUT” and “color-profiles” and renaming the passes from 0 to 7 (so 8 shader passes remain after removal of those two) and then changing the new “0” pass:

shader0 = “shaders_slang/crt/shaders/guest/d65-d50.slang”

To this (i.e. grade.slang replaces guest-venom default d65-d50.slang as “WhitePointPass”)

shader0 = "shaders_slang/misc/grade.slang"
filter_linear0 = "true"
wrap_mode0 = "clamp_to_border"
mipmap_input0 = "false"
alias0 = "WhitePointPass"
float_framebuffer0 = "false"
srgb_framebuffer0 = "false"
scale_type_x0 = "source"
scale_x0 = "1.000000"
scale_type_y0 = "source"
scale_y0 = "1.000000"

Now the very first pass in your shader adaption of guest-dr-venom is already different, with setup parameters and such so I don’t dare to touch this :slight_smile: Also I don’t see the d65-d50.slang to replace, so I could use a helping hand as to where to put the grade shader into your screen scale only preset as quoted below?

I really don’t want to mess anything up with your shader, so any advice help would be welcome where to put the grade pass?

// Add Mega Bezel Params & Initial Prep
//      Add Mega Bezel parameters at the beginning of the list for easy access
//      Add Color Correction
//      Calculate Average Luminance and put in alpha channel
//      Debug Drawing of the resolution & screen scaling info
shader0 = ../crt/shaders/HyperspaceMadness/hsm-prep-initial-screen-scale-only.slang
alias0 = WhitePointPass

// Linearize Color ----------------------------------------------------------------
shader1 = ../crt/shaders/HyperspaceMadness/hsm-guest/hsm-guest-linearize.slang
filter_linear1 = false
scale_type1 = source
scale1 = 1.0
float_framebuffer1 = true
alias1 = LinearizePass

// Guest-Venom Pass ----------------------------------------------------------------
shader2 = ../crt/shaders/HyperspaceMadness/hsm-guest/hsm-guest-linearize_scanlines.slang
filter_linear2 = true
scale_type2 = source
scale2 = 1
float_framebuffer2 = true

// Reduce resolution to a small consistent size so blur is consistent between different core resolutions
shader3 = ../crt/shaders/HyperspaceMadness/hsm-guest/hsm-get-linearize-pass.slang
filter_linear3 = true
mipmap_input3 = true
scale_type3 = absolute
scale_x3 = 320
scale_y3 = 320

// Guest-Venom Pass ----------------------------------------------------------------
shader4 = ../crt/shaders/HyperspaceMadness/hsm-guest/hsm-guest-blur_horiz.slang
// mipmap_input4 = true // This is commented out on purpose, was causing small white dots appearing on final image
filter_linear4 = true
scale_type4 = source
scale4 = 1
float_framebuffer4 = true

// Guest-Venom Pass ----------------------------------------------------------------
shader5 = ../crt/shaders/HyperspaceMadness/hsm-guest/hsm-guest-blur_vert.slang
mipmap_input5 = true
filter_linear5 = true
scale_type5 = source
scale5 = 1
float_framebuffer5 = true
alias5 = GlowPass

// CRT Shader - Guest-Venom ----------------------------------------------------------------
//      Guest's Awesome Shader!!!
//      Has been slightly altered to use the same scaling as the rest of the shders for the bezel & reflection
shader6 = ../crt/shaders/HyperspaceMadness/hsm-guest/hsm-crt-guest-dr-venom-with-scaling-mask-outside-screen.slang
mipmap_input6 = true
filter_linear6 = true
scale_type6 = viewport
scale_x6 = 1.0
scale_y6 = 1.0
float_framebuffer6 = true
alias6 = BR_CRTPass

shaders = 7

// Define textures to be used by the different passes
textures = "SamplerLUT3;"
SamplerLUT3 = ../crt/shaders/HyperspaceMadness/textures/lut/other1.png
SamplerLUT3_linear = true

Hi, I would suggest putting this right after the first pass, then turn all the color correction options from the Mega Bezel to neutral values. Hopefully there are enough parameter slots left for grade when the bezel stuff is not present.

It might technically be possible to remove the first pass but I don’t recommend it because the other shaders in the presets have a general expectation that it’s there.

Let me know how your experiment goes!

Edit Note: The d65-d50 is integrated into the first pass, and the first pass has the phosphor persistence which is similar to the afterglow.

1 Like

Do you have any plans to include grade in your shader? @HyperspaceMadness


It might be possible to add it to one of the screen scale presets (the ones without the bezel), but not the Mega Bezel ones because the Mega Bezel maxes out the number of parameters available.

There would be a way to integrate it without exposing the parameters and having the parameters values predefined, but this would make it harder to use.


Here are some snapshots from an experiment with Nintendo DS and Blending the screens together, I’m also going to try a reflection type treatment between the screens to see how that works.


I’ve always been a fan the DS emulations side-by-side screen option. You get better use of widescreen real estate.

In any case… I like what you’re doing! Never thought we’d see any dual screen systems here.

This is what screen rotation is for, friend :slight_smile:

Any chance of adding a screen sheen/scratch effect parameter? I know that there are a few tube parameters that add a bit of glow/reflection on the screen, but I’m talking about screen surface scratches/scuffs. In my experience this can make the difference between it looking like an effect and an actual screen. I usually apply this via overlays, so I’m not sure if it would be possible to do it via a bezel like this?

1 Like

It’s definitely do-able as the glass reflection thing is just an image being loaded into the shader.

We just need a good image, and for @HyperspaceMadness to want to include it, lol.

1 Like

You can do this with functionality already in the shader…

The tube glass image was designed for this exact purpose and is automatically scaled to the screen. Just replace HSM’s reflection image with your scratches image.

Also, the TopLayerImage has a “screen only” mask as one of the mask parameters. You can use an image of your choice and also a blending mode of your choice. (But you couldn’t also have a night mode TopLayerImage.)

Slang shaders (and others I suppose) have a limit on how many textures you can have. (Learned from one of my discussions with @HyperspaceMadness)

It’s possible that HSM could add scratches in code but that would limit everyone to just one “image” choice.


What they said :wink:

I think the best thing to do here since a scratch effect is best achieved with an image and the limitations on number of textures is to have a separate tube image with scratches and screen highlight included, then include this as a texture in the shader package which can be used if desired.

Below is also good option which would allow you to dial up the visibility of the scratches separate from the glass reflection:

Do you have an image of scratches that you really like that you have used in other overlays?


Yup this is a good point, I’m planning to support this too, probably the shader will check the aspect ratio and split in the middle of the longest axis, so it would split correctly in left/right and top/bottom layouts.


Just when I thought you were done pullng surprises out of your hat.:grin:

1 Like

Yes, I have tended to use the image I’ve pasted below. It’s good to use it with an alpha/transparency adjuster so that you can get the effect just right - I find 100% can be a little too much.

I actually used it with your shader as an overlay, but the corners don’t match exactly so it’s hard to get the sizing right. Perhaps the edges could do with a little smoothing too.

1 Like

Just a note if you want to use something like this as the top image in the Mega Bezel there are a number of different options for the masking, so you can set the mask to inside the tube area and you don’t need to worry about the corners of the tube as long as the image is big enough. There are also different blending options, e.g. normal, add and multiply.

Also, thanks for your image!

Do you have one with the scratches and no highlight?

1 Like