diff options
author | Thorbjørn Lindeijer <thorbjorn@lindeijer.nl> | 2012-07-12 23:10:37 +0200 |
---|---|---|
committer | Thorbjørn Lindeijer <thorbjorn@lindeijer.nl> | 2012-07-12 23:10:37 +0200 |
commit | 55fc460429899df2d976a11d4521eb2f6ab56367 (patch) | |
tree | 7cecc9f16227dc31a46b3d043a7f356eb8d16f63 /src/graphics.h | |
parent | 6fb4a7f6e0b793a0d3033e1ffdc31c115c8313eb (diff) | |
download | mana-55fc460429899df2d976a11d4521eb2f6ab56367.tar.gz mana-55fc460429899df2d976a11d4521eb2f6ab56367.tar.bz2 mana-55fc460429899df2d976a11d4521eb2f6ab56367.tar.xz mana-55fc460429899df2d976a11d4521eb2f6ab56367.zip |
Implemented scaling in OpenGL mode
The screen will be scaled up as much as possible, while keeping a
minimum 'virtual' resolution of 640x360.
Diffstat (limited to 'src/graphics.h')
-rw-r--r-- | src/graphics.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/graphics.h b/src/graphics.h index 6a17aab4..2e23b382 100644 --- a/src/graphics.h +++ b/src/graphics.h @@ -197,12 +197,17 @@ class Graphics : public gcn::SDLGraphics /** * Returns the width of the screen. */ - int getWidth() const; + int getWidth() const { return mWidth; } /** * Returns the height of the screen. */ - int getHeight() const; + int getHeight() const { return mHeight; } + + /** + * Returns the current scale ratio of the screen. + */ + int getScale() const { return mScale; } /** * Returns the amount of bits per pixel that was requested (not the @@ -231,6 +236,7 @@ class Graphics : public gcn::SDLGraphics protected: int mWidth; int mHeight; + int mScale; int mBpp; bool mFullscreen; bool mHWAccel; |