Graphscad
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Graphscad

Graphscad : The Graphic Nodal Editor for OpenScad
 
HomeLatest imagesSearchRegisterLog in

 

 box disappears if rounding=0

Go down 
AuthorMessage
ChrisLT




Messages : 45
Date d'inscription : 2017-01-30
Localisation : Newbury, Berkshire, England

box disappears if rounding=0 Empty
PostSubject: box disappears if rounding=0   box disappears if rounding=0 Icon_minitimeWed 8 Feb - 15:48

A node_box with rounding=0.0001 or greater is drawn, but with rounding=0 it disappears. This is because it is drawn as the convex hull of four cylinders, each with radius=rounding, one at each corner of the box. If the cylinders have radius 0, they cease to exist. You could fix this by changing node_box.py from:
c=c+'translate([-'+xo+',-'+yo+',0]) cylinder(r='+rounding+',h='+zo+',$fn='+fn+');'
to
c=c+'translate([-'+xo+',-'+yo+',0]) cylinder(r=max(0.0001,'+rounding+'),h='+zo+',$fn='+fn+');'

and similarly for the other 7 cylinders.

This is in GraphSCAD 1.0.3 on Ubuntu 16.04
Back to top Go down
 
box disappears if rounding=0
Back to top 
Page 1 of 1

Permissions in this forum:You cannot reply to topics in this forum
Graphscad :: Issues-
Jump to: