diff options
author | Johannes Schickel | 2012-10-10 00:34:30 +0200 |
---|---|---|
committer | Johannes Schickel | 2012-10-10 00:36:15 +0200 |
commit | 1e200620d673af4acdd2d128ed6e390df001aacf (patch) | |
tree | cceefecd0825bd04b96daf2b5a6ecf342465b856 /backends/platform/iphone | |
parent | a5bce746354aa5711f06de7abac442995ae0d956 (diff) | |
download | scummvm-rg350-1e200620d673af4acdd2d128ed6e390df001aacf.tar.gz scummvm-rg350-1e200620d673af4acdd2d128ed6e390df001aacf.tar.bz2 scummvm-rg350-1e200620d673af4acdd2d128ed6e390df001aacf.zip |
IPHONE: Fix cursor artifacts when linear filterting is used.
We need to set a proper texture coordinate wrap parameter for this.
Diffstat (limited to 'backends/platform/iphone')
-rw-r--r-- | backends/platform/iphone/iphone_video.mm | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/backends/platform/iphone/iphone_video.mm b/backends/platform/iphone/iphone_video.mm index 54e5d633d2..2ae1b0e692 100644 --- a/backends/platform/iphone/iphone_video.mm +++ b/backends/platform/iphone/iphone_video.mm @@ -268,6 +268,11 @@ const char *iPhone_getDocumentsDir() { glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, filter); printOpenGLError(); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, filter); printOpenGLError(); + // We use GL_CLAMP_TO_EDGE here to avoid artifacts when linear filtering + // is used. If we would not use this for example the cursor in Loom would + // have a line/border artifact on the right side of the covered rect. + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); printOpenGLError(); + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); printOpenGLError(); } - (void)setGraphicsMode { |