1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-12-01 23:12:49 +02:00

Implement selection of upscaling filter in launcher

This commit is contained in:
Ivan Savenko
2024-08-03 20:14:51 +00:00
parent f29a687234
commit d6059b044d
11 changed files with 173 additions and 32 deletions

View File

@@ -10,6 +10,8 @@
#include "StdInc.h"
#include "Canvas.h"
#include "../gui/CGuiHandler.h"
#include "../render/IScreenHandler.h"
#include "../renderSDL/SDL_Extensions.h"
#include "Colors.h"
#include "IImage.h"
@@ -63,7 +65,7 @@ int Canvas::getScalingFactor() const
{
if (scalingPolicy == CanvasScalingPolicy::IGNORE)
return 1;
return 2; // TODO: get from screen handler
return GH.screenHandler().getScalingFactor();
}
Point Canvas::transformPos(const Point & input)