summaryrefslogtreecommitdiff
path: root/games-fps/quake2-icculus/files/quake2-icculus-0.16.1-x11_soft.patch
blob: cd0f2c807ae097f8787207c7bf08a7f672e2fdb1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45

the x11 software renderer just needs some tweaks to get working

--- a/Makefile
+++ b/Makefile
@@ -358,7 +358,7 @@
  endif
 
  ifeq ($(strip $(BUILD_X11)),YES)
-  $(warning Warning: Software X Renderer not supported for $(ARCH))
+  TARGETS += $(BUILDDIR)/ref_softx.$(SHLIBEXT)
  endif
 
  ifeq ($(strip $(BUILD_GLX)),YES)
--- a/src/linux/rw_x11.c
+++ b/src/linux/rw_x11.c
@@ -53,7 +53,7 @@
 #include <X11/Xatom.h>
 #include <X11/keysym.h>
 #include <X11/extensions/XShm.h>
-#include <X11/extensions/xf86dga.h>
+#include <X11/extensions/Xxf86dga.h>
 #ifdef OPENGL
 #include <X11/extensions/xf86vmode.h>
 #endif
@@ -151,7 +151,7 @@
 int config_notify_height;
 						      
 typedef unsigned short PIXEL16;
-typedef unsigned long PIXEL24;
+typedef unsigned int PIXEL24;
 #ifdef REDBLUE
 static PIXEL16 st2d_8to16table_s[2][256];
 static PIXEL24 st2d_8to24table_s[2][256];
--- a/src/ref_soft/r_poly.c
+++ b/src/ref_soft/r_poly.c
@@ -994,7 +994,7 @@
 		scale = yscale * pout->zi;
 		pout->v = (ycenter - scale * transformed[1]);
 
-		pv += sizeof (vec5_t) / sizeof (pv);
+		pv += sizeof (vec5_t) / sizeof (float);
 	}
 
 // draw it