mirror of https://github.com/OpenRCT2/OpenRCT2.git
Revert "Avoid unnecessary calculations when the passed DPI is the active DPI" (#13672)
This commit is contained in:
parent
eda01dc608
commit
ad52abf39a
|
@ -1010,12 +1010,6 @@ void OpenGLDrawingContext::HandleTransparency()
|
||||||
|
|
||||||
void OpenGLDrawingContext::SetDPI(rct_drawpixelinfo* dpi)
|
void OpenGLDrawingContext::SetDPI(rct_drawpixelinfo* dpi)
|
||||||
{
|
{
|
||||||
if (dpi == _dpi)
|
|
||||||
{
|
|
||||||
// Don't need to recalculate anything if identical.
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
auto screenDPI = _engine->GetDPI();
|
auto screenDPI = _engine->GetDPI();
|
||||||
auto bytesPerRow = screenDPI->GetBytesPerRow();
|
auto bytesPerRow = screenDPI->GetBytesPerRow();
|
||||||
auto bitsOffset = static_cast<size_t>(dpi->bits - screenDPI->bits);
|
auto bitsOffset = static_cast<size_t>(dpi->bits - screenDPI->bits);
|
||||||
|
|
Loading…
Reference in New Issue