Author: eandry
Date: Sun Nov 5 20:34:37 2006
New Revision: 76759
Added:
packages/cooker/widelands/current/SOURCES/widelands-localepath.patch
packages/cooker/widelands/current/SOURCES/widelands-revert_terrain_breakage.diff
Removed:
packages/cooker/widelands/current/SOURCES/widelands-localepath.patch.bz2
packages/cooker/widelands/current/SOURCES/widelands-revert_terrain_breakage.diff.bz2
Modified:
packages/cooker/widelands/current/SPECS/widelands.spec
Log:
bunzip2 patches
Added: packages/cooker/widelands/current/SOURCES/widelands-localepath.patch
==============================================================================
--- (empty file)
+++ packages/cooker/widelands/current/SOURCES/widelands-localepath.patch
Sun Nov 5 20:34:37 2006
@@ -0,0 +1,11 @@
+--- src/constants.h.orig 2006-08-08 22:54:01.000000000 +0200
++++ src/constants.h 2006-08-08 22:54:35.000000000 +0200
+@@ -39,7 +39,7 @@
+ * but if widelands is installed, this changes to something like
+ * /usr/locale/share/... If so, change here
+ */
+-#define LOCALE_PATH "locale"
++#define LOCALE_PATH "/usr/share/locale"
+
+ /* \name Textures
+ * textures have a fixed size and are squares
Added:
packages/cooker/widelands/current/SOURCES/widelands-revert_terrain_breakage.diff
==============================================================================
--- (empty file)
+++
packages/cooker/widelands/current/SOURCES/widelands-revert_terrain_breakage.diff
Sun Nov 5 20:34:37 2006
@@ -0,0 +1,515 @@
+--- SConstruct
++++ SConstruct
+@@ -183,7 +183,7 @@ OPTIMIZE=0
+ SDL_PARACHUTE=1
+ if env['build']=='debug-no-parachute':
+ DEBUG=1
+- OPTIMIZE=1
++# OPTIMIZE=1
+ SDL_PARACHUTE=0
+
+ if env['build']=='debug-slow':
+@@ -191,15 +191,15 @@ if env['build']=='debug-slow':
+
+ if env['build']=='debug':
+ DEBUG=1
+- OPTIMIZE=1
++# OPTIMIZE=1
+
+ if env['build']=='profile':
+ DEBUG=1
+ PROFILE=1
+- OPTIMIZE=1
++# OPTIMIZE=1
+
+ if env['build']=='release':
+- OPTIMIZE=1
++# OPTIMIZE=1
+ # !!!! -fomit-frame-pointer breaks execeptions !!!!
+ env.Append(CCFLAGS=['-finline-functions', '-ffast-math',
'-funroll-loops'])
+ env.Append(CCFLAGS='-fexpensive-optimizations')
+
+--- src/terrain.cc
++++ src/terrain.cc
+@@ -284,8 +284,7 @@ static inline void get_horiz_linearcomb
+ mu=-u2/det;
+ }
+
+-template<typename T>
+-void render_top_triangle (Surface *dst,Texture *tex,Vertex *p1,Vertex
*p2,Vertex *p3,int y2)
++static void render_top_triangle (Surface *dst,Texture *tex,Vertex *p1,Vertex
*p2,Vertex *p3,int y2)
+ {
+ int y,y1,w,h,ix1,ix2,count;
+ int x1,x2,dx1,dx2;
+@@ -293,7 +292,7 @@ void render_top_triangle (Surface *dst,T
+ int b,db,tx,dtx,ty,dty;
+ float lambda, mu;
+ unsigned char *texpixels;
+- T *texcolormap;
++ void *texcolormap;
+
+ get_horiz_linearcomb (p2->x-p1->x, p2->y-p1->y, p3->x-p1->x,
p3->y-p1->y, lambda, mu);
+ db=ftofix((p2->b-p1->b)*lambda + (p3->b-p1->b)*mu);
+@@ -304,7 +303,7 @@ void render_top_triangle (Surface *dst,T
+ h=dst->get_h();
+
+ texpixels=tex->get_curpixels();
+- texcolormap=(T*) (tex->get_colormap());
++ texcolormap=tex->get_colormap();
+
+ y1=p1->y;
+
+@@ -340,18 +339,25 @@ void render_top_triangle (Surface *dst,T
+
+ count=ix2-ix1;
+
+- T *scanline=(T*) ((uchar*)dst->get_pixels() +
y*dst->get_pitch()) + ix1;
++ dst->lock();
++ unsigned char *scanline=(uchar*)dst->get_pixels() +
y*dst->get_pitch() + ix1*dst->get_format()->BytesPerPixel;
+
+ while (count-->0) {
+ int texel=((tx>>16) & (TEXTURE_W-1)) |
((ty>>10) & ((TEXTURE_H-1)<<6));
+
+- *scanline++=texcolormap[texpixels[texel] |
((b>>8) & 0xFF00)];
++ if( dst->get_format()->BytesPerPixel == 2 )
++ *((ushort*)(scanline))=((ushort*)texcolormap)[texpixels[texel]
| ((b>>8) & 0xFF00)];
++ else
++ *((ulong*)(scanline))=((ulong*)texcolormap)[texpixels[texel] |
((b>>8) & 0xFF00)];
++ scanline += dst->get_format()->BytesPerPixel;
+
+ b+=db;
+ tx+=dtx;
+ ty+=dty;
+ }
+ }
++
++ dst->unlock();
+
+ x1+=dx1;
+ x2+=dx2;
+@@ -361,8 +367,7 @@ void render_top_triangle (Surface *dst,T
+ }
+ }
+
+-template<typename T>
+-void render_bottom_triangle (Surface* dst,Texture *tex,Vertex *p1,Vertex
*p2,Vertex *p3,int y1)
++static void render_bottom_triangle (Surface* dst,Texture *tex,Vertex
*p1,Vertex *p2,Vertex *p3,int y1)
+ {
+ int y,y2,w,h,ix1,ix2,count;
+ int x1,x2,dx1,dx2;
+@@ -370,7 +375,7 @@ void render_bottom_triangle (Surface* ds
+ int b,db,tx,dtx,ty,dty;
+ float lambda, mu;
+ unsigned char *texpixels;
+- T *texcolormap;
++ void *texcolormap;
+
+ get_horiz_linearcomb (p2->x-p1->x, p2->y-p1->y, p3->x-p1->x,
p3->y-p1->y, lambda, mu);
+ db=ftofix((p2->b-p1->b)*lambda + (p3->b-p1->b)*mu);
+@@ -381,7 +386,7 @@ void render_bottom_triangle (Surface* ds
+ h=dst->get_h();
+
+ texpixels=tex->get_curpixels();
+- texcolormap=(T*) (tex->get_colormap());
++ texcolormap=tex->get_colormap();
+
+ y2=p3->y;
+
+@@ -421,12 +426,17 @@ void render_bottom_triangle (Surface* ds
+
+ count=ix2-ix1;
+
+- T* scanline=(T*) ((uchar*)dst->get_pixels() +
y*dst->get_pitch()) + ix1;
++ unsigned char* scanline=(uchar*)dst->get_pixels() +
y*dst->get_pitch() + ix1*dst->get_format()->BytesPerPixel;
+
+ while (count-->0) {
+ int texel=((tx>>16) & (TEXTURE_W-1)) |
((ty>>10) & ((TEXTURE_H-1)<<6));
+
+- *scanline++=texcolormap[texpixels[texel] |
((b>>8) & 0xFF00)];
++ if (dst->get_format()->BytesPerPixel == 2)
++ *((ushort*)(scanline))=((ushort*)texcolormap)[texpixels[texel]
| ((b>>8) & 0xFF00)];
++ else
++ *((ulong*)(scanline))=((ulong*)texcolormap)[texpixels[texel] |
((b>>8) & 0xFF00)];
++
++ scanline += dst->get_format()->BytesPerPixel;
+
+ b+=db;
+ tx+=dtx;
+@@ -451,8 +461,7 @@ void render_bottom_triangle (Surface* ds
+ * render_bottom_triangle, which require a horizontal edge at the bottom
+ * or at the top, respectively.
+ */
+-template<typename T>
+-void render_triangle (Surface* dst,Vertex *p1,Vertex *p2,Vertex *p3, Texture
*tex)
++static void render_triangle (Surface* dst,Vertex *p1,Vertex *p2,Vertex *p3,
Texture *tex)
+ {
+ Vertex *p[3]={ p1,p2,p3 };
+ int top,bot,mid,y,ym,i;
+@@ -472,16 +481,16 @@ void render_triangle (Surface* dst,Verte
+
+ if (p[top]->y < ym) {
+ if (p[mid]->x < p[bot]->x)
+- render_top_triangle<T>
(dst,tex,p[top],p[mid],p[bot],ym);
++ render_top_triangle (dst,tex,p[top],p[mid],p[bot],ym);
+ else
+- render_top_triangle<T>
(dst,tex,p[top],p[bot],p[mid],ym);
++ render_top_triangle (dst,tex,p[top],p[bot],p[mid],ym);
+ }
+
+ if (ym < p[bot]->y) {
+ if (p[mid]->x < p[top]->x)
+- render_bottom_triangle<T>
(dst,tex,p[mid],p[top],p[bot],ym);
++ render_bottom_triangle
(dst,tex,p[mid],p[top],p[bot],ym);
+ else
+- render_bottom_triangle<T>
(dst,tex,p[top],p[mid],p[bot],ym);
++ render_bottom_triangle
(dst,tex,p[top],p[mid],p[bot],ym);
+ }
+ }
+
+@@ -511,16 +520,15 @@ #define DITHER_WIDTH 4
+ #define DITHER_RAND_MASK (DITHER_WIDTH*2-1)
+ #define DITHER_RAND_SHIFT (16/DITHER_WIDTH)
+
+-template<typename T>
+-void dither_edge_horiz (Surface* dst, const Vertex& start, const Vertex& end,
Texture* ttex, Texture* btex)
++static void dither_edge_horiz (Surface* dst, const Vertex& start, const
Vertex& end, Texture* ttex, Texture* btex)
+ {
+ unsigned char *tpixels, *bpixels;
+- T *tcolormap, *bcolormap;
++ void *tcolormap, *bcolormap;
+
+ tpixels=ttex->get_curpixels();
+- tcolormap=(T*) (ttex->get_colormap());
++ tcolormap=ttex->get_colormap();
+ bpixels=btex->get_curpixels();
+- bcolormap=(T*) (btex->get_colormap());
++ bcolormap=btex->get_colormap();
+
+ int tx,ty,b,dtx,dty,db,tx0,ty0;
+
+@@ -554,10 +562,14 @@ void dither_edge_horiz (Surface* dst, co
+ // dither above the edge
+ for (unsigned int i = 0; i < DITHER_WIDTH; i++, y++) {
+ if ((rnd0&DITHER_RAND_MASK)<=i && y>=0 &&
y<dsth) {
+- T *pix = (T*)
((uchar*)dst->get_pixels() + y*dst->get_pitch()) + x;
++ uchar *pix = (uchar*)dst->get_pixels()
+ y*dst->get_pitch() + x*dst->get_format()->BytesPerPixel;
+ int texel=((tx0>>16) & (TEXTURE_W-1)) |
((ty0>>10) & ((TEXTURE_H-1)<<6));
+- *pix=tcolormap[tpixels[texel] | ((b>>8)
& 0xFF00)];
+- }
++ if( dst->get_format()->BytesPerPixel == 2 )
++ *((ushort*)(pix))=((ushort*)tcolormap)[tpixels[texel] |
((b>>8) & 0xFF00)];
++ else
++ *((ulong*)(pix))=((ulong*)tcolormap)[tpixels[texel] |
((b>>8) & 0xFF00)];
++
++ }
+
+ tx0+=dty;
+ ty0-=dtx;
+@@ -567,10 +579,14 @@ void dither_edge_horiz (Surface* dst, co
+ // dither below the edge
+ for (unsigned int i = 0; i < DITHER_WIDTH; i++, y++) {
+ if ((rnd0&DITHER_RAND_MASK)>=i+DITHER_WIDTH &&
y>=0 && y<dsth) {
+- T *pix = (T*)
((uchar*)dst->get_pixels() + y*dst->get_pitch()) + x;
+- int texel=((tx0>>16) & (TEXTURE_W-1)) |
((ty0>>10) & ((TEXTURE_H-1)<<6));
+- *pix=bcolormap[bpixels[texel] | ((b>>8)
& 0xFF00)];
+- }
++ uchar *pix = (uchar*)dst->get_pixels() +
y*dst->get_pitch() + x*dst->get_format()->BytesPerPixel;
++ int texel=((tx0>>16) & (TEXTURE_W-1)) |
((ty0>>10) & ((TEXTURE_H-1)<<6));
++ if( dst->get_format()->BytesPerPixel == 2 )
++ *((ushort*)(pix))=((ushort*)bcolormap)[bpixels[texel] |
((b>>8) & 0xFF00)];
++ else
++ *((ulong*)(pix))=((ulong*)bcolormap)[bpixels[texel] |
((b>>8) & 0xFF00)];
++
++ }
+
+ tx0+=dty;
+ ty0-=dtx;
+@@ -585,16 +601,15 @@ void dither_edge_horiz (Surface* dst, co
+ }
+
+
+-template<typename T>
+ static void dither_edge_vert (Surface* dst, const Vertex& start, const
Vertex& end, Texture* ltex, Texture* rtex)
+ {
+ unsigned char *lpixels, *rpixels;
+- T* lcolormap, *rcolormap;
++ void* lcolormap, *rcolormap;
+
+ lpixels=ltex->get_curpixels();
+- lcolormap=(T*) (ltex->get_colormap());
++ lcolormap=ltex->get_colormap();
+ rpixels=rtex->get_curpixels();
+- rcolormap=(T*) (rtex->get_colormap());
++ rcolormap=rtex->get_colormap();
+
+ int tx,ty,b,dtx,dty,db,tx0,ty0;
+
+@@ -628,10 +643,14 @@ static void dither_edge_vert (Surface* d
+ // dither on left side
+ for (unsigned int i = 0; i < DITHER_WIDTH; i++, x++) {
+ if ((rnd0&DITHER_RAND_MASK)<=i && x>=0 &&
x<dstw) {
+- T *pix = (T*)
((uchar*)dst->get_pixels() + y*dst->get_pitch()) + x;
++ uchar *pix = (uchar*)dst->get_pixels()
+ y*dst->get_pitch() + x*dst->get_format()->BytesPerPixel;
+ int texel=((tx0>>16) & (TEXTURE_W-1)) |
((ty0>>10) & ((TEXTURE_H-1)<<6));
+- *pix=lcolormap[lpixels[texel] | ((b>>8)
& 0xFF00)];
+- }
++ if( dst->get_format()->BytesPerPixel == 2 )
++ *((ushort*)(pix))=((ushort*)lcolormap)[lpixels[texel] |
((b>>8) & 0xFF00)];
++ else
++ *((ulong*)(pix))=((ulong*)lcolormap)[lpixels[texel] |
((b>>8) & 0xFF00)];
++
++ }
+
+ tx0+=dty;
+ ty0-=dtx;
+@@ -641,10 +660,14 @@ static void dither_edge_vert (Surface* d
+ // dither on right side
+ for (unsigned int i = 0; i < DITHER_WIDTH; i++, x++) {
+ if ((rnd0 & DITHER_RAND_MASK)>=i+DITHER_WIDTH
&& x>=0 && x<dstw) {
+- T *pix = (T*)
((uchar*)dst->get_pixels() + y*dst->get_pitch()) + x;
++ uchar *pix = (uchar*)dst->get_pixels()
+ y*dst->get_pitch() + x*dst->get_format()->BytesPerPixel;
+ int texel=((tx0>>16) & (TEXTURE_W-1)) |
((ty0>>10) & ((TEXTURE_H-1)<<6));
+- *pix=rcolormap[rpixels[texel] | ((b>>8)
& 0xFF00)];
+- }
++ if( dst->get_format()->BytesPerPixel == 2 )
++ *((ushort*)(pix))=((ushort*)rcolormap)[rpixels[texel] |
((b>>8) & 0xFF00)];
++ else
++ *((ulong*)(pix))=((ulong*)rcolormap)[rpixels[texel] |
((b>>8) & 0xFF00)];
++
++ }
+
+ tx0+=dty;
+ ty0-=dtx;
+@@ -667,8 +690,7 @@ render_road_vert
+ Render a road.
+ ===============
+ */
+-template<typename T>
+-void render_road_horiz(Surface* dst, const Point& start, const Point& end,
Surface* src )
++static void render_road_horiz(Surface* dst, const Point& start, const Point&
end, Surface* src )
+ {
+ int dstw = dst->get_w();
+ int dsth = dst->get_h();
+@@ -686,15 +708,20 @@ void render_road_horiz(Surface* dst, con
+ if (y < 0 || y >= dsth)
+ continue;
+
+- T* dpix = (T*)((uchar*)dst->get_pixels() +
y*dst->get_pitch()) + x;
+- T* spix = (T*)((uchar*)src->get_pixels() +
i*src->get_pitch()) + sx;
+- *dpix = *spix;
++ if( dst->get_format()->BytesPerPixel == 2) {
++ ushort* dpix =
(ushort*)((uchar*)dst->get_pixels() + y*dst->get_pitch() +
x*dst->get_format()->BytesPerPixel);
++ ushort* spix =
(ushort*)((uchar*)src->get_pixels() + i*src->get_pitch() +
sx*src->get_format()->BytesPerPixel);
++ *dpix = *spix;
++ } else {
++ ulong* dpix =
(ulong*)((uchar*)dst->get_pixels() + y*dst->get_pitch() +
x*dst->get_format()->BytesPerPixel);
++ ulong* spix =
(ulong*)((uchar*)src->get_pixels() + i*src->get_pitch() +
sx*src->get_format()->BytesPerPixel);
++ *dpix = *spix;
++ }
+ }
+ }
+ }
+
+-template<typename T>
+-void render_road_vert(Surface* dst, const Point& start, const Point& end,
Surface* src)
++static void render_road_vert(Surface* dst, const Point& start, const Point&
end, Surface* src)
+ {
+ int dstw = dst->get_w();
+ int dsth = dst->get_h();
+@@ -708,28 +735,43 @@ void render_road_vert(Surface* dst, cons
+
+ int x = (centerx >> 16) - 2;
+
+- for(int i = 0; i < 5; i++, x++) {
+- if (x < 0 || x >= dstw)
+- continue;
+-
+-
+- T* dpix = (T*)((uchar*)dst->get_pixels() +
y*dst->get_pitch()) + x;
+- T* spix = (T*)((uchar*)src->get_pixels() +
sy*src->get_pitch()) + i;
+- *dpix = *spix;
+- }
++ for(int i = 0; i < 5; i++, x++) {
++ if (x < 0 || x >= dstw)
++ continue;
++
++
++ if( dst->get_format()->BytesPerPixel == 2) {
++ ushort* dpix =
(ushort*)((uchar*)dst->get_pixels() + y*dst->get_pitch() +
x*dst->get_format()->BytesPerPixel);
++ ushort* spix =
(ushort*)((uchar*)src->get_pixels() + sy*src->get_pitch() +
i*src->get_format()->BytesPerPixel);
++ *dpix = *spix;
++ } else {
++ ulong* dpix =
(ulong*)((uchar*)dst->get_pixels() + y*dst->get_pitch() +
x*dst->get_format()->BytesPerPixel);
++ ulong* spix =
(ulong*)((uchar*)src->get_pixels() + sy*src->get_pitch() +
i*src->get_format()->BytesPerPixel);
++ *dpix = *spix;
++ }
++ }
+ }
+ }
+
+
+-template<typename T>
+-void draw_field_int(Surface* dst, Field * const f, Field * const rf, Field *
const fl, Field * const rfl,
+- Field * const lf, Field * const ft,
+- const int posx, const int rposx, const int posy,
+- const int blposx, const int rblposx, const int blposy,
+- uchar roads, uchar darken, bool draw_all)
++/*
++===============
++Surface::draw_field
++
++Draw ground textures and roads for the given parallelogram (two triangles)
++into the bitmap.
++===============
++*/
++void Surface::draw_field(Rect& subwin, Field * const f, Field * const rf,
Field * const fl, Field * const rfl,
++ Field * const lf, Field * const ft,
++ const int posx, const int rposx, const int posy,
++ const int blposx, const int rblposx, const int blposy,
++ uchar roads, uchar darken, bool draw_all)
+ {
+ Vertex r, l, br, bl;
+
++ set_subwin( subwin );
++
+ r = Vertex(rposx, posy - rf->get_height() * HEIGHT_FACTOR,
rf->get_brightness(), 0, 0);
+ l = Vertex(posx, posy - f->get_height() * HEIGHT_FACTOR,
f->get_brightness(), 64, 0);
+ br = Vertex(rblposx, blposy - rfl->get_height() * HEIGHT_FACTOR,
rfl->get_brightness(), 0, 64);
+@@ -748,17 +790,19 @@ void draw_field_int(Surface* dst, Field
+ Texture* ltex =
get_graphicimpl()->get_maptexture_data(lf->get_terr()->get_texture());
+ Texture* ttex =
get_graphicimpl()->get_maptexture_data(ft->get_terd()->get_texture());
+
+- if( draw_all ) {
+- render_triangle<T> (dst, &r, &l, &br, rtex);
+- render_triangle<T> (dst, &l, &br, &bl, btex);
+- } else {
+- if( rtex->was_animated())
+- render_triangle<T> (dst, &r, &l, &br, rtex);
+- if( btex->was_animated())
+- render_triangle<T>(dst, &l, &br, &bl, btex);
+- }
+-
+- // Render roads and dither polygon edges
++ if( draw_all ) {
++ render_triangle(this, &r, &l, &br, rtex);
++ render_triangle(this, &l, &br, &bl, btex);
++ } else {
++ if( rtex->was_animated()) {
++ render_triangle(this, &r, &l, &br, rtex);
++ }
++ if( btex->was_animated()) {
++ render_triangle(this, &l, &br, &bl, btex);
++ }
++ }
++
++ // Render roads and dither polygon edges
+ uchar road;
+
+ road = (roads >> Road_East) & Road_Mask;
+@@ -766,10 +810,10 @@ void draw_field_int(Surface* dst, Field
+ if (road) {
+ switch(road) {
+ case Road_Normal:
+- render_road_horiz<T> (dst, l, r,
rt_normal);
++ render_road_horiz(this, l, r,
rt_normal);
+ break;
+ case Road_Busy:
+- render_road_horiz<T> (dst, l, r,
rt_busy);
++ render_road_horiz(this, l, r, rt_busy);
+ break;
+ default:
+ assert(0); break; // never here
+@@ -778,7 +822,7 @@ void draw_field_int(Surface* dst, Field
+ else {
+ if( draw_all || rtex->was_animated() ||
ttex->was_animated())
+ if (rtex!=0 && ttex!=0 && rtex!=ttex)
+- dither_edge_horiz<T> (dst, l, r, rtex,
ttex);
++ dither_edge_horiz(this, l, r, rtex,
ttex);
+ }
+ }
+
+@@ -787,10 +831,10 @@ void draw_field_int(Surface* dst, Field
+ if (road) {
+ switch(road) {
+ case Road_Normal:
+- render_road_vert<T> (dst, l, br,
rt_normal);
++ render_road_vert(this, l, br,
rt_normal);
+ break;
+ case Road_Busy:
+- render_road_vert<T> (dst, l, br,
rt_busy);
++ render_road_vert(this, l, br, rt_busy);
+ break;
+ default:
+ assert(0); break; // never here
+@@ -799,7 +843,7 @@ void draw_field_int(Surface* dst, Field
+ else {
+ if( draw_all || rtex->was_animated() ||
btex->was_animated())
+ if (rtex!=0 && btex!=0 && rtex!=btex)
+- dither_edge_vert<T> (dst, l, br, rtex,
btex);
++ dither_edge_vert(this, l, br, rtex,
btex);
+ }
+ }
+
+@@ -808,54 +852,24 @@ void draw_field_int(Surface* dst, Field
+ if (road) {
+ switch(road) {
+ case Road_Normal:
+- render_road_vert<T> (dst, l, bl,
rt_normal);
++ render_road_vert(this, l, bl,
rt_normal);
+ break;
+ case Road_Busy:
+- render_road_vert<T> (dst, l, bl,
rt_busy);
++ render_road_vert(this, l, bl, rt_busy);
+ break;
+ default:
+ assert(0); break; // never here
+ }
+ }
+ else {
+- if( draw_all || btex->was_animated() ||
ltex->was_animated())
+- if (ltex!=0 && btex!=0 && ltex!=btex)
+- dither_edge_vert<T>(dst, l, bl, btex,
ltex);
+- }
++ if( draw_all || btex->was_animated() || ltex->was_animated())
++ if (ltex!=0 && btex!=0 && ltex!=btex)
++ dither_edge_vert(this, l, bl, btex, ltex);
++ }
+ }
+
+ // FIXME: similar textures may not need dithering
+-}
+-
+-/*
+-===============
+-Surface::draw_field
+-
+-Draw ground textures and roads for the given parallelogram (two triangles)
+-into the bitmap.
+-===============
+-*/
+-void Surface::draw_field(Rect& subwin, Field * const f, Field * const rf,
Field * const fl, Field * const rfl,
+- Field * const lf, Field * const ft,
+- const int posx, const int rposx, const int posy,
+- const int blposx, const int rblposx, const int blposy,
+- uchar roads, uchar darken, bool draw_all)
+-{
+- set_subwin( subwin );
+-
+- switch (get_format()->BytesPerPixel) {
+- case 2:
+- draw_field_int<ushort>
+- (this, f, rf, fl, rfl, lf, ft, posx, rposx, posy, blposx,
rblposx, blposy, roads, darken, draw_all);
+- break;
+- case 4:
+- draw_field_int<ulong>
+- (this, f, rf, fl, rfl, lf, ft, posx, rposx, posy, blposx,
rblposx, blposy, roads, darken, draw_all);
+- break;
+- default:
+- assert (0);
+- }
+-
+- unset_subwin();
++
++ unset_subwin();
+ }
+
Modified: packages/cooker/widelands/current/SPECS/widelands.spec
==============================================================================
--- packages/cooker/widelands/current/SPECS/widelands.spec (original)
+++ packages/cooker/widelands/current/SPECS/widelands.spec Sun Nov 5
20:34:37 2006
@@ -1,7 +1,7 @@
%define name widelands
%define version b9half
%define cvs cvs20060725
-%define release %mkrel 6
+%define release %mkrel 7
%define Summary Settlers II clone
Name: %{name}
@@ -9,8 +9,8 @@
Release: %{release}
URL: http://widelands.sourceforge.net/
Source0: %{name}-%{version}.tar.bz2
-Patch0: widelands-revert_terrain_breakage.diff.bz2
-Patch1: widelands-localepath.patch.bz2
+Patch0: widelands-revert_terrain_breakage.diff
+Patch1: widelands-localepath.patch
License: GPL
Group: Games/Strategy
Summary: %{Summary}