- replaced MIN/MAX in common code.
This commit is contained in:
parent
07a181090b
commit
eb69bbcae0
63 changed files with 200 additions and 236 deletions
|
|
@ -186,7 +186,7 @@ void DFrameBuffer::SetViewportRects(IntRect *bounds)
|
|||
int screenWidth = GetWidth();
|
||||
int screenHeight = GetHeight();
|
||||
float scaleX, scaleY;
|
||||
scaleX = std::min(clientWidth / (float)screenWidth, clientHeight / ((float)screenHeight * ViewportPixelAspect()));
|
||||
scaleX = min(clientWidth / (float)screenWidth, clientHeight / ((float)screenHeight * ViewportPixelAspect()));
|
||||
scaleY = scaleX * ViewportPixelAspect();
|
||||
mOutputLetterbox.width = (int)round(screenWidth * scaleX);
|
||||
mOutputLetterbox.height = (int)round(screenHeight * scaleY);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue