Checkerboard flickering shenanigans

A place for your artistic side. Discuss techniques and tools for pixel art on the NES, GBC, or similar platforms.

Moderator: Moderators

Sik
Posts: 1589
Joined: Thu Aug 12, 2010 3:43 am

Checkerboard flickering shenanigans

Post by Sik »

This was discussed for a while not that long ago, so I wondered to see how it'd look when applied to the NES (at least in theory).

The idea behind the checkerboard pattern flickering is that there are two checkerboard patterns with opposite orientations and that they are alternated every frame. Since the pixels don't cover a large enough area, this blends to the eye much better than normal flickering, and if the colors are somewhat close it's pretty much indistinguishable from a single solid color (very useful for making smooth gradients without risking breaking the silhouette).

In theory, it should look like this:

Image

Problem is... the PPU completely breaks this by having every other line shifted by half a pixel. So if you try to apply this trick on the NES, what you get doesn't look anywhere as pleasant (though blurring caused by a low quality signal may sorta hide it):

Image

Ouch, that doesn't look like a checkerboard at all. Generally a better suggestion is to use vertical bars instead of a checkerboard pattern. Unsurprisingly, this actually looks better, though for the record, the outcome ends up being a checkerboard pattern in itself:

Image

And finally, for comparison, checkerboard pattern and vertical bars without any flickering:

Image

Image

There are other issues I'm not taking into account, like any noise introduced by RF or composite encoding. Leaving that for later, I have absolutely no idea how is the noise generated.
User avatar
Bregalad
Posts: 8055
Joined: Fri Nov 12, 2004 2:49 pm
Location: Divonne-les-bains, France

Re: Checkerboard flickering shenanigans

Post by Bregalad »

This again ?!
tepples
Posts: 22705
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: Checkerboard flickering shenanigans

Post by tepples »

On the TVs that I use regularly (three CRT and one LCD), every other scanline in the composite signal output by the NTSC NES is not shifted by a fraction of a pixel. Are you on PAL, PAL/M, SCART, or something else? I can't take a guess because you haven't filled in the location field of your profile. There is a known problem with vertical edges between black ($0F) and darker colors ($0x/$1x) that can be seen especially in underground areas of SMB1, but that repeats on a 3-line pattern, not a 2-line pattern, and edges between black ($0F) and white ($20) are not affected at all.
User avatar
mikejmoffitt
Posts: 1353
Joined: Sun May 27, 2012 8:43 pm

Re: Checkerboard flickering shenanigans

Post by mikejmoffitt »

Between black and white a checkerboard pattern is fairly faithfully reproduced, with maybe some minimal rainbow pattern introduced. The system does not shift every scanline, that could be a defect of your display...

Against black many NTSC artifacts are harder to see as well; games like Super Mario Brothers 3 which feature black outlines over many objects do not suffer so badly as others which put different colors near each other (like the green flagpole against the blue backdrop in Super Mario Bros).
User avatar
koitsu
Posts: 4201
Joined: Sun Sep 19, 2004 9:28 pm
Location: A world gone mad

Re: Checkerboard flickering shenanigans

Post by koitsu »

This sounds more like a display "issue" (please note I'm using quotes) than a 'PPU "issue"' or somesuch.

Moral of the story: what you draw/design on paper/in a graphics editor does not necessarily reflect how things will actually look on a display (whether it be CRT, LCD, or any other medium). Welcome to game design! :-)
Sik
Posts: 1589
Joined: Thu Aug 12, 2010 3:43 am

Re: Checkerboard flickering shenanigans

Post by Sik »

Well, screw that, guess I misunderstood how the anti dot crawl mechanism works =/ Disregard all this then.
tepples
Posts: 22705
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: Checkerboard flickering shenanigans

Post by tepples »

If you want to see what kind of artifacting you get when you use checkerboards on the NES, look at the title screen of Solstice or Dr. Mario. Or fire up Mario Paint and fill the screen with a dark blue checkerboard. Essentially you get a bunch of diagonal stripes from top left to bottom right, spaced 6 pixels apart, because of beating between the color subcarrier (1.5 pixel period) and the pixel pattern (2 pixel period in a checkerboard).
Grapeshot
Posts: 85
Joined: Thu Apr 14, 2011 9:27 pm
Contact:

Re: Checkerboard flickering shenanigans

Post by Grapeshot »

He was almost right, but only for the color part of the signal. In each scanline this is actually shifted from the previous line by 1/3 of the color frequency (4 cycles @ 21.7 mhz) or 2/3 of a pixel. So the pattern repeats every 3 lines. Then every other frame the phase is shifted by half a pixel as well. Flickering black and white checkerboards or two colors with the same hue would actually blend them, with anything else you would get stripes.
Last edited by Grapeshot on Sat Jan 05, 2013 5:01 pm, edited 1 time in total.
lidnariq
Posts: 11430
Joined: Sun Apr 13, 2008 11:12 am

Re: Checkerboard flickering shenanigans

Post by lidnariq »

ARGH.


NO.

The PIXELS are NOT SHIFTED. EVER.


The phase of the color subcarrier is what shifts.

Pure black and white content will have NO JITTER from scanline to scanline.
tepples
Posts: 22705
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: Checkerboard flickering shenanigans

Post by tepples »

lidnariq wrote:Pure black and white content will have NO JITTER from scanline to scanline.
Because if it did, then the menu of a multicart built with Action 53, such as the forthcoming Streemerz bundle, would be unreadable on my TV. Below is a photograph of my Vizio VX32L television displaying Action 53:

Image
ccovell
Posts: 1045
Joined: Sun Mar 19, 2006 9:44 pm
Location: Japan
Contact:

Re: Checkerboard flickering shenanigans

Post by ccovell »

Sik: on the Turbografx / PC-Engine, the VCE shifts pixels by half a pixel, spreading around artifacts... but this only applies to transitions between saturated colours. Pure greys do not move around or (in theory) have artifacts.

So, dithering with black and white should "work" correctly, not like in the example you made.
Sik
Posts: 1589
Joined: Thu Aug 12, 2010 3:43 am

Re: Checkerboard flickering shenanigans

Post by Sik »

Just to make it clear: I had used white and black just to put two colors there, the theory was meant to be applied to any set of colors =P
User avatar
mikejmoffitt
Posts: 1353
Joined: Sun May 27, 2012 8:43 pm

Re: Checkerboard flickering shenanigans

Post by mikejmoffitt »

I was under the impression that all that is shifted is the color sub-carrier's position. This is to even out the artifacts over time.

Chris Covell's I want my RGB page describes this fairly decently on the screenshots page, and has this image to demonstrate:

Image
User avatar
Macbee
Posts: 120
Joined: Sat Nov 26, 2011 8:31 am
Location: Brazil
Contact:

Re: Checkerboard flickering shenanigans

Post by Macbee »

People who wants to avoid these rainbow patterns could also consider replacing checkerboard patterns with horizontal lines.
If Nestopia's NTSC filter isn't lying to me I come to the following conclusions:

1) Checkerboard patterns -
Pros: It's the ultimate flicker technique to make good looking images. Results are usually impressive.
Cons: Diagonal artifacts seems to be present all the time when using Composite cables, no matter how similar flickered colors are.

Demonstrative images (original graphics + NTSC/Composite display):
Image
Image


2) Horizontal lines patterns -
Pros: It's the only flicker technique that doesn't seem to create diagonal artifacts when using Composite cables.
Cons: End results doesn't look as good as checkerboard flickered images (shakiness is way more evident).

Demonstrative images (original graphics + NTSC/Composite display):
Image
Image

My tests were made using emulators only (I'd love to have a Powerpak but it's way too expensive for me).
Last edited by Macbee on Sun Jan 06, 2013 3:49 pm, edited 1 time in total.
User avatar
Dwedit
Posts: 4922
Joined: Fri Nov 19, 2004 7:35 pm
Contact:

Re: Checkerboard flickering shenanigans

Post by Dwedit »

Oh god... Flickering again? We've been through this 100 times already. Flicker on LCD = good, flicker on anything else = bad.
Here come the fortune cookies! Here come the fortune cookies! They're wearing paper hats!
Post Reply