private void OnRequestFrameData(Notification notification) { LogDataModel logModel = notification.Sender as LogDataModel; if (logModel != null) { logModel.SetValue(LogFrameDataColumns.CurrentFrame.ToString(), Time.frameCount.ToString()); logModel.SetValue(LogFrameDataColumns.FrameTime.ToString(), Time.deltaTime.ToString("0.00")); } }
//Jildert logging private void OnRequestFrameData(Notification notification) { // add all frame data LogDataModel logModel = notification.Sender as LogDataModel; if (logModel != null) { logModel.SetValue(LogFrameDataColumns.LeftRaw.ToString(), lastInput1.ToString("f3")); logModel.SetValue(LogFrameDataColumns.RightRaw.ToString(), lastInput2.ToString("f3")); logModel.SetValue(LogFrameDataColumns.LeftNormalized.ToString(), lastNormalizedInput1.ToString("f3")); logModel.SetValue(LogFrameDataColumns.RightNormalized.ToString(), lastNormalizedInput2.ToString("f3")); logModel.SetValue(LogFrameDataColumns.HandPositionX.ToString(), transform.position.x.ToString("f3")); logModel.SetValue(LogFrameDataColumns.HandPositionY.ToString(), transform.position.x.ToString("f3")); logModel.SetValue(LogFrameDataColumns.Pressure.ToString(), squeezePressure.ToString("f3")); if (holdingObject != null) { logModel.SetValue(LogFrameDataColumns.HoldingObjectName.ToString(), holdingObject.name); logModel.SetValue(LogFrameDataColumns.MinObjectPressure.ToString(), holdingObject.minPressure.ToString("f3")); logModel.SetValue(LogFrameDataColumns.MaxObjectPressure.ToString(), holdingObject.maxPressure.ToString("f3")); } else { logModel.SetValue(LogFrameDataColumns.HoldingObjectName.ToString(), "No Object"); logModel.SetValue(LogFrameDataColumns.MinObjectPressure.ToString(), "0"); logModel.SetValue(LogFrameDataColumns.MaxObjectPressure.ToString(), "100"); } } }