Search code examples
postscriptcad

What are those segments? CAD or language tips, please


Inherited files with body content said to be from some unknown CAD system. To me it looks a bit like postscript. I would appreciate any tips and points wrt language description and how I could reconstruct curves/segments.

8
2
T06
43.220
0 -85.5 0
1

newpath 0.000 0.000
arcto 41.943 15.266
           64.260 53.921
lineto 76.669 124.293
closepath

newpath 0.000 -0.500
arcto 42.264 14.883
           64.752 53.834
lineto 77.000 123.293
closepath

Solution

  • Since there are only a few tens of them, you could write a program to roughly convert them into Postscript to at least see what you might have:

    newpath
    0.000 0.000 moveto
    41.943 15.266 64.260 53.921 1 arcto
    76.669 124.293 lineto
    closepath
    
    stroke
    
    newpath
    0.000 -0.500 moveto
    42.264 14.883 64.752 53.834 1 arcto
    77.000 123.293 lineto
    closepath
    
    stroke
    
    showpage
    

    The example file you provided seems to draw the same shape twice, with only slight variation -- I assume from the minimal drawing commands that all the files collectively add up to one (interesting) whole:

    enter image description here