lundi 28 mars 2011

Drawing and then plotting

With the script in the first link you can draw with the mouse ( by clicking ) and if you think the result is ok, by hitting a key on the keyboard the plotting commands are dispatched and you plot the drawing.

basicDrawing_Plotter.pde

(Update: this sketch detects if the plotter is attached and when not the error is caught and does not cause any damage.)

You can do the same without the plotter attached, but then the list of point of the drawing is saved to a file in your datafolder (of the sketch) and can be loaded later:

plottingletters_saveFile.pde

ok and then you can retrieve and plot this linedrawing using this sketch (if the plotter is connected). You only have to change the name of the file to load in this line of code:

String myName = "a";

(in the function draw() )
Now he is searching for a textfile called a.txt in the sketchfolder (in Documents Processing )

plottingletters_loadFile.pde

My name is BEAM from now on!

Aucun commentaire:

Enregistrer un commentaire