DesignCAD 3D Max 2027 box
Now available

DesignCAD 2027

Hatches that follow their boundaries, an on-screen dial to turn your model, and a way to find any command by name, in a clean Windows 11 look.

How to set number of facets on circle when converting

Started by MarkX, February 05, 2013, 11:04:04 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

MarkX

If you convert a circle with makeplane or the lines conversion tool, is there a way to set how many facets will be produced?

Thanks!
Mark

prl


MarkX

Quote from: prl on February 05, 2013, 11:14:10 AM
Mark,

I use the segit.d3m code for such things.  DesignCAD always adds way too many points.


http://forum.designcad.com/index.php?topic=4606.msg28241#msg28241
Thanks PRL,

So there's no official way to accomplish this?

I've put your code into my macro directory. I've also added attribution in my copy. That way I'll know who to ask if it doesn't work in the next vsn of DC ;-)

Thanks again --
Mark

JJG

Quote from: MarkX on February 05, 2013, 11:55:48 AM
So there's no official way to accomplish this?

Yes there is a way, but only "after fact" :
as you have done, convert a circle to a plan or vectors gives 120 "facets", but you can reduce this number with Edit / Selection Edit / Smooth Line by Point Reduction.

prl

Quote from: MarkX on February 05, 2013, 11:55:48 AM
So there's no official way to accomplish this?

Well, when you are first creating a circle or arc, you can "vectorize" it and define the number of segments (less than 120).  But if you are going from a pure cirlce or arc, then you will need to segment it either using some of the DesignCAD tools (point reduction, etc.) or something like segit.d3m. 

I'm highly tuned to the number of facets a solid will have and hence I control the number of segments representing corners or curves, etc.  Only Phil has a super DC computer at this point.  :)

Dr PR

If you are working with a multisegmented line with many segments you can use "Edit/Selection Edit/Smooth Line by Point Reduction" to convert it into a curve with a smaller number of points. The function asks you for the number of points and then ignores what you entered (bug). For example, if you ask for 10 points it will probably give you 12 or 13, or if you ask for 8 it may give 16. Weird!

The program should generate exactly the number of points the user specifies.

Phil

prl - Like you, I am very sensitive to the number of facets in solids. There is no computer fast enough to work with DesignCAD's default settings.
DesignCAD user since 1987

Lar

Here's the official way:

Type the following in the command line, replace the ?? with a number and press enter (or create a macro with it and run the macro, of course). Thereafter that number will be the default for all circles, arcs, ellipse, when saving as a line, until you manually change the default:

sys(269)=??

Only holds for the current session. I would say put it in a startup macro (File menu> Workspace configuration...) but far as I can tell the startup macro does not get executed.

Lar
ps:
Quote from: Dr PR on February 05, 2013, 12:37:54 PM
The function asks you for the number of points and then ignores what you entered (bug). For example, if you ask for 10 points it will probably give you 12 or 13, or if you ask for 8 it may give 16. Weird!

The program should generate exactly the number of points the user specifies.
Phil, I guess the dialog is worded badly. The 'number of points' is more like a factor, not the actual number of points the line would end up with. I can't explain the factor myself but another member, I can't remember who, did explain it here on the forum, sometime in the not too distant past.

Dempsey

Dempsey

Dr PR

Dempsey,

Thanks. I had forgotten that.

I still think it is screwed up.

Phil
DesignCAD user since 1987

prl

Quote from: Lar on February 05, 2013, 01:05:23 PM
Here's the official way:
sys(269)=??

Kind of iffy that sys function. It's the stored segmenting factor for creating vectorized lines and arcs.  Doesn't help you if you are going from an existing true circle to a plane using "makeplane" or the famous "convert to vector" command. 

Lar

You are right Prl. I neglected to mention that in my previous post (although I did use the word "thereafter...".

If I need an exact number of segments for an existing circle I simply draw a new circle on top of the existing, specifying 'save as line' and the number of segments desired. I keep the true circle because 99% of the time I need something to intersect it and the segmented circle would not intersect correctly everywhere along itself, only at the points.

What we do need is a way to fillet with the arc being incorporated in the line, and being able to specify the number of segments of the fillet. You can sort of achieve this now with Planes, but a plane has to be closed.

Lar

prl

Quote from: Lar on February 05, 2013, 02:26:58 PM
What we do need is a way to fillet with the arc being incorporated in the line, and being able to specify the number of segments of the fillet. You can sort of achieve this now with Planes, but a plane has to be closed.

Yes, that sequence is what motivated me to do the segit.d3m approach.  I create construction lines, fillet them as desired, then create user segmented corners from the filleted arcs, then select all my vectorized lines, corners, arcs, etc. to form a closed shape, then combine, then "makeplane", then extrude.   Phew!!