Struct mgf::Segment[][src]

pub struct Segment {
    pub a: Point3<f32>,
    pub b: Point3<f32>,
}

A point and a direction with a finite distance.

Fields

The starting point of the segment.

The end point of the segment.

Methods

impl Segment
[src]

Create a new segment

Trait Implementations

impl Copy for Segment
[src]

impl Clone for Segment
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Debug for Segment
[src]

Formats the value using the given formatter. Read more

impl From<(Point3<f32>, Point3<f32>)> for Segment
[src]

Performs the conversion.

impl From<Segment> for Ray
[src]

Performs the conversion.

impl From<Capsule> for Segment
[src]

Performs the conversion.

impl Add<Vector3<f32>> for Segment
[src]

The resulting type after applying the + operator.

Performs the + operation.

impl Sub<Vector3<f32>> for Segment
[src]

The resulting type after applying the - operator.

Performs the - operation.

impl AddAssign<Vector3<f32>> for Segment
[src]

Performs the += operation.

impl SubAssign<Vector3<f32>> for Segment
[src]

Performs the -= operation.

impl Shape for Segment
[src]

Returns the center of mass of the geometry, assuming a regular density.

Returns the closest point on the shape to the given point.

Sets the center of the shape to p.

impl Particle for Segment
[src]

A segment represents a point particle traveling in a direction with finite velocity.

DT: f32 = 1.0

The length of the time step.

The origin of the particle.

The direction of the particle.

Rotate this particle around the world space of an object.

Auto Trait Implementations

impl Send for Segment

impl Sync for Segment