
    RB_Merge.pov  Merges two pictues into an anaglyph
       3-2009
  Leroy Whetstone Email lrwii@joplin.com



variable list, default, function:

   Image="Junk0.Bmp" the first eye image of an anaglyph
   Brightness=1      the ambeint value of the output 
   Contrast= 2       the color_map adjustment
   
   
 'RB_Merge.pov' can be use for both still and animation anaglyphs.

 Merge takes the 'Image' string and cuts it up and uses the parts to
 make an image_map pigment. This pigment is then put in a function,
 one for each eye. These functions are use in a color_map pigment,
 again one for each eye.The color_map pigments are averaged togather
 to make the final pigment. This pigment is placed on a box that
 just fills the screen.
 
 When Merge cuts 'Image' up its into 3 parts; 
       Image Name, Extention, Type
   Image Name: the base name without the extention
   Extention: zero-padding digits. These must be ZERO!
              Merge counts these digits and with 'frame_number'
              creates the full name of the image files to load.
            example of full names (Image1,Image01,Image001,...) 
   Type: should be any image type that Pov uses. Since I
         use windows 'Bmp' is used with 'sys'.
    examples of full name with type(Image1.tga,Image01.tga,Image001.tga,...) 
  
 Why all this trouble? The only way to have an image_map work ya need
 to have the type before the file name: image_map{type "Image01.type"}
 I could have several places where you change type by hand. But, I 
 wanted to have a simpler input. Simpler input, longer code. Now we
 have we to change the type in the image_map. The image_map pigment code
 is placed in a string, that string is saved as(parse_string.tmp)and
 then parse_string.tmp is included. 


  I added the 'Brightness','Contrast' variables to adjust the final output.
  
  'Brightness' is the ambient value in the output box finish.
   
  'Contrast'  is used in the color_map pigments
           the red color map is{[0 rgb<0,0,0>][1 rgb<ConTrast,0,0>}
           the cyan color map is{[0 rgb<0,0,0>][1 rgb<0,ConTrast,ConTrast>}