Alternate Endpoints

This forum is for users to submit their own gadgets to the community
Post Reply
User avatar
adze_cnc
Vectric Wizard
Posts: 4325
Joined: Sat Jul 27, 2013 10:08 pm
Model of CNC Machine: AXYZ 4008
Location: Vancouver, BC, Canada

Alternate Endpoints

Post by adze_cnc »

andyb wrote:
Thu Mar 10, 2016 4:11 pm
I would like to see a gadget that would alternate the starting point for a series of lines. Example if you have a series of open vertical lines and the start point is at the bottom of all the lines. The gadget would alternate the start points from bottom to top or top to bottom. This would be very handy when creating textures. It would keep the gantry moves of the toolpaths down.

Andy B.
This gadget swaps the start and end points of every other open vector in a selection of vectors. The selected vectors must not be "grouped" together.
 
Starting points (green boxes) before gadget run
Starting points (green boxes) before gadget run
 
Starting points (green boxes) after gadget run
Starting points (green boxes) after gadget run
 
The gadget is non-destructive. All of the source vectors will be copied to a new layer called "Alternating Endpoints". Closed can be included in the selection but will be ignored when swapping endpoints. Those closed vectors will be copied to the new "Alternating Endpoints" layer.

A second layer called "Alternating Markers" will be created. This layer marks the start points of every vector in the selection. It also numbers those vectors showing the order that gadget processed those vectors. This can be used to validate that the new vectors are as desired.

This gadget works in Aspire and VCarve Pro versions 9 to 11.

I have not tried it in version 10.x but as underlying SDK entries have not changed between v9 and v11 it should work fine. I have also not tested it in versions less than v9 but I expect that it should work.

Because the forum software doesn't allow attachments with ".vgadget" extension the file is uploaded as "Alternate Endpoints v1_0.zip". Rename this to "Alternate_Endpoints v1_0.vgadget" after downloading and before installing.

To install the gadget into Aspire/VCarve Pro choose on of the following methods:
  • with Aspire/VCarve closed you can "double-click" on the .vgadget file in Windows Explorer to automatically load Aspire/VCarve and install the gadget.
  • if you already have Aspire/VCarve open you can install the gadget by using the menu option: Gadgets > Install New Gadget...
If you use the latter option you will need to restart Aspire/VCarve to see the new gadget on the Gadget menu.

Some changes that might be made for the gadget:
  • replace vectors in their source layers instead of copying to new layer
  • user input layer name
  • option to turn off marker creation
—Steven

To use this gadget just follow these simple steps:
  1. Select the vectors for the gadget to swap endpoints of every other vector
  2. Go to "Gadgets" on the toolbar and select the "Alternate Endpoints" Gadget
  3. When the gadget is finished it will display an "all done" message.
Attachments
Alternate_Endpoints v1_0.zip
(2.52 KiB) Downloaded 125 times

User avatar
sharkcutup
Vectric Wizard
Posts: 2885
Joined: Sat Mar 26, 2016 3:48 pm
Model of CNC Machine: Shark HD3 Pro Extended Bed with Spindle
Location: U.S.A.

Re: Alternate Endpoints

Post by sharkcutup »

Fiddled a little with Stephen's Alternating Vector Gadget on a circular pattern similar to your post.

Also tried the gadget on vertical and horizontal vectors together and separately works great!!!

Interesting and useful gadget there -- Stephen :)

Sharkcutup
V-Carve Pro Tips, Gadget Tips & Videos
YouTube Channel - Sharkcutup CNC
V-Carve Pro 11.554

User avatar
adze_cnc
Vectric Wizard
Posts: 4325
Joined: Sat Jul 27, 2013 10:08 pm
Model of CNC Machine: AXYZ 4008
Location: Vancouver, BC, Canada

Re: Alternate Endpoints

Post by adze_cnc »

I was thinking. For those that don't like/need the markers you can turn that off yourself.

The gadget program is just a text file that can be edited. In modern versions of Windows it will be in the public user data folder for Vectric programs

usually this folder is:

Code: Select all

C:\Users\Public\Documents\Vectric Files\Gadgets
in that are your installed Vectric programs (if you have more than one). Within a particular product folder is the Alternate Endpoints gadget folder:

Code: Select all

Alternate_Endpoints
With your text editor of choice edit the file:

Code: Select all

Alternate_Endpoints.lua
Find the following at line 135 (or very near if this is in the future):

Code: Select all

AddMarkers(job.Selection)
and change it to:

Code: Select all

-- AddMarkers(job.Selection)
Then save the file (keeping the .lua extension and not letting your text editor call it .txt).

User avatar
sharkcutup
Vectric Wizard
Posts: 2885
Joined: Sat Mar 26, 2016 3:48 pm
Model of CNC Machine: Shark HD3 Pro Extended Bed with Spindle
Location: U.S.A.

Re: Alternate Endpoints

Post by sharkcutup »

Thank you for that info!!!

Another Awesome Gadget to add to my set of tools!!!

Sharkcutup
V-Carve Pro Tips, Gadget Tips & Videos
YouTube Channel - Sharkcutup CNC
V-Carve Pro 11.554

User avatar
scottp55
Vectric Wizard
Posts: 4713
Joined: Thu May 09, 2013 11:30 am
Model of CNC Machine: ShopbotDesktop 5.5"Z/spindle/VCP11.5
Location: Kennebunkport, Maine, US

Re: Alternate Endpoints

Post by scottp55 »

Thanks very much for that Gadget Steven! :)

I haven't been doing many fluting toolpath "bowls" recently, but with Circular Array
that's going to come in Very handy:)
I kinda like the "Markers" for that use, as I usually do 1 or 2 vectors using Pass Depth,
and then just run the rest at full depth(as it's only cutting"stepover"),
and the Markers make it Much easier to tell where the sequence starts!

Don't really grid my spoilboard anymore because I'm not doing protos in the field anymore,
but it really would have made that Much easier to toolpath for less Air time!

Basically a real time saver when toolpathing.
THANKS!! :)
scott
I've learned my lesson well. You can't please everyone,so you have to please yourself
R.N.

Post Reply