Function glm::builtin::mod_s [] [src]

pub fn mod_s<F: BaseFloat, T: GenFloatVec<F>>(x: T, y: F) -> T

Modulus with a scalar number.

Note

mod_s is not a GLSL function name. It is a variant of original mod function and is introduced because Rust does not support function name overloading.

Example

use glm::{ mod_s, dvec3 };

let v = dvec3(-1.5, 1.5, 10.5);
assert_eq!(mod_s(v, 2.), dvec3(-1.5, 1.5, 0.5));