Ejemplo n.º 1
0
        // Open URL
        private void openURLFileItem_Click(object sender, System.EventArgs e)
        {
            URLForm form = new URLForm();

            form.Description = "Enter URL of an updating JPEG from a web camera:";
            form.URLs        = new string[]
            {
                "http://aleksandriacamk1.it.helsinki.fi/axis-cgi/jpg/image.cgi?resolution=320x240",
                "http://stareat.it.helsinki.fi/axis-cgi/jpg/image.cgi?resolution=320x240",
                "http://194.18.89.220/axis-cgi/jpg/image.cgi?resolution=320x240",
                "http://212.247.228.34/axis-cgi/jpg/image.cgi?resolution=352x240"
            };

            if (form.ShowDialog(this) == DialogResult.OK)
            {
                // create video source
                JPEGSource jpegSource = new JPEGSource();
                jpegSource.VideoSource     = form.URL;
                jpegSource.Password        = form.Password;
                jpegSource.Login           = form.Name;
                jpegSource.PreAuthenticate = form.PreAuthenticate;

                // open it
                OpenVideoSource(jpegSource);

                // enable camera window
                cameraWindow.Enabled = true;
            }
        }
Ejemplo n.º 2
0
        // Create video source object
        public IVideoSource CreateVideoSource(object config)
        {
            JPEGConfiguration cfg = (JPEGConfiguration) config;

            if (cfg != null)
            {
                JPEGSource source = new JPEGSource();

                source.VideoSource	= cfg.source;
                source.Login		= cfg.login;
                source.Password		= cfg.password;
                source.FrameInterval = cfg.frameInterval;

                return (IVideoSource) source;
            }
            return null;
        }
Ejemplo n.º 3
0
        // Start receiving video frames
        public void Start()
        {
            videoSource.Start();

            if (thread == null)
            {
                // create events
                stopEvent = new ManualResetEvent(false);
                execEvent = new ManualResetEvent(false);

                // create and start new thread
                thread              = new Thread(new ThreadStart(WorkerThread));
                thread.Name         = this.controlCommand;
                thread.IsBackground = true;
                thread.Start();

                JPEGSource.SetAllowUnsafeHeaderParsing20();
            }
        }
Ejemplo n.º 4
0
 // Constructor
 public FujikoCamera()
 {
     videoSource = new MJPEGSource();
     JPEGSource.SetAllowUnsafeHeaderParsing20();
     streamType = StreamType.MJpeg;
 }
Ejemplo n.º 5
0
 // Constructor
 public BoschCamera()
 {
     videoSource = new JPEGSource();
     //JPEGSource.SetAllowUnsafeHeaderParsing20();
     streamType = StreamType.Jpeg;
 }
Ejemplo n.º 6
0
 // Constructor
 public Axis2401()
 {
     videoSource = new JPEGSource();
     streamType  = StreamType.Jpeg;
 }
Ejemplo n.º 7
0
 // Constructor
 public Axis2460()
 {
     videoSource = new JPEGSource();
     streamType = StreamType.Jpeg;
 }
Ejemplo n.º 8
0
 // 构造函数
 public EasyNCamera()
 {
     videoSource = new JPEGSource();
     streamType = StreamType.Jpeg;
 }
Ejemplo n.º 9
0
 // Constructor
 public PixordCamera()
 {
     videoSource = new JPEGSource();
     streamType = StreamType.Jpeg;
 }
Ejemplo n.º 10
0
 // 构造函数
 public EasyNCamera()
 {
     videoSource = new JPEGSource();
     streamType  = StreamType.Jpeg;
 }
Ejemplo n.º 11
0
 // Constructor
 public PixordCamera()
 {
     videoSource = new JPEGSource();
     streamType  = StreamType.Jpeg;
 }
Ejemplo n.º 12
0
 // Constructor
 public PanasonicCamera()
 {
     videoSource = new JPEGSource();
     streamType = StreamType.Jpeg;
 }
Ejemplo n.º 13
0
 // Constructor
 public PanasonicCamera()
 {
     videoSource = new JPEGSource();
     JPEGSource.SetAllowUnsafeHeaderParsing20();
     streamType = StreamType.Jpeg;
 }
Ejemplo n.º 14
0
 // Constructor
 public PanasonicCamera()
 {
     videoSource = new JPEGSource();
     streamType  = StreamType.Jpeg;
 }