Get Vectors

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 2

GetVectors.

lsp Information
GetVectors.lsp uses the method in the subfunction WmfExplode that uses WmfOut and WmfIn to explode selected entities into lines.
These entities are selected to create the block GetVectors. The color of the entities is very important. By using the Color command, you
have 255 colors to choose from. GetVectors creates the file C:\Temp\Vectors.dcl and C:\Temp\Vectors.lsp. You can copy and paste
sections of these files into your own *.dcl and *.lsp file, and edit as needed.
Images in the dcl files begin with :image. The image method in dcl files is similar to how other image programs like MS Paint.exe
work, where as the top left corner 0,0 is a valid point to colorize. GetVectors.lsp converts the selected coordinates into positive numbers
so you don’t need to mirror your entities to make it work.
Simply draw a rectangle from 0,0 to a location below and to the right of 0,0 like 99,-99 for example to create a Width of 100 by a
Height of 100 image. Then draw some entities, and scale some text of any font down to fit into this area for testing. Erase the outline
rectangle later if you do not need it. Any Height and Width will work as long as it is in the range that will fit on your display screen.
After loading GetVectors.lsp you can use the shortcut GV on the command line to run the program. You will see the Get Vectors
dialog below with the [ Info ] and [ Help ] buttons. Notice the Background checkbox where you can choose to use the AutoCAD
background or the dialog background to make it invisible like part of the dialog.

The [ Info ] button displays this information.

The [ Help ] button displays this information.


The GetVectors [ OK ] button displays this information.

The block DupVectors shows you instances of where two lines intersect, and you may want to tweak which line color you want to be
in that intersection. You may want to use the newly created block GetVectors instead of the original extities, as these have been
converted into the lines that are used to create GetVectors.dcl. Some areas may display better if they are slightly moved less that 0.5 in
any direction, because each point is converted to the nearest number.

GetVectors Example
Here is an example for using GetVectors.lsp. Draw or copy an image that you can scale to fit inside a 149 width by a 99 height area.
Remember that 0,0 is considered a valid point to colorize. So, you have 150 width in pixels by 100 height in pixels. You may need a
smaller or larger area that works out for your own final project.

In this example create a hatch in the blue and green areas with the pattern LINE with an angle of 0 and a scale of 8, as the hatch
lines are 0.125 apart. This also works best for solids. Erase the outline rectangle if you do not need it.

Then run GetVectors using the shortcut GV, and use a 150 width by a 100 height for this example. You will notice the program
processing the information to create the two files C:\Temp\Vectors.dcl and C:\Temp\Vectors.lsp. Then run ViewVectors using the
shortcut VV on the command line to run the program, and view the vectors.

You might also like