summaryrefslogtreecommitdiff
path: root/app/xgc/Written/Jim
blob: e370cd51b12a1ea37cc8839791d58957a28674e3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
The Commands menu should contain the following items:

    Run                                                [the selected benchmark]
    Benchmark Options.../Hide Benchmark Options                        [toggle]
    Graphics Options.../Hide Graphics Options                          [toggle]
    Describe Test.../Hide Test Description                             [toggle]
    Start Recording/Stop Recording                                     [toggle]
    Playback                        [pop up a dialogue box asking for filename]
    --------
    Quit                   [pop up a dialogue box asking if we are really done]


The Benchmark Options sheet should contain the information shown below.  The
list of graphics primitives was derived from the "Definition of the Porting
Layer for the X v11 Sample Server" by Angebranndt et al. and from the Protocol
document.


			       Benchmark Options


            +-----------------------+-----------------------+
 Test       |      Copy Area        |      Copy Plane       |
            +-----------------------+-----------------------+
            |        Points         |        Lines          |
            +-----------------------+-----------------------+
            |       Segments        |      Rectangles       |
            +-----------------------+-----------------------+
            |         Arcs          |    Filled Polygons    |
            +-----------------------+-----------------------+
            |   Filled Rectangles   |      Filled Arcs      |
            +-----------------------+-----------------------+
            |       Put Image       |       Get Image       |
            +-----------------------+-----------------------+
            |        Text 8         |      Image Text 8     |
            +-----------------------+-----------------------+
            |        Text 16        |      Image Text 16    |
            +-----------------------+-----------------------+

            +---------+
 Iterations |   10000 |
            +---------+

            +----+-----+                         +----+-----+
 Record     | on | off |          Describe Test  | on | off |
            +----+-----+                         +----+-----+

            +-----------------------------------------------+
 Filename   |                                  ./xbench.log |
            +-----------------------------------------------+


*******************************************************************************


The Graphics Options area would contain the following entries:

    Function - one-of { clear, and, andReverse, copy, andInverted, noop, xor, 
		        or, nor, equiv, invert, orReverse, copyInverted, 
		        orInverted, nand, set }
    PlaneMask - unsigned value or many-of-n representing bits
    Foreground - unsigned value in range 0..2^nplanes
    Background - unsigned value in range 0..2^nplanes
    ForegroundColor - set rgb value of Foreground
    BackgroundColor - set rgb value of background
    LineWidth - unsigned number in range 0..65535
    LineStyle - oneof { Solid, OnOffDash, DoubleDash }
    CapStyle - one-of { NotLast, Butt, Round, Projecting }
    JoinStyle - one-of { Miter, Round, Bevel }
    FillStyle - one-of { Solid, Tiled, OpaqueStippled, Stippled }
    FillRule - one-of { EvenOdd, Winding }
    ArcMode - one-of { Chord, PieSlice }
    # Tile - pixmap [probably not edittable in first version]
    # Stipple - pixmap [probably not edittable in first version]
    TileStipXOrigin - signed number in range -32768..32767
    TileStipYOrigin - signed number in range -32768..32767
    Font - name of font
    ClipXOrigin - signed number in range -32768..32767
    ClipYOrigin - signed number in range -32768..32767
    ClipMask - one-of { None, select } [user selects by clicking in work area]
    DashOffset - unsigned number in range -32768..32767
    DashList - many-of-n of 8 boxes for defining dashes




			       Graphics Options


             +--------------+--------------+--------------+--------------+
 Function    |     clear    |      and     |  andReverse  |     copy     |
             +--------------+--------------+--------------+--------------+
             | andInverted  |     noop     |      xor     |      or      |
             +--------------+--------------+--------------+--------------+
             |      nor     |     equiv    |    invert    |   orReverse  |
             +--------------+--------------+--------------+--------------+
             | copyInverted |  orInverted  |     nand     |      set     |
             +--------------+--------------+--------------+--------------+

             +-----+---------+
 Colormap    | new | default |
             +-----+---------+

             +----------+                     +--------+--------+--------+
 Foreground  |        1 |    ForegroundColor  |  ffff  |  ffff  |  ffff  |
             +----------+                     +--------+--------+--------+

             +----------+                     +--------+--------+--------+
 Background  |        0 |    BackgroundColor  |  0000  |  0000  |  0000  |
             +----------+                     +--------+--------+--------+

             +------+                   +-------+-----------+------------+
 LineWidth   |    3 |        LineStyle  | Solid | OnOffDash | DoubleDash |
             +------+                   +-------+-----------+------------+

             +---------+------+-------+------------+
 CapStyle    | NotLast | Butt | Round | Projecting |
             +---------+------+-------+------------+

             +-------+-------+-------+
 JoinStyle   | Miter | Round | Bevel |
             +-------+-------+-------+

             +-------+-------+----------+----------------+
 FillStyle   | Solid | Tiled | Stippled | OpaqueStippled |
             +-------+-------+----------+----------------+

             +---------+---------+
 FillRule    | EvenOdd | Winding |
             +---------+---------+

             +-------+----------+
 ArcMode     | Chord | PieSlice |
             +-------+----------+

             +--------------+
 TStipOrigin | +####, +#### |
             +--------------+

             +-+-+-+-+-+-+-+-+                                   +-------+
 DashList    | | |X|X| | |X|X|                       DashOffset  | +#### |
             +-+-+-+-+-+-+-+-+                                   +-------+

             +----+-----+-----+-------+                         +--------+
 ClipMask    | on | off | set | clear |             PlaneMask   |  ffff  |
             +----+-----+-----+-------+                         +--------+


*******************************************************************************

				    Grammar


Both to support Record/Playback (used for debugging, demonstrations, and for
creating benchmark scripts), there needs to be a command line language that
can be used to set all options.  Although we won't be doing anything as
sophisticated as what is provided in many UIMS's, it would be nice to keep
the application section of the benchmark as separate as possible from the
user interface.

    test  { CopyArea, CopyPlane, PolyPoint, PolyLine, PolySegment, 
	    PolyRectangle, PolyArc, FillPolygon, PolyFillRect, PolyFillArc,
	    PutImage, GetImage, ImageText8, PolyText8, ImageText16,
	    PolyText16 }
	-  selects the test to be performed.

    colormap  { new, default }
	-  selects which colormap should be used for test

    iterations UNSIGNEDNUMBER
	-  specifies the number of times that the test should be run.

    record BOOLEAN
	-  indicates whether or not to record commands into the record-file.

    record-file  FILENAME
	-  specifies the name of the file into which commands are recorded.

    describe  BOOLEAN
	-  indicates whether or not a description of the test should be 
	   displayed whenever a test is selected (or when this option is
	   specified).

    function  { clear, and, andReverse, copy, andInverted, noop, xor, or, nor,
		equiv, invert, orReverse, copyInverted, orInverted, nand, set }
	-  selects the alu function to use in the GC.

    foreground UNSIGNEDNUMBER
	-  selects the foreground pixel value to use in the GC; if a new
	   colormap is being used, the RGB value for this slot may be changed.

    background UNSIGNEDNUMBER
	-  selects the background pixel value to use in the GC; if a new
	   colormap is being used, the RGB value for this slot may be changed.

    forecolor COLORNAME
	-  specifies the RGB value or name of the color to be used for the 
	   foreground pixel, if settable.

    backcolor COLORNAME
	-  specifies the RGB value or name of the color to be used for the 
	   background pixel, if settable.

    linewidth NUMBER
	-  specifies width of lines to use in the GC.

    linestyle  { Solid, OnOffDash, DoubleDash }
	-  selects the type of lines to use in the GC.

    capstyle  { NotLast, Butt, Round, Projecting }
	-  selects the type of caps to use in the GC.

    joinstyle  { Miter, Round, Bevel }
	-  selects the type of joins to use in the GC.

    fillstyle  { Solid, Tiled, Stippled, OpaqueStippled }
	-  selects the type of fills to use in the GC.

    fillrule  { EvenOdd, Winding }
	-  selects the fill rule to be used in the GC.

    arcmode  { Chord, PieSlice }
	-  selects the type of arcs to be drawn in the GC.

    tsorigin  NUMBER  NUMBER
	-  specifies the X and Y values of the TileStippleOrigin in the GC.

    dashlist  DASHPATTERN
	-  specifies a pattern of 8 binary digits to use in the dashlist
	   in the GC; the characters are given in big-endian order such that
	   they may be read in binary to form a number between 0 and 255.

    dashoffset  NUMBER
	-  specifies the dashoffset to use in the GC.

    cliporigin  NUMBER  NUMBER
	-  specifies the X and Y values of the cliporigin in the GC.

    clipmask  { on, off, set NUMBER NUMBER NUMBER NUMBER, clear }
	-  selects a clipping mode.  If "on", then use the most recently
	   defined set of clipping rectangles; if "off", then do not do
	   any clipping but keep the clipping rectangles for future
	   reference; if "set", then add the rectangle specified by
	   the remaining numeric arguments as X1 Y1 X2 Y2 relative to the
	   cliporigin.

    planemask  NUMBER
	-  specifies the set of planes on to which graphics may be drawn
	   in the GC.

    run
	-  run the currently configured test.

    quit
	-  exit the program