Struct machinery_api::foundation::CameraApi [−][src]
#[repr(C)]pub struct CameraApi {}Show 15 fields
pub view_from_transform: Option<unsafe extern "C" fn(view: *mut Mat44T, tm: *const TransformT) -> *mut Mat44T>, pub transform_from_view: Option<unsafe extern "C" fn(tm: *mut TransformT, view: *const Mat44T) -> *mut TransformT>, pub projection_from_frustum: Option<unsafe extern "C" fn(proj: *mut Mat44T, left: f32, right: f32, bottom: f32, top: f32, near: f32, far: f32) -> *mut Mat44T>, pub projection_from_fov: Option<unsafe extern "C" fn(proj: *mut Mat44T, near_plane: f32, far_plane: f32, vertical_fov: f32, aspect: f32) -> *mut Mat44T>, pub orthographic_from_frustum: Option<unsafe extern "C" fn(proj: *mut Mat44T, left: f32, right: f32, bottom: f32, top: f32, near: f32, far: f32) -> *mut Mat44T>, pub orthographics_from_dimensions: Option<unsafe extern "C" fn(proj: *mut Mat44T, near_plane: f32, far_plane: f32, width: f32, height: f32) -> *mut Mat44T>, pub projection_from_camera: Option<unsafe extern "C" fn(camera: *mut CameraT, transform: CameraTransform, aspect: f32) -> *mut Mat44T>, pub update_free_flight: Option<unsafe extern "C" fn(tm: *mut TransformT, t: Vec3T, r: Vec2T)>, pub update_pan: Option<unsafe extern "C" fn(tm: *mut TransformT, focus_position: *mut Vec3T, pan: Vec2T)>, pub update_maya: Option<unsafe extern "C" fn(tm: *mut TransformT, focus_position: Vec3T, zoom: f32, rot: Vec2T)>, pub world_to_screen: Option<unsafe extern "C" fn(camera: *const CameraT, transform: CameraTransform, viewport: RectT, world: *const Vec3T, screen: *mut Vec3T, n: u32) -> *mut Vec3T>, pub screen_to_world: Option<unsafe extern "C" fn(camera: *const CameraT, transform: CameraTransform, viewport: RectT, screen: *const Vec3T, world: *mut Vec3T, n: u32) -> *mut Vec3T>, pub meters_per_pixel: Option<unsafe extern "C" fn(distance: f32, vertical_fov: f32, viewport_height: f32) -> f32>, pub default_camera: Option<unsafe extern "C" fn() -> *const CameraT>, pub frustum_planes_from_view_projection: Option<unsafe extern "C" fn(view: *const Mat44T, projection: *const Mat44T, frustum_planes: *mut Vec4T)>,
Fields
view_from_transform: Option<unsafe extern "C" fn(view: *mut Mat44T, tm: *const TransformT) -> *mut Mat44T>transform_from_view: Option<unsafe extern "C" fn(tm: *mut TransformT, view: *const Mat44T) -> *mut TransformT>projection_from_frustum: Option<unsafe extern "C" fn(proj: *mut Mat44T, left: f32, right: f32, bottom: f32, top: f32, near: f32, far: f32) -> *mut Mat44T>projection_from_fov: Option<unsafe extern "C" fn(proj: *mut Mat44T, near_plane: f32, far_plane: f32, vertical_fov: f32, aspect: f32) -> *mut Mat44T>orthographic_from_frustum: Option<unsafe extern "C" fn(proj: *mut Mat44T, left: f32, right: f32, bottom: f32, top: f32, near: f32, far: f32) -> *mut Mat44T>orthographics_from_dimensions: Option<unsafe extern "C" fn(proj: *mut Mat44T, near_plane: f32, far_plane: f32, width: f32, height: f32) -> *mut Mat44T>projection_from_camera: Option<unsafe extern "C" fn(camera: *mut CameraT, transform: CameraTransform, aspect: f32) -> *mut Mat44T>update_free_flight: Option<unsafe extern "C" fn(tm: *mut TransformT, t: Vec3T, r: Vec2T)>update_pan: Option<unsafe extern "C" fn(tm: *mut TransformT, focus_position: *mut Vec3T, pan: Vec2T)>update_maya: Option<unsafe extern "C" fn(tm: *mut TransformT, focus_position: Vec3T, zoom: f32, rot: Vec2T)>world_to_screen: Option<unsafe extern "C" fn(camera: *const CameraT, transform: CameraTransform, viewport: RectT, world: *const Vec3T, screen: *mut Vec3T, n: u32) -> *mut Vec3T>screen_to_world: Option<unsafe extern "C" fn(camera: *const CameraT, transform: CameraTransform, viewport: RectT, screen: *const Vec3T, world: *mut Vec3T, n: u32) -> *mut Vec3T>meters_per_pixel: Option<unsafe extern "C" fn(distance: f32, vertical_fov: f32, viewport_height: f32) -> f32>default_camera: Option<unsafe extern "C" fn() -> *const CameraT>frustum_planes_from_view_projection: Option<unsafe extern "C" fn(view: *const Mat44T, projection: *const Mat44T, frustum_planes: *mut Vec4T)>Implementations
pub unsafe fn view_from_transform(
&self,
view: *mut Mat44T,
tm: *const TransformT
) -> *mut Mat44T
pub unsafe fn transform_from_view(
&self,
tm: *mut TransformT,
view: *const Mat44T
) -> *mut TransformT
pub unsafe fn projection_from_frustum(
&self,
proj: *mut Mat44T,
left: f32,
right: f32,
bottom: f32,
top: f32,
near: f32,
far: f32
) -> *mut Mat44T
pub unsafe fn projection_from_fov(
&self,
proj: *mut Mat44T,
near_plane: f32,
far_plane: f32,
vertical_fov: f32,
aspect: f32
) -> *mut Mat44T
pub unsafe fn orthographic_from_frustum(
&self,
proj: *mut Mat44T,
left: f32,
right: f32,
bottom: f32,
top: f32,
near: f32,
far: f32
) -> *mut Mat44T
pub unsafe fn orthographics_from_dimensions(
&self,
proj: *mut Mat44T,
near_plane: f32,
far_plane: f32,
width: f32,
height: f32
) -> *mut Mat44T
pub unsafe fn projection_from_camera(
&self,
camera: *mut CameraT,
transform: CameraTransform,
aspect: f32
) -> *mut Mat44T
pub unsafe fn update_maya(
&self,
tm: *mut TransformT,
focus_position: Vec3T,
zoom: f32,
rot: Vec2T
)
pub unsafe fn world_to_screen(
&self,
camera: *const CameraT,
transform: CameraTransform,
viewport: RectT,
world: *const Vec3T,
screen: *mut Vec3T,
n: u32
) -> *mut Vec3T
pub unsafe fn screen_to_world(
&self,
camera: *const CameraT,
transform: CameraTransform,
viewport: RectT,
screen: *const Vec3T,
world: *mut Vec3T,
n: u32
) -> *mut Vec3T
pub unsafe fn meters_per_pixel(
&self,
distance: f32,
vertical_fov: f32,
viewport_height: f32
) -> f32
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for CameraApi
impl UnwindSafe for CameraApi
Blanket Implementations
Mutably borrows from an owned value. Read more