Trait mgf::Polygon [] [src]

pub trait Polygon: Shape {
    type FaceType: Collider<Contains, Point3<f32>> + Into<Plane> + Clone;
    fn num_vertices(&self) -> usize;
fn vertex(&self, _: usize) -> Point3<f32>;
fn num_edges(&self) -> usize;
fn edge(&self, _: usize) -> (usize, usize);
fn face(&self) -> &Self::FaceType; }

Polygons are objects composed of edges and vertices that can accurately describe whether or not they contain a point.

Associated Types

Type of the face object the polygon returns.

Required Methods

The number of edges available to query.

Returns the ith vertex as a Point.

The number of edges available to query.

Returns the ith edge of the polygon as a pair of indices.

Implementors