home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 594b.lha / Precognition_rel1 / Precognition3D.h < prev    next >
C/C++ Source or Header  |  1991-12-12  |  3KB  |  102 lines

  1. #ifndef PRECOGNITION3D_H
  2. #define PRECOGNITION3D_H
  3.  
  4. #include "intuition_typedefs.h"
  5.  
  6.  
  7. typedef struct pcg_3DPens
  8.    {
  9.       UBYTE FrontPen,   BackPen;    /* Foreground Pen, Background Pen */
  10.       UBYTE BrightPen,  DarkPen;    /* 3D Highlight, shadow.          */
  11.    } pcg_3DPens;
  12.  
  13.  
  14. /* ==================== pcg_3DBox ============================
  15. ** This type is compatible with a 'Border' structure.
  16. ** It is used to create a 3D looking box, like under
  17. ** Workbench 2.0.  It consists of 2 Border structures linked
  18. ** together.
  19. ** ===========================================================
  20. */
  21.  
  22. typedef struct pcg_3DBox
  23.    {
  24.       Border     TopLeft;       /* Top & Left edge of box.     */
  25.       Border     BottomRight;   /* Bottom & right edge of box. */
  26.       SHORT      Points[20];    /* Box outline.                */
  27.    } pcg_3DBox;
  28.  
  29. /* ======================= pcg_3DBevel ========================
  30. ** This type is compatible with a 'Border' structure.
  31. ** It is used to create a 3D looking Bevel, like the string
  32. ** gadgets under Workbench 2.0.
  33. ** ============================================================
  34. */
  35.  
  36. typedef struct pcg_3DBevel
  37.    {
  38.       pcg_3DBox Outer, Inner;
  39.    } pcg_3DBevel;
  40.  
  41.  
  42. typedef struct pcg_3DThinBevel
  43.    {
  44.       Border         b[4];
  45.       SHORT          Points[20];
  46.    } pcg_3DThinBevel;
  47.    /*
  48.    ** ThinBevels are 2 pixels along the X axis, they're used for
  49.    ** embossed outline boxes.
  50.    */
  51.  
  52.  
  53. pcg_3DPens StandardPens( void );
  54.    /*
  55.    ** Returns the standard color pens.  This works for both
  56.    ** Workbench 1.2/3 and Workbench 2.0.
  57.    */
  58.  
  59.  
  60. void pcg_Init3DBox(     pcg_3DBox *Box,
  61.                         SHORT      LeftEdge,
  62.                         SHORT      TopEdge,
  63.                         USHORT     Width,
  64.                         USHORT     Height,
  65.                         UBYTE      TopLeftPen,
  66.                         UBYTE      BottomRightPen,
  67.                         Border    *NextBorder );
  68.  
  69.  
  70. void pcg_Init3DBevel(   pcg_3DBevel *Bevel,
  71.                         SHORT        LeftEdge,
  72.                         SHORT        TopEdge,
  73.                         USHORT       Width,
  74.                         USHORT       Height,
  75.                         USHORT       BevelWidth,
  76.                         UBYTE        TopLeftPen,
  77.                         UBYTE        BottomRightPen,
  78.                         Border      *NextBorder );
  79. /* LeftEdge, TopEdge, Width, Height refer to the _outer_ box.
  80. **
  81. ** 'BevelWidth' is the amount of blankspace between the inner and
  82. ** outer border.  This number corrected for aspect ratio.  (0 is
  83. ** an ok value.)
  84. **
  85. ** If 'TopLeftPen' is bright, and 'BottomRightPen' is dark, the bevel
  86. ** will appear to stand out.  If 'TopLeftPen' is dark, the bevel will
  87. ** appear recessed.
  88. */
  89.  
  90. void pcg_Init3DThinBevel(  pcg_3DThinBevel *Bevel,
  91.                            SHORT            LeftEdge,
  92.                            SHORT            TopEdge,
  93.                            USHORT           Width,
  94.                            USHORT           Height,
  95.                            USHORT           BevelWidth,
  96.                            UBYTE            TopLeftPen,
  97.                            UBYTE            BottomRightPen,
  98.                            Border          *NextBorder );
  99.  
  100.  
  101. #endif
  102.