Esempio n. 1
0
        static Point[] ParseFromString(RE_Type val)
        {
            Point[] outp;
            switch (val)
            {
            case RE_Type.Star:
                outp    = new Point[8];
                outp[0] = new Point(40, 0);
                outp[1] = new Point(50, 30);
                outp[2] = new Point(80, 40);
                outp[3] = new Point(50, 50);
                outp[4] = new Point(40, 80);
                outp[5] = new Point(30, 50);
                outp[6] = new Point(0, 40);
                outp[7] = new Point(30, 30);
                break;

            case RE_Type.Square:
                outp    = new Point[4];
                outp[0] = new Point(10, 10);
                outp[1] = new Point(70, 10);
                outp[2] = new Point(70, 70);
                outp[3] = new Point(10, 70);
                break;

            default:
                outp = new Point[0];
                break;
            }


            return(outp);
        }
Esempio n. 2
0
        static Point[] GetData(RE_Type val)
        {
            Point[] outp;
            switch (val)
            {
            case RE_Type.Star:
                outp = new Point[]
                {
                    new Point(40, 0),
                    new Point(50, 30),
                    new Point(80, 40),
                    new Point(50, 50),
                    new Point(40, 80),
                    new Point(30, 50),
                    new Point(0, 40),
                    new Point(30, 30)
                };
                break;

            case RE_Type.Star_5:
                outp = new Point[]
                {
                    new Point(91, 0),
                    new Point(147, 174),
                    new Point(0, 66),
                    new Point(182, 66),
                    new Point(35, 174)
                };
                break;

            case RE_Type.Square:
                outp = new Point[]
                {
                    new Point(0, 0),
                    new Point(60, 0),
                    new Point(60, 60),
                    new Point(0, 60)
                };
                break;

            default:
                outp = new Point[0];
                break;
            }


            return(outp);
        }
Esempio n. 3
0
 public RE_Drawing_Model(RE_Type re_Type = RE_Type.Star)
 {
     _RE_Type = re_Type;
     Dictionary.Data.TryGetValue(_RE_Type, out _Data);
     Value = 0.0;
 }