home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-dist / at-inc-bin.lha / os-include / exec / initializers.h < prev    next >
C/C++ Source or Header  |  1993-10-15  |  805b  |  25 lines

  1. #ifndef    EXEC_INITIALIZERS_H
  2. #define    EXEC_INITIALIZERS_H
  3. /*
  4. **    $VER: initializers.h 39.0 (15.10.91)
  5. **    Includes Release 40.15
  6. **
  7. **    Macros for use with the InitStruct() function.
  8. **
  9. **    (C) Copyright 1985-1993 Commodore-Amiga, Inc.
  10. **        All Rights Reserved
  11. */
  12.  
  13. #define    OFFSET(structName, structEntry) \
  14.                 (&(((struct structName *) 0)->structEntry))
  15. #define    INITBYTE(offset,value)    0xe000,(UWORD) (offset),(UWORD) ((value)<<8)
  16. #define    INITWORD(offset,value)    0xd000,(UWORD) (offset),(UWORD) (value)
  17. #define    INITLONG(offset,value)    0xc000,(UWORD) (offset), \
  18.                 (UWORD) ((value)>>16), \
  19.                 (UWORD) ((value) & 0xffff)
  20. #define    INITSTRUCT(size,offset,value,count) \
  21.                 (UWORD) (0xc000|(size<<12)|(count<<8)| \
  22.                 ((UWORD) ((offset)>>16)), \
  23.                 ((UWORD) (offset)) & 0xffff)
  24. #endif /* EXEC_INITIALIZERS_H */
  25.