コード例 #1
0
ファイル: Program.cs プロジェクト: ashersyed/opencvdotnet
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            // make sure all OpenCV errors are thrown as exceptions.
            CVUtils.ErrorsToExceptions();

            ExampleSelection es = new ExampleSelection();

            Assembly me = Assembly.GetExecutingAssembly();
            foreach (Type t in me.GetTypes())
            {
                if (t.IsSubclassOf(typeof(Form)) && t != typeof(ExampleSelection))
                {
                    Form f = (Form) me.CreateInstance(t.FullName);
                    es.AddForm(f);
                }
            }

            es.ShowDialog();
        }
コード例 #2
0
ファイル: Program.cs プロジェクト: tdck/opencvdotnet
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            // make sure all OpenCV errors are thrown as exceptions.
            CVUtils.ErrorsToExceptions();

            ExampleSelection es = new ExampleSelection();

            Assembly me = Assembly.GetExecutingAssembly();

            foreach (Type t in me.GetTypes())
            {
                if (t.IsSubclassOf(typeof(Form)) && t != typeof(ExampleSelection))
                {
                    Form f = (Form)me.CreateInstance(t.FullName);
                    es.AddForm(f);
                }
            }

            es.ShowDialog();
        }