You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
I'm trying to write a 'sector' (circle cut out function).
For testing I wanted to stick a slider on it to choose the angle.
The function needs a couple of comparisons on the angle.
This fails with ERROR: ((*0.017453292519943295)<=3.141592653589793) is not a boolean
Leaving out the parametric slider, it works as expected
Curv Program
parametric
set_angle:: int_slider[0,360] = 35;
in
let
angle = set_angle * deg;
r = 3;
color x = colour x
in
intersection [
circle r,
union [
polygon[
[0,0],
[0,if (angle <= 180 * deg) r*2 else r*-2],
[r * sin angle,r * cos angle]
] >> colour red,
if (angle >= 90*deg) (square r >> translate[r/2,r/2] >> color blue),
if (angle >= 180*deg) (square r >> translate[r/2,-r/2] >> color blue),
if (angle >= 270*deg) (square r >> translate[-r/2,-r/2] >> color blue),
],
] >> show_axes
It might just be me misunderstanding something about the language,
though.
Thanks!
Describe the bug
I'm trying to write a 'sector' (circle cut out function).
For testing I wanted to stick a slider on it to choose the angle.
The function needs a couple of comparisons on the angle.
This fails with ERROR: ((*0.017453292519943295)<=3.141592653589793) is not a boolean
Leaving out the parametric slider, it works as expected
Curv Program
It might just be me misunderstanding something about the language,
though.
Thanks!