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

            if (multipleRenderCams)
            {
                _midCap.ApplyZoomFactor(camera);
                _axesSliders.ApplyZoomFactor(camera);
                _dblSliders.ApplyZoomFactor(camera);
                if (_multiAxisScaleMode == GizmoMultiAxisScaleMode.DoubleAxis)
                {
                    PlaceDblSlidersInSliderPlanes(camera);
                }
            }

            var sortedSliders = _axesSliders.GetRenderSortedSliders(camera);

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

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

            if (LookAndFeel3D.IsScaleGuideVisible && Gizmo.IsDragged && OwnsHandle(Gizmo.DragHandleId))
            {
                _scaleGuide.Render(GameObjectEx.FilterParentsOnly(_scaleGuideTargetObjects), camera);
            }
        }
Beispiel #2
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);
            }
        }