Editing Generating TSP art from a stippled image

Jump to: navigation, search

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision Your text
Line 77: Line 77:
 
On the other hand, if you want a single, closed path drawn then specify <tt>--max-segments=0</tt>. Using a value of zero tells tspart.py to put the entire TSP solution into a single SVG path.  Of course, your SVG viewer needs to be able to handle the single path which results, even if it has thousands or tens of thousands of line segments.
 
On the other hand, if you want a single, closed path drawn then specify <tt>--max-segments=0</tt>. Using a value of zero tells tspart.py to put the entire TSP solution into a single SVG path.  Of course, your SVG viewer needs to be able to handle the single path which results, even if it has thousands or tens of thousands of line segments.
  
When using <tt>--max-segments=0</tt>, you can also specify a fill color.  By default, the closed path has an SVG fill value of "none".  You can select any SVG color name (e.g., blue, red, orange, etc.), or you can specify hexadecimal RGB values using the #rrggbb notation (e.g., #ff0000 for red).  For example, the command
+
When using <tt>--max-segments=0</tt>, you can also specify a fill color.  By default, the closed path has an SVG fill value of "none".  You can select any SVG color name (e.g., "blue", 'red", "orange", etc.), or you can specify hexadecimal RGB values using the #rrggbb notation (e.g., #ff0000 for red).  For example,
  
 
:<tt>% python tspart.py --max-segments=0 --fill=#00ffcc --runs=1 zebra.pbm</tt>
 
:<tt>% python tspart.py --max-segments=0 --fill=#00ffcc --runs=1 zebra.pbm</tt>
  
produced the result,
+
produced
  
 
http://wiki.evilmadscience.com/s3/eggbot/tspart/filled-zebra.png
 
http://wiki.evilmadscience.com/s3/eggbot/tspart/filled-zebra.png

Please note that all contributions to Evil Mad Scientist Wiki are considered to be released under the GNU Free Documentation License 1.3 (see Evil Mad Scientist Wiki:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

To edit this page, please answer the question that appears below (more info):

Cancel | Editing help (opens in new window)

Template used on this page: