mirror of
https://github.com/ApfelTeeSaft/DotNesJit.git
synced 2026-08-26 19:23:35 +00:00
Fixed incorrect render dimension calculations
This commit is contained in:
@@ -185,7 +185,7 @@ public class MonogameApp : Game, IC64Display
|
||||
{
|
||||
// texture has a wider aspect ratio than the viewport, texture is width constrained.
|
||||
width = GraphicsDevice.Viewport.Width;
|
||||
height = (int)Math.Round(width * textureAspectRatio);
|
||||
height = (int)Math.Round(width / textureAspectRatio);
|
||||
startY = (GraphicsDevice.Viewport.Height - height) / 2;
|
||||
}
|
||||
else
|
||||
|
||||
@@ -190,7 +190,7 @@ public class MonogameApp : Game, INesDisplay, INesInput
|
||||
{
|
||||
// texture has a wider aspect ratio than the viewport, texture is width constrained.
|
||||
width = GraphicsDevice.Viewport.Width;
|
||||
height = (int)Math.Round(width * textureAspectRatio);
|
||||
height = (int)Math.Round(width / textureAspectRatio);
|
||||
startY = (GraphicsDevice.Viewport.Height - height) / 2;
|
||||
}
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user