Example #1
0
 private void ocView_Paint(object sender, PaintEventArgs e)
 {
     if (viewer3d != null)
     {
         viewer3d.Redraw();
     }
     //if (view3d != null)
     //    view3d.Redraw();
 }
Example #2
0
        private void UpdateOccOptions()
        {
            var optionsSetup = _actionGraph[InputNames.OptionsSetupInput].Get <OptionsSetup>();
            var occOptions   = optionsSetup.UpdateSectionNode(OptionSectionNames.Background);

            _view.SetBackgroundColor(ShapeUtils.GetOccColor(occOptions.GetColorValue(0)));
            if (occOptions.GetBoolValue(2))
            {
                _view.SetAntialiasingOn();
            }
            else
            {
                _view.SetAntialiasingOff();
            }
            var firstColor  = occOptions.GetColorValue(4);
            var secondColor = occOptions.GetColorValue(5);

            GeomUtils.MakeGradient("background2.bmp", 32, 128, firstColor, secondColor);
            //SetNewGradientBackground();
            _viewer.Redraw();
        }