Two intraoral x-ray films.

Scanning X-Ray Films

Putting It All Together

Open the cover of the modified flatbed scanner, and if the cover simply lifts off as it does on this HP ScanJet 2200c, do so, as seen below. If the cover doesn't simply lift out as it does on this unit, you might investigate modifying something so you can remove it and keep it out of the way.

Modified flatbed scanner.

Modified scanner with lid closed.

Modified flatbed scanner with cover removed.

Modified scanner with lid removed.

Collect the films for one patient. Use a Sharpie type pen to write at least the patient's name on a slip of paper. If the films are grouped by date, write the date of that visit, or whatever else you want to have appear in the scanned image.

Use ordinary paper. You will find that it is much easier to write across the bottom of a sheet of paper and cut off that strip, as opposed to cutting off a narrow strip of paper and then trying to hold it while writing on it!

Two sets of X-ray films, Sharpie pen, hand-written label.

A hand-written label for this scan set. These are real patient films, so their details have been covered here with small pieces of electrical tape. Depending on what was used to write on the film holders, you may not need to add any hand-written labels.

Dental X-ray films, Sharpie pen, hand-written label.

An alternative method of making a hand-written label. The Post-It note could be trimmed to better arrange films on the scanner.

Alternatively, you could write the details on a Post-It note. Turn the pad around, so the sticky strip is toward the bottom of the pad, and write the details across that strip (on the non-sticky side, of course!). Then stick the note to the top of the holder, so your writing is next to the films and the rest of the note extends up from the film holder. You could just leave that tab in place, or cut or tear it off if you are arranging several sets of films for one scan.

Look at the films before proceeding. It is much easier if all the films scanned simultaneously are of similar density. If you attempt to scan one sleeve of very dark films in the same scan as a sleeve of very light films, you are not going to get a satisfactory scan of both at the same time. Splitting them into two jobs will be faster and far less frustrating than trying to do both at once. I speak from experience on this...

Lay the hand-written label and the films on the scanner plate. After a while you will get a feel for when certain types of sleeve labels will scan well. You may find that they usually provide adequate labeling within the scanned image. If so, you don't need a hand-written label.

Lay everything face down. Remember that the scanner "looks up" at the bottom surface of the scan target. Don't lay the films on the scanner as if it were a viewing light box, flip them over so their viewed face is down.

X-ray films on a flatbed scanner.

The X-ray films and hand-written label on the scanner.

X-ray films on a flatbed scanner.

Blank areas are blocked off.

Hopefully you gave some thought as to how to lay out those films, because now you need to block as much of the unused glass as possible.

The more blank glass you block off, the better the resulting scan will be.

However, be careful — the films easily slide around on the glass, and it is easy to misalign them or the blocking material. You should notice this problem when you do the preview scan, but it's best to avoid it in the first place.

Yes, I simply used a Grape-Nuts cereal box. I cut it into a variety of rectangular shapes that would work well given the dimensions of the sleeves and individual films.

Both these sleeves were completely filled. If one had held just three films, and therefore had an empty pocket, I would have covered that pocket with one of the small pieces of blocking material.

Light box on a flatbed scanner.

The light box is set in place. The switch at right allows a choice between 4 and all 8 bulbs, although now I always use all 8 bulbs for even illumination. Notice the small rubber bumper type feet on what is normally the bottom face. You can use it as a conventional viewing light box without scarring the tabletop.

Now you simply place the light box on the scanner, acrylic face down. My light box is narrower than the scanner. This means that I can only use part of the scanner glass area, and I have to be careful to align the box so it illuminates my target area. However, the box's price was right.

Also be careful that you don't disturb the films or the blocking material pieces.

Light dimmer unit.

The light dimmer unit.

My light dimmer is a rotary dimmer and duplex outlet in a 2-gang electrical box. The dimmer is one that rotates to turn on, rather than pushing. It has a 315° range of rotation.

I made a label with this simple Postscript file, click here for the PDF version. The label is mounted with clear packing tape.

Here you see the light box sitting on the scanner, with the light controller nearby. Yes, this is from a different scan, the light box is toward the other side of the scanner. You can see that the light box sits directly on the scanner.

Light dimmer box on flatbed scanner.

The light dimmer box on the scanner.

Light dimmer box on flatbed scanner.

The light dimmer box on the scanner.

Light dimmer box on flatbed scanner.

A temporary arrangement to measure the current. Notice that the light box is turned on, you can see the glow of light between it and the scanner.

I made a current-sensing box to more easily measure electrical current and therefore power consumption, as shown on another page. The measurements would be inaccurate if I were to use it as shown here, between the SCR dimmer and the light box, because the SCR is gating the AC voltage and the ammeter wouldn't be seeing the sinusoidal signal its design assumes. I will have to put the current sensor between the mains supply and the dimmer, and plug the light box directly into the dimmer. This is mainly for my purposes, I doubt that you're as interested in currents and voltage waveforms....

Scanning The Films

Set the dimmer appropriately. For my dimmer and light box and scanner, quite a bit of experimentation showed that a dimmer setting of 6.0 is appropriate for the intraoral 40x30 mm films. For the large 280x125 mm panoramic films, this is harder to specify. A dimmer setting of 6.0 is generally appropriate. Some panoramic films are rather dark, and may need a slightly brighter light, maybe 7.0. Other panoramic films are very light, with large areas nearly transparent — in those cases a dimmer setting of 6.0 but a smaller gamma adjustment (as discussed below) solves the problem.

Those settings are with all eight bulbs in use. I put a switch on the light box to disable half of them, but it works better with the more even light of all bulbs on a lower dimmer setting.

Take a preview scan.

Use the mouse to select the region of interest.

Click the gamma auto-adjust button

You see the result of that at right. The image looks a little dark, but that's OK. The gamma auto-adjustment does not correctly handle the balance of brightnesses in X-ray films, but it's important to start with XSane's attempt at gamma auto-correction.

The most important thing about setting the light level is to get a range of grey levels. If the light is too dim, the films will be limited to a few very dark shades. But if you increase the lighting too much, the automatic gain control on the system will distort the distribution of brightnesses and you end up with a few mostly white areas in films that are otherwise mostly very dark.

Look at this example — the covered area is mostly completely black, and the exposed light box surface is mostly white or nearly so. Not entirely, some of the background to the left of the two leftmost films is a very light grey.

Look at the two films in the third column. They have some fairly light areas at fillings or crowns or other metallic and highly radioopaque material. Between the teeth they're completely black. But the rest of the film shows some variation, different shades of grey, showing enamel versus dentin versus the root canals.

Preview scan of 8 dental intraoral X-ray films.

Initial preview, region of interest marked, and gamma auto-adjusted.

Preview scan of 8 dental intraoral X-ray films, gamma adjusted by +1.

Gamma auto-adjusted, and then increased by 1.0.

Whatever the resulting gamma was after you clicked the auto-correction button, increase it by 1.0.

In this example, it happened to auto-adjust to 1.15 and I have manually increased it to 2.15. Expect the automatically adjusted gamma to range from 0.95 to maybe 1.60.

The important thing is to simply increase it by 1.0.

The easy way to do this is to click in the "track" of the gamma slider control, clicking to the right of the button itself. Each of those clicks increases the gamma by 0.1. So, just click 10 times in the "track" to the right of the slider button.

If you lose track or otherwise worry that something has gone wrong, simply click on the auto-adjust button again. That will reset the gamma to the initial estimate. It also resets the brightness and contrast offsets to their default of 0.0, in case you were adjusting the wrong thing.

Notice how the preview looks a little more promising now that the gamma has been increased by 1.0. See how the films show a range of shades of grey, they aren't just black and white.

An exception to this gamma increase of 1.0 would be for very "washed out" films, such as panoramic films with large regions nearly transparent. I have had success with keeping the light dimmer setting at 6.0, but then applying a smaller gamma increase. Experiment with this! You can always reset it to the auto-adjusted value with one button click, and then watch in the preview window as you bump the slider up and down by 0.1 steps.

Do that experimenting by clicking in the "track" of the gamma slider, so it jumps by 0.1 at a time! Using the up and down arrow buttons at the far right of the gamma control changes the setting so slowly that it's hard to decide what's best, or even whether it's getting better or worse.

And below is the result! Notice that the hand-written label shows up very boldly, but the cardstock label on the left-hand sleeve is also very readable. This image has been downsampled by a factor of four in both dimensions. Click on the image to see the actual scan.

Downsampled scan of 8 intraoral X-ray films.

Downsampled resulting scan, click here or on the image to see the full image.

The two upper films in the right-hand sleeve have blank regions — the lower-left corner of the right one, and about the bottom half of the left one. That's simply the way those films look. As the old computer saying goes, "Garbage In, Garbage Out."

Below is just one of those eight films cropped out and shown full size. It's the lower-left film on the right-hand sleeve.

Scan of one intraoral X-ray film.

One of those films cropped from the scan. Remember that this is a 40x30 mm film, and you are seeing it much larger on your screen. Some damage and other artifacts on the original films are quite visible here.

Once you have good starting data from careful scans, you can then apply any sort of image enhancement or processing you wish. Below you see the result of histogram equalization to enhance the global contrast. See my histogram equalization page for more details.

Scan of one intraoral X-ray film, enhanced with histogram equalization.

That same cropped subimage with histogram equalization enhancement.

Tektronix 2445A oscilloscope measuring SCR output.

Tektronix 2445A oscilloscope measuring SCR output.

Tektronix 2445A oscilloscope measuring SCR output.

SCR output waveform at dimmer setting of 5.0. Horizontal trace segments are just a few volts either size of 0 V.

Tektronix 2445A oscilloscope measuring SCR output.

SCR output waveform at dimmer setting of 7.0. You can see how an SCR dimmer works, it clips out larger or smaller portions of the input sine wave.

Tektronix 2445A oscilloscope measuring SCR output.

SCR output waveform at dimmer setting of 10.0, "fully on" or so it seems. The SCR output still isn't a clean sine wave. The clipping means sharp discontinuities, and lots of harmonic output possibly reaching up through the entire HF range and beyond. An SCR dimmer is very "dirty", generating lots of radio frequency noise. This is why dimmer circuits at low settings may cause radio interference, especially on the relatively low AM broadcast band but reaching up into low VHF and possibly interfering with the lower television channels.

Adjusting the Light Brightness, Avoiding Problems, and Troubleshooting

Be careful when placing the light box on the scanner, as it is easy to accidentally move the films or opaque blocking material.

It is tempting to use small pieces of transparent adhesive tape to hold sleeves and opaque material in place. But remember that the light box is going to get quite warm, and that could lead to a sticky mess!

Related to that, keep the scanner's glass clean and wipe down the X-ray sleeves as needed. Some sleeves may be a little dirty or dusty. Remember, "Garbage In, Garbage Out."

Don't forget to take a preview scan before every real scan! It is tedious, but it is crucial to getting the sensitivity set correctly.

Make sure that your monitor is correctly adjusted before assuming that the problem is in the scanner or the films! Two excellent pages for adjusting your monitor are:

Norman Koren's page with good explanations and helpful test patterns.

The PhotoScientia page also with calibration patterns for various gamma values.

Anyone attempting to carefully examine images on a computer monitor should first adjust the monitor's gamma characteristics.

If your images turn out too light or too dark, slightly adjust the dimmer. Then take another preview, auto-adjust the gamma, and then increase the resulting gamma by 1.0.

The lighting adjustments can be very counter-intuitive. Remember than when you adjust the light brighter and brighter, the automatic gain control attempts to balance the distribution of brightnesses in the entire scene. The result with overly bright light tends to be completely saturated white background and films that are almost completely black.

The trick is to get a reasonable amount of brightness variation, which requires lower lighting than you might expect, and then use the gamma correction to remap the resulting measurement values.

As mentioned earlier, it is much easier if all the films scanned in one set are of similar density. If one patient has a mix of dark and light sleeves, split them into multiple scans.

If the films look like they're mostly black with some white regions at fillings or crowns, then you probably have too much light. Decrease the light setting, take another preview scan, auto-adjust the gamma and then manually increase it by 1.0, and see if that doesn't provide a more useful range of shades of grey.

If a panoramic film scan has fine horizontal lines across it, then your chosen scan resolution might happen to be close to the film grain size and you're getting a sort of moiré pattern. Increase or decrease the resolution by 50 or so ppi. I have only noticed this on panoramic films.

If your scan has a broad horizontal band that's a little darker, corresponding to maybe two to five centimeters on the films, then it's possible that you have your light box plugged into the same circuit as a heavy load like a LaserJet printer. An SCR dimmer is sensitive to input voltage changes when it's at a low setting. A LaserJet printer kicking in its heater from time to time in idle mode can cause a slight variation in line voltage. I suppose a large air conditioning system could do the same thing for an entire office building. If it's the printer, switch it off while you're scanning. If it's the air conditioner, repeat that scan. I have mostly noticed this on panoramic scans.

4.0 0.93 A
5.0 1.10 A
6.0 1.22 A
7.0 1.35 A

Using my current-measuring box, I measured these currents at the input to the dimmer. These are the currents to a bank of eight 25-watt 120 VAC bulbs with frosted envelopes. At right are the waveforms at the SCR output. I have included these measurements for anyone trying to duplicate the light box. I have to assume that my clamp-on ammeter does a reasonable job of sensing the average current. You can see from the waveforms at far right that the voltages and currents have unusual waveforms on an SCR circuit.

Finally, don't let the light box get too hot! Be careful to turn the light box off when you aren't using it! Since the labeled dimmer provides easily repeatable brightness settings, you can turn it off between scans and then quickly dial the needed brightness back in when you have the next films in place.

The only other page I have is a relatively short checklist. Now that you have seen all the details, the checklist should make sense.