I decided to release the tool which was used for these conversions. Download it HERE
EDIT: Note: There's a small bug in the tool, there can't be spaces in the path of the image.
This tool takes a 256x480 or 512x240 resolution image and attempts to convert it to be displayed on NES to the best of its abilities. You can of course also convert a 256x240 image (so it won't flicker) by resizing it (using nearest neighbor filtering) to 256x480 or 512x240, then converting.
To use it, first of all you'll need to download and install ImageMagick
(download the file ImageMagick-x.x.x-x-Q16-windows-dll.exe). After installing, open up command line and type "convert --version" to verify it installed succesfully. It should print something like this:
Code: Select all
Version: ImageMagick 6.7.1-2 2011-08-02 Q16 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2011 ImageMagick Studio LLC
You'll also need some version of the .NET runtime, I'm not exactly sure which. But you probably have it anyways if you're not using an ancient version of Windows.
In the package there's a file named "sample.png" which looks like this:
Drag & drop "sample.png" over the file "convert-256x480.cmd". After a little while it should have been converted to "sample.nes". Open the ROM in your favourite emulator to verify it works. I prefer Nestopia, since it seems to be the best at keeping a stable frame rate. If it worked, CONGLATURATION!!! If not, drop me a line.
Preparing images for conversion (with Photoshop)
So how to prepare your own images for converting? You can't use just any arbitrary image. Here are the restrictions:
- Resolution must be 256x480 or 512x240.
- All colors in the image must be from Nestopia's YUV palette! Photoshop palette file is included in the package (nestopia-yuv-palette.act).
- Bit depth of the input image doesn't matter (at least 8 bpp and 24 bpp work).
Here's a process I've found to work fairly well for preparing arbitrary images. Let's take this random image from the internet for example:
First I'm going to resize it down to 512x240 (from menu Image -> Image Size). 256x480 could be used as well, it's your choice. Looks like this:
Now we need to reduce the number of colors in the image. Go to menu Image -> Mode and choose Indexed Color. This dialog will pop up:
Color amount between 9-12 seems to work the best. The higher the number of colors, harder it is for the converter to give good results. I like to use Pattern dithering, but Diffusion can produce nice results as well.
The result looks like this:
Next step is to make the colors compatible with NES palette. First we need to convert the image back to RGB. Choose to Image -> Mode -> RGB Color.
At this point it's usually good to make some adjustments to the image to make it better suited for NES. For example, pump up the contrast from Image -> Adjustments -> Brightness/Contrast. Image -> Adjustments -> Curves is another useful one. High contrast images tend to work better because there aren't very many shades of colors available on NES. The adjustments here are really the key to getting decent looking results, along with the complexity of the image.
Here's the image after my adjustments:
Now let's apply the NES palette. Go again to Image -> Mode and choose Indexed Color. Under "Palette", choose "Custom...". In the "Color Table" dialog press "Load..." and navigate to the file "nestopia-yuv-palette.act". Be sure to turn Dithering off at this point! While it might look better, it'll make the image too complex to convert well. Take a look at the preview, and if it looks like shit, go back to adjusting the image.
Press OK, and here's the result:
Now the image is ready to be converted. Save it in PNG format, and drag&drop the resulting PNG over "convert-512x240.cmd" to convert it. Pray to your deity of choice that it will be converted well.
Open the ROM in your favourite emulator to enjoy the fruits of your labor... It should look something like this:
That's all! As usual, if you make something cool with this, let me know!
EDIT: Forgot to mention, in this latest version of image viewer button A can be pressed to skip over one frame, making it possible to adjust the even/odd field on displays such as HDTVs which treat the signal as interlaced. This can be used to make 256x480 images look better (or rather, a little bit less bad) on those displays.