public override void Resize(int width, int height) { Projection = Mat4.CreatePerspective(Math.PI / 4, width / (float)height, 1f, 2 * _dist); //Projection = Mat4.CreateOrthographic(-width / 2.0, width / 2.0, -height / 2.0, height / 2.0, Near, Far) * Mat4.Scale(Scale); }
public void Apply() { RenderState.ProjectionMatrix = Mat4.CreatePerspective(FOV, RenderState.Aspect, 1e-2, 1e3); RenderState.CameraMatrix = Matrix; }
public static void ViewPerspective(double fov) { ProjectionMatrix = Mat4.CreatePerspective(fov, Aspect, 1e-2, 1e3); }