summaryrefslogtreecommitdiff
path: root/src/openglgraphics.cpp
diff options
context:
space:
mode:
authorBertram <bertram@cegetel.net>2009-10-09 14:10:24 +0200
committerBertram <bertram@cegetel.net>2009-10-09 14:10:24 +0200
commit79d65e08403b4a24846eac57ca9ffd1ddd92a5cd (patch)
treee40e918df2df56ed379f42276bacd606bc016770 /src/openglgraphics.cpp
parent0a3e2c75c5fcc359e257548267d5ffae6726e2db (diff)
downloadmana-79d65e08403b4a24846eac57ca9ffd1ddd92a5cd.tar.gz
mana-79d65e08403b4a24846eac57ca9ffd1ddd92a5cd.tar.bz2
mana-79d65e08403b4a24846eac57ca9ffd1ddd92a5cd.tar.xz
mana-79d65e08403b4a24846eac57ca9ffd1ddd92a5cd.zip
Final fix (or I hope so) to smooth effect in OpenGL.
Diffstat (limited to 'src/openglgraphics.cpp')
-rw-r--r--src/openglgraphics.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/openglgraphics.cpp b/src/openglgraphics.cpp
index 84ed7820..97417be7 100644
--- a/src/openglgraphics.cpp
+++ b/src/openglgraphics.cpp
@@ -226,8 +226,9 @@ bool OpenGLGraphics::drawRescaledImage(Image *image, int srcX, int srcY,
if (!image)
return false;
- // Just draw the image normally when no resizing is necessary
- if (width == desiredWidth && height == desiredHeight)
+ // Just draw the image normally when no resizing is necessary,
+ // or when the desired image is smaller than the current one.
+ if (width >= desiredWidth && height >= desiredHeight)
{
return drawImage(image, srcX, srcY, dstX, dstY, width, height, useColor);
}