Exemple #1
0
        public override void OnGizmoRender(Camera camera)
        {
            bool multipleRenderCams = RTGizmosEngine.Get.NumRenderCameras > 1;

            if (multipleRenderCams)
            {
                _mvAxesSliders.ApplyZoomFactor(camera);
                if (!_isMvVertexSnapEnabled && !_is2DModeEnabled)
                {
                    _mvDblSliders.ApplyZoomFactor(camera);
                    PlaceMvDblSlidersInSliderPlanes(camera);
                }

                Update2DGizmoPosition();
                if (_is2DModeEnabled)
                {
                    Update2DModeHandlePositions();
                }

                _rtMidCap.ApplyZoomFactor(camera);
                _rtAxesSliders.ApplyZoomFactor(camera);
                if (_rtCamLookSlider.IsBorderVisible)
                {
                    UpdateRtCamLookSlider(camera);
                }

                _scMidCap.ApplyZoomFactor(camera);
            }

            _rtXSlider.Render(camera);
            _rtYSlider.Render(camera);
            _rtZSlider.Render(camera);
            _rtMidCap.Render(camera);

            var sortedSliders = _mvAxesSliders.GetRenderSortedSliders(camera);

            foreach (var slider in sortedSliders)
            {
                slider.Render(camera);
            }

            _rtCamLookSlider.Render(camera);
            _mvXYSlider.Render(camera);
            _mvYZSlider.Render(camera);
            _mvZXSlider.Render(camera);
            _scMidCap.Render(camera);

            _mvVertSnapCap.Render(camera);
            _mv2DModeSliders.Render(camera);
            _mv2DModeDblSlider.Render(camera);

            if (LookAndFeel3D.IsScScaleGuideVisible && Gizmo.IsDragged && IsScaleHandle(Gizmo.DragHandleId))
            {
                _scScaleGuide.Render(GameObjectEx.FilterParentsOnly(_scScaleGuideTargetObjects), camera);
            }
        }
        public override void OnGizmoRender(Camera camera)
        {
            bool multipleRenderCams = RTGizmosEngine.Get.NumRenderCameras > 1;

            if (multipleRenderCams)
            {
                _midCap.ApplyZoomFactor(camera);
                _axesSliders.ApplyZoomFactor(camera);
                if (_camLookSlider.IsBorderVisible)
                {
                    UpdateCamLookSlider(camera);
                }
            }

            _xSlider.Render(camera);
            _ySlider.Render(camera);
            _zSlider.Render(camera);
            _midCap.Render(camera);
            _camLookSlider.Render(camera);
        }
Exemple #3
0
        public override void OnGizmoRender(Camera camera)
        {
            bool multipleRenderCams = RTGizmosEngine.Get.NumRenderCameras > 1;

            if (multipleRenderCams)
            {
                _axesSliders.ApplyZoomFactor(camera);
                if (_midCap.IsVisible)
                {
                    _midCap.ApplyZoomFactor(camera);
                }
                if (!_isVertexSnapEnabled && !_is2DModeEnabled)
                {
                    _dblSliders.ApplyZoomFactor(camera);
                    PlaceDblSlidersInSliderPlanes(camera);
                }

                Update2DGizmoPosition();
                if (_is2DModeEnabled)
                {
                    Update2DModeHandlePositions();
                }
            }

            List <GizmoLineSlider3D> sortedSliders = _axesSliders.GetRenderSortedSliders(camera);

            foreach (GizmoLineSlider3D slider in sortedSliders)
            {
                slider.Render(camera);
            }

            _midCap.Render(camera);
            _xySlider.Render(camera);
            _yzSlider.Render(camera);
            _zxSlider.Render(camera);

            _vertSnapCap.Render(camera);
            _2DModeSliders.Render(camera);
            _2DModeDblSlider.Render(camera);
        }