/// <summary> /// Unsubscribe a delegate from the bodyRemoved event /// </summary> /// <param name="bodyRemoved">The delegate to unsubscribe</param> public static void UnsubscribeBodyRemoved(this IUsesBodyTracking obj, Action <MRBody> bodyRemoved) { obj.provider.bodyRemoved -= bodyRemoved; }
/// <summary> /// Get the currently tracked bodies /// </summary> /// <param name="bodies">A list of MRRect objects to which the currently tracked planes will be added</param> public static void GetBodies(this IUsesBodyTracking obj, List <MRBody> bodies) { obj.provider.GetBodies(bodies); }
/// <summary> /// Subscribe to the bodyUpdated event, which is called when a tracked body has updated data /// </summary> /// <param name="bodyUpdated">The delegate to subscribe</param> public static void SubscribeBodyUpdated(this IUsesBodyTracking obj, Action <MRBody> bodyUpdated) { obj.provider.bodyUpdated += bodyUpdated; }
/// <summary> /// Track body at specified position /// </summary> /// <param name="center">The position (center) at which to track a body</param> public static void TrackBody(this IUsesBodyTracking obj, Vector2 center) { obj.provider.TrackBody(center); }