waterfall-cad-0.0.0.1: Declarative CAD/Solid Modeling Library
Safe HaskellSafe-Inferred
LanguageHaskell2010

Waterfall.Solids

Synopsis

Documentation

data Solid Source #

The Boundary Representation of a solid object.

Alternatively, a region of 3d Space.

Under the hood, this is represented by an OpenCascade Shape. The underlying shape should either be a Solid, or a CompSolid.

While you shouldn't need to know what this means to use the library, please feel free to report a bug if you're able to construct a Solid where this isnt' the case (without using internal functions).

Instances

Instances details
Monoid Solid Source # 
Instance details

Defined in Waterfall.Internal.Solid

Methods

mempty :: Solid #

mappend :: Solid -> Solid -> Solid #

mconcat :: [Solid] -> Solid #

Semigroup Solid Source #

While Solid could form a Semigroup via either union or intersection. the default Semigroup is from union.

The Semigroup from intersection can be obtained using Meet from the lattices package.

Instance details

Defined in Waterfall.Internal.Solid

Methods

(<>) :: Solid -> Solid -> Solid #

sconcat :: NonEmpty Solid -> Solid #

stimes :: Integral b => b -> Solid -> Solid #

BoundedJoinSemiLattice Solid Source # 
Instance details

Defined in Waterfall.Internal.Solid

Methods

bottom :: Solid #

Lattice Solid Source # 
Instance details

Defined in Waterfall.Internal.Solid

Methods

(\/) :: Solid -> Solid -> Solid #

(/\) :: Solid -> Solid -> Solid #

Transformable Solid Source # 
Instance details

Defined in Waterfall.Transforms

nowhere :: Solid Source #

An empty solid

Be warned that complement nowhere does not appear to work correctly.

unitCube :: Solid Source #

A cube with side lengths of 1, one vertex on the origin, another on \( (1, 1, 1) \)

centeredCube :: Solid Source #

A cube with side lengths of 1, centered on the origin

box :: V3 Double -> Solid Source #

A cuboid, one vertex on the origin, another on a given point

unitSphere :: Solid Source #

A sphere with radius of 1, centered on the origin

unitCylinder :: Solid Source #

A cylinder with radius 1, length 1, one of it's circular faces centered on the origin, the other centered on \( (0, 0, 1) \)

prism :: Double -> Shape -> Solid Source #

Extruded a 2D face into a prism with a given length \(len\).

One of the prisms faces lies on the plane \(z = 0\), the other on the plane \(z = len\).