xf86dgaconst.h 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  1. /*
  2. Copyright (c) 1999 XFree86 Inc
  3. */
  4. #ifndef _XF86DGACONST_H_
  5. #define _XF86DGACONST_H_
  6. #include <X11/extensions/xf86dga1const.h>
  7. #define X_XDGAQueryVersion 0
  8. /* 1 through 9 are in xf86dga1.h */
  9. /* 10 and 11 are reserved to avoid conflicts with rogue DGA extensions */
  10. #define X_XDGAQueryModes 12
  11. #define X_XDGASetMode 13
  12. #define X_XDGASetViewport 14
  13. #define X_XDGAInstallColormap 15
  14. #define X_XDGASelectInput 16
  15. #define X_XDGAFillRectangle 17
  16. #define X_XDGACopyArea 18
  17. #define X_XDGACopyTransparentArea 19
  18. #define X_XDGAGetViewportStatus 20
  19. #define X_XDGASync 21
  20. #define X_XDGAOpenFramebuffer 22
  21. #define X_XDGACloseFramebuffer 23
  22. #define X_XDGASetClientVersion 24
  23. #define X_XDGAChangePixmapMode 25
  24. #define X_XDGACreateColormap 26
  25. #define XDGAConcurrentAccess 0x00000001
  26. #define XDGASolidFillRect 0x00000002
  27. #define XDGABlitRect 0x00000004
  28. #define XDGABlitTransRect 0x00000008
  29. #define XDGAPixmap 0x00000010
  30. #define XDGAInterlaced 0x00010000
  31. #define XDGADoublescan 0x00020000
  32. #define XDGAFlipImmediate 0x00000001
  33. #define XDGAFlipRetrace 0x00000002
  34. #define XDGANeedRoot 0x00000001
  35. #define XF86DGANumberEvents 7
  36. #define XDGAPixmapModeLarge 0
  37. #define XDGAPixmapModeSmall 1
  38. #define XF86DGAClientNotLocal 0
  39. #define XF86DGANoDirectVideoMode 1
  40. #define XF86DGAScreenNotActive 2
  41. #define XF86DGADirectNotActivated 3
  42. #define XF86DGAOperationNotSupported 4
  43. #define XF86DGANumberErrors (XF86DGAOperationNotSupported + 1)
  44. typedef struct {
  45. int num; /* A unique identifier for the mode (num > 0) */
  46. char *name; /* name of mode given in the XF86Config */
  47. float verticalRefresh;
  48. int flags; /* DGA_CONCURRENT_ACCESS, etc... */
  49. int imageWidth; /* linear accessible portion (pixels) */
  50. int imageHeight;
  51. int pixmapWidth; /* Xlib accessible portion (pixels) */
  52. int pixmapHeight; /* both fields ignored if no concurrent access */
  53. int bytesPerScanline;
  54. int byteOrder; /* MSBFirst, LSBFirst */
  55. int depth;
  56. int bitsPerPixel;
  57. unsigned long redMask;
  58. unsigned long greenMask;
  59. unsigned long blueMask;
  60. short visualClass;
  61. int viewportWidth;
  62. int viewportHeight;
  63. int xViewportStep; /* viewport position granularity */
  64. int yViewportStep;
  65. int maxViewportX; /* max viewport origin */
  66. int maxViewportY;
  67. int viewportFlags; /* types of page flipping possible */
  68. int reserved1;
  69. int reserved2;
  70. } XDGAMode;
  71. typedef struct {
  72. XDGAMode mode;
  73. unsigned char *data;
  74. Pixmap pixmap;
  75. } XDGADevice;
  76. #endif /* _XF86DGACONST_H_ */