Enclose passed macro values in brackets to ensure correct read/write span

values.
This commit is contained in:
Alan Hourihane
2005-01-20 13:24:08 +00:00
parent cb3bc2c49a
commit ddfa61ee19
7 changed files with 33 additions and 33 deletions

View File

@@ -153,10 +153,10 @@ do { \
/* 16 bit depthbuffer functions.
*/
#define WRITE_DEPTH( _x, _y, d ) \
*(GLushort *)(buf + _x*2 + _y*pitch) = d;
*(GLushort *)(buf + (_x)*2 + (_y)*pitch) = d;
#define READ_DEPTH( d, _x, _y ) \
d = *(GLushort *)(buf + _x*2 + _y*pitch);
d = *(GLushort *)(buf + (_x)*2 + (_y)*pitch);
#define TAG(x) intel##x##_16