implicit-0.2.0: Math-inspired programmatic 2&3D CAD: CSG, bevels, and shells; gcode export..

Safe HaskellSafe
LanguageHaskell98

Graphics.Implicit.MathUtil

Synopsis

Documentation

rmax Source #

Arguments

::

radius

->

first number to round maximum

->

second number to round maximum

->

resulting number

Rounded Maximum Consider max(x,y) = 0, the generated curve has a square-like corner. We replace it with a quarter of a circle

rmaximum Source #

Arguments

::

radius

-> []

numbers to take round maximum

->

resulting number

Like rmax, but on a list instead of two. Just as maximum is. The implementation is to take the maximum two and rmax those.

rminimum Source #

Arguments

::

radius

-> []

numbers to take round minimum

->

resulting number

Like rmin but on a list.

distFromLineSeg :: ℝ2 -> (ℝ2, ℝ2) -> Source #

The distance a point p is from a line segment (a,b)

pack Source #

Arguments

:: Box2

The box to pack within

->

The space seperation between items

-> [(Box2, a)]

Objects with their boxes

-> ([(ℝ2, a)], [(Box2, a)])

Packed objects with their positions, objects that could be packed

Pack the given objects in a box the given size.