New CRT shader from Guest + CRT Guest Advanced updates

OK, i found a good combo… :smiley:

New Release Version (2021-07-23-r4):

Notable changes:

  • NTSC scaling adjusted regarding original resolution.
  • NTSC phase can now be forced (auto is still default).
  • Needs testing.

Download link:

https://mega.nz/file/wpwVCYaC#XU3JS9LccSCUCLqhWV-XgGE8gfP1ayhRdXqz5RUD5yU

9 Likes

That’s wonderful. I hope this gets integrated into Mega Bezel. It would be perfect.

4 Likes

It’s officially on the list :grin: so hopefully will come in before too long :slight_smile:

8 Likes

So crt-guest-advanced-hires is for higher res content i presume (high, like 480p?) but what is crt-guest-advanced-ntsc is used for? PS - in ideal world there will be presets for each console (for somebody like us who does not understand what each shader settings do) and maybe for each console with different resolutions lol, but doubt it will be possible because everybody has different preferences :blush:

1 Like

It can be used for regular content of any sort. The ntsc shaders add signal encoding and decoding procedures, which emulate different connection types feat. analogue signaling used with a classic crt display.

Pros are that originally pixel art wasn’t designed for modern digital connections and representations and those features were considered. So dithering gets blended nicely plus you get quite authentic coloring effects.

I like to mention that i like to implement features to have an adequate parameter range and step, so users can quickly understand what that parameter does. So some curious tinkering of the shader’s parameters is welcome.

Not to mention the crt displays. The result is multiplicative, like 10 consoles and 10 crt display types make 100 presets… :grin:

3 Likes

@guest.r

With your latest release, my profile is complete. The “Merge” option you added finally let me complete the NES era settings without visual compromise.

I wish to share with you a before/after screenshot. As well as the people on this thread.

A quick mention, I use this shader for handheld consoles as well, as it dramatically helps when extending to a higher screen size.

I’m taking ALL criticism. Keep in mind that my goal here is not nostalgia but the positive benefits of the shader with as little trade-off as possible to visual clarity.

2 Likes

New Release Version (2021-07-27-r2):

Notable changes:

  • Adjustments and some tweaking for the official repository.
  • NTSC code cleanup.
  • Edit: small fix.

Download link:

https://mega.nz/file/V9oWhBSb#5Bfyexy1BhWX_CQ1r2zBRxu0j5pKPrNMl00YkHniqBw

10 Likes

So, are the crt-gdv-new/crt-guest-dr-venom2 directory, shaders and presets obsolete? Can I completely replace them with the ‘advanced’ ones?

4 Likes

Yes, they should be obsolete compared with the new versions. Though the directory could stay for a while if users have custom presets saved. The preset itself can be removed though.

5 Likes

Okay, I have PR open to bring the repo up to date, if anyone cares to test it (or just take a look at all of the changes):

I also modified ntsc-pass1 a bit to make it automatically merge fields for svideo and composite (this is how blargg’s filter does it, and I think it’s technically correct) and leave them unmerged for RF, but with the ability to control it manually if it’s in ‘custom’ mode, and I added ‘NTSC’ to all of the NTSC shaders’ parameters to make them clearer in the parameter list.

6 Likes

Thanks @hunterk! for the effort!

I would only suggest the ‘last minute change’ to the ntsc-pass1 file (vertex shader part), like this:

	float res = global.ntsc_scale;
	gl_Position = global.MVP * Position;
	vTexCoord = TexCoord;
	if (res < 1.0) pix_no = TexCoord * global.SourceSize.xy * (res * global.OutputSize.xy / global.SourceSize.xy); else
                   pix_no = TexCoord * global.SourceSize.xy * (      global.OutputSize.xy / global.SourceSize.xy);
	phase = (global.ntsc_phase < 1.5) ? ((global.OriginalSize.x > 300.0) ? 2.0 : 3.0) : ((global.ntsc_phase > 2.5) ? 3.0 : 2.0);
	
	res = max(res, 1.0);
	CHROMA_MOD_FREQ = (phase < 2.5) ? (4.0 * PI / 15.0) : (PI / 3.0);
	ARTIFACTING = (global.quality > -0.5) ? global.quality * 0.5*(res+1.0) : global.cust_artifacting;
	FRINGING = (global.quality > -0.5) ? global.quality : global.cust_fringing;
	SATURATION = global.ntsc_sat;
	BRIGHTNESS = global.ntsc_bright;
	pix_no.x = pix_no.x * res;  

The position of the res = max(res, 1.0); line was incorrect, should be exactly like above.

And thanks again. :smiley:

2 Likes

Got it! Thanks for the review :slight_smile:

2 Likes

With this release GameCube games look a bit too pixelated again.

2 Likes

Have you tried downsampling under Interlacing options?

1 Like

Yeah that or adjusting NTSC resolution scaling can work. I just liked that it was automatic before lol.

2 Likes

I think there’s a problem with ntsc when fringing and artifacting are active. (phase 3 here)
When pushing the resolution scaling parameter to the max at 3, it produces horizontal lines:

around 2.8 it’s diagonal lines.

If I do the scaling manually with x12 on pass1 and x0.166667 on pas2 I don’t have this problem, the result is clean.

2 Likes

It’s just out of the safe zone of the parameter and you can still do the scaling manually. :wink: With regular scaling there are more values at hand, you can fake the effect to a degree only. The scaling was originally limited to 2x though.

3 Likes

NTSC Adaptive shaders update:

I managed to improve the ntsc resolution scale feature for “upscaling”, which works much nicer now. Before “fixing” chroma channels broke luma and vice-versa. It’s possible to adapt both for scaling though with some extra lines of code.

Download link for ntsc-adaptive shaders:

https://mega.nz/file/wpQBFQiY#Eqs9yIzHtd96t-_woH0kKRwBjmeFy2Z5R8nOAUUwwBc

7 Likes

It’s a lot better at non integer scale now, here for 1.5 upscaling:

:+1:

7 Likes

@guest.r

Have you considered adding the sharpness filter from guest-advanced-ntsc to vanilla guest-advanced? Or would it not be feasible? I just like what it does for pixel art regardless of accuracy.

3 Likes