aboutsummaryrefslogtreecommitdiff
path: root/backends/platform/iphone
diff options
context:
space:
mode:
authorJohannes Schickel2012-02-20 22:21:20 +0100
committerJohannes Schickel2012-02-21 18:54:26 +0100
commitcc8a6cc993b8f6215cb80afa07278b3e5ab5d88f (patch)
tree9ec6af1a09fff8d437202e9d83c93072162774a2 /backends/platform/iphone
parentaa42d78658eacc17a36ffe0d86541deffa534f79 (diff)
downloadscummvm-rg350-cc8a6cc993b8f6215cb80afa07278b3e5ab5d88f.tar.gz
scummvm-rg350-cc8a6cc993b8f6215cb80afa07278b3e5ab5d88f.tar.bz2
scummvm-rg350-cc8a6cc993b8f6215cb80afa07278b3e5ab5d88f.zip
IPHONE: Add _overlayRect, which describes the overlay screen rect.
Diffstat (limited to 'backends/platform/iphone')
-rw-r--r--backends/platform/iphone/iphone_video.m5
1 files changed, 4 insertions, 1 deletions
diff --git a/backends/platform/iphone/iphone_video.m b/backends/platform/iphone/iphone_video.m
index d5002ff3d2..f60d7de12d 100644
--- a/backends/platform/iphone/iphone_video.m
+++ b/backends/platform/iphone/iphone_video.m
@@ -40,6 +40,7 @@ static int _overlayTexWidth = 0;
static int _overlayTexHeight = 0;
static int _overlayWidth = 0;
static int _overlayHeight = 0;
+static CGRect _overlayRect;
static float _overlayPortraitRatio = 1.0f;
static int _needsScreenUpdate = 0;
@@ -628,9 +629,11 @@ static void setFilterModeForTexture(GLuint tex, GraphicsModes mode) {
[self addSubview:[_keyboardView inputView]];
[self addSubview: _keyboardView];
[[_keyboardView inputView] becomeFirstResponder];
- _overlayPortraitRatio = (_overlayHeight * ratio) / _overlayWidth;
+ overlayPortraitRatio = (_overlayHeight * ratio) / _overlayWidth;
}
+ _overlayRect = CGRectMake(0, 0, _renderBufferWidth, _renderBufferHeight * overlayPortraitRatio);
+
_gameScreenVertCoords[0] = _heightOffset;
_gameScreenVertCoords[1] = _widthOffset;
_gameScreenVertCoords[2] = _visibleWidth - _heightOffset;