New CRT shader from Guest + CRT Guest Advanced updates

New Release Version (2021-06-15-r1):

Notable changes:

  • New scanline spike removal code, faster and nicer, more fluid scanlines.
  • Scanline type 2 falloff correcture.
  • Very nice downsampling options added.
  • Some spedup.
  • NTSC version overhaul.
  • Improved scanline deconvergence.
  • Better performance with interlacing.
  • Deconvergence adapted for non standard presets.
  • Probably some more stuff.

Download link:

https://mega.nz/file/s0wExKaZ#fXhYzve299uorU81lFupC7TgS7eeolNM8cWM_5VBzDY

Feedback is welcome as there are many changes, hopefully no regressions.

12 Likes

A post was merged into an existing topic: Mega Preset Assembler

Does this look right? Seems like magenta was stronger in the example screenshot you posted.

scanline deconvergence 1.00

scanline deconvergence -1.00

2 Likes

72fps vs 65fps before same parameters on my HD4000 here.
Yeah my GTX770 just died… :persevere:

2 Likes

RIP your card and now your wallet

1 Like

It’s a new implementation, definitely more consistent on thinner scanlines. The default strength on normal scanlines is sortoff a new deal, should be around the same as before, but not stronger.

3 Likes

The Sonic waterfall transparency is gone in the new NTSC version.

1 Like

Same here.
And with the new “custom” parameter of the ntsc shader, you can see that fringing isn’t really making a big difference when pushed high.
There’s always some problems with changing the ntsc passes resolutions. :slightly_frowning_face:

1 Like

For ‘old’ look the ‘Prescale-X Factor’ can be set to 2.0, transparency should get a better treatment.

Meanwhile i also improved the ntsc composition and the second ntsc pass outputs to 2x native resolution, but from a better perspective filtering still got priority.

2 Likes

New Release Version (2021-06-16-r1):

Notable changes:

  • New scanline spike removal code, faster and nicer, more fluid scanlines.
  • Scanline type 2 falloff correcture.
  • Very nice downsampling options added.
  • Some spedup.
  • NTSC version overhaul.
  • Improved scanline deconvergence.
  • Better performance with interlacing.
  • Deconvergence adapted for non standard presets.
  • Probably some more stuff.
  • Edit: nicer NTSC preset.
  • Edit: polishing of scanline type 2.0 and scanline deconvergence.

Download link:

https://mega.nz/file/9kxWjIDB#VWXh76-DUHmfjx_bTc3xuXKc9CqPfmsAeaZ16u0dYWI

The feedback was a bit modest, but stil useful. :grin:

12 Likes

Example of the new ntsc preset:

6 Likes

Can I ask what the native resolution of your monitor is?

1 Like

It’s an 2560x1440 IPS monitor. Sometimes i make windowed screenshots because of the reduced filesize.

2 Likes

@guest.r

I’m not sure why this doesn’t work; some kind of syntax error.

In case it’s not obvious, I’m trying to do yellow, purple, blue, green because I have GRB subpixels.

New version of GDV is working great btw. :slight_smile:

Also, is there documentation for GDV somewhere? I’m curious about the CRT color profiles.

// 4k mask
	else 
	{
		mask = vec3(mc);
		pos.x = fract(pos.x * 0.25);
		if      (pos.x < 0.2)  mask.rg  = 1.0.xx;
		else if (pos.x < 0.4)  mask.rb = 1.0.xx;
		else if (pos.x < 0.7)  mask.b = 1.0.;	
		else                   mask.g  = 1.0;	
	}
3 Likes

else if (pos.x < 0.7) mask.b = 1.0.;

The extra dot after 1.0 looks suspicious. :wink:

Dr. Venom made a very nice job producing and documenting these:

"CRT Colors" for CRT-Guest-Dr-Venom  -- Additional information.

3 x spec
2 x calibration

Specifications for three standards

1. EBU Standard Phosphors
// Amongst others used in Sony BVMs and Higher-end PVMs
// Tolerances are described in the E.B.U. standard reference document "E.B.U. standard for chromaticity tolerances for studio monitors" tech-3213-E.
// PVM-1440QM service manual quotes 0.01 as tolerance on the RGB CIE coordinates. 

xb0 = "150.000000"
xg0 = "290.000000"
xr0 = "640.000000"
yb0 = "60.000000"
yg0 = "600.000000"
yr0 = "330.000000"

Whitepoint is D65

X 95,04  --> Xw0 950.4
Y 100    --> Yw0 1000
Z 108,88 --> Zw0 1088.8

2. P22 Phosphors 
// These phosphors are often quoted as the "default" phosphors used in CRTs 
// Also used in lower-end PVMs, see Sony PVM-20M4E 20M2E Colour Video Monitor.pdf
// These can still be bought :-)  https://www.phosphor-technology.com/crt-phosphors/  -- includes CIE coordinates.

xb0 = "148.000000"
xg0 = "310.000000"
xr0 = "647.000000"
yb0 = "62.000000"
yg0 = "594.000000"
yr0 = "343.000000"

3. SMPTE-C
// Spec for most of America.
// I have forgone on the 1953 NTSC standard, as apart from very few early color TV's the 1953 NTSC standard was never actually used. Instead less saturated primaries were used to achieve brighter screens.
// Taken from the WIKI on NTSC (https://en.wikipedia.org/wiki/NTSC) In 1968-69 the Conrac Corp., working with RCA, defined a set of controlled phosphors for use in broadcast color picture video monitors. This specification survives today as the SMPTE "C" phosphor specification: 

xb0 = "155.000000"
xg0 = "310.000000"
xr0 = "630.000000"
yb0 = "70.000000"
yg0 = "595.000000"
yr0 = "340.000000"

Whitepoint is D65

X 95,04  --> Xw0 950.4
Y 100    --> Yw0 1000
Z 108,88 --> Zw0 1088.8


4. Calibrated profile for Philips CRT monitors. Of course an approximation, but I'm pleased with the "quite accurate" results.
// Manually calibrated and compared to real Philips based CRT monitors, running side by side with the shader on a 10-bit DCI-P3 gamut panel. This calibrated CRT profile covers amongst others Philips CM8533, Philips VS-0080, and Commodore 1084.
// Note the whitepoint is significantly different from D65. It's closer to 6100K, but clearly not on the blackbody curve. Possibly an ISO-line target, given the slight hue on the whitepoint. Other than that it could be aging / whitepoint drift. I compared four CRT monitors, one of them in very mint condition, and they all have this slight hue on the whitepoint, so I would guess this is how they came out of the factory. But then again since these things are now getting close to 30 years old, who knows? Either way the profile should be good: factory out or true to life aged CRTs... :D.   
// It's important this specific whitepoint is used in the shader or the colors will not be accurate.
// Also it's important to note that this profile should be used with "Gamma Out" at 2.25 or the colors will be less accurate.

xb0 = "154.000000"
xg0 = "300.000000"
xr0 = "635.000000"
yb0 = "60.000000"
yg0 = "620.000000"
yr0 = "339.000000"

Whitepoint:
Xw0 = "910.000000"
Yw0 = "1000.000000"
Zw0 = "960.000000"


5. Calibrated profile for Sony Trinitron Monitor. 
// In a similar fashion as the Philips CRT based profile, this is a manually calibrated profile for a Sony Trinitron monitor, model KX-14CP1.
// This monitor uses a Whitepoint that is close to 9300K. The Z value in the calibration process has been raised to the point where the "blue-ishness" of the white matches. To achieve further 9300K white, I guess one has to raise the hardware whitepoint of the host PC monitor...
// It's important this specific whitepoint is used in the shader or the colors will not be accurate.
// Also it's important to note that this profile should be used with "Gamma Out" at 2.25 or the colors will be less accurate.

xb0 = "152.000000"
xg0 = "279.000000"
xr0 = "647.000000"
yb0 = "60.000000"
yg0 = "635.000000"
yr0 = "335.000000"

Whitepoint:
Xw0 = "903.000000"
Yw0 = "1000.000000"
Zw0 = "1185.000000" 

Reference is the readme file in the /guest folder, also included with newer versions.

4 Likes

see, this is why I don’t do code lol. Thanks for the help!

2 Likes

Yooo.

Even when you code you do this shit… If I’m just starting for the day you better believe I’m making some kind of damn sentax error.

3 Likes

So if we’re using a color profile with a different white point or gamma should we also adjust the white point and/or gamma in grade? For example, if we’re using profile 5 (calibrated Trinitron monitor), should we also set grade’s white point to 9300K and grade’s gamma out to 2.25?

Should we basically just consider GDV’s color profiles as an alternative to using grade?

2 Likes

Grade is kinda like color profiles on steroids iirc, so if you can get what you need from gdv and color profiles you don’t really need grade in that mix.

2 Likes

The transformation matrix considers the ‘color triangle coordinates’ + white point, so there is no need to extra set the white point, because it would just double the effect. Assuming corresponding LCD calibration and OS settings ofc.

Gamma is trickier, because it might refer to the matrix multiply gamma in/out. Anyway, it’s best to use grade’s gamma or crt shader gamma combinations.

4 Likes