Exemplo n.º 1
0
        // Open file
        private void openFileItem_Click( object sender, System.EventArgs e )
        {
            if ( ofd.ShowDialog( ) == DialogResult.OK )
            {
                // create video source
                VideoFileSource fileSource = new VideoFileSource( );
                fileSource.VideoSource = ofd.FileName;

                // open it
                OpenVideoSource( fileSource );
            }
        }
Exemplo n.º 2
0
        //video laden en achtergrond bepalen
        //(is voor testen bedoeld als er momenteel
        public bool VideoLadenEnAchtergrondBepalen(VideoFileSource videoLinks, VideoFileSource videoRechts, VideoFileSource videoMidden)
        {
            try
            {
                //linkervideo
                videoL = new VideoInput(videoLinks, frames, pixels, verBack);
                while (!videoL.BackgroundFound) { }
                imageLinks = videoL.backGround;
                Console.WriteLine("links gevonden");

                //middenvideo
                videoM = new VideoInput(videoMidden, frames, pixels, verBack);
                while (!videoM.BackgroundFound) { }
                imageMidden = videoM.backGround;
                Console.WriteLine("midden gevonden");

                //rechtervideo
                videoR = new VideoInput(videoRechts, frames, pixels, verBack);
                while (!videoR.BackgroundFound) { }
                imageRechts = videoR.backGround;
                Console.WriteLine("rechts gevonden");

                //hoogte van image bepalen
                height = imageMidden.Height;
                return true;
            }
            catch { return false; }
        }