## Idea - Spacing dots along a line/path

**Moderators:** andrew, Husky, J-J

### Idea - Spacing dots along a line/path

Howdy!

Would it be possible to create a function where I could draw an arc, circle or perhaps a line, and create 'Points' along it at a distance specifically set by the end-user?

As you can see in the images I am making points along a half-circle.

#1) For this, I have made an ARC at 180 degrees. Next I create a new layer; create a center point and draw lines out from the 'center' roughly drawn where I desire it, and then, to get more accurate, I type in the angle afterwards. I used to draw these on graph paper, and map the coordinates and hand-code the data I will do this for every point I need to make. (Something of a long process and prone to errors!).

#2) When the other layers are hidden/removed, we have achieved points on an arc! (Note this is *not* the final outcome! This is a work-in-progress and I am just starting on it.)

Thanx for your time!

Would it be possible to create a function where I could draw an arc, circle or perhaps a line, and create 'Points' along it at a distance specifically set by the end-user?

As you can see in the images I am making points along a half-circle.

#1) For this, I have made an ARC at 180 degrees. Next I create a new layer; create a center point and draw lines out from the 'center' roughly drawn where I desire it, and then, to get more accurate, I type in the angle afterwards. I used to draw these on graph paper, and map the coordinates and hand-code the data I will do this for every point I need to make. (Something of a long process and prone to errors!).

#2) When the other layers are hidden/removed, we have achieved points on an arc! (Note this is *not* the final outcome! This is a work-in-progress and I am just starting on it.)

Thanx for your time!

>>>Thanx!

~Sterl~

~Sterl~

### Re: Idea - Spacing dots along a line/path

Howdy!

Just curious ...

Question for Points on a line:

The tools "N Points on a Line" or "Move / Copy" will not suit what you are looking for?

Question for Points on an arc or circle:

Whats about the "Rotate" tool?

Example: Draw your arc - place on the end(?) a point - check the "Property Editor" to get the exact length of the arc - use this information in the Rotate dialog for a calculation.

In this example my arc length is 78.539816 and I like to have every 10 units along(!) the arc a point ...

Sterling wrote:Would it be possible to create a function where I could draw an arc, circle or perhaps a line, and create 'Points' along it at a distance specifically set by the end-user?

Just curious ...

Question for Points on a line:

The tools "N Points on a Line" or "Move / Copy" will not suit what you are looking for?

Question for Points on an arc or circle:

Whats about the "Rotate" tool?

Example: Draw your arc - place on the end(?) a point - check the "Property Editor" to get the exact length of the arc - use this information in the Rotate dialog for a calculation.

In this example my arc length is 78.539816 and I like to have every 10 units along(!) the arc a point ...

Work smart, not hard: QCad Pro

### Re: Idea - Spacing dots along a line/path

Husky's idea is good for creating points at equal distances, however currently there is no tool to place points along an arc, line at varying distances. Maybe someone in the community will take up the challenge of developing such a tool, alternatively it might be worth considering to sponser Andrew to develop a tool if this would be worth your while .

For the best support please state your operating system, QCAD version and add any supporting DXF/DWG files, screenshots etc...

### Re: Idea - Spacing dots along a line/path

This may help.

Try placing your points using the snap to entity option and the snap distance option, if you know the distances between one end of your Arc, Circle, Spline etc. and the points in sequence, you can simply type them into the Snap distance field

*Note if you are placing points around a Circle using this method you will need to divide the Circle (Modify -Divide) into two arcs.

Try placing your points using the snap to entity option and the snap distance option, if you know the distances between one end of your Arc, Circle, Spline etc. and the points in sequence, you can simply type them into the Snap distance field

*Note if you are placing points around a Circle using this method you will need to divide the Circle (Modify -Divide) into two arcs.

For the best support please state your operating system, QCAD version and add any supporting DXF/DWG files, screenshots etc...

### Re: Idea - Spacing dots along a line/path

Not to stretch the point too far (excuse the pun ) here's a similar method to Husky's ... but more of a click and go method.

1. Set up required layers.

2.Working on layer 'Construction' copy with reference the Arc in question and paste to the 'current' layer (Construction).

3.Working only on layer Construction, split the Arc into required number of parts, remember to check the Green tick.

4.Now working on layer 'Point' place a point on either end of your Arc.

5. Use the Rotate tool and follow the prompt -Center - using the 'Snap to Center' option, snap to the arc's center.

6. The Rotate options dialog window opens, select Multiple, type in the number and hit the cursor button, this will allow you to use the mouse cursor to select the rotation angle.

7. Select the point as your reference.

8. Set the snap option to 'End' then snap to the nearest end point (your end points created from your divisions) from your reference point.

9 Turn on/off appropriate layers and job done .

1. Set up required layers.

2.Working on layer 'Construction' copy with reference the Arc in question and paste to the 'current' layer (Construction).

3.Working only on layer Construction, split the Arc into required number of parts, remember to check the Green tick.

4.Now working on layer 'Point' place a point on either end of your Arc.

5. Use the Rotate tool and follow the prompt -Center - using the 'Snap to Center' option, snap to the arc's center.

6. The Rotate options dialog window opens, select Multiple, type in the number and hit the cursor button, this will allow you to use the mouse cursor to select the rotation angle.

7. Select the point as your reference.

8. Set the snap option to 'End' then snap to the nearest end point (your end points created from your divisions) from your reference point.

9 Turn on/off appropriate layers and job done .

For the best support please state your operating system, QCAD version and add any supporting DXF/DWG files, screenshots etc...

### Re: Idea - Spacing dots along a line/path

My history/reason for asking...FYI: I built a CNC machine, and am teaching myself elements of GCoding and CAD work. I've made this particular forum-request, because I am designing custom cribbage boards, and to make the peg-holes even on a curve is more difficult than I had realized.

#1) Husky –

- The "N points on a line" (command PN) are for straight lines, not an Arc.

- I am new to all of this and I think I understand your solution. I will give that a try. Thanx!

#2) Clive

– Wow, I think you give me too much credit, as your example went beyond my understanding! When I have some free time, I will certainly give that a try, and hopes it expands my knowledge of the software, Thanx!

#1) Husky –

- The "N points on a line" (command PN) are for straight lines, not an Arc.

- I am new to all of this and I think I understand your solution. I will give that a try. Thanx!

#2) Clive

– Wow, I think you give me too much credit, as your example went beyond my understanding! When I have some free time, I will certainly give that a try, and hopes it expands my knowledge of the software, Thanx!

>>>Thanx!

~Sterl~

~Sterl~

### Re: Idea - Spacing dots along a line/path

Hmm... Husky's solution doesn't seem to work for me. Did I misunderstand?

Steps Taken:

#1) I created an ARC using "2 points and Angle" (A2)

#2) Property editor states the arc is 180 degrees with a length of 5.885146

#3) I place a "Single Point" (PO) at the end of the arc.

#4) I then highlight the single point, and select "Rotate" from the menu above (R,O)

#5) I entered the formula but nothing happened. (tried this several times)

...

The only way I seem able to get the points to appear ON THE ARC (where I want them) is to...

#1 - #3) As above

#4) Using the center coordinates of the Arc from the Property window, make a Point in the center.

#5) Selected the End Point of the Arc,

#6) Selected Rotate

#7) Select the Center Point; When the Rotate Options window appears enter the formula & press [Okay].

...The points appear 360 degrees around the center point. (half on the arc, half below, completing the circle).

- I have tried to double and half the division number at the end to see if it gives me what I need; if the points appear all the way around, I could simply delete the unwanted points.

I'll think and play with it some more. This is MORE progress than what I had before, Thanx!

Steps Taken:

#1) I created an ARC using "2 points and Angle" (A2)

#2) Property editor states the arc is 180 degrees with a length of 5.885146

#3) I place a "Single Point" (PO) at the end of the arc.

#4) I then highlight the single point, and select "Rotate" from the menu above (R,O)

#5) I entered the formula but nothing happened. (tried this several times)

...

The only way I seem able to get the points to appear ON THE ARC (where I want them) is to...

#1 - #3) As above

#4) Using the center coordinates of the Arc from the Property window, make a Point in the center.

#5) Selected the End Point of the Arc,

#6) Selected Rotate

#7) Select the Center Point; When the Rotate Options window appears enter the formula & press [Okay].

...The points appear 360 degrees around the center point. (half on the arc, half below, completing the circle).

- I have tried to double and half the division number at the end to see if it gives me what I need; if the points appear all the way around, I could simply delete the unwanted points.

I'll think and play with it some more. This is MORE progress than what I had before, Thanx!

>>>Thanx!

~Sterl~

~Sterl~

### Re: Idea - Spacing dots along a line/path

Clive -

Your "Snap on Entity" using the Distance measurement seems to be working, thanx!

...It looks a little weird, but I suspect that is my failure to accurately perform math functions!

Your "Snap on Entity" using the Distance measurement seems to be working, thanx!

...It looks a little weird, but I suspect that is my failure to accurately perform math functions!

>>>Thanx!

~Sterl~

~Sterl~

### Re: Idea - Spacing dots along a line/path

Sterling wrote:Clive -

Your "Snap on Entity" using the Distance measurement seems to be working, thanx!

...It looks a little weird, but I suspect that is my failure to accurately perform math functions!

Okay, good, you just have to remember that the distance entered is the distance from the end point of the arc/entity to the most recent point you need to place - so for example if you need to place a set of points along a line starting with the first point at a distance of say 13.56 then the next at an interval of 10 units, you would proceed as follows:

1.First point distance -type 13.56.

2.Next point distance - type 23.56 and so on ...

This method will suit if you are placing points at equal or unequal spacing!

### Re: Idea - Spacing dots along a line/path

Sterling wrote:Hmm... Husky's solution doesn't seem to work for me. Did I misunderstand?

Steps Taken:

#1) I created an ARC using "2 points and Angle" (A2)

#2) Property editor states the arc is 180 degrees with a length of 5.885146

#3) I place a "Single Point" (PO) at the end of the arc.

#4) I then highlight the single point, and select "Rotate" from the menu above (R,O)

#1 - #4 is already correct ...

... the next steps would be:

#5) The rotate tool needs a reference point for the rotation - snap to the center point of the arc.

#6) Now the rotate dialog pops up - use a formula similar to this "180/58.590703*10".

180 = degree of the arc

58.590703 = the length of the arc (taken from the property editor)

10 = desired(?) distance along the arc

Don't forget to tell the tool how many copies do you need - in my example 5.

Result:

Is it now, with this explanation, working for you?

Edit:

I forgot - if you need to rotate in the other direction .... "-(180/58.590703*10)"

Work smart, not hard: QCad Pro

### Re: Idea - Spacing dots along a line/path

Thanx, Husky, I'll give that a try.

For some reason, when I tried the second (inner) path using Clive's method something went awry. :/

And yes, I double checked my numbers and did all the math in an excel spread sheet to so I had all the required distance marks in place. But...it didn't seem to line up properly to me. (The points represent peg-holes for a cribbage board)

In the image, you can see the PINK and White points make a nice arcs, half of what I need, however they are still a bit off.

- The White points do not line up between the center-point and their corresponding point on the outside.

- The Pink point on the top doesn't line up perfectly with the green center-line like the white one does.

- The spacing isn't quite right yet either. The outside bottom white point is the last hole in the prior series of 5 peg holes. So, that being the last spot before the next series of '5', where the turn begins, I need to delete the first and last pink point.

...I'm not sure why. It might be that I shortened the number used for measuring the distance points. The coordinates initially came back with 6+ digits to the right of the decimal, but I shortened them to 3, thinking anything beyond that probably wouldn't matter. (I'll try to re-do it all again tonight and see if I get different results.)

My rational behind this (If you play cribbage you will understand, if not I can whip up another JPG to upload)

#1) I needed 10 points to drill across an this 180 arc. To ensure that they would be evenly spaced for this curve, I thought I would need 13 points. 10 points for the peg-holes, and 3 points to mark the spacing between the series of 5 = [space] + [5points] + [space] + [5points] + [space].

...but (shrugs) it didn't come out the way I thought.

need to and I need to adjust the spacing so there are 5 evenly distributed holes (points) between that and the green center line.

For some reason, when I tried the second (inner) path using Clive's method something went awry. :/

And yes, I double checked my numbers and did all the math in an excel spread sheet to so I had all the required distance marks in place. But...it didn't seem to line up properly to me. (The points represent peg-holes for a cribbage board)

In the image, you can see the PINK and White points make a nice arcs, half of what I need, however they are still a bit off.

- The White points do not line up between the center-point and their corresponding point on the outside.

- The Pink point on the top doesn't line up perfectly with the green center-line like the white one does.

- The spacing isn't quite right yet either. The outside bottom white point is the last hole in the prior series of 5 peg holes. So, that being the last spot before the next series of '5', where the turn begins, I need to delete the first and last pink point.

...I'm not sure why. It might be that I shortened the number used for measuring the distance points. The coordinates initially came back with 6+ digits to the right of the decimal, but I shortened them to 3, thinking anything beyond that probably wouldn't matter. (I'll try to re-do it all again tonight and see if I get different results.)

My rational behind this (If you play cribbage you will understand, if not I can whip up another JPG to upload)

#1) I needed 10 points to drill across an this 180 arc. To ensure that they would be evenly spaced for this curve, I thought I would need 13 points. 10 points for the peg-holes, and 3 points to mark the spacing between the series of 5 = [space] + [5points] + [space] + [5points] + [space].

...but (shrugs) it didn't come out the way I thought.

need to and I need to adjust the spacing so there are 5 evenly distributed holes (points) between that and the green center line.

>>>Thanx!

~Sterl~

~Sterl~

### Re: Idea - Spacing dots along a line/path

Howdy gents...

I regret to inform you that I am still not getting the job done. Husky, I have tried your method, and here is what I did... Step-By-Step

#1) Made two paths for the cribbage holes, where the arcs will meet, outer-to-outer, and inner-to-inner.

#2) Using 2 Points and Angle to make the ARC

#3) Length of the ARC = 5.885146 (also has Center point of X3 Y1.9375)

#4) Make Center point at X3 Y1.9375

#5) Point on the end of the arc has been selected, then I chose Rotate from the menu options.

#6) Clicking on the center point, then in Rotate Options window, place in math and number of points needed. I needed 13 points to create 10* peg holes.

Here is the input:

#7) Unfortunately, it did not work. As you can see, the dots went ALL THE WAY AROUND. :/

* Here is why I wanted 13 points for 10 holes...(Again, I do not know if you know how to play, so I feel compelled to ensure accuracy here!)

Holes on a cribbage board are evenly drilled in sets of 5-per-player (thus 10 holes because it's 2 player! ) with a space between each set that is approximately double between the holes. So, by making the space between every point the same, all I would need to do, is delete every 6th point and I would get series of 5! This image is of cribbage board I made for someone out of hardwood flooring. The holes are not 100% precise, but they are very close and as you can see there are 6 sets of 5.

So, I'm not sure what to do here and I apologize greatly if I am making a mistake that I do not see...!

I regret to inform you that I am still not getting the job done. Husky, I have tried your method, and here is what I did... Step-By-Step

#1) Made two paths for the cribbage holes, where the arcs will meet, outer-to-outer, and inner-to-inner.

#2) Using 2 Points and Angle to make the ARC

#3) Length of the ARC = 5.885146 (also has Center point of X3 Y1.9375)

#4) Make Center point at X3 Y1.9375

#5) Point on the end of the arc has been selected, then I chose Rotate from the menu options.

#6) Clicking on the center point, then in Rotate Options window, place in math and number of points needed. I needed 13 points to create 10* peg holes.

Here is the input:

#7) Unfortunately, it did not work. As you can see, the dots went ALL THE WAY AROUND. :/

* Here is why I wanted 13 points for 10 holes...(Again, I do not know if you know how to play, so I feel compelled to ensure accuracy here!)

Holes on a cribbage board are evenly drilled in sets of 5-per-player (thus 10 holes because it's 2 player! ) with a space between each set that is approximately double between the holes. So, by making the space between every point the same, all I would need to do, is delete every 6th point and I would get series of 5! This image is of cribbage board I made for someone out of hardwood flooring. The holes are not 100% precise, but they are very close and as you can see there are 6 sets of 5.

So, I'm not sure what to do here and I apologize greatly if I am making a mistake that I do not see...!

>>>Thanx!

~Sterl~

~Sterl~

### Re: Idea - Spacing dots along a line/path

Howdy gentleman,

Forget to MAKE a center point by yourself! You don't need to do that! Yes - it's right that the Rotate tool is asking for a reference point - and in this case it has to be the center of the arc but you can easily pick this center point with an automatic snap.

The work order would be:

1. Start the rotation tool

2. Choose the snap point CENTER tool,

3. Click with the mouse on the arc - and you will see that the reference point will be placed directly on the center of the arc ...

This is what I'm talking about:

But - honestly - I don't understand why you have to work with distances on the arc. To make it correct you have always to calculate the radius for the arc before you draw it - otherwise it will never suit both criteria - distance and number of holes ...

I would just work with angles ...

Please do me a favor. Attach your dxf file with this two paths example and tell me exactly how many holes do you need on this 180° arc.

I like to show you my solution for this problem, ok?

Sterling wrote:#4) Make Center point at X3 Y1.9375

Forget to MAKE a center point by yourself! You don't need to do that! Yes - it's right that the Rotate tool is asking for a reference point - and in this case it has to be the center of the arc but you can easily pick this center point with an automatic snap.

The work order would be:

1. Start the rotation tool

2. Choose the snap point CENTER tool,

3. Click with the mouse on the arc - and you will see that the reference point will be placed directly on the center of the arc ...

This is what I'm talking about:

But - honestly - I don't understand why you have to work with distances on the arc. To make it correct you have always to calculate the radius for the arc before you draw it - otherwise it will never suit both criteria - distance and number of holes ...

I would just work with angles ...

Please do me a favor. Attach your dxf file with this two paths example and tell me exactly how many holes do you need on this 180° arc.

I like to show you my solution for this problem, ok?

Work smart, not hard: QCad Pro

### Re: Idea - Spacing dots along a line/path

Howdy -

So, to further expand my situation (and try to learn), i have discovered that making these points on an Arc is different than trying to make them along a shape that was drawn by a bunch of short lines.

To clarify - I have drawn an apple (for a school teacher - not the electronics corporation), and I want to intersperse it with points. I used the "Line From Two Points" tool (LI), to draw it, and now I have approximately 60 straight lines that make up the apple.

In reviewing what has been posted earlier, It seems to me that CLIVE'S options might work=

(Heh-heh) I'm sure you gents already knew that it wasn't going to work out~!

As I sift through the 'Help' file, I realize I'm not educated on this. I'm not coming up with something that I could understand. Is there a "Merge" or "Join" function that would bring all the line segments together so I can use Clive's process? Or not? Have I unwittingly created an entirely different situation?

Once again...thanx in advance for your time!

In confusion...

~Sterl~

So, to further expand my situation (and try to learn), i have discovered that making these points on an Arc is different than trying to make them along a shape that was drawn by a bunch of short lines.

To clarify - I have drawn an apple (for a school teacher - not the electronics corporation), and I want to intersperse it with points. I used the "Line From Two Points" tool (LI), to draw it, and now I have approximately 60 straight lines that make up the apple.

In reviewing what has been posted earlier, It seems to me that CLIVE'S options might work=

Clive wrote:This may help.

Try placing your points using the snap to entity option and the snap distance option, if you know the distances between one end of your Arc, Circle, Spline etc. and the points in sequence, you can simply type them into the Snap distance field

*Note if you are placing points around a Circle using this method you will need to divide the Circle (Modify -Divide) into two arcs.

(Heh-heh) I'm sure you gents already knew that it wasn't going to work out~!

As I sift through the 'Help' file, I realize I'm not educated on this. I'm not coming up with something that I could understand. Is there a "Merge" or "Join" function that would bring all the line segments together so I can use Clive's process? Or not? Have I unwittingly created an entirely different situation?

Once again...thanx in advance for your time!

In confusion...

~Sterl~

### Re: Idea - Spacing dots along a line/path

Sterling wrote:As I sift through the 'Help' file, I realize I'm not educated on this. I'm not coming up with something that I could understand. Is there a "Merge" or "Join" function that would bring all the line segments together

You can create a continuous Polyline from seperate line, arc segments, use the-

Draw > Polyline > 'Craete from Segments' command.

Return to “QCAD 'Script Add-On & Plug-in challenge' - Work in Progress”

### Who is online

Users browsing this forum: No registered users and 1 guest