View projection is now updated when engaging Visual mode. This means no more distorted visuals after disproportionately changing window size.

This commit is contained in:
MaxED 2014-09-09 12:16:26 +00:00
parent 359cea1ce8
commit 5e7de03847
2 changed files with 12 additions and 9 deletions

View file

@ -27,19 +27,19 @@ namespace CodeImp.DoomBuilder.Geometry
#region ================== Variables
// Frustum settings
private float near;
private float far;
private float fov;
private Vector2D pos;
private float xyangle;
private float zangle;
private readonly float near;
private readonly float far;
private readonly float fov;
private readonly Vector2D pos;
private readonly float xyangle;
private readonly float zangle;
// Frustum lines
private Line2D[] lines;
private readonly Line2D[] lines;
// Circle
private Vector2D center;
private float radius;
private readonly Vector2D center;
private readonly float radius;
#endregion

View file

@ -157,6 +157,9 @@ namespace CodeImp.DoomBuilder.VisualModes
public override void OnEngage()
{
base.OnEngage();
// Update projection (mxd)
General.Map.CRenderer3D.CreateProjection();
// Update the used textures
General.Map.Data.UpdateUsedTextures();