Module nannou::geom[][src]

Expand description

Types, functions and other items related to geometry. This module is the source of all graphics and lazer primitives and aids work in 2D and 3D space.

Each module provides a set of general tools for working with the named geometry including:

  • A typed, object representation.
  • Functions for producing vertices, triangles and triangulation indices.
  • Functions for checking whether or not the geometry contains a point.
  • Functions for determining the bounding rectangle or cuboid.
  • A function for finding the centroid.

Re-exports

pub use self::path::path;
pub use self::path::Path;

Modules

Items related to cube geometry.

Items related to working with paths for 2D geometry and vector graphics.

Implementation of the Point types.

A type for working with one-dimensional ranges.

Structs

A light-weight Cuboid type with many helper and utility methods.

A 2-dimensional vector.

A 3-dimensional vector.

A 4-dimensional vector.

A simple ellipse type with helper methods around the ellipse module’s functions.

A 2-dimensional vector.

A 3-dimensional vector.

A 4-dimensional vector.

The distance between the inner edge of a border and the outer edge of the inner content.

A simple type wrapper around a list of points that describe a polygon.

A quad represented by its four vertices.

Some start and end position along a single axis.

Defines a Rectangle’s bounds across the x and y axes.

A triangle as three vertices.

A 2-dimensional vector.

A 3-dimensional vector without SIMD support.

A 4-dimensional vector.

Enums

Describes alignment along a range.

Either of the four corners of a Rect.

Represents either the Start or End Edge of a Range.

Traits

Implemented for all numeric scalar types used within geom.

Types used as vertices that can be used to describe geometric points in space.

Vertex types that have at least 2 dimensions.

Vertex types that have at least 3 dimensions.

Functions

The Cuboid that bounds the given sequence of vertices.

The Rect that bounds the given sequence of vertices.

The centroid (average position) of all vertices in the given iterator.

Creates a 2-dimensional vector.

Creates a 3-dimensional vector.

Creates a 4-dimensional vector.

Creates a 2-dimensional vector.

Creates a 3-dimensional vector.

Creates a 4-dimensional vector.

Construct a 2-dimensional point.

Construct a 3-dimensional point.

Construct a 4-dimensional point.

Creates a 2-dimensional vector.

Creates a 3-dimensional vector.

Creates a 4-dimensional vector.

Type Definitions

A 2-dimensional point type.

A 3-dimensional point type.

A 4-dimensional point type.

Vector2Deprecated

A common alias for the glam::Vec2 type.

Vector3Deprecated

A common alias for the glam::Vec3 type.

Vector4Deprecated

A common alias for the glam::Vec4 type.