Inheritance: IDisposable
        public PointCloudStreamRecorder(IMotionFrameSerializer serializer)
        {
            this._serializer = serializer;

            SetupFrameQueue();

            soundRecording = new SoundRecording();
        }
Exemple #2
0
        public PointCloudStreamRecorder(IMotionFrameSerializer serializer)
        {
            this._serializer = serializer;

            SetupFrameQueue();

            soundRecording = new SoundRecording();
        }
Exemple #3
0
        private void Dispose(bool disposing)
        {
            ShutdownFrameQueue();

            if (soundRecording != null)
            {
                soundRecording.Stop();
                soundRecording.Dispose();
                soundRecording = null;
            }
        }
        private void Dispose(bool disposing)
        {
            ShutdownFrameQueue();

            if (soundRecording != null)
            {
                soundRecording.Stop();
                soundRecording.Dispose();
                soundRecording = null;
            }
        }
        public ArtofKinectRecorderWindow()
        {
            InitializeComponent();

            frameQueue = new WorkQueue<MotionFrame>();
            frameQueue.Callback = ProcessFrame;
            frameQueue.MaxQueueLength = 5;

            InitSensor();
            InitSerializer();
            InitSoundCapture();
            CreateViews();
            lastFPSCheck = DateTime.Now;

            Application.Current.Exit += (s, e) =>
            {
                this.CurrentFrameViewer = null;
                pointCloudFrameViewer.pointCloudImage.Dispose();
                //pointCloudFrameViewer2.Deactivate();
                //pointCloudFrameViewer2.pointCloudImage.Dispose();
                if (playerSource != null)
                {
                    playerSource.Dispose();
                    playerSource = null;
                }

                if (soundRecording != null)
                {
                    soundRecording.Stop();
                    soundRecording.Dispose();
                    soundRecording = null;
                }
                if (sensorDevice != null)
                {
                    sensorDevice.Dispose();
                    sensorDevice = null;
                }
                if (frameQueue != null)
                {
                    frameQueue.Dispose();
                    frameQueue = null;
                }
            };
        }
 private void InitSoundCapture()
 {
     soundRecording = new SoundRecording();
 }