Clone of mesa.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

xmesa_x.h 3.5KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. /**************************************************************************
  2. Copyright 1998-1999 Precision Insight, Inc., Cedar Park, Texas.
  3. All Rights Reserved.
  4. Permission is hereby granted, free of charge, to any person obtaining a
  5. copy of this software and associated documentation files (the
  6. "Software"), to deal in the Software without restriction, including
  7. without limitation the rights to use, copy, modify, merge, publish,
  8. distribute, sub license, and/or sell copies of the Software, and to
  9. permit persons to whom the Software is furnished to do so, subject to
  10. the following conditions:
  11. The above copyright notice and this permission notice (including the
  12. next paragraph) shall be included in all copies or substantial portions
  13. of the Software.
  14. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
  15. OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  16. MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
  17. IN NO EVENT SHALL PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR
  18. ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
  19. TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
  20. SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  21. **************************************************************************/
  22. /*
  23. * Authors:
  24. * Kevin E. Martin <kevin@precisioninsight.com>
  25. *
  26. * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/include/GL/xmesa_x.h,v 1.2 2000/02/25 20:31:11 brianp Exp $
  27. */
  28. #ifndef _XMESA_X_H_
  29. #define _XMESA_X_H_
  30. typedef Display XMesaDisplay;
  31. typedef Pixmap XMesaPixmap;
  32. typedef Colormap XMesaColormap;
  33. typedef Drawable XMesaDrawable;
  34. typedef Window XMesaWindow;
  35. typedef GC XMesaGC;
  36. typedef XVisualInfo *XMesaVisualInfo;
  37. typedef XImage XMesaImage;
  38. typedef XPoint XMesaPoint;
  39. typedef XColor XMesaColor;
  40. #define XMesaDestroyImage XDestroyImage
  41. #define XMesaPutPixel XPutPixel
  42. #define XMesaGetPixel XGetPixel
  43. #define XMesaSetForeground XSetForeground
  44. #define XMesaSetBackground XSetBackground
  45. #define XMesaSetPlaneMask XSetPlaneMask
  46. #define XMesaSetFunction XSetFunction
  47. #define XMesaSetDashes XSetDashes
  48. #define XMesaSetLineAttributes XSetLineAttributes
  49. #define XMesaSetFillStyle XSetFillStyle
  50. #define XMesaSetTile XSetTile
  51. #define XMesaSetStipple XSetStipple
  52. #define XMesaDrawPoint XDrawPoint
  53. #define XMesaDrawPoints XDrawPoints
  54. #define XMesaDrawLine XDrawLine
  55. #define XMesaFillRectangle XFillRectangle
  56. #define XMesaPutImage XPutImage
  57. #define XMesaCopyArea XCopyArea
  58. #define XMesaFillPolygon XFillPolygon
  59. #define XMesaCreatePixmap XCreatePixmap
  60. #define XMesaFreePixmap XFreePixmap
  61. #define XMesaFreeGC XFreeGC
  62. #define GET_COLORMAP_SIZE(__v) __v->visinfo->colormap_size
  63. #define GET_REDMASK(__v) __v->visinfo->red_mask
  64. #define GET_GREENMASK(__v) __v->visinfo->green_mask
  65. #define GET_BLUEMASK(__v) __v->visinfo->blue_mask
  66. #if defined(__cplusplus) || defined(c_plusplus)
  67. #define GET_VISUAL_CLASS(__v) __v->visinfo->c_class
  68. #else
  69. #define GET_VISUAL_CLASS(__v) __v->visinfo->class
  70. #endif
  71. #define GET_VISUAL_DEPTH(__v) __v->visinfo->depth
  72. #define GET_BLACK_PIXEL(__v) BlackPixel(__v->display, __v->visinfo->screen)
  73. #define CHECK_BYTE_ORDER(__v) host_byte_order()==ImageByteOrder(__v->display)
  74. #define CHECK_FOR_HPCR(__v) XInternAtom(__v->display, "_HP_RGB_SMOOTH_MAP_LIST", True)
  75. #endif