home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Misc / DC-POS24.LZX / pOS / IncPOS.lzx / pGFX / Color.h next >
Encoding:
C/C++ Source or Header  |  1997-03-18  |  3.3 KB  |  143 lines

  1. #ifndef __INC_POS_PGFX_COLOR_H
  2. #define __INC_POS_PGFX_COLOR_H
  3. /*******************************************************************
  4.  Includes Release 24
  5.  (C) Copyright 1995-1997 proDAD
  6.      All Rights Reserved
  7.  
  8.  $AUT Holger Burkarth
  9.  $DAT >>Color.h<<   20 Oct 1996    09:16:44 - (C) ProDAD
  10. *******************************************************************/
  11. #ifndef __INC_POS_PEXEC_TYPES_H
  12. #include <pExec/Types.h>
  13. #endif
  14.  
  15.  
  16. /*----------------------------------
  17. -----------------------------------*/
  18. struct pOS_ColorMap
  19. {
  20.   struct pOS_GfxLibrary  *cm_Base;
  21.   ULONG                   cm_UserData[2];
  22.   UWORD                   cm_Type;       /* (enum pOS_ColorMapType) */
  23.   UWORD                   cm_Pad;
  24.   ULONG                   cm_Flags;      /* (enum pOS_ColorMapFlags) */
  25.   ULONG                   cm_Colors;     /* Anzahl der Farbregistern */
  26.   struct pOS_ColorMapEx  *cm_Ex;         /* System-Extension */
  27.   UBYTE cm_Reserved[32];
  28. };
  29.  
  30.  
  31.  
  32. /*----------------------------------
  33.     Real-Color - 8 Bit
  34. -----------------------------------*/
  35. struct pOS_RColor
  36. {
  37.   union {
  38.     ULONG rcu_Color;
  39.     UBYTE rcu_Area[4]; /* Index: enum pOS_RColorIdx */
  40.     struct {
  41.       UBYTE rcue_A;
  42.       UBYTE rcue_B;
  43.       UBYTE rcue_G;
  44.       UBYTE rcue_R;
  45.     } rc_E;
  46.   } rc_U;
  47. };
  48.  
  49.  
  50.  
  51. /*----------------------------------
  52.     Real-Color - 16 Bit
  53. -----------------------------------*/
  54. struct pOS_R2Color
  55. {
  56.   union {
  57.     UWORD r2cu_Area[4]; /* Index: enum pOS_RColorIdx */
  58.     struct {
  59.       UWORD r2cue_A;
  60.       UWORD r2cue_B;
  61.       UWORD r2cue_G;
  62.       UWORD r2cue_R;
  63.     } rc_E;
  64.   } rc_U;
  65. };
  66.  
  67.  
  68. /*----------------------------------
  69.     RLUT-Color - 16 Bit
  70. -----------------------------------*/
  71. struct pOS_UColor
  72. {
  73.   UWORD uc_Pad;
  74.   UWORD uc_Color;
  75. };
  76.  
  77.  
  78.  
  79.  
  80. enum pOS_RColorIdx
  81. {
  82.   RCOLIDX_A,
  83.   RCOLIDX_B,
  84.   RCOLIDX_G,
  85.   RCOLIDX_R
  86. };
  87.  
  88.  
  89.  
  90.  
  91.  
  92. enum pOS_ColorMapFlags /* cm_Flags */
  93. {
  94.   COLMAPF_Display = 0x0002, /* die ColorMap kann dargestellt werden */
  95.  
  96.   COLMAPF_Clear=    0x80000000, /* ColorMap ist genullt */
  97. };
  98.  
  99.  
  100.  
  101. enum pOS_ColorMapType /* cm_Type */
  102. {
  103.   COLMAPTYP_None =0,
  104.   COLMAPTYP_RLut,       /*  */
  105.  
  106.   COLMAPTYP_StdRLut=0x80, /* (struct pOS_StdRLColorMap) */
  107.   COLMAPTYP_MAXStd
  108. };
  109.  
  110.  
  111.  
  112. /**  pOS_ObtainColorPen() - Flags **/
  113. enum pOS_ObtainColorPenFlags
  114. {
  115.   OTCOLPF_Exclusive     = 0x0000, /* der Pen wird nur einmal vergeben */
  116.   OTCOLPF_Shared        = 0x0001, /* der Pen wird von mehreren Usern verwendet */
  117.   OTCOLPF_Flow          = 0x0002, /* nur in Verbindung mit _Shared
  118.                                   ** Der Farbwert wird bei Bedarf minimal verändert.
  119.                                   */
  120.  
  121.  
  122.   OTCOLPF_Force         = 0x0020, /* Konnte auf herkömmliche Weise kein Pen gefunden
  123.                                   ** werden, dann wird der nachliegenste Pen verwendet.
  124.                                   ** => Beachte: Es ist nicht sicher, daß immer ein Pen
  125.                                   **    gefunden wird (=>OTCOLPF_Exclusive)
  126.                                   */
  127.   OTCOLPF_Display       = 0x0080, /* Update Display */
  128. };
  129.  
  130.  
  131. /** pOS_DisplayColorMap() - Flags **/
  132. enum pOS_DisplayColorMapFlags
  133. {
  134.   DISCOLF_Always        = 0x0000,       /* immer berechnen */
  135.   DISCOLF_Update        = 0x0001,       /* Die Color werden nur bei einer Veränderung
  136.                                         ** neu berechnet und dargestellt.
  137.                                         */
  138. };
  139.  
  140.  
  141.  
  142. #endif
  143.