1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-25 22:42:04 +02:00

Remove access to internal surface of Canvas

This commit is contained in:
Ivan Savenko
2025-01-16 15:09:03 +00:00
parent 4a600a9d4c
commit 668bf63fc0
34 changed files with 275 additions and 174 deletions

View File

@@ -60,7 +60,7 @@ void CursorHardware::setImage(std::shared_ptr<IImage> image, const Point & pivot
CSDL_Ext::fillSurface(cursorSurface, CSDL_Ext::toSDL(Colors::TRANSPARENCY));
image->draw(cursorSurface, Point(0,0), nullptr, GH.screenHandler().getScalingFactor());
auto cursorSurfaceScaled = CSDL_Ext::scaleSurface(cursorSurface, cursorDimensionsScaled.x, cursorDimensionsScaled.y );
auto cursorSurfaceScaled = CSDL_Ext::scaleSurface(cursorSurface, cursorDimensionsScaled.x, cursorDimensionsScaled.y, EScalingAlgorithm::BILINEAR );
auto oldCursor = cursor;
cursor = SDL_CreateColorCursor(cursorSurfaceScaled, pivotOffsetScaled.x, pivotOffsetScaled.y);