I'm working on a game with 32px tiles and I have one question regarding this and scaling. When I try to see my game fullscreen my image just becomes blurry. I remember playing NES games and when the image was scaled you just saw pixels as big blocks but they were still as crisp as when they were small, so I'm wondering how I can do this in SDL.
Answer
As far as I know, this is not a standard feature of SDL. It is (if I remember correctly) a feature in SDL2_gfx(an extension library made specifically for linux) and OpenGL.
However, if you would like to multiply your image's size by a whole number (n), you could do so by reading each pixel and assigning that color value to a square that is (n)-times larger than a single pixel. This would work best for small sprites, rather than large and complex images. I have not implemented this myself, but theoretically it sounds straight-forward.
No comments:
Post a Comment