From: Andy Spencer Date: Wed, 3 Feb 2010 02:12:36 +0000 (+0000) Subject: map: colormap for cities and linear texture filtering X-Git-Tag: v0.4~99 X-Git-Url: http://pileus.org/git/?p=grits;a=commitdiff_plain;h=4893dd3bdb2b724d3d3234e369f4ad414fe5cecb map: colormap for cities and linear texture filtering --- diff --git a/src/plugins/map.c b/src/plugins/map.c index e30975f..b39ae34 100644 --- a/src/plugins/map.c +++ b/src/plugins/map.c @@ -32,6 +32,7 @@ const guchar colormap[][2][4] = { {{0xf6, 0xee, 0xee}, {0xf6, 0xee, 0xee, 0x00}}, // Ground {{0xff, 0xff, 0xff}, {0xff, 0xff, 0xff, 0xff}}, // Borders {{0x73, 0x93, 0xad}, {0x73, 0x93, 0xad, 0x40}}, // Lakes + {{0xff, 0xe1, 0x80}, {0xff, 0xe1, 0x80, 0x60}}, // Cities }; struct _LoadTileData { @@ -78,8 +79,8 @@ static gboolean _load_tile_cb(gpointer _data) glPixelStorei(GL_PACK_ALIGNMENT, 1); glTexImage2D(GL_TEXTURE_2D, 0, 4, width, height, 0, (alpha ? GL_RGBA : GL_RGB), GL_UNSIGNED_BYTE, pixels); - glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST); - glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST); + glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR); + glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_BORDER); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_BORDER); glFlush();