POD documentation for svg2hpl.pl


  1. N
  2. S
  3. D
  4. O
  5. A
  6. S
  7. S
  8. K
  9. A
  10. C
  11. S


svg2hpl.pl - Makes stage analysis location file (.hpl) or tab-delimited txt file from .svg (Scalable Vector Graphics file).


svg2hpl.pl [-vb|--verbose -o|-out filename -i|--interactive] [svgfilename]
svg2hpl.pl filename Reads .svg file
svg2hpl.pl --help produces this message
svg2hpl.pl --help -v produces a longer help message
svg2hpl.pl -out filename Writes to filename, or filename.txt and filename.hpl depending on if .txt or .hpl is specified.
svg2hpl.pl -i -out filename Silently writes to filename, if there are no problems.


This program generates either an IMS-1270 stage analysis file (.hpl), a tab-delimited text-file (.txt) with IMS-1270 coordinates for editing, or both. It determines these coordinates from an Scalable Vector Graphics (.SVG) file, and is designed to be run either with or without command-line options or arguments. When run without arguments it locates and processes the most recently modified .svg file, otherwise it runs on the given filename. The program uses the location of the upper-left corner of rectangles in any layer with 'target' as part of its name. It sets the analysis order based upon the 'id' field for each rectangle sorted alphabetically (10 is after 2, but 10 is before 02). If you do not change this manually, it means that the order in which you add points will be the order in which they will be analyzed. The program then translates the pixel locations into stage coordinates (10 microns to the pixel), rounding to the nearest micron, and adds the comment (optional) from the 'Inkscape id' field. It then asks for a filename to output to. If the filename ends in .txt or .hpl it will generate the appropriate format, otherwise it will make both files. The tab-delimited text-file (.txt) can be loaded by Microsoft Excel for editing and translated to a stage coordinate file by txt2hpl.pl. The stage coordinate file can be moved to the Sun Workstation and loaded.



This program currently expects either one argument (a properly formatted svg file) or no arguments. If given no arguments it will find the most recent .svg file and run on that file.


This program currently has several parts:


perlpod, http://www.perl.org, http://www.gnu.org, txt2hpl.pl, hpl2txt.pl, svg_generator.pl, startdialog.pl


This makes .txt files like correlator.html. If you are careless this may cause problems.


Miles McCammon, <miles86@ucla.edu>


svg2hpl.pl - Makes stage analysis location file (.hpl) or tab-delimited txt file from .svg (Scalable Vector Graphics file). Copyright © 2008 SIMS Lab, University of California Los Angeles; University of California Regents This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation version 2. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. To receive a copy of the GNU General Public License, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.

Source Code

Source code for this version (11/6/08, 20:41) can be downloaded here.
N 34° 4' 9" W 118° 26' 27"