Ejemplo n.º 1
0
 /// <summary>
 /// Transforms the specified point in screen coordinates to the element's local coordinate system
 /// </summary>
 /// <returns>The to local coordinates.</returns>
 /// <param name="screenCoords">Screen coords.</param>
 public Vector2 ScreenToLocalCoordinates(Vector2 screenCoords)
 {
     if (stage == null)
     {
         return(screenCoords);
     }
     return(StageToLocalCoordinates(stage.ScreenToStageCoordinates(screenCoords)));
 }
Ejemplo n.º 2
0
        /// <summary>
        /// Transforms the specified point in screen coordinates to the element's local coordinate system
        /// </summary>
        /// <returns>The to local coordinates.</returns>
        /// <param name="screenCoords">Screen coords.</param>
        public System.Numerics.Vector2 ScreenToLocalCoordinates(System.Numerics.Vector2 screenCoords)
        {
            if (_stage == null)
            {
                return(screenCoords);
            }

            return(StageToLocalCoordinates(_stage.ScreenToStageCoordinates(screenCoords)));
        }