pub struct Transform {
pub m: Matrix4x4,
pub m_inv: Matrix4x4,
}
Fields§
§m: Matrix4x4
§m_inv: Matrix4x4
Implementations§
source§impl Transform
impl Transform
pub fn new( t00: Float, t01: Float, t02: Float, t03: Float, t10: Float, t11: Float, t12: Float, t13: Float, t20: Float, t21: Float, t22: Float, t23: Float, t30: Float, t31: Float, t32: Float, t33: Float ) -> Self
pub fn inverse(t: &Transform) -> Transform
pub fn is_identity(&self) -> bool
pub fn swaps_handedness(&self) -> bool
pub fn translate(delta: &Vector3f) -> Transform
pub fn scale(x: Float, y: Float, z: Float) -> Transform
pub fn rotate_x(theta: Float) -> Transform
pub fn rotate_y(theta: Float) -> Transform
pub fn rotate_z(theta: Float) -> Transform
pub fn rotate(theta: Float, axis: &Vector3f) -> Transform
pub fn look_at(pos: &Point3f, look: &Point3f, up: &Vector3f) -> Transform
pub fn orthographic(z_near: Float, z_far: Float) -> Transform
pub fn perspective(fov: Float, n: Float, f: Float) -> Transform
pub fn transform_point(&self, p: &Point3f) -> Point3f
pub fn transform_vector(&self, v: &Vector3f) -> Vector3f
pub fn transform_normal(&self, n: &Normal3f) -> Normal3f
pub fn transform_ray(&self, r: &Ray) -> Ray
pub fn transform_bounds(&self, b: &Bounds3f) -> Bounds3f
pub fn transform_point_with_error( &self, p: &Point3f, p_error: &mut Vector3f ) -> Point3f
pub fn transform_point_with_abs_error( &self, pt: &Point3f, pt_error: &Vector3f, abs_error: &mut Vector3f ) -> Point3f
pub fn transform_vector_with_error( &self, v: &Vector3f, abs_error: &mut Vector3f ) -> Vector3f
pub fn transform_ray_with_error( &self, r: &Ray, o_error: &mut Vector3f, d_error: &mut Vector3f ) -> Ray
pub fn transform_surface_interaction(&self, si: &mut SurfaceInteraction<'_>)
Trait Implementations§
source§impl PartialEq<Transform> for Transform
impl PartialEq<Transform> for Transform
impl Copy for Transform
Auto Trait Implementations§
impl RefUnwindSafe for Transform
impl Send for Transform
impl Sync for Transform
impl Unpin for Transform
impl UnwindSafe for Transform
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> Pointable for T
impl<T> Pointable for T
source§impl<R, P> ReadPrimitive<R> for Pwhere
R: Read + ReadEndian<P>,
P: Default,
impl<R, P> ReadPrimitive<R> for Pwhere R: Read + ReadEndian<P>, P: Default,
source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian()
.