~ubuntu-branches/ubuntu/gutsy/vnc4/gutsy

« back to all changes in this revision

Viewing changes to unix/xc/programs/Xserver/PEX5/ddpex/mi/include/miInfo.h

  • Committer: Bazaar Package Importer
  • Author(s): Ola Lundqvist
  • Date: 2006-05-15 20:35:17 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20060515203517-l4lre1ku942mn26k
Tags: 4.1.1+X4.3.0-10
* Correction of critical security issue. Thanks to Martin Kogler
  <e9925248@student.tuwien.ac.at> that informed me about the issue,
  and provided the patch.
  This flaw was originally found by Steve Wiseman of intelliadmin.com.
* Applied patch from Javier Kohen <jkohen@users.sourceforge.net> that
  inform the user that only 8 first characters of the password will
  actually be used when typing more than 8 characters, closes:
  #355619.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* $Xorg: miInfo.h,v 1.4 2001/02/09 02:04:08 xorgcvs Exp $ */
 
2
/*
 
3
 
 
4
Copyright 1989, 1990, 1991, 1998  The Open Group
 
5
 
 
6
Permission to use, copy, modify, distribute, and sell this software and its
 
7
documentation for any purpose is hereby granted without fee, provided that
 
8
the above copyright notice appear in all copies and that both that
 
9
copyright notice and this permission notice appear in supporting
 
10
documentation.
 
11
 
 
12
The above copyright notice and this permission notice shall be included
 
13
in all copies or substantial portions of the Software.
 
14
 
 
15
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 
16
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 
17
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
 
18
IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR
 
19
OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
 
20
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
 
21
OTHER DEALINGS IN THE SOFTWARE.
 
22
 
 
23
Except as contained in this notice, the name of The Open Group shall
 
24
not be used in advertising or otherwise to promote the sale, use or
 
25
other dealings in this Software without prior written authorization
 
26
from The Open Group.
 
27
 
 
28
 
 
29
Copyright 1989, 1990, 1991 by Sun Microsystems, Inc. 
 
30
 
 
31
                        All Rights Reserved
 
32
 
 
33
Permission to use, copy, modify, and distribute this software and its
 
34
documentation for any purpose and without fee is hereby granted,
 
35
provided that the above copyright notice appear in all copies and that
 
36
both that copyright notice and this permission notice appear in
 
37
supporting documentation, and that the name of Sun Microsystems,
 
38
not be used in advertising or publicity pertaining to distribution
 
39
of the software without specific, written prior permission.
 
40
 
 
41
SUN MICROSYSTEMS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
 
42
INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT
 
43
SHALL SUN MICROSYSTEMS BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL
 
44
DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
 
45
WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
 
46
ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
 
47
SOFTWARE.
 
48
 
 
49
*/
 
50
 
 
51
/* this file contains the definitions for the enum type and imp dep constant
 
52
 * values
 
53
 * Theoretically, these values can depend on the capabilities of the 
 
54
 * different workstation types, which basically depends on the drawable
 
55
 * of the workstation.  Currently, the SI support is the same for all
 
56
 * drawables.  If your implementation requires different support for each
 
57
 * drawables, then define a similar set of values as these for
 
58
 * each type.  They are then loaded in a table which is accessed
 
59
 * according to the drawable type (see ddpex/shared/miMisc.c).
 
60
 */
 
61
 
 
62
#ifndef MI_INFO_H
 
63
#define MI_INFO_H
 
64
 
 
65
#include "miNS.h"
 
66
/* imp dep constants */
 
67
 
 
68
/* These values are in two arrays that can be accessed by
 
69
 * the PEXID constant value.  Two arrays are used  since some values are CARD32 and
 
70
 * some are FLOAT.  SI_NUM_..._IMPS define how many values there are of each type
 
71
 */
 
72
 
 
73
/* card32s */
 
74
#define SI_NUM_INT_IMPS         22
 
75
 
 
76
#define SI_DITHERING_SUPPORTED          MI_FALSE
 
77
#define SI_MAX_EDGE_WIDTH               ~((unsigned long)0)
 
78
#define SI_MAX_LINE_WIDTH               ~((unsigned long)0)
 
79
#define SI_MAX_MARKER_SIZE              ~((unsigned long)0)
 
80
#define SI_MAX_MODEL_CLIP_PLANES        64
 
81
#define SI_MAX_NAME_SET_NAMES           MINS_NAMESET_SIZE
 
82
#define SI_MAX_NON_AMBIENT_LIGHTS       64
 
83
#define SI_MAX_NURB_ORDER               10
 
84
#define SI_MAX_TRIM_CURVE_ORDER         6
 
85
#define SI_MIN_EDGE_WIDTH               1
 
86
#define SI_MIN_LINE_WIDTH               1
 
87
#define SI_MIN_MARKER_SIZE              1
 
88
#define SI_NOM_EDGE_WIDTH               1       /* nominal edge width */
 
89
#define SI_NOM_LINE_WIDTH               1       /* nominal line width */
 
90
#define SI_NOM_MARKER_SIZE              1       /* nominal marker size */
 
91
#define SI_SUPP_EDGE_WIDTHS             ~((unsigned long)0)     /* number of supported edge widths */
 
92
#define SI_SUPP_LINE_WIDTHS             ~((unsigned long)0)     /* number of supported line widths */
 
93
#define SI_SUPP_MARKER_SIZES            ~((unsigned long)0)     /* number of supported marker sizes */
 
94
#define SI_BEST_COLOUR_APPROX_VALUES    PEXColourApproxAnyValues
 
95
#define SI_TRANSPARENCY_SUPPORTED       MI_FALSE
 
96
#define SI_DOUBLE_BUFFERING_SUPPORTED   MI_TRUE
 
97
#define SI_MAX_HITS_EVENT_SUPPORTED     MI_TRUE
 
98
 
 
99
/* floats */
 
100
#define SI_NUM_FLOAT_IMPS       12
 
101
 
 
102
/* ALL CIE primary chromaticity coefficients are taken from
 
103
 * Rodgers' Procedural Elements for Computer Graphics
 
104
 * for Color CRT monitor aligned to d6500 white
 
105
 */
 
106
#define SI_CHROM_RED_U                  0.628
 
107
#define SI_CHROM_RED_V                  0.346
 
108
#define SI_LUM_RED                      1.0
 
109
#define SI_CHROM_GREEN_U                0.268
 
110
#define SI_CHROM_GREEN_V                0.588
 
111
#define SI_LUM_GREEN                    1.0
 
112
#define SI_CHROM_BLUE_U                 0.150
 
113
#define SI_CHROM_BLUE_V                 0.070
 
114
#define SI_LUM_BLUE                     1.0
 
115
#define SI_CHROM_WHITE_U                0.313
 
116
#define SI_CHROM_WHITE_V                0.329
 
117
#define SI_LUM_WHITE                    1.0
 
118
 
 
119
 
 
120
/* enumerated type info */
 
121
 
 
122
/* the SI_..._NUM value is the number of supported types */
 
123
 
 
124
/* If you are changing these values.....
 
125
 * OK, I blew it here.  You gotta change the NUM info here
 
126
 * AND you gotta go into ../shared/miMisc.c and change the
 
127
 * stuff that's in the info tables.  Maybe there's a way
 
128
 * to do this so you can just go to one place and change it
 
129
 * Also, this info isn't coded to match what's really happening
 
130
 * in the rendering, so's if you change what happens during
 
131
 * rendering, you gotta come here and change dese tables too.
 
132
 * It isn't all done automagically and it probably should, but
 
133
 * it's too late now.  These values are used when setting the
 
134
 * real_entry of LUTS. 
 
135
 */
 
136
 
 
137
/* marker type */
 
138
#define SI_MARKER_NUM           5
 
139
#define SI_MARKER_1             "Dot"
 
140
#define SI_MARKER_2             "Cross"
 
141
#define SI_MARKER_3             "Asterisk"
 
142
#define SI_MARKER_4             "Circle"
 
143
#define SI_MARKER_5             "X"
 
144
 
 
145
/* annotation text style */
 
146
#define SI_ATEXT_NUM            2
 
147
#define SI_ATEXT_1              "NotConnected"
 
148
#define SI_ATEXT_2              "Connected"
 
149
 
 
150
/* interior style */
 
151
#define SI_INT_NUM              3
 
152
#define SI_INT_1                "Hollow"
 
153
#define SI_INT_2                "Solid"
 
154
#define SI_INT_5                "Empty"
 
155
/* others */
 
156
#define SI_INT_3                "Pattern"
 
157
#define SI_INT_4                "Hatch"
 
158
 
 
159
/* hatch style */
 
160
#define SI_HATCH_NUM            0
 
161
 
 
162
/* line type */
 
163
#define SI_LINE_NUM             4
 
164
#define SI_LINE_1               "Solid"
 
165
#define SI_LINE_2               "Dashed"
 
166
#define SI_LINE_3               "Dotted"
 
167
#define SI_LINE_4               "DashDot"
 
168
 
 
169
/* surface edge type */
 
170
#define SI_EDGE_NUM             4
 
171
#define SI_EDGE_1               "Solid"
 
172
#define SI_EDGE_2               "Dashed"
 
173
#define SI_EDGE_3               "Dotted"
 
174
#define SI_EDGE_4               "DashDot"
 
175
 
 
176
/* pick device type */
 
177
#define SI_PICK_DEVICE_NUM      2
 
178
#define SI_PICK_DEVICE_1        "DC_HitBox"
 
179
#define SI_PICK_DEVICE_2        "NPC_HitVolume"
 
180
 
 
181
/* pick one methods */
 
182
#define SI_PICK_ONE_NUM         1
 
183
#define SI_PICK_ONE_LAST        "Last"
 
184
/* others */
 
185
#define SI_PICK_ONE_CLOSEST_Z    "ClosestZ"
 
186
#define SI_PICK_ONE_VISIBLE_ANY  "VisibleAny"
 
187
#define SI_PICK_ONE_VISIBLE_CLOSEST      "VisibleClosest"
 
188
 
 
189
/* pick all methods */
 
190
#define SI_PICK_ALL_NUM         1
 
191
#define SI_PICK_ALL_ALL         "All"
 
192
/* others */
 
193
#define SI_PICK_ALL_VISIBLE     "Visible"
 
194
 
 
195
/* polyline interpolation method */
 
196
#define SI_LINE_INTERP_NUM      1
 
197
#define SI_LINE_INTERP_1        "None"
 
198
/* others */
 
199
#define SI_LINE_INTERP_2        "Color"
 
200
 
 
201
/* curve approximation method */
 
202
#define SI_CURVE_APPROX_NUM     6
 
203
#define SI_CURVE_APPROX_1       "ConstantBetweenKnots"  /* (Imp. Dep.) */
 
204
#define SI_CURVE_APPROX_2       "ConstantBetweenKnots"
 
205
#define SI_CURVE_APPROX_3       "WCS_ChordalSize"
 
206
#define SI_CURVE_APPROX_4       "NPC_ChordalSize"
 
207
#define SI_CURVE_APPROX_6       "WCS_ChordalDev"
 
208
#define SI_CURVE_APPROX_7       "NPC_ChordalDev"
 
209
/* others */ 
 
210
#define SI_CURVE_APPROX_5       "DC_ChordalSize"
 
211
#define SI_CURVE_APPROX_8       "DC_ChordalDev"
 
212
#define SI_CURVE_APPROX_9       "WCS_Relative"
 
213
#define SI_CURVE_APPROX_10      "NPC_Relative"
 
214
#define SI_CURVE_APPROX_11      "DC_Relative"
 
215
 
 
216
/* reflection method */
 
217
#define SI_REFLECT_NUM          4
 
218
#define SI_REFLECT_1            "NoShading"
 
219
#define SI_REFLECT_2            "Ambient"
 
220
#define SI_REFLECT_3            "Diffuse"
 
221
#define SI_REFLECT_4            "Specular"
 
222
/* others */
 
223
 
 
224
/* surface interpolation method */
 
225
#define SI_SURF_INTERP_NUM      1
 
226
#define SI_SURF_INTERP_1        "None"
 
227
/* others */
 
228
#define SI_SURF_INTERP_2        "Color"
 
229
#define SI_SURF_INTERP_3        "DotProduct"
 
230
#define SI_SURF_INTERP_4        "Normal"
 
231
 
 
232
/* surface approximation method */
 
233
#define SI_SURF_APPROX_NUM      6
 
234
#define SI_SURF_APPROX_1        "ConstantBetweenKnots"  /* (Imp. Dep.) */
 
235
#define SI_SURF_APPROX_2        "ConstantBetweenKnots"
 
236
#define SI_SURF_APPROX_3        "WCS_ChordalSize"
 
237
#define SI_SURF_APPROX_4        "NPC_ChordalSize"
 
238
#define SI_SURF_APPROX_6        "WCS_PlanarDev"
 
239
#define SI_SURF_APPROX_7        "NPC_PlanarDev"
 
240
/* others */ 
 
241
#define SI_SURF_APPROX_5        "DC_ChordalSize"
 
242
#define SI_SURF_APPROX_8        "DC_PlanarDev"
 
243
#define SI_SURF_APPROX_9        "WCS_Relative"
 
244
#define SI_SURF_APPROX_10       "NPC_Relative"
 
245
#define SI_SURF_APPROX_11       "DC_Relative"
 
246
 
 
247
/* trim curve approximation method */
 
248
#define SI_TRIM_CURVE_NUM       2
 
249
#define SI_TRIM_CURVE_1         "ConstantBetweenKnots"  /* (Imp. Dep.) */
 
250
#define SI_TRIM_CURVE_2         "ConstantBetweenKnots"
 
251
 
 
252
/* model clip operator */
 
253
#define SI_MODEL_CLIP_NUM       2
 
254
#define SI_MODEL_CLIP_1         "Replace"
 
255
#define SI_MODEL_CLIP_2         "Intersection"
 
256
 
 
257
/* light type */
 
258
#define SI_LIGHT_NUM            4
 
259
#define SI_LIGHT_1              "Ambient"
 
260
#define SI_LIGHT_2              "WCS_Vector"
 
261
#define SI_LIGHT_3              "WCS_Point"
 
262
#define SI_LIGHT_4              "WCS_Spot"
 
263
 
 
264
/* colour type */
 
265
#define SI_COLOUR_NUM           2
 
266
#define SI_COLOUR_0             "Indexed"
 
267
#define SI_COLOUR_1             "RGBFloat"
 
268
/* others */
 
269
#define SI_COLOUR_2             "CIEFloat"
 
270
#define SI_COLOUR_3             "HSVFloat"
 
271
#define SI_COLOUR_4             "HLSFloat"
 
272
#define SI_COLOUR_5             "RGBInt8"
 
273
#define SI_COLOUR_6             "RGBInt16"
 
274
 
 
275
/* float format */
 
276
#define SI_FLOAT_NUM            2
 
277
#define SI_FLOAT_1              "IEEE_754_32"
 
278
#define SI_FLOAT_2              "DEC_F_Floating"
 
279
/* others */
 
280
#define SI_FLOAT_3              "IEEE_754_64"
 
281
#define SI_FLOAT_4              "DEC_D_Floating"
 
282
 
 
283
/* hlhsr mode */
 
284
#define SI_HLHSR_NUM            1
 
285
#define SI_HLHSR_1              "Off"
 
286
/* others */
 
287
#define SI_HLHSR_2              "ZBuffer"
 
288
#define SI_HLHSR_3              "Painters"
 
289
#define SI_HLHSR_4              "Scanline"
 
290
#define SI_HLHSR_5              "HiddenLineOnly"
 
291
#define SI_HLHSR_6              "ZBufferId"
 
292
 
 
293
/* prompt echo type */
 
294
#define SI_PET_NUM              1
 
295
#define SI_PET_1                "EchoPrimitive"
 
296
/* others */
 
297
#define SI_PET_2                "EchoStructure"
 
298
#define SI_PET_3                "EchoNetwork"
 
299
 
 
300
/* display update mode */
 
301
#define SI_UPDATE_NUM           5
 
302
#define SI_UPDATE_1             "VisualizeEach"
 
303
#define SI_UPDATE_2             "VisualizeEasy"
 
304
#define SI_UPDATE_3             "VisualizeNone"
 
305
#define SI_UPDATE_4             "SimulateSome"
 
306
#define SI_UPDATE_5             "VisualizeWhenever"
 
307
 
 
308
/* colour approximation type */
 
309
#define SI_CLR_APPROX_TYPE_NUM  2
 
310
#define SI_CLR_APPROX_TYPE_1    "ColorSpace"
 
311
#define SI_CLR_APPROX_TYPE_2    "ColorRange"
 
312
 
 
313
/* colour approximation model */
 
314
#define SI_CLR_APPROX_MODEL_NUM 1
 
315
#define SI_CLR_APPROX_MODEL_1   "RGB"
 
316
/* others */
 
317
#define SI_CLR_APPROX_MODEL_2   "CIE"
 
318
#define SI_CLR_APPROX_MODEL_3   "HSV"
 
319
#define SI_CLR_APPROX_MODEL_4   "HLS"
 
320
#define SI_CLR_APPROX_MODEL_5   "YIQ"
 
321
 
 
322
/* gdp */
 
323
#define SI_GDP_NUM              0
 
324
 
 
325
/* gdp3 */
 
326
#define SI_GDP3_NUM             0
 
327
 
 
328
/* gse */
 
329
#define SI_GSE_NUM              0
 
330
 
 
331
/* escape */
 
332
#define SI_ESCAPE_NUM           1
 
333
#define SI_ESCAPE_1             "SetEchoColor"
 
334
 
 
335
/* rendering colour model */
 
336
#define SI_REND_COLOUR_NUM      1
 
337
#define SI_REND_COLOUR_1                "RGB"
 
338
/* others */
 
339
#define SI_REND_COLOUR_0                "(Imp. Dep.)"
 
340
#define SI_REND_COLOUR_2                "CIE"
 
341
#define SI_REND_COLOUR_3                "HSV"
 
342
#define SI_REND_COLOUR_4                "HLS"
 
343
 
 
344
/* parametric surface characteristics */
 
345
#define SI_P_SURF_CHAR_NUM      3
 
346
#define SI_P_SURF_CHAR_1        "None"
 
347
#define SI_P_SURF_CHAR_2        "None"
 
348
#define SI_P_SURF_CHAR_3        "IsoparametricCurves"
 
349
/* others */ 
 
350
#define SI_P_SURF_CHAR_4        "MC_LevelCurves"
 
351
#define SI_P_SURF_CHAR_5        "WC_Levelcurves"
 
352
 
 
353
#endif                            /* MI_INFO_H */