Software For Use With Optoelectronic Measuring Tool
- Created: Friday, 01 October 2004
A computer program has been written to facilitate and accelerate the process of measurement by use of the apparatus described in “Optoelectronic Tool Adds Scale Marks to Photographic Images” (KSC-12201), NASA Tech Briefs, Vol. 27, No. 1 (January 2003), page 6a. To recapitulate: The tool contains four laser diodes that generate parallel beams of light spaced apart at a known distance. The beams of light are used to project bright spots that serve as scale marks that become incorporated into photographic images (including film and electronic images). The sizes of objects depicted in the images can readily be measured by reference to the scale marks.
The computer program is applicable to a scene that contains the laser spots and that has been imaged in a square pixel format that can be imported into a graphical user interface (GUI) generated by the program. It is assumed that the laser spots and the distance(s) to be measured all lie in the same plane and that the plane is perpendicular to the line of sight of the camera used to record the image. The user marks the locations of the laser spots in the image, and the program calculates the distance (Ls) between them in pixels as simply the square root of the sum of squares of the horizontal and vertical pixel distances between them. Similarly, the user marks any two points, the distance between which is to be measured, and the program calculates the distance (Ps) between them in pixels, in the same manner in which it calculates the pixel distance between the laser spots. Then the program calculates the real distance (Lo) between the two points by Lo = LsPo / Ps, where Ls is the known real distance between the laser spots.
The original version of the program, written in Fortran, offered limited performance: it could accept only bit-map (BMP) image data files and was somewhat awkward to use. The current version, written in C++, performs better, in part because it utilizes capabilities afforded by the Windows operating system. In addition to BMP files, the program can now read and save image files in the Joint Photographic Experts Group (JPEG or JPG) and Graphic Image File (GIF) formats. Some of the other features of the current version of the software are the following:
- The GUI has been made less complex and is easier to use than it was in the original version.
- The total number of laser-spot marks that the user can place in the image is not limited to four. Moreover, the marks need not be limited in application to the laser spots: they can be applied to any linear set of evenly spaced reference marks (for example, a row of evenly spaced screw heads) as long as the distance between the marks is known.
- A given pair of measurement points and a rectangular measurement zone bounded by two points at diagonally opposite corners is established by stretching the straight diagonal line between them in a conventional point-and-click “rubber band” mouse operation. The GUI displays the horizontal, vertical, and diagonal dimensions of the measurement zone as the mouse is dragged to stretch the diagonal.
- By means of a “Set Actual Distance” command, the user can prescribe or update the distance along the diagonal of a measurement zone. The updated actual diagonal horizontal, vertical, and diagonal distance values are immediately displayed in the image. In addition, a status bar provides an option to display the actual distance between laser spots.
- Context-sensitive help displays comprising text, images, and hypertext links to related pages are available for each command and GUI button. There is also a help page describing the procedure for using the program.
This program was written by Kim C. Ballard of Kennedy Space Center. For further information, access the Technical Support Package (TSP) free on-line at www.techbriefs.com/tsp under the Software category.
This invention is owned by NASA, and a patent application has been filed. Inquiries concerning nonexclusive or exclusive license for its commercial development should be addressed to the Technology Programs and Commercialization Office, Kennedy Space Center, (321) 867-8130. Refer to KSC-12505.