Exemple #1
0
        public Form1()
        {
            InitializeComponent();
            this.Size = new Size(1450,750);        // why is this needed?
            _CVMan = new CVMan(".\\");
            _recipeMan = new RecipeMan(_CVMan);
            //_CVMan.StartVideoStream(showImage);
            _delegate = showImage;
            foreach (CAPI.ImageMode mode in Enum.GetValues(typeof(CAPI.ImageMode)))
                modeComboBox.Properties.Items.Add(mode.ToString());
            foreach (CAPI.ImageColor color in Enum.GetValues(typeof(CAPI.ImageColor)))
                colorComboBox.Properties.Items.Add(color.ToString());
            foreach (CAPI.ColorMap colorMap in Enum.GetValues(typeof(CAPI.ColorMap)))
                colorMapComboBox.Properties.Items.Add(colorMap.ToString());
            foreach (var mode in Enum.GetValues(typeof(DevExpress.XtraEditors.Controls.PictureSizeMode)))
                pictureEditModeComboBox.Properties.Items.Add(mode.ToString());
            foreach (var morphMode in Enum.GetValues(typeof(CAPI.MorphMode)))
                morphModeComboBox.Properties.Items.Add(morphMode.ToString());
            foreach (var se in Enum.GetValues(typeof(CAPI.MorphStructureEnum)))
                structuringElementComboBox.Properties.Items.Add(se.ToString());
            foreach (var bmode in Enum.GetValues(typeof(CAPI.BooleanMode)))
                booleanComboBox.Properties.Items.Add(bmode.ToString());
            foreach (var blurmode in Enum.GetValues(typeof(CAPI.BlurMode)))
                blurComboBox.Properties.Items.Add(blurmode.ToString());

            foreach (var recipeNo in Enum.GetValues(typeof(RecipeMan.Recipes)))
                recipeCompboBox.Properties.Items.Add(recipeNo.ToString());
            recipeCompboBox.SelectedIndex = 0;

            pictureEdit1.Properties.ShowZoomSubMenu = DevExpress.Utils.DefaultBoolean.True;
            pictureEdit2.Properties.ShowZoomSubMenu = DevExpress.Utils.DefaultBoolean.True;
            pictureEdit3.Properties.ShowZoomSubMenu = DevExpress.Utils.DefaultBoolean.True;
            SetMainImage();

            morphModeComboBox.SelectedIndex = 0;
            structuringElementComboBox.SelectedIndex = 0;
            modeComboBox.SelectedIndex = 0;
            colorMapComboBox.SelectedIndex = 1;
            colorMapLabel.Visible = false;
            colorMapComboBox.Visible = false;
            pictureEdit1.Properties.SizeMode = DevExpress.XtraEditors.Controls.PictureSizeMode.Zoom;
            pictureEdit2.Properties.SizeMode = DevExpress.XtraEditors.Controls.PictureSizeMode.Zoom;
            pictureEdit3.Properties.SizeMode = DevExpress.XtraEditors.Controls.PictureSizeMode.Zoom;
            booleanComboBox.SelectedIndex = 0;
            blurComboBox.SelectedIndex = 0;
            kernelSizeEdit.EditValue = 7;
            inputDirectoryEdit.EditValue = "InputImages";
            outputDirectoryTextEdit.EditValue = "OutputImages";
        }
Exemple #2
0
 public RecipeMan(CVLib.CVMan man)
 {
     _CVMan = man;
 }
Exemple #3
0
        public Form1()
        {
            InitializeComponent();
            this.Size  = new Size(1450, 750);      // why is this needed?
            _CVMan     = new CVMan(".\\");
            _recipeMan = new RecipeMan(_CVMan);
            //_CVMan.StartVideoStream(showImage);
            _delegate = showImage;
            foreach (CAPI.ImageMode mode in Enum.GetValues(typeof(CAPI.ImageMode)))
            {
                modeComboBox.Properties.Items.Add(mode.ToString());
            }
            foreach (CAPI.ImageColor color in Enum.GetValues(typeof(CAPI.ImageColor)))
            {
                colorComboBox.Properties.Items.Add(color.ToString());
            }
            foreach (CAPI.ColorMap colorMap in Enum.GetValues(typeof(CAPI.ColorMap)))
            {
                colorMapComboBox.Properties.Items.Add(colorMap.ToString());
            }
            foreach (var mode in Enum.GetValues(typeof(DevExpress.XtraEditors.Controls.PictureSizeMode)))
            {
                pictureEditModeComboBox.Properties.Items.Add(mode.ToString());
            }
            foreach (var morphMode in Enum.GetValues(typeof(CAPI.MorphMode)))
            {
                morphModeComboBox.Properties.Items.Add(morphMode.ToString());
            }
            foreach (var se in Enum.GetValues(typeof(CAPI.MorphStructureEnum)))
            {
                structuringElementComboBox.Properties.Items.Add(se.ToString());
            }
            foreach (var bmode in Enum.GetValues(typeof(CAPI.BooleanMode)))
            {
                booleanComboBox.Properties.Items.Add(bmode.ToString());
            }
            foreach (var blurmode in Enum.GetValues(typeof(CAPI.BlurMode)))
            {
                blurComboBox.Properties.Items.Add(blurmode.ToString());
            }

            foreach (var recipeNo in Enum.GetValues(typeof(RecipeMan.Recipes)))
            {
                recipeCompboBox.Properties.Items.Add(recipeNo.ToString());
            }
            recipeCompboBox.SelectedIndex = 0;

            pictureEdit1.Properties.ShowZoomSubMenu = DevExpress.Utils.DefaultBoolean.True;
            pictureEdit2.Properties.ShowZoomSubMenu = DevExpress.Utils.DefaultBoolean.True;
            pictureEdit3.Properties.ShowZoomSubMenu = DevExpress.Utils.DefaultBoolean.True;
            SetMainImage();

            morphModeComboBox.SelectedIndex          = 0;
            structuringElementComboBox.SelectedIndex = 0;
            modeComboBox.SelectedIndex        = 0;
            colorMapComboBox.SelectedIndex    = 1;
            colorMapLabel.Visible             = false;
            colorMapComboBox.Visible          = false;
            pictureEdit1.Properties.SizeMode  = DevExpress.XtraEditors.Controls.PictureSizeMode.Zoom;
            pictureEdit2.Properties.SizeMode  = DevExpress.XtraEditors.Controls.PictureSizeMode.Zoom;
            pictureEdit3.Properties.SizeMode  = DevExpress.XtraEditors.Controls.PictureSizeMode.Zoom;
            booleanComboBox.SelectedIndex     = 0;
            blurComboBox.SelectedIndex        = 0;
            kernelSizeEdit.EditValue          = 7;
            inputDirectoryEdit.EditValue      = "InputImages";
            outputDirectoryTextEdit.EditValue = "OutputImages";
        }
Exemple #4
0
 public RecipeMan(CVLib.CVMan man)
 {
     _CVMan = man;
 }