using JetBrains.Annotations; using Robust.Shared.Map; using Robust.Shared.Maths; namespace Robust.Client.Graphics { /// /// An Eye is a point through which the player can view the world. /// It's a 2D camera in other game dev lingo basically. /// [PublicAPI] public interface IEye { /// /// Should the black FoV effect be drawn for this eye? /// bool DrawFov { get; set; } /// /// Current position of the center of the eye in the game world. /// MapCoordinates Position { get; } /// /// Translation offset from . Does not influence the center of FOV. /// Vector2 Offset { get; set; } /// /// Rotation of the camera around the Z axis. /// Angle Rotation { get; set; } /// /// Current zoom level of this eye. Zoom is the inverse of Scale (Zoom = 1 / Scale). /// Vector2 Zoom { get; set; } /// /// Current view scale of this eye. Scale is the inverse of Zoom (Scale = 1 / Zoom). /// Vector2 Scale { get; set; } /// /// Returns the view matrix for this eye, used to convert a point from /// world space to camera space. /// /// View matrix for this camera. /// void GetViewMatrix(out Matrix3 viewMatrix, Vector2 renderScale); /// /// Returns the inverted view matrix for this eye, used to convert a point from /// camera space to world space. /// /// Inverted view matrix for this camera. /// void GetViewMatrixInv(out Matrix3 viewMatrixInv, Vector2 renderScale); void GetViewMatrixNoOffset(out Matrix3 viewMatrix, Vector2 renderScale); } }