home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: alt.cad.autocad
- Path: sparky!uunet!zaphod.mps.ohio-state.edu!sol.ctr.columbia.edu!caen!batcomputer!lynx@msc.cornell.edu!grits.msc.cornell.edu!putnam
- From: putnam@grits.msc.cornell.edu (Albert M. Putnam)
- Subject: HPGL to DXF in PERL available
- Message-ID: <1992Nov23.230417.18198@msc.cornell.edu>
- Keywords: HPGL DXF PERL
- Sender: news@msc.cornell.edu
- Reply-To: putnam@msc.cornell.edu
- Organization: Materials Science Center
- Date: Mon, 23 Nov 1992 23:04:17 GMT
- Lines: 36
-
- I have available a PERL program to convert
- HPGL to AutoCAD dxf format (hpgl2dxf.prl).
-
- Why PERL? - It was available at our site, and PERL is reasonably easy
- to obtain for any platform.
- I wanted transparent buffer management (N/A in C).
- Why DXF? - There is a program out there (A very nice C program
- called HPGL2SCR by William Palmer)
- that converts HPGL to AutoCAD script
- but, on our platform anyway, script input
- is unacceptably slow and DXF format is preferable.
-
- On an IBM 520 workstation this PERL program can convert
- a 50K HPGL file in about 20-30 seconds to a DXF file that is about 150K.
- Then AutoCAD V11 can "DXFIN" that file in about 5 seconds.
-
- The program should be fairly easy to expand to include new entities,
- and there is a sister PERL program that converts HPGL to script
- (a la HPGL2SCR) that includes a larger fraction of the HPGL object types.
- If one were brave one could convert the programs to C with a little
- bit of I/O buffer management coding.
-
- The program has a serious bug involving the label (LB) HPGL command.
- If a ";" is part of the label string then things could go rather awry.
- I actually have this vague recollection about an old HP7220 that I
- used years ago that DID go awry if there were delimiters or
- control characters in the text - so maybe this is a feature?
-
- If you would like a copy send me e-mail.
- If you have a format preference (uuencoded, shar, etc.)
- I can TRY and send it as you wish.
- If I get overwhelmed I will try and have the programs archived somewhere.
-
- Albert Putnam
- putnam@msc.cornell.edu
-
-