Struct cgmath::Rad [] [src]

pub struct Rad<S> {
    pub s: S,
}

An angle, in radians

Fields

s

Methods

impl<S: BaseFloat> Rad<S>

fn zero() -> Rad<S>

fn full_turn() -> Rad<S>

fn turn_div_2() -> Rad<S>

fn turn_div_3() -> Rad<S>

fn turn_div_4() -> Rad<S>

fn turn_div_6() -> Rad<S>

Trait Implementations

impl<S> From<Deg<S>> for Rad<S> where S: BaseFloat

fn from(d: Deg<S>) -> Rad<S>

impl<R: Into<Rad<S>>, S: BaseFloat> Add<R> for Rad<S>

type Output = Rad<S>

fn add(self, other: R) -> Rad<S>

impl<R: Into<Rad<S>>, S: BaseFloat> Sub<R> for Rad<S>

type Output = Rad<S>

fn sub(self, other: R) -> Rad<S>

impl<S: BaseFloat> Neg for Rad<S>

type Output = Rad<S>

fn neg(self) -> Rad<S>

impl<S: BaseFloat> Zero for Rad<S>

fn zero() -> Rad<S>

fn is_zero(&self) -> bool

impl<R: Into<Rad<S>>, S: BaseFloat> Mul<R> for Rad<S>

type Output = Rad<S>

fn mul(self, other: R) -> Rad<S>

impl<S: BaseFloat> One for Rad<S>

fn one() -> Rad<S>

impl<S: BaseFloat> Angle<S> for Rad<S>

fn from<A: Angle<S>>(theta: A) -> Rad<S>

fn full_turn() -> Rad<S>

fn neg_self(&mut self)

fn add_a(&self, other: Self) -> Self

fn sub_a(&self, other: Self) -> Self

fn div_a(&self, other: Self) -> S

fn rem_a(&self, other: Self) -> S

fn mul_s(&self, s: S) -> Self

fn div_s(&self, s: S) -> Self

fn rem_s(&self, s: S) -> Self

fn add_self_a(&mut self, other: Self)

fn sub_self_a(&mut self, other: Self)

fn mul_self_s(&mut self, s: S)

fn div_self_s(&mut self, s: S)

fn rem_self_s(&mut self, s: S)

fn normalize(&self) -> Self

fn normalize_self(&mut self)

fn opposite(&self) -> Self

fn bisect(&self, other: Self) -> Self

fn turn_div_2() -> Self

fn turn_div_3() -> Self

fn turn_div_4() -> Self

fn turn_div_6() -> Self

fn equiv(&self, other: &Self) -> bool

impl<S: BaseFloat + Debug> Debug for Rad<S>

fn fmt(&self, f: &mut Formatter) -> Result

impl<S: BaseFloat> ApproxEq<S> for Rad<S>

fn approx_eq_eps(&self, other: &Rad<S>, epsilon: &S) -> bool

fn approx_epsilon(_hack: Option<Self>) -> T

fn approx_eq(&self, other: &Self) -> bool

impl<S: BaseFloat + PartialOrd + SampleRange + Rand> Rand for Rad<S>

fn rand<R: Rng>(rng: &mut R) -> Rad<S>

Derived Implementations

impl<S: Decodable> Decodable for Rad<S>

fn decode<__D: Decoder>(__arg_0: &mut __D) -> Result<Rad<S>, __D::Error>

impl<S: Encodable> Encodable for Rad<S>

fn encode<__S: Encoder>(&self, __arg_0: &mut __S) -> Result<(), __S::Error>

impl<S: Hash> Hash for Rad<S>

fn hash<__H: Hasher>(&self, __arg_0: &mut __H)

fn hash_slice<H>(data: &[Self], state: &mut H) where H: Hasher

impl<S: PartialOrd> PartialOrd for Rad<S>

fn partial_cmp(&self, __arg_0: &Rad<S>) -> Option<Ordering>

fn lt(&self, __arg_0: &Rad<S>) -> bool

fn le(&self, __arg_0: &Rad<S>) -> bool

fn gt(&self, __arg_0: &Rad<S>) -> bool

fn ge(&self, __arg_0: &Rad<S>) -> bool

impl<S: PartialEq> PartialEq for Rad<S>

fn eq(&self, __arg_0: &Rad<S>) -> bool

fn ne(&self, __arg_0: &Rad<S>) -> bool

impl<S: Clone> Clone for Rad<S>

fn clone(&self) -> Rad<S>

fn clone_from(&mut self, source: &Self)

impl<S: Copy> Copy for Rad<S>