RRIntersection

Objective-C

@interface RRIntersection : NSObject

Swift

class RRIntersection : NSObject

A class that represents an intersection of a ray with a renderable’s attached collider

See

RRRay
  • The renderable whose colliders delivered an intersection,

    Declaration

    Objective-C

    @property (nonatomic, strong, readonly) RRRenderable *_Nonnull renderable;

    Swift

    var renderable: RRRenderable { get }
  • The distance of the intersection position from the ray’s origin

    Declaration

    Objective-C

    @property (nonatomic, readonly) CGFloat distance;

    Swift

    var distance: CGFloat { get }
  • The intersection position in global coordinates

    Declaration

    Objective-C

    @property (nonatomic, readonly) simd_float3 intersectionPoint;

    Swift

    var intersectionPoint: simd_float3 { get }