[Home]
Appendix A: Matlab Scripts
- CameraGamma.m
- Read in camera output image of GrayPatch, approximate camera Gamma Correction function for R, G & B values, and plot the results.
- CompareImagesCenterNo.m
- Compares the camera output images without a center to the originals. This process involved performing the camera gamma correction.
- CompareImagesCenterNo2.m
- Compares the camera output images with a center (corresponding to the set without a center) to the originals. This process involved performing the camera gamma correction.
- CompareImagesCenterYes.m
- Compares the camera output images with a center to the originals. This process involved performing the camera gamma correction.
- CreateImagesCenterNoBig.m
- Creates the image set without a center. This script creates the images before and after the monitor gamma correction.
- CreateImagesCenterYesBig.m
- Creates the image set with a center. This script creates the images before and after the monitor gamma correction.
- f.m
- Function f used for fmin to approximate camera gamma.
- Gamma.m
- Displays a gray patch next to a 50 white / 50 black patch for determining monitor gamma.
- GrayPatchFun.m
- Generate input image with 9 gray levels to test camera gamma function. Inversed monitor gamma is corrected to feed in camera with a linear scaled image.
- GrayWorldCompare.m
- Compute the difference between Gray World outputs and inputs, then plot the differences.
Also compute the difference between Gray World outputs and camera outputs, then plot the differences.
- GrayWorldFun.m
- Function to implement GrayWorld color balancing algorithm, which takes R, G & B value as input and output color balanced R, G & B.
- GrayWorldPlot.m
- Read in 252 output images of GrayWorld algorithm, compute the mean values of R, G, B & Gray and plot the results in 4 3-dimension pictures.
- GrayWorldTest1.m
- Read in 252 input 'bmp' images. For each image, convert it into R, G & B values, run the GrayWorld color balancing algorithm on the image and write the results to output image.
- GrayWorldTest2.m
- Run GrayWorld color balancing algorithm on 2 StanfordTower images, one without bright patch and one with bright patch.
- InputPlot.m
- Read in 252 input 'bmp' images. compute the mean values of R, G, B & Gray and plot the results in 4 3-dimension pictures.
- MakeRainbow.m
- Creates the colorRGB.mat file containing a rainbow for use in the image generation.
- PerfectReflectorCompare.m
- Compute the difference between Perfect Reflector outputs and inputs, then plot the differences.
Also compute the difference between Perfect Reflector outputs and camera outputs, then plot the differences.
- PerfectReflectorFun.m
- Function to implement PerfectReflector color balancing algorithm, which takes R, G & B value as input and output color balanced R, G & B.
- PerfectReflectorPlot.m
- Read in 252 output images of PerfectReflector algorithm, compute the mean values of R, G, B & Gray and plot the results in 4 3-dimension pictures.
- PerfectReflectorTest1.m
- Read in 252 input 'bmp' images. For each image, convert it into R, G & B values, run the PerfectReflector color balancing algorithm on the image and write the results to output image.
- PerfectReflectorTest2.m
- Run PerfectReflector color balancing algorithm on 2 StanfordTower images, one without bright patch and one with bright patch.
- RealImage.m
- Generate StanfordTower image with bright patch and do the inverse monitor correction for both StanfordTower images without bright patch and with bright patch.
- spectrum.m
- Creates the rainbox spectrum used by MakeRainbow.m. This is a modified (corrected) version of the spectrumMap.m script from the toolbox.
trek@alumni.stanford.edu
lihui@leland.stanford.edu