Exemplo n.º 1
0
        public void progressbarDecrement()
        {
            renderer.render();
            Thread.Sleep(100);
            if (progressbar.Value > 0)
            {
                progressbar.Value -= 1;
            }
            else
            {
                return;
            }
            double progress = (double)progressbar.Value / (double)progressbar.Maximum;

            poly.tweening(points1, points2, progress, progressbarDecrement);
        }
Exemplo n.º 2
0
        public Displayer()
        {
            InitializeComponent();

            // Initialize render engine
            renderer = new RenderEngine(this.canvas);

            // Create polygon
            points2 = new int[, ] {
                { 130, 125 },
                { 192, 80 },
                { 247, 72 },
                { 252, 69 },
                { 315, 69 },
                { 319, 72 },
                { 375, 80 },
                { 438, 125 },
                { 412, 174 },
                { 367, 154 },
                { 370, 309 },
                { 198, 309 },
                { 200, 154 },
                { 157, 174 }
            };

            points1 = new int[, ] {
                { 228, 66 },
                { 387, 66 },
                { 387, 135 },
                { 380, 318 },
                { 345, 318 },
                { 311, 138 },
                { 277, 318 },
                { 243, 318 },
                { 228, 135 },
                { 228, 66 },
                { 228, 71 },
                { 387, 71 },
                { 387, 66 },
                { 228, 66 }
            };

            poly = new Polygon(points1);
            renderer.render(ref poly);
        }
Exemplo n.º 3
0
        public Displayer()
        {
            InitializeComponent();

            // Initialize render engine
            renderer = new RenderEngine(this.canvas);

            // Create polygon
            points2 = new int[,] {
                {130,125},
                {192,80},
                {247,72},
                {252,69},
                {315,69},
                {319,72},
                {375,80},
                {438,125},
                {412,174},
                {367,154},
                {370,309},
                {198,309},
                {200,154},
                {157,174} };

            points1 = new int[,] {
                {228,66},
                {387,66},
                {387,135},
                {380,318},
                {345,318},
                {311,138},
                {277,318},
                {243,318},
                {228,135},
                {228,66},
                {228,71},
                {387,71},
                {387,66},
                {228,66}};

            poly = new Polygon(points1);
            renderer.render(ref poly);
        }