zoukankan      html  css  js  c++  java
  • AnyCAD C#开发-设置背景颜色,工作平面,坐标轴等renderView.SetBackgroundColor

          private void Form1_Load(object sender, EventArgs e)
            {
                //设置背景颜色
                renderView.SetBackgroundColor(new ColorValue(180, 182, 184), new ColorValue(230, 232, 234), new ColorValue(210, 212, 214));
                //隐藏工作平面
                renderView.ShowWorkingGrid(false);
    
                //隐藏默认的坐标轴
                renderView.ShowCoordinateAxis(false);
                
                //讲原有坐标系的xyz改名字
                ////xwh.EnableLeftHandCS();
                ////xwh.SetArrowText((int)EnumAxesDirection.Axes_Y, "w");
                ////xwh.SetArrowText((int)EnumAxesDirection.Axes_Z, "h");
    
                //设置局部坐标
                AxesWidget xwh = new AxesWidget();
                Coordinate3 coord = new Coordinate3(Vector3.ZERO, Vector3.UNIT_X, Vector3.UNIT_Y, Vector3.UNIT_Z);
                xwh.SetCoordinate(coord);
                renderView.ShowSceneNode(xwh);
    
                //设置坐标系到左下角
                ScreenWidget coorWidget = new ScreenWidget();
                coorWidget.SetNode(xwh);
                coorWidget.SetWidgetPosition((int)EnumWidgetPosition.WP_BottomLeft);
                renderView.Renderer.AddWidgetNode(coorWidget);
    
                GlobalInstance.EventListener.OnSelectElementEvent += OnSelectionEvent;
    
            }

    Caesar卢尚宇

    2020年11月22日

  • 相关阅读:
    单分发器
    Python 虚拟环境
    $modal
    memoization
    directive例子2
    UI-Router
    angular-translate
    directive例子1
    FileInputStream/FileOutputStream的应用
    自定义readLine
  • 原文地址:https://www.cnblogs.com/nxopen2018/p/14022062.html
Copyright © 2011-2022 走看看