rapier2d::utils

Trait SimdSign

Source
pub trait SimdSign<Rhs>: Sized {
    // Required method
    fn copy_sign_to(self, to: Rhs) -> Rhs;
}
Expand description

Trait to copy the sign of each component of one scalar/vector/matrix to another.

Required Methods§

Source

fn copy_sign_to(self, to: Rhs) -> Rhs

Copy the sign of each component of self to the corresponding component of to.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl SimdSign<f32> for f32

Source§

fn copy_sign_to(self, to: Self) -> Self

Source§

impl<N: Scalar + Copy + SimdSign<N>> SimdSign<Matrix<N, Const<2>, Const<1>, ArrayStorage<N, 2, 1>>> for Vector2<N>

Source§

fn copy_sign_to(self, to: Vector2<N>) -> Vector2<N>

Source§

impl<N: Scalar + Copy + SimdSign<N>> SimdSign<Matrix<N, Const<3>, Const<1>, ArrayStorage<N, 3, 1>>> for Vector3<N>

Source§

fn copy_sign_to(self, to: Vector3<N>) -> Vector3<N>

Implementors§

Source§

impl SimdSign<AutoSimd<[f32; 4]>> for SimdReal

Source§

impl<N: Scalar + Copy + SimdSign<N>> SimdSign<Matrix<N, Const<2>, Const<1>, ArrayStorage<N, 2, 1>>> for N

Source§

impl<N: Scalar + Copy + SimdSign<N>> SimdSign<Matrix<N, Const<3>, Const<1>, ArrayStorage<N, 3, 1>>> for N