Main > Main Forum
GaryMcT's Mame CRT simulation project
(1/9) > >>
GaryMcT:
Just starting to work on this.  I'm really busy at work, and I have other projects in the works here, but I figure I'll try to spend a little bit of time on this soonish.

Basically, I want to modify Mame to emulate the look of an arcade CRT display using D3D9 pixel shaders.  I have a Wells Gardner D9500 sitting next to my first-gen 1920x1200 Apple Cinema Display.  The blacks on the Cinema Display aren't great, but I can try to get them to look similar.  This LCD may not be high enough resolution to be able to do it well, but I'll give it a try.

My test case is Pac-Man.  It originally runs at 224x288.  The CRT and LCD are about the same height.  Assuming I'm going to be looking at the images sideways, the image will be cropped on the left and right on the LCD.  I end up with 1200/224 LCD pixels in one dimension for every CRT pixel.  That give me a little more than a 5x5 pixel array on the LCD to emulate a pixel on the CRT.  I'm not sure if this is enough to do a good job, but I'll give it a try.  I have higher DPI monitors at work that I can look at this well.

I'm going to start off by running some test patterns on the CRT to see what the pixels actually look like on there.  I'll start with a single white pixel and single red, green, and blue pixels.  Hopefully I can borrow my wife's DLSR camera and a little tripod to get some shots of what the falloff function looks like.  I'll likely use tweaks of these shots to get images to use as textures for the pixel shader to use to model the pixel falloff on a CRT.

This'll probably take me a while. . I'm very very busy at work. :)

DJ_Izumi:
I think your first issue is that arcade CRT monitors don't use 1:1 square pixels where as your LCD does.  That would present issues with getting the aspect ratio right.  Which puts a wrench into the idea that you have 5x5 to use per pixel.
GaryMcT:
I'm not going to be doing any one to one pixel operations on the output.  I'm just trying to get an idea of how many output pixels per every input pixel I roughly have to try to emulate the pixel function of the CRT.  There is probably overlap between pixels as well.
Applekid:
Visualizing it, I can see a massive number of "phosphor pixel" point sprites each with a color phosphor and glow. They all decay at different rates as that chart in the last thread showed.

I'm not sure they'd be perfect 1-1 anyway. Definitely definitely need to think in subpixels and the shadow mask of the color monitor, and a tracing beam. The amount of operations per second to get it right.... wow.... Refresh seveal times the number of raster rows for every one emulated CRT row to the tune of at least 60 (x emulation accuracy) per second.

Good thing we've got 200 GHz 256-core CPUs, right?  :notworthy:
GaryMcT:
A dx9 ps20 pixel shader should be able to do it without a problem on the GPU.
Navigation
Message Index
Next page

Go to full version