private void HandleZoom()
        {
            var dpad     = SteamVR_Actions.default_DpadOrientation.GetAxis(SteamVR_Input_Sources.LeftHand);
            var zoomMode = SteamVR_Actions.default_MinimapZoomModifier.GetState(SteamVR_Input_Sources.LeftHand);

            if (zoomMode)
            {
                var internalDelta = dpad.y * 10000; //Mathf.RoundToInt(dpad.y * ZoomSpeed * Time.deltaTime);
                var delta         = internalDelta > 0.2f
                    ? 1
                    : internalDelta < -0.2f
                        ? -1
                        : 0;
                if (delta != 0)
                {
                    var margs = new MouseEventArgs
                    {
                        ComplexEventType = MouseEventType.Wheel,
                        WheelDelta       = delta,
                        Viewport         = viewports[0],
                        State            = new MouseState
                        {
                            Buttons            = MouseButtons.None,
                            Position           = new IntVector2(MinimapImageSize.Width / 2, MinimapImageSize.Height / 2),
                            HmgnPosition       = new cna.Vector2(0.5f, 0.5f),
                            NormalizedPosition = new cna.Vector2(0.5f, 0.5f),
                        },
                    };
                    inputService.OnInputEvent(margs);
                }
            }
            else
            {
                var delta      = new cna.Vector2(dpad.x, dpad.y) * MovementSpeed * Time.deltaTime;
                var pixelDelta = new IntVector2((int)Math.Round(delta.X * -MinimapImageSize.Width),
                                                (int)Math.Round(delta.Y * MinimapImageSize.Height));
                if (pixelDelta != IntVector2.Zero)
                {
                    var margs = new MouseEventArgs
                    {
                        ComplexEventType = MouseEventType.Move,
                        Delta            = pixelDelta,
                        Viewport         = viewports[0],
                        State            = new MouseState
                        {
                            Buttons            = MouseButtons.Right,
                            Position           = new IntVector2(MinimapImageSize.Width / 2, MinimapImageSize.Height / 2),
                            HmgnPosition       = new cna.Vector2(0.5f, 0.5f),
                            NormalizedPosition = new cna.Vector2(0.5f, 0.5f),
                        },
                    };
                    inputService.OnInputEvent(margs);
                }
            }
        }
 private cna.Vector2 Hmgnize(cna.Vector2 v)
 {
     return(new cna.Vector2(
                v.X / MinimapImageSize.Width * 2f - 1f,
                1f - v.Y * 2f / MinimapImageSize.Height));
 }
 private cna.Vector2 Normalize(cna.Vector2 v)
 {
     return(new cna.Vector2(
                2f * (v.X - MinimapImageSize.Width / 2f) / MinimapImageSize.Height,
                1f - v.Y * 2f / MinimapImageSize.Height));
 }