Accord.Video.Kinect.KinectNative.freenect_shutdown C# (CSharp) Метод

freenect_shutdown() приватный Метод

private freenect_shutdown ( IntPtr context ) : int
context System.IntPtr
Результат int
        public static extern int freenect_shutdown(IntPtr context);

Usage Example

        // Shuts down the context and closes any open devices
        public static void ShutdownContext()
        {
            if (freenectContext != IntPtr.Zero)
            {
                // shutdown context
                int result = KinectNative.freenect_shutdown(freenectContext);
                if (result != 0)
                {
                    throw new ApplicationException("Could not shutdown freenect context. Error Code:" + result);
                }

                // Dispose pointer
                KinectNative.freenectContext = IntPtr.Zero;
            }
        }