#[repr(C)]pub struct MPSRayOriginMinDistanceDirectionMaxDistance {
pub origin: MPSPackedFloat3,
pub minDistance: c_float,
pub direction: MPSPackedFloat3,
pub maxDistance: c_float,
}MPSRayIntersector and MPSRayIntersectorTypes only.Expand description
Represents a 3D ray with an origin, a direction, and an intersection distance range from the origin
This type is available from the Metal Shading Language by including the MetalPerformanceShaders/MetalPerformanceShaders.h header.
See also Apple’s documentation
Fields§
§origin: MPSPackedFloat3Ray origin. The intersection test will be skipped if the origin contains NaNs or infinities.
minDistance: c_floatMinimum intersection distance from the origin along the ray direction. The intersection test will be skipped if the minimum distance is equal to positive infinity or NaN.
direction: MPSPackedFloat3Ray direction. Does not need to be normalized. The intersection test will be skipped if the direction has length zero or contains NaNs or infinities.
maxDistance: c_floatMaximum intersection distance from the origin along the ray direction. May be infinite. The intersection test will be skipped if the maximum distance is less than zero, NaN, or less than the minimum intersection distance.
Trait Implementations§
Source§impl Clone for MPSRayOriginMinDistanceDirectionMaxDistance
impl Clone for MPSRayOriginMinDistanceDirectionMaxDistance
Source§fn clone(&self) -> MPSRayOriginMinDistanceDirectionMaxDistance
fn clone(&self) -> MPSRayOriginMinDistanceDirectionMaxDistance
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl PartialEq for MPSRayOriginMinDistanceDirectionMaxDistance
impl PartialEq for MPSRayOriginMinDistanceDirectionMaxDistance
Source§fn eq(&self, other: &MPSRayOriginMinDistanceDirectionMaxDistance) -> bool
fn eq(&self, other: &MPSRayOriginMinDistanceDirectionMaxDistance) -> bool
self and other values to be equal, and is used by ==.