Dogway's grading shader (slang)

I don’t think it will be helpful as information, but just in case.
Or please keep in mind that there is an error because this is a simple measurement with a smartphone. The error is about ±200.
This is a Japan SONY BRAVIA.

high

Medium (Japan SONY BRAVIA default settings)

Low

Expert 1 (Expert 2 is not linked with video distribution)
This is the color temperature automatically selected in Cinema Mode, Game Mode and PC Mode.

TV mode High

If you select Middle and Low in TV mode, it will be the same color temperature as before, so exclude it.

2 Likes

In Japan, mega drives use composite cables, so I don’t think the color temperature will be that high. 6500-8000K I think. I don’t know how high it can actually go.

It seems that 12000K and 14000K are only available when receiving broadcasts.

1 Like

Before that, I have this knowledge. I have heard that people overseas, especially Caucasians, have pale eyes and are not good at brightness. In particular, I heard that “KONAMI intro screen makes me want to smash the screen.”

Japanese people have darker eyes, so they are more resistant to brightness. Perhaps this is why the NTSC standard was divided between Japan and other countries.

1 Like

To add on to that I don’t think crts in general even had a “cool” mode in their settings until the mid 90’s, I could be wrong though. I know I don’t remember seeing any “cool” settings in my crts until the days of Saturn/PlayStation/N64.

1 Like

I think it was only installed in professional CRTs or PC-monitors or high-end consumer TV. And this will break your eyes in Dynamic mode. I think that the color temperature was quite high even with plasma. Cool mode was effective only when receiving TV, and this function was invalid for external input.

By the time SS/PS1/N64, cool mode had already disappeared from high-end consumer TV.

Also, cool mode and I used it normally without being conscious of it, but in Japan cool mode is dynamic mode.

dynamic mode
Standard mode
Cinema mode
Game mode

In Japan, the terms “cool” and “warm” were never used in this way.

Also, when I enabled the game mode (low latency) on a general cathode ray tube, it was always 6500K. Cool mode (dynamic mode) could not be used in the game

I think it’s 7500-8000K if you don’t use game mode. It is also doubtful whether the dynamic mode could be used with the external input. I have never tried.

2 Likes

These terms were used for crts in the 90s in Japan? I thought those were names that came around when hdtvs started hitting stores in the early 2000’s or so. I don’t remember seeing a “game mode” on American crts in the 90s. In fact even this old 4k TV I’m using now still uses terms such as “warm”, “normal” and “cool”. It’s also where I got the idea from recently to start making warm normal and cool presets lately.

1 Like

This is an example of video mode on SDTV in Japan. Some Japanese models had physical buttons like this. External input and game buttons are independent.

When I switched to video 2 with the external input button, there was no change, but when I switched with the game button, the color temperature dropped. I remember this clearly. At the time, I thought it was a mode to protect my eyes.


and...

https://www.jstage.jst.go.jp/article/itej1978/42/12/42_12_1358/_pdf



I was surprised when there were not only 14000K but also 15000K and 20000K. The data seems to indicate that increasing the color temperature increases discomfort. This seems to be an experiment with a black and white CRT… The reporting period is 1988.

Because of this, 14000K was abolished, and I think that 12000K is now the upper limit.

If you try to reproduce 14000K, I think it is impossible without HDR. And since 14000K was discontinued early even in Japan, I don’t think we need to think about it after 14000K…

It’s not good for eyes.

1 Like

I’ve spent too many hours trying to figure out where to put Dogway’s GitHub files in Retroarch to get the shaders to work. Can someone help me figure this out? It’s going way over my head apparently, haha.

1 Like

Never knew Japanese sdtvs from back then actually had a “game” button on the remote, that’s interesting.

I think even 12000k is extreme but it’s still interesting. When I’m ready to make my “Japan” shader presets I’ll most likely use 6500k for (warm) cinema mode, 9300k or something close to that for standard and it’s still up in the air which white point I’ll use for cool, maybe I’ll just go with the 12000k I don’t know yet.

1 Like

The grade shader comes preloaded with RetroArch. Go to shaders_slang then go to the “misc” folder and it’s in there.

@Greetings @Dogway. I’ve been playing around with the new Grade for a few days now and I think it’s fantastic what you’re did here.

There’s one feature that I would like to be able to turn off without affecting anything else if possible and that’s the raised black level.

I use an OLED TV and prefer the jet black blacks even for CRT emulation. Even when I used to use CRTs a very long time ago, I used to turn the brightness down to eliminate any noise, improve saturation and get things jet black.

The problem is that I can’t seem to find a way to turn this raised black level texture off or down without crushing the blacks I would like to keep.

I don’t think I ever encountered this in the old grade.

As an example I like to use the halo around the green Nintendo logo in Donkey Kong Country to set SNES gamma, however so far I haven’t been able to do this with the new Grade because the raised black level texture is blending with it and making it difficult to see what’s going on.

If I set the Black Level to -0.01, the green fade effect around the logo seems to completely disappear. That can’t be right?

I’ve tried lowering the Black Level to see if I can turn the texture off while looking closely at my TV and even down to -0.25 it can still be barely visible.

At these settings though all my hard calibration work goes out the door.

Can this be made optional for someone who would like the best of both worlds when it comes to harnessing the advantages of the new tech with emulating the old?

3 Likes

Yes, the 1886a function assumes a black lift depending on gamma, that’s by design from the paper. In grade-mini PR (which I will pull out in a week due to lack of interest) I added a black-lift compensation fit for this effect. I can try to port that to Grade with an extra gamma compensation as now the image would be slightly darker.

3 Likes

Interesting.

Hopefully this won’t mess up your masterpiece in any way.

I just checked over this phenomenon with a few different presets I was noticing it with with the aim of sharing some screenshots to better demonstrate what I’m talking about when I found that I hardly noticed the issue of the black lift texture being visible at Black Level values below -0.01. The difference with now and then though is now it’s still daytime and when I couldn’t get rid of the raised black texture it was at night and the room was probably much darker. At that time I was also doing some hard tweaking so I was wondering if it was persistence of vision or my mind playing tricks on me.

Today had me wondering the same because it doesn’t seem to look like I can see the texture with the naked eye when Black level is at -0.01. Initially I wasn’t seeing it in my screenshot either. However when I zoomed in on those dark areas in my screenshot, I could see those lit pixels.

Here are the results, the first three are taken from my new preset pack using the new Grade, CRT-Royale and Super XBR, while the others are taken from some experimental CRT-Guest-Advanced or NTSC presets.

New Grade, CRT-Royale and Super XBR

CRT-Guest-Advanced or NTSC

1 Like

Yes you need to test these things on dark adapted vision. And if possible isolating the shader in question, that means testing Grade solely.

Hopefully this won’t mess up your masterpiece in any way.

Not that it will mess it in any way, but doing regressions is a last measure approach. I was unable to find an operand in 1886a that would keep blacks normalized and maybe it’s impossible to do so a regression fit would be fine in this case.

I see that you added some black crushing with -0.01, and that’s fine, but I will apply the fit in a non-linear way so it will work exactly for any CRT gamma input value given. I will also study the needed gamma gain to counteract the darkening from the normalization. I don’t know when I will do this but I’ll post here when that happens. I also need to review zfast_crt_geo_svideo for further performance optimizations.

1 Like

Of course, in this case I had been using the older grade via HSM Mega Bezel Reflection Shader then CRT-Guest-Advanced/NTSC, then I paired it with my new CRT-Royale Presets. I had never seen any behavior or appearance like that until I replaced the old grade with the newer grade. So that’s the only variable that changed.

I included the screenshots using CRT-Guest-Advanced/NTSC just to show you what I do using Donkey Kong Country and what I would like to be able to do that is being somewhat hindered by the current behaviour of the new Grade.

It was only a necessary evil to attempt to get rid of the raised black level texture. I would much prefer to be able to finely adjust the Green Nintendo logo in Donkey Kong Country until it just slightly and very gradually fades into black while keeping my jet blacks which I have grown accustomed to and which help to offset the limited brightness inherent in OLED TVs relative to some of their counterparts as well as inherent in high opacity Mask and Scanlines settings due to the increased contrast provided by that 0 nit black experience.

To be honest it felt like my OLED TV was turning into an LCD TV. Lol

So in other words the raised black level is lowering my contrast ratio and I’m already limited by the style of presets I create - limited bloom, glow and halation in the name of mask preservation.

My approach is a sort of phosphor and scanlines first approach. Everything else has to fit around that concept and constraint.

Two more things to consider are the possibility of this texture clashing with the new visible inactive phosphor mask and mask wires feature from CRT-Guest Advanced and similar tube glass colour feature in Mega Bezel Reflection Shader and I also noticed inconsistency in the brightness of the lines which made up the texture i.e. each horizontal line is not the same brightness as the one above or below it.

Thank you very much for looking into this.

1 Like

@Cyber I updated Grade with several updates.

So black lift compensation is implemented now in 1886a function. Following a gamma compensation, not much though, at gamma 2.31 the black lift is about 0.1, so a gamma compensation of 0.998442 to raise darks is needed. This was regressed, not perfect fit but better none the less. Here’s my workbench.

Now you can use “Black Level” parameter alongside “Surround Luminance” to raise blacks.

Talking about “Black Level” I refactored it to mean real values in 8-bit scale. So you define +10 and it means a perfect black will be raised to an 8-bit value of 10 (0-255 scale), regardless of display gamma output.

Finally a small optimization in case you want to bypass original game colors (skip the wp_adjust function with all its matrices work). Basically you set signal_type to RGB, phosphor to sRGB, color space to sRGB or 709, and temperature to ~6504K.

6 Likes

What are the primaries of 80s-90s TVs? For some reason i can’t match my CRT colors(Trinitron, eg blue looks more red-ish in CRT). While NTSC colors improve the desaturated Microsoft RGB colors, it looks different.

I think it should be something close to P22 at around 7000K?

2 Likes

Wow! Thanks very much! Has this been pushed to the RetroArch repo yet?

1 Like

Here you can see in order 80s, 90s and RPTV. You say Trinitron, is it a model for the US or Japanese market? For the Japanese market you use P22_J, since the problem is with blues you can play with temperature or CRT beam It would never be perfect but at least in the ball-park.

What do you mean with “Microsoft RGB” Colors?

Not yet, waiting for some feedback first to minimize PRs

2 Likes

It is European. I guess it should be EBU-Rec601 PAL? Difference is almost nothing compared to default RGB colors. In any case, i am doing something wrong in code i think… I meant sRGB because it was made by Microsoft :smile:

1 Like