home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-bin / x11r6.1 / include / x11 / pex5 / pexprotost.h < prev   
Encoding:
C/C++ Source or Header  |  1996-10-17  |  16.8 KB  |  685 lines

  1. /* $XConsortium: PEXprotost.h,v 1.7 94/04/17 20:22:27 mor Exp $ */
  2. /*
  3.  
  4. Copyright (c) 1992  X Consortium
  5.  
  6. Permission is hereby granted, free of charge, to any person obtaining
  7. a copy of this software and associated documentation files (the
  8. "Software"), to deal in the Software without restriction, including
  9. without limitation the rights to use, copy, modify, merge, publish,
  10. distribute, sublicense, and/or sell copies of the Software, and to
  11. permit persons to whom the Software is furnished to do so, subject to
  12. the following conditions:
  13.  
  14. The above copyright notice and this permission notice shall be included
  15. in all copies or substantial portions of the Software.
  16.  
  17. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
  18. OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  19. MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
  20. IN NO EVENT SHALL THE X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR
  21. OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
  22. ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
  23. OTHER DEALINGS IN THE SOFTWARE.
  24.  
  25. Except as contained in this notice, the name of the X Consortium shall
  26. not be used in advertising or otherwise to promote the sale, use or
  27. other dealings in this Software without prior written authorization
  28. from the X Consortium.
  29.  
  30. */
  31.  
  32.  
  33. /******************************************************************************
  34. Copyright 1989, 1990, 1991 by Sun Microsystems, Inc.
  35.  
  36.                         All Rights Reserved
  37.  
  38. Permission to use, copy, modify, distribute, and sell this software and its
  39. documentation for any purpose is hereby granted without fee, provided that
  40. the above copyright notice appear in all copies and that both that copyright
  41. notice and this permission notice appear in supporting documentation, and that
  42. the name of Sun Microsystems not be used in advertising or publicity
  43. pertaining to distribution of the software without specific, written prior
  44. permission.  Sun Microsystems makes no representations about the
  45. suitability of this software for any purpose.  It is provided "as is" without
  46. express or implied warranty.
  47.  
  48. SUN MICROSYSTEMS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, 
  49. INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT 
  50. SHALL SUN MICROSYSTEMS BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL 
  51. DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
  52. WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
  53. ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
  54. SOFTWARE.
  55. ******************************************************************************/
  56.  
  57. #ifndef _PEXPROTOST_H_
  58. #define _PEXPROTOST_H_
  59.  
  60. /* Matches revision 5.1C */
  61.  
  62. #include <X11/Xmd.h>            /* defines things like CARD32 */
  63.  
  64.  
  65. /* This is FLOAT as defined and used by the Protocol Encoding */
  66. #ifndef WORD64
  67. typedef float PEXFLOAT;
  68. #else
  69. typedef CARD32 PEXFLOAT;
  70. #endif
  71.  
  72.  
  73. typedef CARD32  pexAsfAttribute;
  74. typedef CARD8    pexAsfValue;
  75. typedef CARD32    pexBitmask;
  76. typedef CARD16    pexBitmaskShort;
  77. typedef CARD16  pexCoordType;     /* rational, nonrational */
  78. typedef CARD16    pexComposition;
  79. typedef CARD16    pexCullMode;
  80. typedef BYTE     pexDynamicType;
  81. typedef INT16    pexEnumTypeIndex;
  82. typedef XID     pexLookupTable;
  83. typedef CARD32     pexName;
  84. typedef XID     pexNameSet;
  85. typedef XID    pexPC;
  86. typedef XID    pexFont;
  87.  
  88. #ifndef WORD64
  89. typedef PEXFLOAT    pexMatrix[4][4];
  90. typedef PEXFLOAT     pexMatrix3X3[3][3];
  91. #else
  92. typedef CARD8        pexMatrix[64];
  93. typedef CARD8        pexMatrix3X3[36];
  94. #endif
  95.  
  96. typedef XID    pexPhigsWks;
  97. typedef XID    pexPickMeasure;
  98. typedef XID    pexRenderer;
  99. typedef XID    pexSC;
  100. typedef XID    pexStructure;
  101. typedef CARD8    pexSwitch;
  102. typedef CARD16    pexTableIndex;
  103. typedef CARD16    pexTableType;    /* could be smaller if it ever helps */
  104. typedef CARD16    pexTextHAlignment;
  105. typedef CARD16    pexTextVAlignment;
  106. typedef CARD16    pexTypeOrTableIndex;
  107. typedef pexEnumTypeIndex    pexColorType;     /* ColorType */
  108.  
  109. /* included in others */
  110. typedef struct {
  111.     CARD16    length B16;
  112.     /* list of CARD8 -- don't swap */
  113. } pexString;
  114.  
  115. typedef struct {
  116.     pexStructure    sid B32;
  117.     PEXFLOAT        priority B32;
  118. } pexStructureInfo;
  119.  
  120. typedef struct {
  121.     PEXFLOAT    x B32;
  122.     PEXFLOAT    y B32;
  123. } pexVector2D;
  124.  
  125. typedef struct {
  126.     PEXFLOAT    x B32;
  127.     PEXFLOAT    y B32;
  128.     PEXFLOAT    z B32;
  129. } pexVector3D;
  130.  
  131. /* Coord structures */
  132.  
  133. typedef struct {
  134.     PEXFLOAT    x B32;
  135.     PEXFLOAT    y B32;
  136. } pexCoord2D;
  137.  
  138. typedef struct {
  139.     PEXFLOAT    x B32;
  140.     PEXFLOAT    y B32;
  141.     PEXFLOAT    z B32;
  142. } pexCoord3D;
  143.  
  144. typedef struct {
  145.     PEXFLOAT    x B32;
  146.     PEXFLOAT    y B32;
  147.     PEXFLOAT    z B32;
  148.     PEXFLOAT    w B32;
  149. } pexCoord4D;
  150.  
  151.  
  152. /* Color structures */
  153. typedef struct {
  154.     PEXFLOAT    red B32;
  155.     PEXFLOAT    green B32;
  156.     PEXFLOAT    blue B32;
  157. } pexRgbFloatColor;
  158.  
  159. typedef struct {
  160.     PEXFLOAT    hue B32;
  161.     PEXFLOAT    saturation B32;
  162.     PEXFLOAT    value B32;
  163. } pexHsvColor;
  164.  
  165. typedef struct {
  166.     PEXFLOAT    hue B32;
  167.     PEXFLOAT    lightness B32;
  168.     PEXFLOAT    saturation B32;
  169. } pexHlsColor;
  170.  
  171. typedef struct {
  172.     PEXFLOAT    x B32;
  173.     PEXFLOAT    y B32;
  174.     PEXFLOAT    z B32;
  175. } pexCieColor;
  176.  
  177. typedef struct {
  178.     CARD8    red;
  179.     CARD8    green;
  180.     CARD8    blue;
  181.     CARD8    pad;
  182. } pexRgb8Color;
  183.  
  184. typedef struct {
  185.     CARD16    red B16;
  186.     CARD16    green B16;
  187.     CARD16    blue B16;
  188.     CARD16    pad B16;
  189. } pexRgb16Color;
  190.  
  191. typedef struct {
  192.     pexTableIndex    index B16;
  193.     CARD16        pad B16;
  194. } pexIndexedColor;
  195.  
  196. typedef struct {
  197.     union {
  198.     pexIndexedColor        indexed;
  199.     pexRgb8Color        rgb8;
  200.     pexRgb16Color        rgb16;
  201.     pexRgbFloatColor    rgbFloat;
  202.     pexHsvColor        hsvFloat;
  203.     pexHlsColor        hlsFloat;
  204.     pexCieColor        cieFloat;
  205.     } format;
  206. } pexColor;
  207.  
  208. typedef struct {
  209.     PEXFLOAT   first B32;
  210.     PEXFLOAT   second B32;
  211.     PEXFLOAT   third B32;
  212. } pexFloatColor;
  213.  
  214. typedef struct {
  215.     pexColorType    colorType B16;    /* ColorType enumerated type */
  216.     CARD16        unused B16;
  217.     /* SINGLE COLOR(colorType) */
  218. } pexColorSpecifier;
  219.  
  220.  
  221. typedef struct {
  222.     pexEnumTypeIndex    approxMethod B16;
  223.     CARD16        unused B16;
  224.     PEXFLOAT        tolerance B32;
  225. } pexCurveApproxData;
  226.  
  227. typedef struct {
  228.     INT16    x B16;
  229.     INT16     y B16;
  230.     PEXFLOAT     z B32;
  231. } pexDeviceCoord;
  232.  
  233. typedef struct {
  234.     INT16    x B16;
  235.     INT16     y B16;
  236. } pexDeviceCoord2D;
  237.  
  238. typedef struct {
  239.     INT16    xmin B16;
  240.     INT16    ymin B16;
  241.     INT16    xmax B16;
  242.     INT16    ymax B16;
  243. } pexDeviceRect;
  244.  
  245. typedef struct {
  246.     CARD16    elementType B16;
  247.     CARD16    length B16;
  248. } pexElementInfo;
  249.  
  250. typedef struct {
  251.     CARD16    whence B16;
  252.     CARD16    unused B16;
  253.     INT32    offset B32;
  254. } pexElementPos;
  255.  
  256. typedef struct {
  257.     pexElementPos    position1;    /* pexElementPos is 8 bytes long */
  258.     pexElementPos    position2;
  259. } pexElementRange;
  260.  
  261. typedef struct {
  262.     pexStructure    structure B32;
  263.     CARD32        offset B32;
  264. } pexElementRef;
  265.  
  266. typedef struct {
  267.     PEXFLOAT    lowerLeft_x B32;
  268.     PEXFLOAT    lowerLeft_y B32;
  269.     PEXFLOAT    upperRight_x B32;
  270.     PEXFLOAT    upperRight_y B32;
  271.     PEXFLOAT    concatpoint_x B32;
  272.     PEXFLOAT    concatpoint_y B32;
  273. } pexExtentInfo;
  274.  
  275. typedef struct {
  276.     pexEnumTypeIndex    index B16;
  277.     CARD16        descriptor_length B16;
  278. } pexEnumTypeDesc;
  279.  
  280. typedef struct {
  281.     PEXFLOAT    point_x B32;
  282.     PEXFLOAT    point_y B32;
  283.     PEXFLOAT    point_z B32;
  284.     PEXFLOAT    vector_x B32;
  285.     PEXFLOAT    vector_y B32;
  286.     PEXFLOAT    vector_z B32;
  287. } pexHalfSpace;
  288.  
  289. typedef struct {
  290.     pexNameSet    incl B32;
  291.     pexNameSet    excl B32;
  292. } pexNameSetPair;
  293.  
  294. typedef struct {
  295.     PEXFLOAT    point_x B32;
  296.     PEXFLOAT    point_y B32;
  297.     PEXFLOAT    vector_x B32;
  298.     PEXFLOAT    vector_y B32;
  299. } pexHalfSpace2D;
  300.  
  301. typedef struct {
  302.     CARD16    composition B16;
  303.     CARD16    unused B16;
  304.     pexMatrix    matrix;
  305. } pexLocalTransform3DData;
  306.  
  307. typedef struct {
  308.     CARD16        composition B16;
  309.     CARD16        unused B16;
  310.     pexMatrix3X3    matrix;
  311. } pexLocalTransform2DData;
  312.  
  313. typedef struct {
  314.     PEXFLOAT    xmin B32;
  315.     PEXFLOAT    ymin B32;
  316.     PEXFLOAT    zmin B32;
  317.     PEXFLOAT    xmax B32;
  318.     PEXFLOAT    ymax B32;
  319.     PEXFLOAT    zmax B32;
  320. } pexNpcSubvolume;
  321.  
  322. /*  an OPT_DATA  structure cannot be defined because it has variable content
  323.  *  and size.  An union structure could be used to define a template for
  324.  *  the data. However, since unions pad to a fixed amount of space and the
  325.  *  protocol uses variable lengths, this is not appropriate for protocol
  326.  *  data types.  The most correct way of defining this data is to define
  327.  *  one data structure for every possible combination of color, normal and
  328.  *  edge data that could be given with a vertex or facet.
  329.  */
  330.  
  331. typedef struct {
  332.     pexStructure    sid B32;
  333.     CARD32        offset B32;
  334.     CARD32        pickid B32;
  335. } pexPickElementRef;
  336.  
  337. /* pexPickPath is the old name of the above strucutre.
  338.    This is wrong, since the above is a Pick Element Ref
  339.    a Pick Path is a list of Pick Element Refs so naming
  340.    this structure pexPickPath was wrong, but it can't just
  341.    be changed without effecting lots of other code....... */
  342.  
  343. typedef pexPickElementRef pexPickPath;
  344.  
  345. typedef struct {
  346.     pexTextVAlignment        vertical B16;
  347.     pexTextHAlignment        horizontal B16;
  348. } pexTextAlignmentData;
  349.  
  350. typedef struct {
  351.     pexSwitch        visibility;
  352.     CARD8        unused;
  353.     CARD16        order B16;
  354.     pexCoordType    type B16;
  355.     INT16        approxMethod B16;
  356.     PEXFLOAT        tolerance B32;
  357.     PEXFLOAT        tMin B32;
  358.     PEXFLOAT        tMax B32;
  359.     CARD32        numKnots B32;
  360.     CARD32        numCoord B32;
  361.     /* LISTof FLOAT(numKnots) -- length = order + number of coords */
  362.     /* LISTof {pexCoord3D|pexCoord4D}(numCoord) */
  363. } pexTrimCurve;
  364.  
  365. typedef struct {
  366.     CARD8        depth;
  367.     CARD8        unused;
  368.     CARD16        type B16;
  369.     CARD32        visualID B32;
  370. } pexRendererTarget;
  371.  
  372. typedef struct {
  373.     pexEnumTypeIndex    pickType B16;
  374.     CARD16        unused B16;
  375.     /* SINGLE HITBOX() */
  376. } pexPickRecord;
  377.  
  378. typedef struct {
  379.     PEXFLOAT        ambient B32;
  380.     PEXFLOAT        diffuse B32;
  381.     PEXFLOAT        specular B32;
  382.     PEXFLOAT        specularConc B32;
  383.     PEXFLOAT        transmission B32; /* 0.0 = opaque, 1.0 = transparent */
  384.     pexColorType        specular_colorType B16;
  385.     CARD16              unused B16;
  386.     /* SINGLE COLOR() */
  387. } pexReflectionAttr;
  388.  
  389. typedef struct {
  390.     pexEnumTypeIndex    approxMethod B16;
  391.     CARD16        unused B16;
  392.     PEXFLOAT        uTolerance B32;
  393.     PEXFLOAT        vTolerance B32;
  394. } pexSurfaceApproxData;
  395.  
  396.  
  397. typedef struct {
  398.     PEXFLOAT    point_x B32;
  399.     PEXFLOAT    point_y B32;
  400.     PEXFLOAT    point_z B32;
  401.     /* SINGLE OPT_DATA() */
  402. } pexVertex;
  403.  
  404.  
  405. typedef struct {
  406.     INT16        xmin B16;
  407.     INT16        ymin B16;
  408.     PEXFLOAT        zmin B32;
  409.     INT16        xmax B16;
  410.     INT16        ymax B16;
  411.     PEXFLOAT        zmax B32;
  412.     pexSwitch        useDrawable;
  413.     BYTE        pad[3];
  414. } pexViewport;
  415.  
  416. typedef struct {
  417.     CARD16    clipFlags B16;
  418.     CARD16    unused B16;
  419.     PEXFLOAT    clipLimits_xmin B32;
  420.     PEXFLOAT    clipLimits_ymin B32;
  421.     PEXFLOAT    clipLimits_zmin B32;
  422.     PEXFLOAT    clipLimits_xmax B32;
  423.     PEXFLOAT    clipLimits_ymax B32;
  424.     PEXFLOAT    clipLimits_zmax B32;
  425.     pexMatrix    orientation;
  426.     pexMatrix    mapping;
  427. } pexViewEntry;
  428.  
  429. typedef struct {
  430.     pexTableIndex    index B16;
  431.     CARD16        unused1 B16;
  432.     CARD16        clipFlags B16;
  433.     CARD16        unused2 B16;
  434.     PEXFLOAT        clipLimits_xmin B32;
  435.     PEXFLOAT        clipLimits_ymin B32;
  436.     PEXFLOAT        clipLimits_zmin B32;
  437.     PEXFLOAT        clipLimits_xmax B32;
  438.     PEXFLOAT        clipLimits_ymax B32;
  439.     PEXFLOAT        clipLimits_zmax B32;
  440.     pexMatrix        orientation;
  441.     pexMatrix        mapping;
  442. } pexViewRep;
  443.  
  444. /*
  445.  * typedefs for lookup tables
  446.  */
  447.  
  448. typedef struct {
  449.     CARD16    definableEntries B16;
  450.     CARD16    numPredefined B16;
  451.     CARD16    predefinedMin B16;
  452.     CARD16    predefinedMax B16;
  453. } pexTableInfo;
  454.  
  455. typedef struct {
  456.     pexEnumTypeIndex    lineType B16;
  457.     pexEnumTypeIndex    polylineInterp B16;
  458.     pexEnumTypeIndex    curveApprox_method B16;
  459.     CARD16        unused1 B16;
  460.     PEXFLOAT        curveApprox_tolerance B32;
  461.     PEXFLOAT        lineWidth B32;
  462.     pexColorType    lineColorType B16;
  463.     CARD16        unused2 B16;
  464.     /* SINGLE COLOR(lineColorType) */
  465. } pexLineBundleEntry;
  466.  
  467. typedef struct {
  468.     pexEnumTypeIndex    markerType B16;
  469.     INT16        unused1 B16;
  470.     PEXFLOAT        markerScale B32;
  471.     pexColorType    markerColorType B16;
  472.     CARD16        unused2 B16;
  473.     /* SINGLE COLOR(markerColorType) */
  474. } pexMarkerBundleEntry;
  475.  
  476. typedef struct {
  477.     CARD16        textFontIndex B16;
  478.     CARD16        textPrecision B16;
  479.     PEXFLOAT        charExpansion B32;
  480.     PEXFLOAT        charSpacing B32;
  481.     pexColorType    textColorType B16;
  482.     CARD16        unused B16;
  483.     /* SINGLE COLOR(textColorType) */
  484. } pexTextBundleEntry;
  485.  
  486.  
  487. /*
  488.     Note that since an InteriorBundleEntry contains 4 embedded instances of 
  489.     pexColorSpecifier, a variable-sized item, a data structure cannot be
  490.     defined for it.
  491. */
  492. typedef struct {
  493.     pexEnumTypeIndex    interiorStyle B16;
  494.     INT16        interiorStyleIndex B16;
  495.     pexEnumTypeIndex    reflectionModel B16;
  496.     pexEnumTypeIndex    surfaceInterp B16;
  497.     pexEnumTypeIndex    bfInteriorStyle B16;
  498.     INT16        bfInteriorStyleIndex B16;
  499.     pexEnumTypeIndex    bfReflectionModel B16;
  500.     pexEnumTypeIndex    bfSurfaceInterp B16;
  501.     pexEnumTypeIndex    surfaceApprox_method B16;
  502.     CARD16        unused B16;
  503.     PEXFLOAT        surfaceApproxuTolerance B32;
  504.     PEXFLOAT        surfaceApproxvTolerance B32;
  505.     /* SINGLE pexColorSpecifier        surfaceColor    */
  506.     /* SINGLE pexReflectionAttr        reflectionAttr   */
  507.     /* SINGLE pexColorSpecifier        bfSurfaceColor  */
  508.     /* SINGLE pexReflectionAttr        bfReflectionAttr */
  509. } pexInteriorBundleEntry;
  510.  
  511. typedef struct {
  512.     pexSwitch        edges;
  513.     CARD8        unused1;
  514.     pexEnumTypeIndex    edgeType B16;
  515.     PEXFLOAT        edgeWidth B32;
  516.     pexColorType    edgeColorType B16;
  517.     CARD16        unused2 B16;
  518.     /* SINGLE COLOR(edgeColorType) */
  519. } pexEdgeBundleEntry;
  520.  
  521. typedef struct {
  522.     pexColorType    colorType B16; 
  523.     CARD16        numx B16;
  524.     CARD16        numy B16;
  525.     CARD16        unused B16;
  526.     /* LISTof Color(numx, numy) 2D array of colors */
  527. } pexPatternEntry;
  528.  
  529. /* a pexColorEntry is just a pexColorSpecifier
  530. */
  531.  
  532. typedef struct {
  533.     CARD32    numFonts B32;
  534.     /* LISTof pexFont( numFonts ) */
  535. } pexTextFontEntry;
  536.  
  537. /* a pexViewEntry is defined above */
  538.  
  539. typedef struct {
  540.     pexEnumTypeIndex    lightType B16;
  541.     INT16        unused1 B16;
  542.     PEXFLOAT        direction_x B32;
  543.     PEXFLOAT        direction_y B32;
  544.     PEXFLOAT        direction_z B32;
  545.     PEXFLOAT        point_x B32;
  546.     PEXFLOAT        point_y B32;
  547.     PEXFLOAT        point_z B32;
  548.     PEXFLOAT        concentration B32;
  549.     PEXFLOAT        spreadAngle B32;
  550.     PEXFLOAT        attenuation1 B32;
  551.     PEXFLOAT        attenuation2 B32;
  552.     pexColorType    lightColorType B16;
  553.     CARD16        unused2 B16;
  554.     /* SINGLE COLOR(lightColorType) */
  555. } pexLightEntry;
  556.  
  557. typedef struct {
  558.     pexSwitch        mode;
  559.     CARD8        unused1;
  560.     CARD16        unused2 B16;
  561.     PEXFLOAT        frontPlane B32;
  562.     PEXFLOAT        backPlane B32;
  563.     PEXFLOAT        frontScaling B32;
  564.     PEXFLOAT        backScaling B32;
  565.     pexColorType    depthCueColorType B16;
  566.     CARD16        unused3 B16;
  567.     /* SINGLE COLOR(depthCueColorType) */
  568. } pexDepthCueEntry;
  569.  
  570. typedef struct {
  571.     INT16    approxType B16;
  572.     INT16    approxModel B16;
  573.     CARD16    max1 B16;
  574.     CARD16    max2 B16;
  575.     CARD16    max3 B16;
  576.     CARD8    dither;
  577.     CARD8    unused;
  578.     CARD32    mult1 B32;
  579.     CARD32    mult2 B32;
  580.     CARD32    mult3 B32;
  581.     PEXFLOAT    weight1 B32;
  582.     PEXFLOAT    weight2 B32;
  583.     PEXFLOAT    weight3 B32;
  584.     CARD32    basePixel B32;
  585. } pexColorApproxEntry;
  586.  
  587.  
  588. /*  Font structures */
  589.  
  590. typedef struct {
  591.     Atom    name B32;
  592.     CARD32    value B32;
  593. } pexFontProp;
  594.  
  595. typedef struct {
  596.     CARD32    firstGlyph B32;
  597.     CARD32    lastGlyph B32;
  598.     CARD32    defaultGlyph B32;
  599.     pexSwitch    allExist;
  600.     pexSwitch    strokeFont;
  601.     CARD16    unused B16;
  602.     CARD32    numProps B32;
  603.     /* LISTof pexFontProp(numProps) */
  604. } pexFontInfo;
  605.  
  606.  
  607. /* Text Structures */
  608.  
  609. typedef struct {
  610.     INT16    characterSet B16;
  611.     CARD8    characterSetWidth;
  612.     CARD8    encodingState;
  613.     CARD16    unused B16;
  614.     CARD16    numChars B16;
  615.     /* LISTof CHARACTER( numChars ) */
  616.     /* pad */
  617. } pexMonoEncoding;
  618.  
  619. /* CHARACTER is either a CARD8, a CARD16, or a CARD32 */
  620.  
  621.  
  622. /* Parametric Surface Characteristics types */
  623.  
  624. /* type 1 None */
  625.  
  626. /* type 2 Implementation Dependent */
  627.  
  628. typedef struct {
  629.     CARD16    placementType B16;
  630.     CARD16    unused B16;
  631.     CARD16    numUcurves B16;
  632.     CARD16    numVcurves B16;
  633. } pexPSC_IsoparametricCurves;        /* type 3 */
  634.  
  635. typedef struct {
  636.     PEXFLOAT    origin_x B32;
  637.     PEXFLOAT    origin_y B32;
  638.     PEXFLOAT    origin_z B32;
  639.     PEXFLOAT    direction_x B32;
  640.     PEXFLOAT    direction_y B32;
  641.     PEXFLOAT    direction_z B32;
  642.     CARD16    numberIntersections B16;
  643.     CARD16    pad B16;
  644.     /* LISTof pexCoord3D( numIntersections ) */
  645. } pexPSC_LevelCurves;            /*  type 4: MC
  646.                         type 5: WC */
  647.  
  648. /* Pick Device data records */
  649.  
  650. typedef struct {
  651.     INT16    position_x B16;
  652.     INT16     position_y B16;
  653.     PEXFLOAT    distance B32;
  654. } pexPD_DC_HitBox;                /* pick device 1 */
  655.  
  656. typedef pexNpcSubvolume pexPD_NPC_HitVolume;    /* pick device 2 */
  657.  
  658.  
  659. /* Output Command errors */
  660.  
  661. typedef struct {
  662.     CARD8    type;            /*  0 */
  663.     CARD8    errorCode;        /* 14 */
  664.     CARD16    sequenceNumber B16;
  665.     CARD32    resourceId B32;        /* renderer or structure */
  666.     CARD16    minorCode B16;
  667.     CARD8    majorCode;
  668.     CARD8    unused;
  669.     CARD16    opcode B16;        /* opcode of failed output command */
  670.     CARD16    numCommands B16;    /* number successfully done before error */
  671.     BYTE    pad[16];
  672. } pexOutputCommandError;
  673.  
  674.  
  675. /* Registered PEX Escapes */
  676.  
  677. typedef struct {
  678.     INT16    fpFormat B16;
  679.     CARD8    unused[2];
  680.     CARD32    rdr B32;        /* renderer ID */
  681.     /* SINGLE ColorSpecifier()  */
  682. } pexEscapeSetEchoColorData;
  683.  
  684. #endif /* _PEXPROTOST_H_ */
  685.