roof behaviour

7 views
Skip to first unread message

Raymond West

unread,
Jun 9, 2025, 10:10:21 AMJun 9
to PythonSCAD
Hi,

I've never understood the requirement for 'roof', it may be a tad more
useful if the angle of slope could be adjusted.

Anyway, in playing around with it, I found the following -

###################################

from openscad import *
s=union(square(20),circle(10).right(10))
p =s.roof()
p. show()     # ridge is horizontal

b=union(square(20),circle(10).left(8))
c =b.roof()
c. show()  # ridge is crippled

s=union(square(20),square(20).rotate([0,0,45]).right(25))
p =s.roof()
p.show() #peaks chopped off

#########################

At first sight I would expect ridges going from peak to peak, being
horizontal. That obviously is not so, so  then I thought that the sides
would be at 45 deg. However, it seems to be some mix of the two. Is
there any succinct description of how it should be?

Best wishes,

Ray

Guenther Sohler

unread,
Jun 9, 2025, 11:34:54 AMJun 9
to Raymond West, PythonSCAD
You can easily Change the Angle by sclaling z. Roof Default Angle should be 45 degree normal to the 2d Edge.
--
You received this message because you are subscribed to the Google Groups "PythonSCAD" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pythonscad+unsubscribe@googlegroups.com.
To view this discussion, visit https://groups.google.com/d/msgid/pythonscad/7f463a1f-88f4-4d94-a4a2-78c8c8725932%40raywest.com.
For more options, visit https://groups.google.com/d/optout.


--
Null
Reply all
Reply to author
Forward
0 new messages