[Freeciv-Dev] Re: (PR#2259) GTK2 bug in tile "dithering"
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
On Sat, 16 Nov 2002, Jason Short via RT wrote:
>
> [andrearo@xxxxxxxxxxxx - Mon Oct 28 06:15:02 2002]:
>
> > The GTK2-client in 1.14.0-beta1 has a graphic-bug.
> > There are white dots between tiles. (see screenshot)
>
> I re-enabled tile blending (tile_dither()). But I cannot reproduce
> this, either with S1_14 branch, with the current CVS, or with the
> downloaded source code of the beta1 release.
>
> Why would this be?
Not all tiles have holes. Try the attached savegame.
Another problem is that the colour you see through the holes changes
depending on what was below drawn previously.
The attached patch will always paint the background white before drawing
the tiles so you can see the holes.
---
Vasco Alexandre da Silva Costa @ Instituto Superior Tecnico, Lisboa
--- client/gui-gtk-2.0/mapview.c 2 Nov 2002 21:29:20 -0000 1.11.2.3
+++ client/gui-gtk-2.0/mapview.c 16 Nov 2002 16:32:26 -0000
@@ -1151,6 +1151,18 @@
/* returns whether the tile is visible. */
if (get_canvas_xy(x, y, &canvas_x, &canvas_y)) {
+{
+ gdk_gc_set_clip_origin(fill_bg_gc, canvas_x, canvas_y);
+ gdk_gc_set_clip_mask(fill_bg_gc, sprites.black_tile->mask);
+ gdk_gc_set_foreground(fill_bg_gc, colors_standard[COLOR_STD_WHITE]);
+
+ gdk_draw_rectangle(map_canvas_store, fill_bg_gc, TRUE,
+ canvas_x+offset_x, canvas_y+offset_y,
+ MIN(width, MAX(0, sprites.black_tile->width-offset_x)),
+ MIN(height, MAX(0,
sprites.black_tile->height-offset_y)));
+ gdk_gc_set_clip_mask(fill_bg_gc, NULL);
+}
+
if (normalize_map_pos(&x, &y)) {
pixmap_put_tile_iso(map_canvas_store, x, y, canvas_x, canvas_y, 0,
offset_x, offset_y, offset_y_unit,
@@ -2192,11 +2204,9 @@
}
/*** Dither base terrain ***/
-/* Remove until fix. -vasc
if (draw_terrain)
dither_tile(pm, dither, canvas_x, canvas_y,
offset_x, offset_y, width, height, fog);
-*/
}
/*** Rest of terrain and specials ***/
tilesbug.sav.gz
Description: tilesbug.sav.gz
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Freeciv-Dev] Re: (PR#2259) GTK2 bug in tile "dithering",
Vasco Alexandre Da Silva Costa via RT <=
|
|