Go to the documentation of this file.
37#undef CAREFUL_ALIGNMENT
42#define CAREFUL_ALIGNMENT 0
45#ifndef CAREFUL_ALIGNMENT
46#define CAREFUL_ALIGNMENT 1
49#define CVAL(buf,pos) (((unsigned char *)(buf))[pos])
50#define PVAL(buf,pos) ((unsigned)CVAL(buf,pos))
51#define SCVAL(buf,pos,val) (CVAL(buf,pos) = (val))
54#define SVAL(buf,pos) (PVAL(buf,pos)|PVAL(buf,(pos)+1)<<8)
55#define IVAL(buf,pos) (SVAL(buf,pos)|SVAL(buf,(pos)+2)<<16)
56#define SSVALX(buf,pos,val) (CVAL(buf,pos)=(val)&0xFF,CVAL(buf,pos+1)=(val)>>8)
57#define SIVALX(buf,pos,val) (SSVALX(buf,pos,val&0xFFFF),SSVALX(buf,pos+2,val>>16))
58#define SVALS(buf,pos) ((int16)SVAL(buf,pos))
59#define IVALS(buf,pos) ((int32)IVAL(buf,pos))
60#define SSVAL(buf,pos,val) SSVALX((buf),(pos),((uint16)(val)))
61#define SIVAL(buf,pos,val) SIVALX((buf),(pos),((uint32)(val)))
62#define SSVALS(buf,pos,val) SSVALX((buf),(pos),((int16)(val)))
63#define SIVALS(buf,pos,val) SIVALX((buf),(pos),((int32)(val)))
71#define SVAL(buf,pos) (*(uint16 *)((char *)(buf) + (pos)))
72#define IVAL(buf,pos) (*(uint32 *)((char *)(buf) + (pos)))
73#define SVALS(buf,pos) (*(int16 *)((char *)(buf) + (pos)))
74#define IVALS(buf,pos) (*(int32 *)((char *)(buf) + (pos)))
75#define SSVAL(buf,pos,val) SVAL(buf,pos)=((uint16)(val))
76#define SIVAL(buf,pos,val) IVAL(buf,pos)=((uint32)(val))
77#define SSVALS(buf,pos,val) SVALS(buf,pos)=((int16)(val))
78#define SIVALS(buf,pos,val) IVALS(buf,pos)=((int32)(val))
82#define SREV(x) ((((x)&0xFF)<<8) | (((x)>>8)&0xFF))
83#define IREV(x) ((SREV(x)<<16) | (SREV((x)>>16)))
85#define RSVAL(buf,pos) SREV(SVAL(buf,pos))
86#define RIVAL(buf,pos) IREV(IVAL(buf,pos))
87#define RSSVAL(buf,pos,val) SSVAL(buf,pos,SREV(val))
88#define RSIVAL(buf,pos,val) SIVAL(buf,pos,IREV(val))
Introduction
Documentation
Support
Miscellaneous
Web Site Translations
Mirrors