pub fn to_transform(ray: Ray3d) -> Mat4