Part-wb extrude with taper angle, bug or feature?

Have some feature requests, feedback, cool stuff to share, or want to know where FreeCAD is going? This is the place.
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
freecad-heini-1
Veteran
Posts: 7790
Joined: Tue Jan 07, 2014 11:10 am
Contact:

Part-wb extrude with taper angle, bug or feature?

Post by freecad-heini-1 »

Hi,

please create a sketch with a circle 2mm diameter on xz-plane.
Extrude it along y axis 2mm with taper angle 4°.

This is my result:
sketch_2mm_dia.png
sketch_2mm_dia.png (14.5 KiB) Viewed 1417 times
part-wb_extrude_y2mm_tapper_angle_4.png
part-wb_extrude_y2mm_tapper_angle_4.png (22.95 KiB) Viewed 1417 times
Is it a bug or a feature?

Best regards
Wilfried

Code: Select all

OS: Ubuntu 16.04.5 LTS
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.18.15650 (Git)
Build type: Release
Branch: master
Hash: c9b4f4ba6779c9ccddb69fba57eee1b5acfd4083
Python version: 2.7.12
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: German/Germany (de_DE)
herbk
Veteran
Posts: 2660
Joined: Mon Nov 03, 2014 3:45 pm
Location: Windsbach, Bavarya (Germany)

Re: Part-wb extrude with taper angle, bug or feature?

Post by herbk »

Hi Wilfried,

it works with other Diameters and angles to. ;)

Seams that nobody had made a cylinder with an taper angle, which is not placed at xy plane till now... :lol:
Gruß Herbert
freecad-heini-1
Veteran
Posts: 7790
Joined: Tue Jan 07, 2014 11:10 am
Contact:

Re: Part-wb extrude with taper angle, bug or feature?

Post by freecad-heini-1 »

herbk wrote: Wed Jan 23, 2019 12:02 pm Hi Wilfried,

it works with other Diameters and angles to. ;)

Seams that nobody had made a cylinder with an taper angle, which is not placed at xy plane till now... :lol:
YZ same problem.
part-wb_extrude_taper-angle.FCStd
(10.99 KiB) Downloaded 88 times
wmayer
Founder
Posts: 20306
Joined: Thu Feb 19, 2009 10:32 am
Contact:

Re: Part-wb extrude with taper angle, bug or feature?

Post by wmayer »

freecad-heini-1 wrote:If you extrude a sketch with a taper angle in xy plane, it works fine.
But if you extrude in xz and yz direction, it's wrong.
It does not even work correctly when the sketch is in xy plane. Just observe the height of the drafted object: it will be 20 instead of 10.

The actual problem seems to be the OCCT class BRepOffsetAPI_MakeOffset which has a very strange behaviour. If the underlying shape to be offset has a placement applied then this class applies it a second time on the output shape.

Example:

Code: Select all

wire1=App.ActiveDocument.Sketch.Shape # the xy sketch
wire1.Placement
# empty placement
wire2=wire1.makeOffset2D(-0.5)
Part.show(wire2)
# wire2 is ok
wire3=wire1.copy()
wire3.Placement.Base.z=10
wire3.Placement
# wire has been moved along z axis
Part.show(wire3)
wire4=wire3.makeOffset2D(-0.5)
Part.show(wire4)
# wire4 again has been moved along z which is not OK
wmayer
Founder
Posts: 20306
Joined: Thu Feb 19, 2009 10:32 am
Contact:

Re: Part-wb extrude with taper angle, bug or feature?

Post by wmayer »

wmayer wrote: Thu Jan 24, 2019 6:23 pm
freecad-heini-1 wrote:If you extrude a sketch with a taper angle in xy plane, it works fine.
But if you extrude in xz and yz direction, it's wrong.
It does not even work correctly when the sketch is in xy plane. Just observe the height of the drafted object: it will be 20 instead of 10.

The actual problem seems to be the OCCT class BRepOffsetAPI_MakeOffset which has a very strange behaviour. If the underlying shape to be offset has a placement applied then this class applies it a second time on the output shape.
It looks like that the problem only occurs if the basis wire consists of a single edge. If you make a sketch with two half-circles then the extrusion works independent from the sketch plane.
chrisb
Veteran
Posts: 54194
Joined: Tue Mar 17, 2015 9:14 am

Re: Part-wb extrude with taper angle, bug or feature?

Post by chrisb »

Now as you mention this: I think we had it before and DeepSOIC has investigated it. There might even be a bugtracker issue.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
freecad-heini-1
Veteran
Posts: 7790
Joined: Tue Jan 07, 2014 11:10 am
Contact:

Re: Part-wb extrude with taper angle, bug or feature?

Post by freecad-heini-1 »

wmayer wrote: Thu Jan 24, 2019 10:05 pm It looks like that the problem only occurs if the basis wire consists of a single edge. If you make a sketch with two half-circles then the extrusion works independent from the sketch plane.
Hi Werner,
thank you so much for your ongoing great work here. Two half circle, that's a hack I can work with.
Best regards
Wilfried
wmayer
Founder
Posts: 20306
Joined: Thu Feb 19, 2009 10:32 am
Contact:

Re: Part-wb extrude with taper angle, bug or feature?

Post by wmayer »

You don't need to. With git commit 4079c9603fe it should work out of the box now.
jmaustpc
Veteran
Posts: 11207
Joined: Tue Jul 26, 2011 6:28 am
Location: Australia

Re: Part-wb extrude with taper angle, bug or feature?

Post by jmaustpc »

wmayer wrote: Fri Jan 25, 2019 9:10 am You don't need to. With git commit 4079c9603fe it should work out of the box now.
Your getting a bit slow Werner....a whole hour and 5 minutes to fix and report a bug! You must need more caffeine, come over to my place mate and I'll make you a coffee. :D
Actually I am feeling generous, I'll take you into town to a nice caffee and buy you one, it's only about a 60km drive. :D
Post Reply