summaryrefslogtreecommitdiff
path: root/fb/fb.h
diff options
context:
space:
mode:
authorAaron Plattner <aplattner@nvidia.com>2006-07-25 15:27:31 -0700
committerAaron Plattner <aplattner@nvidia.com>2006-07-26 15:48:51 -0700
commit377a581ddf5e428a368efb1b59fcb317666fecdd (patch)
tree73b0df492e4a6ba8ad6da3ff8fa4717987eb295c /fb/fb.h
parenta4005c15fbb48231cb958c32b2c791a2d23a135a (diff)
Switch to using void* pointers.
Pass the size of the data pointed to by src or dst as an argument to wfb{Read,Write}Memory. This allows one set of macros to be used with any size pointer. Assumes that sizeof(FbBits) >= sizeof(FbStip).
Diffstat (limited to 'fb/fb.h')
-rw-r--r--fb/fb.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/fb/fb.h b/fb/fb.h
index 13783d36d..22ed4f78a 100644
--- a/fb/fb.h
+++ b/fb/fb.h
@@ -47,8 +47,8 @@
#ifdef FB_ACCESS_WRAPPER
#include "wfbrename.h"
#define FBPREFIX(x) wfb##x
-#define WRITE(ptr, val) ((*wfbWriteMemory)(ptr, val))
-#define READ(ptr) ((*wfbReadMemory)(ptr))
+#define WRITE(ptr, val) ((*wfbWriteMemory)(ptr, val, sizeof(*ptr)))
+#define READ(ptr) ((*wfbReadMemory)(ptr, sizeof(*ptr)))
#else
#define FBPREFIX(x) fb##x
#define WRITE(ptr, val) (*(ptr) = (val))
@@ -601,8 +601,8 @@ extern WindowPtr *WindowTable;
/* Framebuffer access wrapper */
#ifdef FB_ACCESS_WRAPPER
-typedef FbBits (*ReadMemoryProcPtr)(FbBits *src);
-typedef void (*WriteMemoryProcPtr)(FbBits *dst, FbBits value);
+typedef FbBits (*ReadMemoryProcPtr)(void *src, int size);
+typedef void (*WriteMemoryProcPtr)(void *dst, FbBits value, int size);
typedef void (*SetupWrapProcPtr)(ReadMemoryProcPtr *pRead,
WriteMemoryProcPtr *pWrite,
PixmapPtr pPixmap);