Mega Bezel Reflection Shader! - Feedback and Updates

I think you might want to take into consideration the luminance components for the P22 phosphors:

0.4665636420249939 0.25661000609397890 0.005832045804709196

that’s the transformation, the current primaries are:

0.640, 0.282, 0.146

As for these coefficients the red phosphor has almost double the luminance component than green.

2 Likes

Yeah, a LUT is a look up table, which means I take a current color, then look it up in a table of defined colors that it should map to. Exactly how accurate it is I’m not sure. What seems like the case is that a lot of the really deep blues that are in the original before the LUT are applied may not really be the expected color, but in the end it’s hard to know without vintage hardware to check against, and color calibration is a really tricky thing, I’m interested in looking at Dogway’s stuff as it seems like he has gone into all the details.

Here are some examples, I find in general that the LUT is making stuff look more natural.

Afterburner LUT Colors OFF

Afterburner LUT Colors ON

Sonic Title LUT Colors OFF

Sonic Title LUT Colors ON

Sonic - LUT Colors OFF

Sonic - LUT Colors OFF

Super Metroid - LUT Colors OFF

Super Metroid - LUT Colors ON

If you use negative cropping to push the edge of the crt image in from the edge of the tube Negative Crop Brightness adjusts the newly revealed empty area at the edge of the screen so it matches the blacks in the screen image because the blacks in the image won’t be black anymore if the black level is < 0. The Black level < 0 is mostly there so that you can get faint scanlines to appear in the black area.

You are totally right that the pre-crt black level is totally broken when used with values greater than 0. I’ll fix this.

4 Likes

Thanks for pointing this out, how would this be applied in the shader, just keeping in mind that the luminance is different between them?

When you refer to the current primaries, where are you talking about?

2 Likes

I agree the Lut looks more natural but when I see the contrast in blues blurred the OCD part of me cries out that I’m missing some pixels. It’s irrational since it only happens on a small number of games but it still drives me a little nuts.

2 Likes

In playing around with some motionblur shaders, the thing that looks the closest to your shots seems to be just basing the persistence on the luminance value of the pixel. That seems to be more important than the color/material.

2 Likes

But the luminance is based on the emulated primaries. For P22 the red phosphor adds more to the luminance than the green. The eye cone receptors are more sensible to green colors, so you have to subtract the P22 RGB luminance components to the eye’s cone RGB response, which matches those of Rec.709.

R'G'B' P22 (phosphor response)
0.640, 0.352, 0.008
0.282, 0.620, 0.098
0.146, 0.061, 0.793

RGB Rec.709 (cone respone)
0.212655, 0.715158, 0.072187
2 Likes

Right, how you calculate the luminance is going to matter a little bit, but it’s going to be hair-splitting vs trying to base it on phosphor characteristics. That is, even something really naive like max(max(R,G),B) is going to look more “right”, I think, than basing it on phosphor decay/afterglow characteristics.

3 Likes

Sure, if you don’t want to emulate the phosphor characteristics that’s a good and fast approach.

3 Likes

The new Lut definitely feels more natural to me now. Here is Batman on the NES. It makes way more sense he would have been designed to be blue and not purple. This sort of thing drives me so nuts I want to buy a CRT just to check what it was meant to be.

3 Likes

The issue with that would be some manufacturers had different color outputs to an extent from each other (that’s why torridgristle made multiple LUTs because Sony did different stuff with color vs the other manufacturers), the other issue would be that’d you have to make sure the TV was properly setup, calibrated, etc.

So in some color instances (purple for instance, basically any non-primary color that could easily be changed to any two different primary colors) it makes it hard to tell what color something was supposed to be without ripping things from the game to get values for things to figure out what color it was supposed to be.

I do agree blue Batman makes more sense though, I’m just saying getting a CRT may not help you decide about the colors as this can vary a fairly decent amount from understanding between brands and models.

EDIT: Seems he may have been purple. Don’t know accurate this is, though. https://www.spriters-resource.com/nes/batman/sheet/38501/

2 Likes

I decided i don’t want LUT colors as default. But some games do benefit from it, mostly MAME arcade games.

Also, i take back what i said about the color persistence. It looks great on some certain (older) games.

I’d like to start saving different game presets but the fact they will get reset each update holds me back. I’ll wait until the bottom scale/overscan bug is fixed so i can settle once and for all (i think :p)

2 Likes

NES colors are a sticky wicket due to the issue of palette variation, but he was definitely purple on a typical home setup. Easiest way to verify is by looking at these shots from Nintendo Power.

3 Likes

The game being from 1989 I’m assuming all artwork was laboriously coded in pixel by pixel. That means they where looking at it all through a monitor with a color LUT and never seeing the raw sprites like we can today. (As far as I know.) The Joker is a lighter pinkish purple in the game, so I would be surprised if Batman was dark purple. Yet the NES did have a limited color palette…

@hunterk good find. Here is a video of someone playing on a crt. It’s not great quality but to my eye Batman looks a little more bluish than the magazine.

1 Like

I watched a little of the video, it’s either the camera or TV that’s pushing the blue a little harder. I can see some purple-ness to Batman in the video, alot of the colors seem off to be honest. Look at the HUD up at the top, the whole this is basically blue in the video. (Which is most certainly not right, so yeah either his camera or CRT is pushing blue hard.)

I do w/e with the color when I’m playing games anyway. But yeah he “should” be purple in that game, makes more sense too use the LUT and make him blue though, lol.

1 Like

I also just remember him being purple from playing the game as a kid :stuck_out_tongue:

Nevertheless, there is the ongoing question of whether the sprites were designed around cooler japanese NTSC standards, etc. (the usual “artist’s intention” subjective b.s.), not to mention differences in calibration, manufacturers’ differences, etc.

Just make it look how you think it should and you’ll be in good shape :smiley:

3 Likes

Those shots from Nintendo power are great :slight_smile: I also remember him being purplish.

3 Likes

Here is a little more fun. This flyer for the game at the time shows our batty boy in blue, but the back of the box has him purple. (Which I would side on being the intended color.) None of it matters but it’s fun to speculate as I have no screen grabs from my 1989 memories.

4 Likes

That flyer is interesting as it looks like they took a picture of a CRT running the game and then layered the rest of the image over it.

Also colors should be a little off in the flyer as it was most likely in a magazine and magazines to my knowledge you a different color (range? CMYK I think) then TV, and monitors.

The Mega Bezel is updated to V2020-05-18

Changes:

  • By God, Cropping is finally working on all shaders except the LCD shader and Royale!
  • It had nothing at all to do with guest-venom, it was all in how I was dealing with the cropped coordinates
  • I’m not sure I’m going to do it on the lcd shader as it’s using an odd function I haven’t seen before texelFetchOffset, and may not add much value anyway * I’m still planning to do Royale, but I have to venture into the depths of the include chain
  • Post-CRT scanlines, these are similar to the resolution independent scanlines, but pulled from crt-torridgristle, brightness is automatically boosted when these are on so brightness is maintained
  • New Guest-Venom HD preset whch uses the Post-CRT scanlines
  • Black Level is fixed
  • New Parameter to reduce the vertical resolution, useful for getting sort of realish scanlines on high res content [SCANLINES] Core Res Mult (Inv), this could be used if you have increased the core res. Note that this doesn’t currently play well with the cropping.
  • You probably need to update your presets

Cropping Example: Original no Cropping

Negative Crop

Negative Black Level

Negative Crop Brightness

MDapt with the most relaxed setting

HD Preset & Post CRT Scanlines

Vertical Downres


11 Likes

That’s correct. CMYK has a limited range. However, this should also apply to boxes as well since they get printed just like magazines. So, if a box can display a certain color, so can a magazine.

1 Like