1 #ifndef GRAPHICS_DISPLAYINFO_H
    2 #define GRAPHICS_DISPLAYINFO_H
    3 
    4 /*
    5 	graphics displayinfo definitions
    6 
    7 	Copyright © 2002 The MorphOS Development Team, All Rights Reserved.
    8 */
    9 
   10 #ifndef EXEC_TYPES_H
   11 # include <exec/types.h>
   12 #endif
   13 
   14 #ifndef GRAPHICS_GFX_H
   15 # include <graphics/gfx.h>
   16 #endif
   17 
   18 #ifndef GRAPHICS_MONITOR_H
   19 # include <graphics/monitor.h>
   20 #endif
   21 
   22 #ifndef GRAPHICS_MODEID_H
   23 # include <graphics/modeid.h>
   24 #endif
   25 
   26 #ifndef UTILITY_TAGITEM_H
   27 # include <utility/tagitem.h>
   28 #endif
   29 
   30 #pragma pack(2)
   31 
   32 
   33 typedef APTR DisplayInfoHandle;
   34 
   35 
   36 #define DTAG_DISP  0x80000000
   37 #define DTAG_DIMS  0x80001000
   38 #define DTAG_MNTR  0x80002000
   39 #define DTAG_NAME  0x80003000
   40 #define DTAG_VEC   0x80004000
   41 
   42 
   43 struct QueryHeader
   44 {
   45 	ULONG StructID;
   46 	ULONG DisplayID;
   47 	ULONG SkipID;
   48 	ULONG Length;
   49 };
   50 
   51 struct DisplayInfo
   52 {
   53 	struct QueryHeader Header;
   54 	UWORD              NotAvailable;
   55 	ULONG              PropertyFlags;
   56 	Point              Resolution;
   57 	UWORD              PixelSpeed;
   58 	UWORD              NumStdSprites;
   59 	UWORD              PaletteRange;
   60 	Point              SpriteResolution;
   61 	UBYTE              pad[4];
   62 	UBYTE              RedBits;
   63 	UBYTE              GreenBits;
   64 	UBYTE              BlueBits;
   65 	UBYTE              pad2[5];
   66 	ULONG              reserved[2];
   67 };
   68 
   69 
   70 #define DI_AVAIL_NOCHIPS         0x0001
   71 #define DI_AVAIL_NOMONITOR       0x0002
   72 #define DI_AVAIL_NOTWITHGENLOCK  0x0004
   73 
   74 
   75 #define DIPF_IS_LACE               0x00000001
   76 #define DIPF_IS_DUALPF             0x00000002
   77 #define DIPF_IS_PF2PRI             0x00000004
   78 #define DIPF_IS_HAM                0x00000008
   79 
   80 #define DIPF_IS_ECS                0x00000010
   81 #define DIPF_IS_AA                 0x00010000
   82 
   83 #define DIPF_IS_PAL                0x00000020
   84 #define DIPF_IS_SPRITES            0x00000040
   85 #define DIPF_IS_GENLOCK            0x00000080
   86 
   87 #define DIPF_IS_WB                 0x00000100
   88 #define DIPF_IS_DRAGGABLE          0x00000200
   89 #define DIPF_IS_PANELLED           0x00000400
   90 #define DIPF_IS_BEAMSYNC           0x00000800
   91 
   92 #define DIPF_IS_EXTRAHALFBRITE     0x00001000
   93 
   94 #define DIPF_IS_SPRITES_ATT        0x00002000
   95 #define DIPF_IS_SPRITES_CHNG_RES   0x00004000
   96 #define DIPF_IS_SPRITES_BORDER     0x00008000
   97 #define DIPF_IS_SCANDBL            0x00020000
   98 #define DIPF_IS_SPRITES_CHNG_BASE  0x00040000
   99 #define DIPF_IS_SPRITES_CHNG_PRI   0x00080000
  100 #define DIPF_IS_DBUFFER            0x00100000
  101 #define DIPF_IS_PROGBEAM           0x00200000
  102 #define DIPF_IS_FOREIGN            0x80000000
  103 
  104 
  105 struct DimensionInfo
  106 {
  107 	struct QueryHeader Header;
  108 	UWORD              MaxDepth;
  109 	UWORD              MinRasterWidth;
  110 	UWORD              MinRasterHeight;
  111 	UWORD              MaxRasterWidth;
  112 	UWORD              MaxRasterHeight;
  113 	struct Rectangle   Nominal;
  114 	struct Rectangle   MaxOScan;
  115 	struct Rectangle   VideoOScan;
  116 	struct Rectangle   TxtOScan;
  117 	struct Rectangle   StdOScan;
  118 	UBYTE              pad[14];
  119 	ULONG              reserved[2];
  120 };
  121 
  122 struct MonitorInfo
  123 {
  124 	struct QueryHeader  Header;
  125 	struct MonitorSpec *Mspc;
  126 	Point               ViewPosition;
  127 	Point               ViewResolution;
  128 	struct Rectangle    ViewPositionRange;
  129 	UWORD               TotalRows;
  130 	UWORD               TotalColorClocks;
  131 	UWORD               MinRow;
  132 	WORD                Compatibility;
  133 	UBYTE               pad[32];
  134 	Point               MouseTicks;
  135 	Point               DefaultViewPosition;
  136 	ULONG               PreferredModeID;
  137 	ULONG               reserved[2];
  138 };
  139 
  140 
  141 #define MCOMPAT_MIXED    0
  142 #define MCOMPAT_SELF     1
  143 #define MCOMPAT_NOBODY  -1
  144 
  145 #define DISPLAYNAMELEN  32
  146 
  147 struct NameInfo
  148 {
  149 	struct QueryHeader Header;
  150 	UBYTE              Name[DISPLAYNAMELEN];
  151 	ULONG              reserved[2];
  152 };
  153 
  154 
  155 struct VecInfo
  156 {
  157 	struct QueryHeader Header;
  158 	APTR               Vec;
  159 	APTR               Data;
  160 	UWORD              Type;
  161 	UWORD              pad[3];
  162 	ULONG              reserved[2];
  163 };
  164 
  165 
  166 #pragma pack()
  167 
  168 #endif /* GRAPHICS_DISPLAYINFO_H */