next up previous contents
Next: 3.2.5 Correcting within nip2 Up: 3.2 Infrared imaging Previous: 3.2.3 Correcting illumination   Contents


3.2.4 Correcting with the command-line tool

First, close nip2 and open a command line window, (xterm, mingw, etc). Move to the directory containing your image files with cd. For example, if you have made a directory called raphael inside your home directory, type:

                                                      
  prompt% cd raphael              

The program you need to use is called light_correct. You need to give it the name of the grey-card image and the names of all of the image files you want it to correct with that gray card. Suppose you have saved your gray card image as grey.v, and your painting image files are called dat1.1.v and dat1.2.v. You would then enter:

                                                      
  prompt% light_correct grey.v dat1.1.v dat1.2.v              

The program will run and print messages explaining its progress. It creates a new set of corrected image files, with the same names as before, but prefixed with ic_. In this example, it would create two new images files called ic_dat1.1.v and ic_dat1.2.v.

If there are a lot of image files to correct this could mean a lot of typing. Fortunately, you can use wildcard characters to abbreviate lists of file names. The example above can be abbreviated to:

                                                      
  prompt% light_correct grey.v dat*.v              

The dat*.v means `any filename which starts dat and ends with .v'.

You can use this technique to correct different parts of your mosaic with different grey cards. If you have a file called grey1.v for the first row in your mosaic, and a file called grey2.v for the second, you could do the correction in two parts:

                                                      
  prompt% light_correct grey1.v dat1.*.v              
  prompt% light_correct grey2.v dat2.*.v              


next up previous contents
Next: 3.2.5 Correcting within nip2 Up: 3.2 Infrared imaging Previous: 3.2.3 Correcting illumination   Contents
John Cupitt 2004-12-20