/// <summary> /// Starts this handler /// </summary> /// <param name="c">controller class</param> /// <param name="sensor">kinect sensor</param> public override void Start(Controller c, KinectSensor sensor) { controller = c; provider = new PencilProvider(controller); provider.changeCursorToHand(); if (sensor != null) { //load reader and register frame arrived delegate (listener) reader = sensor.BodyFrameSource.OpenReader(); reader.FrameArrived += Reader_FrameArrived; coordinateMapper = sensor.CoordinateMapper; drawer = controller.Ui.CanvasDrawer; drawer.controller = this.controller; drawer.provider = this.provider; } }