Please show off what crt shaders can do!

An EGA filter with dithering i ported (added a PR inside folder misc) :stuck_out_tongue_winking_eye:

4 Likes

Added CGA mode too along with EGA.

crt-consumer as 2nd pass

6 Likes

Is this bayer dithering and is this a EGA palette? I miss these bright colors https://preview.redd.it/7skrn8o84v341.jpg?auto=webp&s=6cbacb81cfc9cbfc39efcef61800a9ae71cd1088 and dither should mix them in.

1 Like

Well i guess i can adjust the palette.

1 Like

Maybe. Do you use a 3Bit or 4Bit quantization? If you use only 3Bits you end up with 8 colors.

1 Like

Yes and basic 16 colors of EGA are covered.

And which quantization shader are you using?

I used this small glsl function for 5Bit quantization. But every main color channel has 5 Bits. EGA looks like 2Bits per channel. Divider would be 1.0/4.0.

Quantization must be applied after dithering pattern was added.

1 Like

If you do a

round(color*3.0)/3.0;

3 is the number for EGA,it goes on steps of 0, 85, 170, 255. 3 is full 255.

In the end you will cover all 64 (4 * 4 * 4) EGA colors, and that is not how EGA supposed to look like.

2 Likes

Oh yes. That’s right👍.

2 Likes

Added hercules and improved shader a bit to map more colors

5 Likes

@DariusG EGA has a 64 color palette. 16 colors can be used at the same time. In theory you could analyze source texture with a histogram and pick up the 16 best fitting colors :sweat_smile:.

2 Likes

So essentially with these latest shaders you’ve essentially created a “DOS/Vintage PC Monitor Shader Pack”? Am I right?

If so, I hope it will be easy to locate and that maybe someday it can be integrated with the venerable Mega Bezel Reflection by @HyperspaceMadness!

These bring back so many fond memories of never having enough computing horsepower to run anything you wanted but you didn’t let that stop you. I read the entire DOS 3.3 manual looking for ways to optimize performance in games on an old dual 3.5" pre 286 I believe IBM PS/2 sometime in the early 90’s.

2 Likes

Well they could be combined to create a dos monitor yes. :wink:

2 Likes

4 Likes

@DariusG Just thought about it again and tried a own implementation:

gizmo-crt-shader/glsl_shaders/dithering at main · gizmo98/gizmo-crt-shader · GitHub

3 Likes

This preset is my customization/copy of @Cyber and @RetroGames4K presets. I converted them to the glass version. I did this by eye so anything off is definitely my fault and not theirs :sweat_smile:

I use this on my LG C9; Vulkan; HDR=ON; 700 nits; paper white = 300 nits; 5.00 contrast

This is using Megabezel

#reference "shaders_slang/bezel/Mega_Bezel/Presets/Variations/Glass-Minimal-Bezel-Edge__ADV-GLASS.slangp"
post_br = "2.079999"
HSM_INT_SCALE_MODE = "1.000000"
HSM_INT_SCALE_MAX_HEIGHT = "100.000000"
HSM_DREZ_SIGMA_HV = "0.700000"
HSM_DOWNSAMPLE_BLUR_SCANLINE_DIR = "23.000000"
HSM_DOWNSAMPLE_BLUR_OPPOSITE_DIR = "16.000000"
HSM_CURVATURE_MODE = "0.000000"
HSM_SCREEN_REFLECTION_SCALE = "200.000000"
HSM_REFLECT_NOISE_SAMPLE_DISTANCE = "70.000000"
SHARPSMOOTHER_ON = "1.000000"
smoot = "0.230000"
CP = "3.000000"
g_signal_type = "0.000000"
g_crtgamut = "0.000000"
wp_temperature = "6504.000000"
m_glow = "1.000000"
glow = "-0.040000"
bloom = "-0.050000"
halation = "-0.025000"
BLOOMCUT_H = "0.500000"
SIGMA_VB = "0.250000"
mask_bloom = "0.350000"
gamma_c = "0.900000"
brightboost1 = "1.350000"
gsl = "2.000000"
scanline1 = "9.000000"
scanline2 = "9.000000"
beam_min = "1.350000"
beam_max = "1.300000"
scans = "1.600000"
shadowMask = "12.000000"
maskstr = "1.000000"
maskDark = "0.000000"
maskLight = "2.000000"
mask_layout = "1.000000"
mask_gamma = "1.550000"
slotwidth = "7.000000"
double_slot = "3.000000"
mclip = "0.900000"
smoothmask = "1.000000"
GDV_DECONVERGENCE_ON = "1.000000"
decons = "1.400000"
dcscalemode = "2.000000"
GDV_NOISE_ON = "1.000000"
addnoised = "0.180000"
noiseresd = "1.000000"
noiseresd4kmult = "1.000000"

Here’s a bonus screenshot. Is it a CRT? :thinking::

5 Likes

Great Job of doing 16 Colour quantization and dithering. While your implementation might appear to be more aesthetically appealing compared to @DariusG’s, are you sure it’s more authentic from an 80’s EGA implementation perspective? Were all of those dither patterns and dithering techniques commonly in use at the time? What about the source palette? Were there limitations there as well?

This might tend to wash out the mask a bit on the whites.

Also, which presets did you use?

I’m glad you were able to get our settings integrated with the glass base preset!

1 Like

Yeah, I did this on purpose because from my viewing distance it makes a big difference in brightness and removes some of the dulling/slightly warm coloring. I believe I may have used CyberLab_Arcade_CyberTron_Neo-GX

1 Like

@Cyber I just use the default 4x4 bayer matrix which was certainly used in the 80s for printers and so on. There are much better dithering methods even for animations like noise dithering or a higher order bayer matrixes.

The EGA palette was not right. Should be fixed now with latest commit.

4 Likes

The 640 × 200 and 320 × 200 EGA graphics modes provide backwards compatibility with CGA software and monitors, but permit use of all sixteen colors in the CGA palette. Full CGA palette is what is used at 320x200 (most probably the resolution for 99% of games). In the 640 × 350 high resolution mode, which requires an enhanced EGA monitor, 16 colors can be selected from a palette comprising all combinations of two bits per pixel for red, green and blue, allowing four levels of intensity for each primary color and 64 colors overall.

FWIW Master system uses the same 64 col palette but no cga limitations and 32 colors on screen (I think).

2 Likes