Fix lines arise when zooming. Doesn't fix water sprites.
authorunc0rr
Sun, 31 May 2009 09:56:21 +0000
changeset 2133 1a6570dd45d8
parent 2132 370581ce983f
child 2134 cde30c8539bb
Fix lines arise when zooming. Doesn't fix water sprites.
hedgewars/uMisc.pas
--- a/hedgewars/uMisc.pas	Thu May 28 11:46:27 2009 +0000
+++ b/hedgewars/uMisc.pas	Sun May 31 09:56:21 2009 +0000
@@ -333,6 +333,8 @@
 
 glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, width, height, 0, GL_RGBA, GL_UNSIGNED_BYTE, buf);
 
+glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP);
+glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP);
 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR)
 end;
@@ -449,6 +451,8 @@
 if SDL_MustLock(surf) then
 	SDL_UnlockSurface(surf);
 
+glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP);
+glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP);
 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR)
 end;