Abstract:
A method and apparatus are provided for correcting for optical misalignment of the dual (left and right) images produced by a stereo electronic endoscope, or of the corresponding dual images produced by coupling electronic imaging devices to each of two monocular teaching ports of a stereo optical endoscope. The stereo image alignment technique comprises electronically capturing the video image data of the dual images, and subsequently processing that data electronically to correct for optical alignment errors. The method involves digitizing the electronic data and digitally performing the equivalent of vertical image shift, and/or image size change, and/or image rotation as required to correct for any visual image misalignment.

Description:
FIELD OF THE INVENTION 
     This invention relates to a method and apparatus for aligning left and right images generated by an electronic stereo camera and more particularly to stereo endoscopes and operating microscopes. 
     BACKGROUND OF THE INVENTION 
     A three-dimensional (“3D”) vision endoscope or microscope, hereinafter referred to as a “stereo” endoscope or microscope, comprises a stereoscopic optical system for forming a 3D image of an object. The stereoscopic optical system comprises objective lens means arranged to pick up two slightly different images of a object that approximate the two views (left and right) provided by human binocular vision. The difference between the two views is known as parallax. By properly aligning and presenting the two optical target images to human binocular vision, a three-dimensional sense of the target is presented to the viewer. 
     In the case of a conventional (non-electronic) optical endoscope or microscope the two optical target images picked up by the objective lens means are passed to a viewing system in the form of a binocular eyepiece unit comprising two like optical channels each having, inter alia, a focusing lens followed by an ocular lens. In the case of an electronic stereo endoscope or microscope, the images picked up by the objective lens means are passed to an electronic stereo camera. As used herein the term “electronic stereo camera” is intended to denote a camera comprising two solid state electronic imaging devices, typically charge coupled devices (CCD&#39;s), that are capable of generating electrical output signals representative of images received thereby. The camera may also include electronic circuit means for controlling operation of the imaging devices so as to produce said output signals. Alternatively, some or all of said electronic circuit means may be disposed outside of the camera. The camera may also comprise image formation optics for relaying images and focusing them on the imaging devices. Also as used herein the term “video camera head” is intended to designate a camera having a single electronic imaging device, with or without associated electronic circuit means for controlling its operation so as to produce a useful output signal representative of the images received by said imaging device. Hence a stereo video camera essentially comprises two video cameras heads. The video camera head also may also comprise image formation optics for relaying images and focusing them on the imaging device. 
     The output signals of the electronic imaging devices are processed to provide video signals that in turn are used to drive an electronic viewing (display) system. The latter may comprise a conventional video monitor that is operated so as to provide a stereoscopic display in response to the video signals, the stereoscopic display typically being generated so as to be viewable by special polarized spectacles or, in the case where left and right images are displayed alternately, by spectacles having shutters that alternately block each eye in synchronism with alternate displaying of the left and right images. The viewing system also may be a head-mounted display unit, comprising first and second miniature electronic display devices, one for each eye, that display the left and right images respectively. The form of display system used is not critical to the invention. 
     The capability of the human brain to fuse two images to produce a three-dimensional visual effect is tolerant of misalignment errors between the two images. However, only a small degree of misalignment, in the form of differences in image size, vertical position and rotation, will cause viewer discomfort, and such discomfort increases as a function of the degree of misalignment. Consequently prolonged viewing of misaligned stereo images, such as occurs in cardiac surgery or pneurosurgery operations, can produce a high degree of viewer discomfort. 
     In the optical domain, it is possible to align images by physically moving lenses, prisms, CCD&#39;s and other optical devices. However, in the case of a stereo endoscope the size limitation on the insertion portion of the endoscope results in the optical elements being quite small, making it difficult to mechanically adjust components to correct for misalignment errors. 
     U.S. Pat. No. 5,577,991, issued Nov.26, 1996 to N. Akui et al, discloses various methods for adjusting left and right images to correct for mismatch. FIG. 3 of that patent discloses a method and apparatus for electronically correcting for optical mismatch errors, while other figures of that patent show mechanical means for optical systems of images. Mechanical methods and means for correcting for misalignment errors of the type described are expensive and are not fully satisfactory for a number of reasons. The electronic method embodied in the system of FIG. 3 of said patent is not explained or illustrated in specific detail but appears to have certain limitations. Nevertheless, it is recognized that the equivalent of horizontal and vertical image shift, image size change, and image rotation can be performed very effectively in the electronic domain. 
     OBJECTS AND SUMMARY OF THE INVENTION 
     Accordingly, the primary object of this invention is to provide a new and improved method and means for electronically correcting for misalignment of stereo images generated by solid state imaging devices in electronic video cameras, especially where such cameras form part of or are coupled to stereo endoscopes and operating microscopes. 
     Another object is to provide a method and apparatus for correcting for stereo images misalignment that differs from and improves upon the electronic system shown in FIG. 3 of said U.S. Pat. No. 5,577,991. 
     A further object is to provide a new and improved stereo image alignment technique for endoscopes and operating microscopes which involves capturing electronically generated left and right images which may contain residual optical alignment errors and subsequently processing those images electronically to correct those errors. 
     Still another object is to provide a method and apparatus for correcting stereo image misalignment problems which involves automatically capturing left and right electronic images (video image data), digitizing those images, processing the digitized images to achieve alignment, and processing the aligned digitized images to generate signals for driving a stereo display device. 
     These and other objects are achieved by passing left and right channel video signals derived from first and second CCD&#39;s to analog-to-digital (A/D) signal converters to generate digitized video image data, inputting the digitized images to a stereo image processor that comprises first and second frame memory units for storing the video image data, and an image analysis computer for comparing the digitized images inputted to said first and second frame memory units, using said computer to compare the digitized left and right images inputted to said first and second frame memory units and to determine the sense and degree of mismatch between said digitized left and right images, generating correction command signals according to the sense and degree of mismatch between said digitized left and right images, inputting those command signals to said frame memory units as readout control signals to control the readout of video image data from said frame memory units, passing the digitized data read out from said memory units to digital to analog converters so as to generate analog video signals, and passing said analog video signals to a stereo display device. By way of example, the preferred embodiment of the invention may be used in conjunction with a head-mounted binocular electronic display, but the stereo display device may also be a TV-type monitor. Also preferably in the case of an endoscope, the video signals are derived from a video camera that comprises an integral part of an electronic stereo endoscope. An alternative embodiment involves a stereo-optical operating microscope having two auxiliary observation ports, one for each optical channel, which are commonly identified as “teaching ports”. A monocular electronic video camera head is coupled to each observation port, with the left and right video image signals derived from the two monocular camera heads being used drive a display after being processed to correct stereo misalignment errors. 
    
    
     THE DRAWINGS 
     FIG. 1 is a diagrammatic illustration of the general arrangement of an endoscope system and an image alignment measuring and adjusting system embodying the present invention; 
     FIG. 2 is a diagrammatic illustration similar to FIG. 1 but providing details of the image alignment measuring and adjusting system. 
     FIG. 3 illustrates certain details of the image capture memory shown in FIG. 2; 
     FIGS. 4-7 illustrate the concept of digital electronic image processing and particularly the concept of separating data entry and data readout addressing sequences so as to effect corrections of various forms of misalignment; 
     FIG. 8 illustrates a target used in measuring and correcting for image misalignment; 
     FIGS. 9A and 9B constitute a computer software flow diagram indicating one form of computer program required to correct misalignment problems using the system shown in FIGS. 1-3; 
     FIG. 10 illustrates a stereo operating microscope having video camera heads coupled to each of its two teaching ports, the image alignment measuring and adjusting system of FIG. 2 making it possible to align the images formed by the two video camera heads to provide an electronically generated stereo display based on the right and left images transmitted by the microscope&#39;s two optical systems to the two cameras. 
    
    
     In the several figures, like components or elements are designated by like numerals. 
     DETAILED DESCRIPTION OF INVENTION 
     FIG. 1 illustrates diagrammatically a preferred form of image alignment measuring and adjusting system embodying the invention in combination with an electronic stereo endoscope. The latter comprises a housing  2  having a tubular insertion portion or barrel  4  containing two objective lenses  8 R and  8 L and two sets of relay lenses  10 R,  10 L. The housing also contains two pairs of  45 ° mirrors  12 R,  12 L and  14 R,  14 L, and a pair of focusing lenses  16 R,  16 L. The foregoing optical components form two observation optical systems or channels, one right (“R”) and the other left (“L”). The endoscope also contains a stereo video camera comprising two electronic imaging devices  18 R and  18 L, e.g., two CCD&#39;s, positioned to pick up left and right images with parallax between them that are focused by lenses  16 R,  16 L. Alternatively and preferably, each imaging device may be an RBG imaging device (not shown) that comprises a color resolution prism, an R-imaging CCD, a G-imaging CCD, and a B imaging CCD (see FIGS. 11 and 31 of U.S. Pat. No. 5,579,772 for illustrations of RBG imaging devices coupled to a color-resolving prism. 
     Although the camera is shown as built into housing  2  as an integral part of the endoscope, it is to be understood that the camera may be constructed as an independent stereo unit, or as two independent monocular video cameras, that are permanently or releasably attached to the endoscope, in the manner illustrated in FIGS. 7 and 8 of U.S. Pat. No. 5,577,991. The significant thing is that the endoscope comprises two optical channels or image formation systems and two imaging devices  18 R and  18 L. The output terminals of the imaging devices are connected to control and signal processing circuits  22 R and  22 L. The latter drive the CCD units and process the electrical signal outputs from those units so as to generate video signals. In passing through units  22 R and  22 L the output signals from the CCD&#39;s are amplified and linearized and then analog video output signals representing sequential frames of the images seen by the CCD&#39;s are produced from those amplified and linearized signals. Such control and signal processing units are well known to persons skilled in the video art. In the case of RGB imaging devices, the control and signal processing circuits  22 R and  22 L amplify and process the individual R, G and B output signals and generate therefrom an RGB video signal. The video signal outputs from the control and signal processing circuits  22 R and  22 L are then passed to analog-to-digital (AD) converters  24 R and  24 L where they are digitized. The digital output from converters  24 R and  24 L are then applied to a stereo image processor module  26  designed according to this invention which looks for and measures misalignment errors between the R and L images represented by the digitized video signals, and then corrects for any discerned misalignment errors. The digital signal outputs of image processor module  26  representing the corrected digitized video images are then passed to digital-to-analog converters  28 R and  28 L, and the analog video signal outputs from those converters are fed to a video processor unit  30  which comprises circuits for processing and formatting the R and L video signals for use in driving a stereo video display unit  32 . The circuits required for video processor  30  are well known to persons skilled in the video art, as exemplified by U.S. Pat. No. 4,253,447 issued to W. C. Moore et al for “Color Endoscope With Charge Coupled Device And Television Viewing”. 
     FIG. 2 presents further details of the preferred form of the image processor module  26 . Although the A/D converters  24 R and  24 L and the D/A converters  28 R and  28 L are shown as discrete components separate from module  26 , it is to be appreciated that they may be embodied in and form part of the image processor module itself. The latter comprises two dual-port image frame memory units  34 R and  34 L, with memory writing control circuits (i.e., writing address sequence generators)  36 R and  36 L coupled to one port and memory readout control circuits (i.e., readout address sequence generators)  38 R and  38 L coupled to the second port. Dual port memory units offer the advantage that data can be read out from one location while simultaneously new data is entered into any other location. The memory writing control circuits  36 R and  36 L control the entry of data from the A/D converters  24 R and  24 L and cause memory units  34 R and  34 L respectively to receive (read) such data on a frame-by-frame basis. The memory readout control circuits  38 R and  38 L cause data representing each image frame to be read out of the two memory units  34 R and  34 L respectively on a frame by frame basis in accordance with image correction instructions received from an image analysis computer  42 . The digitized image data read out from memory units  34 R and  34 L are fed to the D/A converters  28 R and  28 L respectively. Additionally the same image data is fed to image capture memory units  44 R and  44 L, which in turn read that data out to computer  42  as hereinafter described. It is to be noted that control and signal processing circuits  22 R and  22 L produce control signals which are applied to memory writing control circuits  36 R and  36 L, memory readout control circuits  38 R and  38 L, and image capture memory units  44 R and  44 L, whereby those circuits are clocked in synchronism with each image frame represented by the video signal outputs from signal processing circuits  22 R and  22 L respectively. This control and clocking arrangement is represented in FIG. 2 by lines connecting the input line to A/D converters  24 R and  24 L to memory control circuits  36 R and  36 L, memory readout control circuits  38 R and  38 L, and image capture memories  44 A and  44 L. 
     FIG. 3 illustrates details of image capture memory units  44 R and  44 L. These units comprise random access memories  48 R and  48 L, image capture control circuits  50 R and  50 L (i.e., writing address sequence generators) and analysis readout control circuits  52 R and  52 L (i.e., readout address sequence generators). The input lines for memories  48 R and  48 L labeled “video output” are connected to the output lines of dual-port frame memory units  34 R and  34 L respectively. The clocking of image capture memories mentioned above is achieved by applying the control signals produced by signal processing circuits  22 R and  22 L to image capture control circuits  50 R and  50 L and analysis readout control circuits  52 R and  52 L. Readout of image data from memories  48 R and  48 L into computer  42  is controlled by readout commands provided by image analysis computer  42  via lines  54 R and  54 L (FIGS.  2  and  3 ). 
     The invention is based on the concept that stereo images misalignment in electronic endoscopes and microscopes involves one or more of the following: (1) vertical shift, i.e., one image is slightly above or below the other, (2) one image is rotated relative to the other, and (3) one image is too large or too small relative to the other. These errors can be corrected by separately storing the two digitized images in memory, then reading out all or only a portion of the data representing each image in a selected order calculated to properly align the two images, and then by storing the appropriate alignment compensation values into the stereo image processor&#39;s memory readout controls  38 R and  38 L. 
     FIGS. 4-7 illustrate the concept of digital electronic image processing, and particularly the concept of separating data entry and date readout addressing sequences. These figures illustrate a section of an image stored in memory unit  34 L or  34 R that is 8 lines by 16 pixels. The squares represent memory locations while the line and pixel numbers represent both data entry addressing sequences and date readout (in bold numerals) addressing sequences. The illustrations could equally well apply to video data storage “by the frame” or “by the field”. 
     FIG. 4 illustrates data being read in and read out with identical addressing sequences. Hence data entered from input line  1  is read out as output line  1 , with identical alignment of pixel positions on each line. Consequently a readout from memory of the image data stored in memory unit  34 R or  34 L as illustrated in FIG. 4 produces an output exactly identical to the input data, and, therefore, the video data output from the memory unit exactly equals the video input to that memory. 
     FIG. 5 illustrates data entry and data readout with slightly different addressing sequences. In this case assume that digitized image data was read into the memory unit exactly as shown in FIG.  4 . However, data is read out in a different sequence. More specifically, data entered from input line  1  is not read out at all, and the same is true of the first 3 pixels from all subsequent lines. Thus the read out of data from memory produces an output that is not equal to the data input. Essentially the output video data is shifted vertically up 1 line and horizontally left 3 pixels. This capability to move the output image signal generated by one imaging device in a way different from the output image signal of another imaging device is the fundamental basis of the image alignment technique of this invention. 
     FIG. 6 illustrates another mode of addressing the memory units. In this case data is entered into and read out of a memory unit with radically different addressing sequences in order to achieve a magnification of a portion of a video image. Again assume that digitized image data was read into the memory unit exactly as shown in FIG.  4 . However readout begins with pixel  4  of line  2 . The second data readout is again pixel  4  of line  2 . The same double readout occurs vertically, as output lines  2  and  3  both are read from data captured from input line  3 . Thus the output video produced is generated from only a portion of the input image captured. In fact the output video generated with these addressing sequences is a linear 2:1 (4:1 area) magnification. 
     The simple repetition of successive pixels and successive lines would create a magnified blotchy representation of the original input image. However, this blotchiness can be reduced substantially by a process called interpolation. In such process, output data values are generated by considering not only which pixels and which lines are being read out for any given output pixel, but also the values of other pixel data nearby. In particular each output address can be viewed as an integer part and a fractional part in both vertical and horizontal directions. The integer parts can be used to select which input pixel data points shall participate in a mathematical function to generate the output data, while the fractional parts can be used to weight the contribution of the various selected input pixels. 
     FIG. 7 illustrates rotation as well as magnification of image data. In this case, data is read out so that it performs a linear 2:1 (4:1 area) magnification of the input data, but also a rotation of the output video image relative to the input video image. It should be noted also that as an output line is traversed, the input line required for providing its data shifts in midline. This arbitrary sequence shift from input to output is the reason that the readout addressing mechanism must permit random access. 
     In the practice of this invention, it is preferred that misalignment errors be corrected by changing only the R or the L video image according to the foregoing technique, while processing the other image unchanged. However, the system may be programmed so that in the event of relatively large misalignment errors, the correction be effected by changing each of the two video images by one-half of the total amount of change required to achieve correct alignment. 
     FIG.  8  and the following description explain how stereo-pair misalignment can be measured and corrected by this invention. FIG. 8 illustrates a calibration target used to measure misalignment, the target comprising a grid of horizontal and vertical lines. The image analysis computer  42  is programmed so as to carry out the following procedure for measuring and correcting for stereo-pair misalignment using the target of FIG.  8 . The procedure is as follows: 
     1. The endoscope is mounted so that it is pointed at the target shown in FIG. 8, with the target located at the natural convergence distance for the R and L optical observation channels of the endoscope, as represented in FIG. 1 by target T. This is the distance at which the two images should be the most alike. In fact if there are no alignment errors, they will be identical. 
     2. The computer  42  sets the input and output channel address sequence generators  36 R,  36 L,  38 R, and  38 L for both the left and right channels to identical nominal conditions, with the result that the digitized video output of both memory units will be as illustrated in FIG.  4 . 
     3. The computer  42  causes memory units  34 R and  34 L to capture R and L images of the entire target, or preferably an appropriate subset of both images consisting of the four lines H 1 , H 2 , V 1  &amp; V 2  using a subsystem such as illustrated in FIG.  8 . In this subsystem, the data corresponding to light intensity along lines H 1 , H 2 , V 1  &amp; V 2  are available, and it is possible to associate the position of analysis output data points with image pixel position and line position. 
     4. The computer determines the exact values of the intersections listed in FIG. 8, namely: Lh 11 , Lh 12 , Lh 13 , Lh 21 , Lh 22 , Lh 23 , Lv 11 , Lv 12 , Lv 13 , Lv 21 , Lv 22 , and Lv 23  for the Left image, and Rh 11 , Rh 12 , Rh 13 , Rh 21 , Rh 22 , Rh 23 , Rv 11 , Rv 12 , Rv 13 , Rv 21 , Rv 22 , and Rv 23  for the right image. Since the target has been positioned such that the two images are supposed to be identical, the differences between left and right intersection values are used to determine misalignment between left and right images. If desired for maximum accuracy, the computer may be programmed to apply various techniques for noise cancellation, data filtering and line center calculations. With such techniques sub-pixel accuracies are possible. 
     5. The computer calculates image size ratio as follows:        SIZE_RATIO   =         (     Lh13   -   Lh11     )     +     (     LH23   -   Lh21     )           (     Rh13   -   Rh11     )     +     (     Rh23   -   Rh21     )                                
      The result of this calculation is applied to adjust one or both of the dual-port memory data readout sequence generators  38 R and  38 L, so that subsequent use of the two dual-port memories will result in equal size images of the same target. 
     6. The computer calculates image rotation of each target image as follows:              LEFT_ANGLE   =     arctan                   (       (     Lh21   +   Lh22   +   Lh23   -   Lh11   -   Lh12   -   Lh13     )       3        (     Y2   -   Y1     )                         RIGHT_ANGLE   =     arctan                   (       (     Rh21   +   Rh22   +   RH23   -   Rh11   -   Rh12   -   Rh13     )       3        (     Y2   -   Y1     )                                          
      where Y 2  and Y 1  are the line numbers for lines H 2  and H 1  respectively. The difference between Left_Angle and Right_Angle is the rotation misalignment between left and right images. These factors are applied to adjust the dual-port memory readout sequence generators  38 R and  38 B so that the resultant images will have equal rotation angles. 
     7. Once size and rotation adjustments have been accomplished a second image capture is performed automatically. As a result of the size and rotation adjustments, this second image has zero size and angle misalignment. This second image is used to correct horizontal and vertical offsets. The computer calculates horizontal offset misalignment as follows: 
     
       
         LEFT_HORIZ=( Lh   11 + Lh   12 + Lh   13 + Lh   21 + Lh   22 + Lh   23 )/6 
       
     
     
       
         RIGHT_HORIZ=( Rh   11 + Rh   12 + Rh   13 + Rh   21 + Rh   22 + Rh   23 )/6 
       
     
     The amount of horizontal misalignment is (LEFT_HORIZ_RIGHT HORIZ). This factor is applied to the dual port memory readout sequence generators  38 R and  38 L to correct the horizontal error. 
     8. The computer then calculates vertical offset misalignment as follows: 
     
       
         LEFT_VERT=( Lv   11 + Lv   12 + Lv   13 + Lv   21 + Lv   22 + Lv   23 )/6 
       
     
     
       
         RIGHT_VERT=( Rv   11 + Rv   12 + Rv   13 + Rv   21 + Rv   22 + Rv   23 )/6 
       
     
     The amount of vertical misalignment is (LEFT_VERT−RIGHT_VERT). The compute applies this factor to the dual-port memory readout sequence generators  38 R and  38 L to correct the vertical error. 
     FIGS. 9A and 9B together constitute a flow diagram illustrating the program required to execute the foregoing alignment procedure. The flow diagram is self-explanatory to one skilled in the art of computer programming. 
     It is to be noted that the invention may be practiced other than as described above. For one thing, the two dual port memory units  34 R and  34 L are not required, although their use is preferred. Thus it is contemplated to replace dual port memory unit  34 R with two conventional random access memory units connected in parallel, with one of the replacement memory units being used for writing in data at the same time that data is being read out of the other replacement memory unit. Of course, the other dual port memory unit  34 L would be replaced by two like conventional random access memory units that are connected in parallel and also would write data in and read data out on an alternating basis relative to one another. 
     It is to be noted also that the invention may be used with an endoscope or microscope that utilizes two objectives, one for each channel, instead of the single objective shown in FIG.  1 . 
     The invention also has application to stereo operating (surgical) microscopes of the type having auxiliary viewing ports commonly called “teaching ports”. FIG. 10 illustrates diagrammatically an operating microscope having a barrel  60  containing an objective lens  62  and right and left imaging channels comprising focusing lenses  64 R and  64 L, two beam splitters  66 R and  66 L, and two eyepieces  68 R and  68 L comprising lens pairs  70 R and  70 L forming a binocular viewing system. Barrel  60  has two side ports fitted with side tubes  72 R and  72 L. Two 45° mirrors  74 R and  74 L are mounted in the two tubes as shown. Attached to tubes  72 R and  72 L and communicating with the two mirrors via apertures in the two tubes are video camera heads  78 R and  78 L comprising focusing lenses  80 R and  80 L and electronic imaging devices  82 R and  82 L each in the form of a single CCD or an RBG imaging unit as described above. Beam splitter  66 R splits the image focused thereon by focusing lenses  64 R, transmitting it to lens pair  70 R and also to mirror  74 R, while beam splitter  66 L splits the image focused thereon by lenses  64 L, transmitting the image to ocular lens pair  70 L and also to mirror  74 L. As a result the binocular viewing system comprising lens pairs  70 R and  70 L provides one surgeon with a stereo image presentation, while camera head  78 R sees only the image carried by the right channel and camera head  78 L sees only the image carried by the left channel. However, according to this invention, the output image signals derived from camera heads  78 R and  78 L are fed to an image alignment system as shown in FIGS. 1 and 2, with the signal outputs of imaging devices  82 R and  82 L being inputted to control and signal processing circuits  22 R and  22 L respectively. Since it is obviously difficult to assemble an operating microscope as shown in FIG. 10 so as to achieve correctly aligned stereo image pairs, applying the output of camera heads  78 R and  78 L to a system as shown in FIGS. 1 and 2 will correct for any misalignment and provide a second surgeon with a stereo presentation via electronic display  32 . 
     It should be noted that the particular optical channels illustrated in FIGS. 1 and 10 are presented by way of example only, and may be replaced by other optical systems of like purpose. 
     Thus it is contemplated that the microscope of FIG. 10 could be modified by replacing objective lens  62  with two smaller objectives, one for each channel as is common practice and as is the case with the endoscope represented in FIG.  1 . The invention also is not limited to systems using a particular type of display device. Thus the display device may be a head-mounted unit or a conventional video monitor. The invention also can be used with display devices that are adapted to display the left and right images alternately or concurrently, according to well known techniques for presenting 3-D pictures. 
     It should be noted that the invention is not limited to stereo electronic endoscopes and microscopes but can be used for aligning the stereo images of any stereo electronic camera. Although the stereo image alignment components shown in FIG. 2 can be united as a separate test instrument for use by instrument manufacturers in aligning stereo microscopes, endoscopes, and stereo video cameras per se, the invention also may be incorporated as a permanent part of the electronics system of a microscope or endoscope. In the case where the stereo camera is a permanent part of an instrument such as an endoscope, the stereo alignment system shown in FIGS. 1-3 need not be incorporated into the instrument&#39;s electronic system, but instead the corrections determined to be necessary by computer  42  may be permanently stored in a non-volatile memory that is integrated into the instrument or its associated electronics, with the electronics programmed so that each time the instrument is activated the data recorded in the non-volatile memory will be accessed automatically and used to adjust the stereo images as fed to the display system. Furthermore, as suggested by the two broken lines labeled “digital output” in FIG. 2, the image alignment system of this invention may be modified by using the corrected digital video image data output from memory units  34 R and  34 L to drive a digital video display according to recently developed digital video techniques. 
     The invention has numerous advantages. The electronic system for correcting misalignment errors utilizes conventional components and the software required to control operation of computer  42  and the other parts of stereo image processor  26  is straightforward and imposes no unreasonable or costly hardware requirements. Best of all, the alignment can be accomplished rapidly and accurately. 
     Other modifications and advantages will be obvious to persons skilled in the art.