SVGImport.wiki
changeset 363 c6e60247e9d4
parent 334 612048d0890b
child 374 8473f5d4d817
equal deleted inserted replaced
362:10fb0298948b 363:c6e60247e9d4
    37 The coordinates should now be rounded for use by the crude script in (10) unless you plan to handle that yourself in some way.  Here is a vim one-liner to do it.
    37 The coordinates should now be rounded for use by the crude script in (10) unless you plan to handle that yourself in some way.  Here is a vim one-liner to do it.
    38 {{{:s/[0-9][0-9.]*/\=float2nr(floor(submatch(0)*1))/g}}}
    38 {{{:s/[0-9][0-9.]*/\=float2nr(floor(submatch(0)*1))/g}}}
    39 
    39 
    40 
    40 
    41 9) Convert the path data.  Here is a crude script to do that.  Note this one uses a line size of 1 (that's the 0x01 business).
    41 9) Convert the path data.  Here is a crude script to do that.  Note this one uses a line size of 1 (that's the 0x01 business).
    42 If you want larger lines you can pick anything between 0x01 and 0x3F.  That's 16-636.  See the map format wiki page.
    42 If you want larger lines you can pick anything between 0x00 and 0x3F.  That's 6-636.  See the [DrawnMapFormat] wiki page.
    43 {{{
    43 {{{
    44 #!/usr/bin/perl
    44 #!/usr/bin/perl
    45 # just a one-line list of points. at least, it had better be one-line
    45 # just a one-line list of points. at least, it had better be one-line
    46 open FILE, $ARGV[0];
    46 open FILE, $ARGV[0];
    47 while(<FILE>)
    47 while(<FILE>)