[][src]Trait nannou::draw::properties::spatial::orientation::SetOrientation

pub trait SetOrientation<S>: Sized {
    fn properties(&mut self) -> &mut Properties<S>;

    fn look_at(self, target: LookAt<S>) -> Self { ... }
fn look_at_node(self, node: Index) -> Self { ... }
fn look_at_point(self, point: Point3<S>) -> Self { ... }
fn x_orientation(self, orientation: Orientation<S>) -> Self { ... }
fn y_orientation(self, orientation: Orientation<S>) -> Self { ... }
fn z_orientation(self, orientation: Orientation<S>) -> Self { ... }
fn x_radians(self, x: S) -> Self { ... }
fn y_radians(self, y: S) -> Self { ... }
fn z_radians(self, z: S) -> Self { ... }
fn x_degrees(self, x: S) -> Self
    where
        S: BaseFloat
, { ... }
fn y_degrees(self, y: S) -> Self
    where
        S: BaseFloat
, { ... }
fn z_degrees(self, z: S) -> Self
    where
        S: BaseFloat
, { ... }
fn x_turns(self, x: S) -> Self
    where
        S: BaseFloat
, { ... }
fn y_turns(self, y: S) -> Self
    where
        S: BaseFloat
, { ... }
fn z_turns(self, z: S) -> Self
    where
        S: BaseFloat
, { ... }
fn radians(self, v: Vector3<S>) -> Self { ... }
fn degrees(self, v: Vector3<S>) -> Self
    where
        S: BaseFloat
, { ... }
fn turns(self, v: Vector3<S>) -> Self
    where
        S: BaseFloat
, { ... }
fn euler<A>(self, e: Euler<A>) -> Self
    where
        S: BaseFloat,
        A: Angle + Into<Rad<S>>
, { ... }
fn quaternion(self, q: Quaternion<S>) -> Self
    where
        S: BaseFloat
, { ... }
fn x_radians_relative(self, x: S) -> Self { ... }
fn y_radians_relative(self, y: S) -> Self { ... }
fn z_radians_relative(self, z: S) -> Self { ... }
fn x_radians_relative_to(self, other: Index, x: S) -> Self { ... }
fn y_radians_relative_to(self, other: Index, y: S) -> Self { ... }
fn z_radians_relative_to(self, other: Index, z: S) -> Self { ... }
fn x_degrees_relative(self, x: S) -> Self
    where
        S: BaseFloat
, { ... }
fn y_degrees_relative(self, y: S) -> Self
    where
        S: BaseFloat
, { ... }
fn z_degrees_relative(self, z: S) -> Self
    where
        S: BaseFloat
, { ... }
fn x_degrees_relative_to(self, other: Index, x: S) -> Self
    where
        S: BaseFloat
, { ... }
fn y_degrees_relative_to(self, other: Index, y: S) -> Self
    where
        S: BaseFloat
, { ... }
fn z_degrees_relative_to(self, other: Index, z: S) -> Self
    where
        S: BaseFloat
, { ... }
fn x_turns_relative(self, x: S) -> Self
    where
        S: BaseFloat
, { ... }
fn y_turns_relative(self, y: S) -> Self
    where
        S: BaseFloat
, { ... }
fn z_turns_relative(self, z: S) -> Self
    where
        S: BaseFloat
, { ... }
fn x_turns_relative_to(self, other: Index, x: S) -> Self
    where
        S: BaseFloat
, { ... }
fn y_turns_relative_to(self, other: Index, y: S) -> Self
    where
        S: BaseFloat
, { ... }
fn z_turns_relative_to(self, other: Index, z: S) -> Self
    where
        S: BaseFloat
, { ... }
fn radians_relative(self, v: Vector3<S>) -> Self { ... }
fn radians_relative_to(self, other: Index, v: Vector3<S>) -> Self { ... }
fn degrees_relative(self, v: Vector3<S>) -> Self
    where
        S: BaseFloat
, { ... }
fn degrees_relative_to(self, other: Index, v: Vector3<S>) -> Self
    where
        S: BaseFloat
, { ... }
fn turns_relative(self, v: Vector3<S>) -> Self
    where
        S: BaseFloat
, { ... }
fn turns_relative_to(self, other: Index, v: Vector3<S>) -> Self
    where
        S: BaseFloat
, { ... }
fn euler_relative<A>(self, e: Euler<A>) -> Self
    where
        S: BaseFloat,
        A: Angle + Into<Rad<S>>
, { ... }
fn euler_relative_to<A>(self, other: Index, e: Euler<A>) -> Self
    where
        S: BaseFloat,
        A: Angle + Into<Rad<S>>
, { ... }
fn pitch(self, pitch: S) -> Self { ... }
fn yaw(self, yaw: S) -> Self { ... }
fn roll(self, roll: S) -> Self { ... }
fn rotate(self, radians: S) -> Self { ... } }

An API for setting the orientation::Properties.

Required methods

fn properties(&mut self) -> &mut Properties<S>

Provide a mutable reference to the orientation::Properties for updating.

Loading content...

Provided methods

fn look_at(self, target: LookAt<S>) -> Self

Describe orientation via the vector that points to the given target.

fn look_at_node(self, node: Index) -> Self

Describe orientation via the vector that points to the given node.

fn look_at_point(self, point: Point3<S>) -> Self

Describe orientation via the vector that points to the given point.

fn x_orientation(self, orientation: Orientation<S>) -> Self

Build with the given Orientation along the x axis.

fn y_orientation(self, orientation: Orientation<S>) -> Self

Build with the given Orientation along the x axis.

fn z_orientation(self, orientation: Orientation<S>) -> Self

Build with the given Orientation along the x axis.

fn x_radians(self, x: S) -> Self

Specify the orientation around the x axis as an absolute value in radians.

fn y_radians(self, y: S) -> Self

Specify the orientation around the y axis as an absolute value in radians.

fn z_radians(self, z: S) -> Self

Specify the orientation around the z axis as an absolute value in radians.

fn x_degrees(self, x: S) -> Self where
    S: BaseFloat

Specify the orientation around the x axis as an absolute value in radians.

fn y_degrees(self, y: S) -> Self where
    S: BaseFloat

Specify the orientation around the y axis as an absolute value in radians.

fn z_degrees(self, z: S) -> Self where
    S: BaseFloat

Specify the orientation around the z axis as an absolute value in radians.

fn x_turns(self, x: S) -> Self where
    S: BaseFloat

Specify the orientation around the x axis as a number of turns around the axis.

fn y_turns(self, y: S) -> Self where
    S: BaseFloat

Specify the orientation around the y axis as a number of turns around the axis.

fn z_turns(self, z: S) -> Self where
    S: BaseFloat

Specify the orientation around the z axis as a number of turns around the axis.

fn radians(self, v: Vector3<S>) -> Self

Specify the orientation along each axis with the given Vector of radians.

This has the same affect as calling self.x_radians(v.x).y_radians(v.y).z_radians(v.z).

fn degrees(self, v: Vector3<S>) -> Self where
    S: BaseFloat

Specify the orientation along each axis with the given Vector of degrees.

This has the same affect as calling self.x_degrees(v.x).y_degrees(v.y).z_degrees(v.z).

fn turns(self, v: Vector3<S>) -> Self where
    S: BaseFloat

Specify the orientation along each axis with the given Vector of "turns".

This has the same affect as calling self.x_turns(v.x).y_turns(v.y).z_turns(v.z).

fn euler<A>(self, e: Euler<A>) -> Self where
    S: BaseFloat,
    A: Angle + Into<Rad<S>>, 

Specify the orientation with the given Euler.

The euler can be specified in either radians (via Rad) or degrees (via Deg).

fn quaternion(self, q: Quaternion<S>) -> Self where
    S: BaseFloat

Specify the orientation with the given Quaternion.

fn x_radians_relative(self, x: S) -> Self

Specify the orientation around the x axis as a relative value in radians.

fn y_radians_relative(self, y: S) -> Self

Specify the orientation around the y axis as a relative value in radians.

fn z_radians_relative(self, z: S) -> Self

Specify the orientation around the z axis as a relative value in radians.

fn x_radians_relative_to(self, other: Index, x: S) -> Self

Specify the orientation around the x axis as a relative value in radians.

fn y_radians_relative_to(self, other: Index, y: S) -> Self

Specify the orientation around the y axis as a relative value in radians.

fn z_radians_relative_to(self, other: Index, z: S) -> Self

Specify the orientation around the z axis as a relative value in radians.

fn x_degrees_relative(self, x: S) -> Self where
    S: BaseFloat

Specify the orientation around the x axis as a relative value in degrees.

fn y_degrees_relative(self, y: S) -> Self where
    S: BaseFloat

Specify the orientation around the y axis as a relative value in degrees.

fn z_degrees_relative(self, z: S) -> Self where
    S: BaseFloat

Specify the orientation around the z axis as a relative value in degrees.

fn x_degrees_relative_to(self, other: Index, x: S) -> Self where
    S: BaseFloat

Specify the orientation around the x axis as a relative value in degrees.

fn y_degrees_relative_to(self, other: Index, y: S) -> Self where
    S: BaseFloat

Specify the orientation around the y axis as a relative value in degrees.

fn z_degrees_relative_to(self, other: Index, z: S) -> Self where
    S: BaseFloat

Specify the orientation around the z axis as a relative value in degrees.

fn x_turns_relative(self, x: S) -> Self where
    S: BaseFloat

Specify the relative orientation around the x axis as a number of turns around the axis.

fn y_turns_relative(self, y: S) -> Self where
    S: BaseFloat

Specify the relative orientation around the y axis as a number of turns around the axis.

fn z_turns_relative(self, z: S) -> Self where
    S: BaseFloat

Specify the relative orientation around the z axis as a number of turns around the axis.

fn x_turns_relative_to(self, other: Index, x: S) -> Self where
    S: BaseFloat

Specify the relative orientation around the x axis as a number of turns around the axis.

fn y_turns_relative_to(self, other: Index, y: S) -> Self where
    S: BaseFloat

Specify the relative orientation around the y axis as a number of turns around the axis.

fn z_turns_relative_to(self, other: Index, z: S) -> Self where
    S: BaseFloat

Specify the relative orientation around the z axis as a number of turns around the axis.

fn radians_relative(self, v: Vector3<S>) -> Self

Specify a relative orientation along each axis with the given Vector of radians.

This has the same affect as the following:

This example is not tested
self.x_radians_relative(v.x)
    .y_radians_relative(v.y)
    .z_radians_relative(v.z)

fn radians_relative_to(self, other: Index, v: Vector3<S>) -> Self

Specify a relative orientation along each axis with the given Vector of radians.

This has the same affect as the following:

This example is not tested
self.x_radians_relative_to(other, v.x)
    .y_radians_relative_to(other, v.y)
    .z_radians_relative_to(other, v.z)

fn degrees_relative(self, v: Vector3<S>) -> Self where
    S: BaseFloat

Specify a relative orientation along each axis with the given Vector of degrees.

This has the same affect as the following:

This example is not tested
self.x_degrees_relative(v.x)
    .y_degrees_relative(v.y)
    .z_degrees_relative(v.z)

fn degrees_relative_to(self, other: Index, v: Vector3<S>) -> Self where
    S: BaseFloat

Specify a relative orientation along each axis with the given Vector of degrees.

This has the same affect as the following:

This example is not tested
self.x_degrees_relative_to(other, v.x)
    .y_degrees_relative_to(other, v.y)
    .z_degrees_relative_to(other, v.z)

fn turns_relative(self, v: Vector3<S>) -> Self where
    S: BaseFloat

Specify a relative orientation along each axis with the given Vector of "turns".

This has the same affect as the following:

This example is not tested
self.x_turns_relative(v.x)
    .y_turns_relative(v.y)
    .z_turns_relative(v.z)

fn turns_relative_to(self, other: Index, v: Vector3<S>) -> Self where
    S: BaseFloat

Specify a relative orientation along each axis with the given Vector of "turns".

This has the same affect as the following:

This example is not tested
self.x_turns_relative_to(other, v.x)
    .y_turns_relative_to(other, v.y)
    .z_turns_relative_to(other, v.z)

fn euler_relative<A>(self, e: Euler<A>) -> Self where
    S: BaseFloat,
    A: Angle + Into<Rad<S>>, 

Specify a relative orientation with the given Euler.

The euler can be specified in either radians (via Rad) or degrees (via Deg).

fn euler_relative_to<A>(self, other: Index, e: Euler<A>) -> Self where
    S: BaseFloat,
    A: Angle + Into<Rad<S>>, 

Specify a relative orientation with the given Euler.

The euler can be specified in either radians (via Rad) or degrees (via Deg).

fn pitch(self, pitch: S) -> Self

Specify the "pitch" of the orientation in radians.

This has the same effect as calling x_radians.

fn yaw(self, yaw: S) -> Self

Specify the "yaw" of the orientation in radians.

This has the same effect as calling y_radians.

fn roll(self, roll: S) -> Self

Specify the "roll" of the orientation in radians.

This has the same effect as calling z_radians.

fn rotate(self, radians: S) -> Self

Assuming we're looking at a 2D plane, positive values cause a clockwise rotation where the given value is specified in radians.

This is equivalent to calling the z_radians or roll methods.

Loading content...

Implementors

impl<S> SetOrientation<S> for nannou::draw::properties::spatial::orientation::Properties<S>[src]

impl<S> SetOrientation<S> for Ellipse<S>[src]

impl<S> SetOrientation<S> for Line<S>[src]

impl<S> SetOrientation<S> for Mesh<S>[src]

impl<S> SetOrientation<S> for Path<S>[src]

impl<S> SetOrientation<S> for Polygon<S>[src]

impl<S> SetOrientation<S> for PolygonInit<S>[src]

impl<S> SetOrientation<S> for Quad<S>[src]

impl<S> SetOrientation<S> for Rect<S>[src]

impl<S> SetOrientation<S> for Text<S>[src]

impl<S> SetOrientation<S> for Tri<S>[src]

impl<S> SetOrientation<S> for nannou::draw::properties::spatial::Properties<S>[src]

impl<T, S> SetOrientation<S> for PathOptions<T, S>[src]

Loading content...