Sweep1 precision/problem

Hi,
question is very simple but for some reason my sweep doesn’t not follow curve (polyline) exactly.
See enclosed. Sweep_Example.gh (4.9 KB)
Any hint how to fix?

image

Thanks,
Dmitriy

Hi
You are confusing a coarse, poor fitting render mesh with the actual surface edges represented by the curves.
Have a look at this:
https://www.hydraulicdesign.net/meshes.htm

Hi @John_Brock,

my question is not about meshing, it is about actual edges. See below:

Moved to Grasshopper category.

Hi @John_Brock, I see you moved to GH category, this is not however GH problem.
If you do natural Sweep from Rhino - you will get same.

Hello - in the file you posted, the mesh is what is way off - the baked sweep is not within the requested tolerance of the rail curve either, but the display mesh is what is miles off. You can set the mesh quality for the display . To get the sweep closer using Rhino commands, you need to reduce the angle tolerance in the file - there are some very slight angles in the rail curve and these are ignored because smaller than the file angle tolerance. I do not know if there is an equivalent tolerance for the GH sweeper.

-Pascal

@pascal, thanks for this. Maybe the first picture was confusing but there is no question about mesh :slight_smile:

For sweep I am using RC method Brep.CreateFromSweep. This method doesn’t have any angle tolerance. To change angle settings it in the global settings is not convenient.

Thanks,
Dmitriy

Hi Dmitry - for now, you can set this on the fly in your code if you are scripting -

https://developer.rhino3d.com/api/RhinoCommon/html/P_Rhino_RhinoDoc_ModelAngleToleranceDegrees.htm

-Pascal

Thanks, @pascal.
I am using Sweep from RhinoCommon. As it seems - setting of AngleTolerance to lower value doesn’t influence result of the sweep.
Checked also in Rhino directly: lowering angle tolerance from 1.0 deg to 0.1 deg solves one part:

image

but giving problem for other part:

Hi Dimtry - something of a shot in the dark but see if using CreateFromSweepSegmented() does anything different here.

-Pascal

No difference

Yeah, I do not see how to get there in RhinoCommon - I’ll ask.

-Pascal

1 Like

Thanks, appreciated.

Moved to Developer category.

Hi @pascal,

Any news? Will it be possible to update method in RC to include angle tolerance as well?

Thanks,
Dmitriy

Hi @Dmitriy,

I am hoping to have time to look at this today. Thanks for your patience.

– Dale

Hi @Dmitriy,

I’m assuming the Sweep1 command is giving you the results you want. Can you take a screen capture of the Sweep1 dialog box so I can see what options you’ve chosen?

Thanks,

– Dale

Hi @dale

Yes, after modifying angle tolerance and applying Untrimmed miters, result shows as it should, see below:

Hi @Dmitriy,

Brep.CreateFromSweepSegmented is definitely what you want to use. However, the function overloads, provided by RhinoCommon, don’t allow you to specify trimmed vs untrimmed miters. Providing a more ful-featured overload is on the to-do list for Rhino 7.

https://mcneel.myjetbrains.com/youtrack/issue/RH-56247

– Dale

1 Like

Thanks, @dale