Example #1
0
        /**
         * Creates a new Clock Correlation object for maintaining a latency-adjusted relationship between the
         * Leap Motion system clock and an external clock.
         *
         * @since 3.x.y
         */
        public ClockCorrelator()
        {
            eLeapRS result = LeapC.CreateClockRebaser(out _rebaserHandle);

            if (result != eLeapRS.eLeapRS_Success)
            {
                throw new Exception(result.ToString());
            }
        }
Example #2
0
        private void InitClockRebaser()
        {
            _stopwatch.Start();
            eLeapRS result = LeapC.CreateClockRebaser(out _clockRebaser);

            if (result != eLeapRS.eLeapRS_Success)
            {
                Debug.LogError("Failed to create clock rebaser");
            }

            if (_clockRebaser == IntPtr.Zero)
            {
                Debug.LogError("Clock rebaser is null");
            }
        }