Lines Matching +full:depth +full:-
1 diff -Nrup rubix-1.0.5/fillpoly.c rubix-1.0.5-avr32/fillpoly.c
2 --- rubix-1.0.5/fillpoly.c 2003-10-12 15:41:43.000000000 -0400
3 +++ rubix-1.0.5-avr32/fillpoly.c 2008-02-29 12:39:51.000000000 -0500
4 @@ -435,7 +435,7 @@ void fill_lines(device *d, int thecol)
8 - } else if (d->depth==16) { /* here 16bpp */
9 + } else if ((d->depth==16) | (d->depth==15)) { /* here 16bpp */
13 diff -Nrup rubix-1.0.5/line.c rubix-1.0.5-avr32/line.c
14 --- rubix-1.0.5/line.c 2003-10-12 14:15:19.000000000 -0400
15 +++ rubix-1.0.5-avr32/line.c 2008-02-29 12:39:51.000000000 -0500
16 @@ -1317,7 +1317,7 @@ void drawline(device *d, line *l)
18 if (d->depth==8)
20 - else if (d->depth==16)
21 + else if ((d->depth==16) | (d->depth==15))
23 else if (d->depth==24)
25 diff -Nrup rubix-1.0.5/Makefile rubix-1.0.5-avr32/Makefile
26 --- rubix-1.0.5/Makefile 2003-12-04 14:27:58.000000000 -0500
27 +++ rubix-1.0.5-avr32/Makefile 2008-02-29 12:58:30.000000000 -0500
28 @@ -11,21 +11,17 @@
32 -GAMESDIR=/usr/games
34 #architecture=-DPC_ARCHI
37 #EXTRALIBS=-lsocket
39 -CC=gcc
40 CFLAGS=-Wall -O3 -fomit-frame-pointer -ffast-math \
41 -DGAMESDIR="\"$(GAMESDIR)\"" \
42 -D$(LANGUAGE) $(architecture)
44 #CFLAGS=-Wall -g -ffast-math -Iplayer $(architecture)
45 -XINC=-I/usr/X11R6/include
46 -XLIB=-L/usr/X11R6/lib -lX11
50 @@ -37,7 +33,7 @@ rubix : $(OBJ)
53 mkdir -p $(GAMESDIR)
54 - install -c -s rubix $(GAMESDIR)
55 + install -c rubix $(GAMESDIR)
58 rm -f *.o *~ core *.bak *.dat gmon.out
59 diff -Nrup rubix-1.0.5/screen.c rubix-1.0.5-avr32/screen.c
60 --- rubix-1.0.5/screen.c 2004-04-26 04:26:05.000000000 -0400
61 +++ rubix-1.0.5-avr32/screen.c 2008-02-29 12:39:51.000000000 -0500
62 @@ -80,11 +80,17 @@ void error_statement(SCREEN *s)
68 if (s->im)
69 XDestroyImage(s->im);
70 + if (s->depth == 15) {
73 + temp=s->depth;
76 - s->buffer=(char *)malloc(((SCREEN_X+7)/8)*SCREEN_Y*s->depth);
77 + s->buffer=(char *)malloc(((SCREEN_X+7)/8)*SCREEN_Y*temp);
79 if (!s->buffer) {
81 @@ -106,7 +112,7 @@ int reset_data_buffers(SCREEN *s)
83 /* Sed - december 2003 - no it has to be 8 */
84 s->im=XCreateImage(s->d, DefaultVisual(s->d, DefaultScreen(s->d)),
85 - s->depth==32?24:s->depth, ZPixmap,
86 + s->depth, ZPixmap,
87 0, s->buffer, SCREEN_X, SCREEN_Y, 8, 0);
89 if (!s->im) {
90 @@ -139,8 +145,8 @@ int init_screen(SCREEN *s)
92 s->depth=DefaultDepth(s->d, DefaultScreen(s->d));
94 - if (s->depth!=8 && s->depth!=16 && s->depth!=24) {
95 - fprintf(stderr, "screen depth not supported (only 8, 16 and 24bpp (which means 32bpp too) hand…
96 + if (s->depth!=8 && s->depth!=15 && s->depth!=16 && s->depth!=24) {
97 + fprintf(stderr, "screen depth not supported (only 8, 15, 16 and 24bpp (which means 32bpp too) …
98 XCloseDisplay(s->d);
99 s->d=(Display *)0;
100 return -1;
101 @@ -182,10 +188,10 @@ int init_screen(SCREEN *s)
104 s->w=XCreateWindow(s->d, DefaultRootWindow(s->d), 0, 0,
105 - SCREEN_X, SCREEN_Y, 3, s->depth==32?24:s->depth,
106 + SCREEN_X, SCREEN_Y, 3, s->depth,
108 s->h=XCreateWindow(s->d, DefaultRootWindow(s->d), 0, 0,
109 - HELP_X, HELP_Y, 3, s->depth==32?24:s->depth,
110 + HELP_X, HELP_Y, 3, s->depth,
114 @@ -946,13 +952,18 @@ void close_screen(SCREEN *s)
117 /* fill s->im with pixel[10], avoid XPutPixel which is rather slow... */
118 - int i, w, dw;
120 + if (s->depth == 15) {
123 + temp = s->depth;
126 - dw = s->depth/8;
128 XPutPixel(s->im, 0, 0, pixel[10]);
130 memcpy(s->buffer + i*dw, s->buffer, dw);
131 - w = w * s->depth;
134 memcpy(s->buffer + i*w, s->buffer, w);