예제 #1
0
 public override void OnInitialize()
 {
     m_SuperFast = new AGG.UI.cbox_ctrl <T>(M.New <T>(10), M.New <T>(10), "Run Super Fast");
     AddChild(m_SuperFast);
     m_Controller = new CController <T>(rbuf_window(), 30, 40, .1, .7, .3, 4, 1, 2000);
     base.OnInitialize();
 }
예제 #2
0
        public override void OnDraw(Graphics2D graphics2D)
        {
            ImageBuffer widgetsSubImage = ImageBuffer.NewSubImageReference(graphics2D.DestImage, graphics2D.GetClippingRect());

            IImageByte backBuffer = widgetsSubImage;

            if (firstTime)
            {
                firstTime   = false;
                m_SuperFast = new MatterHackers.Agg.UI.CheckBox(10, 10, "Run Super Fast");
                AddChild(m_SuperFast);
                m_Controller = new CController(backBuffer, 30, 40, .1, .7, .3, 4, 1, 2000);
            }

            graphics2D.Clear(new RGBA_Floats(1, 1, 1, 1));
            graphics2D.Rasterizer.SetVectorClipBox(0, 0, (int)Width, (int)Height);
            m_Controller.FastRender(m_SuperFast.Checked);
            m_Controller.Render(graphics2D);
            //m_SuperFast.Render(graphics2D);
            base.OnDraw(graphics2D);
        }
예제 #3
0
		public override void OnDraw(Graphics2D graphics2D)
		{
			ImageBuffer widgetsSubImage = ImageBuffer.NewSubImageReference(graphics2D.DestImage, graphics2D.GetClippingRect());

			IImageByte backBuffer = widgetsSubImage;

			if (firstTime)
			{
				firstTime = false;
				m_SuperFast = new MatterHackers.Agg.UI.CheckBox(10, 10, "Run Super Fast");
				AddChild(m_SuperFast);
				m_Controller = new CController(backBuffer, 30, 40, .1, .7, .3, 4, 1, 2000);
			}

			graphics2D.Clear(new RGBA_Floats(1, 1, 1, 1));
			graphics2D.Rasterizer.SetVectorClipBox(0, 0, (int)Width, (int)Height);
			m_Controller.FastRender(m_SuperFast.Checked);
			m_Controller.Render(graphics2D);
			//m_SuperFast.Render(graphics2D);
			base.OnDraw(graphics2D);
		}