-
Notifications
You must be signed in to change notification settings - Fork 13
/
enums_windows.go
2122 lines (2043 loc) · 94.6 KB
/
enums_windows.go
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
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
package d3d9
// BACKBUFFER_TYPE defines constants that describe the type of a back buffer.
type BACKBUFFER_TYPE uint32
const (
// BACKBUFFER_TYPE_MONO specifies a nonstereo swap chain.
BACKBUFFER_TYPE_MONO = 0
// BACKBUFFER_TYPE_LEFT specifies the left side of a stereo pair in a swap
// chain.
BACKBUFFER_TYPE_LEFT = 1
// BACKBUFFER_TYPE_RIGHT specifies the right side of a stereo pair in a
// swap chain.
BACKBUFFER_TYPE_RIGHT = 2
)
// BASISTYPE defines the basis type of a high-order patch surface.
type BASISTYPE uint32
const (
// BASIS_BEZIER means input vertices are treated as a series of Bézier
// patches. The number of vertices specified must be divisible by 4.
// Portions of the mesh beyond this criterion will not be rendered. Full
// continuity is assumed between sub-patches in the interior of the surface
// rendered by each call. Only the vertices at the corners of each
// sub-patch are guaranteed to lie on the resulting surface.
BASIS_BEZIER = 0
// BASIS_BSPLINE means input vertices are treated as control points of a
// B-spline surface. The number of apertures rendered is two fewer than the
// number of apertures in that direction. In general, the generated surface
// does not contain the control vertices specified.
BASIS_BSPLINE = 1
// BASIS_CATMULL_ROM means an interpolating basis defines the surface so
// that the surface goes through all the input vertices specified. In
// DirectX 8, this was BASIS_INTERPOLATE.
BASIS_CATMULL_ROM = 2
)
// BLEND defines the supported blend mode.
type BLEND uint32
const (
// BLEND_ZERO Blend factor is (0, 0, 0, 0).
BLEND_ZERO = 1
// BLEND_ONE Blend factor is (1, 1, 1, 1).
BLEND_ONE = 2
// BLEND_SRCCOLOR Blend factor is (Rs, Gs, Bs, As).
BLEND_SRCCOLOR = 3
// BLEND_INVSRCCOLOR Blend factor is (1 - Rs, 1 - Gs, 1 - Bs, 1 - As).
BLEND_INVSRCCOLOR = 4
// BLEND_SRCALPHA Blend factor is (As, As, As, As).
BLEND_SRCALPHA = 5
// BLEND_INVSRCALPHA Blend factor is ( 1 - As, 1 - As, 1 - As, 1 - As).
BLEND_INVSRCALPHA = 6
// BLEND_DESTALPHA Blend factor is (Ad, Ad, Ad, Ad).
BLEND_DESTALPHA = 7
// BLEND_INVDESTALPHA Blend factor is (1 - Ad, 1 - Ad, 1 - Ad, 1 - Ad).
BLEND_INVDESTALPHA = 8
// BLEND_DESTCOLOR Blend factor is (Rd, Gd, Bd, Ad).
BLEND_DESTCOLOR = 9
// BLEND_INVDESTCOLOR Blend factor is (1 - Rd, 1 - Gd, 1 - Bd, 1 - Ad).
BLEND_INVDESTCOLOR = 10
// BLEND_SRCALPHASAT Blend factor is (f, f, f, 1); where f = min(As, 1 -
// Ad).
BLEND_SRCALPHASAT = 11
// BLEND_BOTHSRCALPHA is obsolete. Starting with DirectX 6, you can achieve
// the same effect by setting the source and destination blend factors to
// BLEND_SRCALPHA and BLEND_INVSRCALPHA in separate calls.
BLEND_BOTHSRCALPHA = 12
// BLEND_BOTHINVSRCALPHA is obsolete. Source blend factor is (1 - As, 1 -
// As, 1 - As, 1 - As), and destination blend factor is (As, As, As, As);
// the destination blend selection is overridden. This blend mode is
// supported only for the RS_SRCBLEND render state.
BLEND_BOTHINVSRCALPHA = 13
// BLEND_BLENDFACTOR is a constant color blending factor used by the
// frame-buffer blender. This blend mode is supported only if
// PBLENDCAPS_BLENDFACTOR is set in the SrcBlendCaps or DestBlendCaps
// members of CAPS.
BLEND_BLENDFACTOR = 14
// BLEND_INVBLENDFACTOR is an inverted constant color-blending factor used
// by the frame-buffer blender. This blend mode is supported only if the
// PBLENDCAPS_BLENDFACTOR bit is set in the SrcBlendCaps or DestBlendCaps
// members of CAPS.
BLEND_INVBLENDFACTOR = 15
)
// BLENDOP defines the supported blend operations.
type BLENDOP uint32
const (
// BLENDOP_ADD means the result is the destination added to the source.
// Result = Source + Destination
BLENDOP_ADD = 1
// BLENDOP_SUBTRACT means the result is the destination subtracted from to
// the source. Result = Source - Destination
BLENDOP_SUBTRACT = 2
// BLENDOP_REVSUBTRACT means the result is the source subtracted from the
// destination. Result = Destination - Source
BLENDOP_REVSUBTRACT = 3
// BLENDOP_MIN means the result is the minimum of the source and
// destination. Result = MIN(Source, Destination)
BLENDOP_MIN = 4
// BLENDOP_MAX means the result is the maximum of the source and
// destination. Result = MAX(Source, Destination)
BLENDOP_MAX = 5
)
// CMPFUNC defines the supported compare functions.
type CMPFUNC uint32
const (
// CMP_NEVER always fails the test.
CMP_NEVER = 1
// CMP_LESS accepts the new pixel if its value is less than the value of
// the current pixel.
CMP_LESS = 2
// CMP_EQUAL accepts the new pixel if its value equals the value of the
// current pixel.
CMP_EQUAL = 3
// CMP_LESSEQUAL accepts the new pixel if its value is less than or equal
// to the value of the current pixel.
CMP_LESSEQUAL = 4
// CMP_GREATER accepts the new pixel if its value is greater than the value
// of the current pixel.
CMP_GREATER = 5
// CMP_NOTEQUAL accepts the new pixel if its value does not equal the value
// of the current pixel.
CMP_NOTEQUAL = 6
// CMP_GREATEREQUAL accepts the new pixel if its value is greater than or
// equal to the value of the current pixel.
CMP_GREATEREQUAL = 7
// CMP_ALWAYS always passes the test.
CMP_ALWAYS = 8
)
// CUBEMAP_FACES defines the faces of a cubemap.
type CUBEMAP_FACES uint32
const (
// CUBEMAP_FACE_POSITIVE_X is the positive x-face of the cubemap.
CUBEMAP_FACE_POSITIVE_X = 0
// CUBEMAP_FACE_NEGATIVE_X is the negative x-face of the cubemap.
CUBEMAP_FACE_NEGATIVE_X = 1
// CUBEMAP_FACE_POSITIVE_Y is the positive y-face of the cubemap.
CUBEMAP_FACE_POSITIVE_Y = 2
// CUBEMAP_FACE_NEGATIVE_Y is the negative y-face of the cubemap.
CUBEMAP_FACE_NEGATIVE_Y = 3
// CUBEMAP_FACE_POSITIVE_Z is the positive z-face of the cubemap.
CUBEMAP_FACE_POSITIVE_Z = 4
// CUBEMAP_FACE_NEGATIVE_Z is the negative z-face of the cubemap.
CUBEMAP_FACE_NEGATIVE_Z = 5
)
// CULL defines the supported culling modes.
type CULL uint32
const (
// CULL_NONE does not cull back faces.
CULL_NONE = 1
// CULL_CW culls back faces with clockwise vertices.
CULL_CW = 2
// CULL_CCW culls back faces with counterclockwise vertices.
CULL_CCW = 3
)
// DEBUGMONITORTOKENS defines the debug monitor tokens.
type DEBUGMONITORTOKENS uint32
const (
// DMT_ENABLE enables the debug monitor.
DMT_ENABLE = 0
// DMT_DISABLE disables the debug monitor.
DMT_DISABLE = 1
)
// DECLMETHOD defines the vertex declaration method which is a predefined
// operation performed by the tessellator (or any procedural geometry routine
// on the vertex data during tessellation).
type DECLMETHOD byte
const (
// DECLMETHOD_DEFAULT is the default value. The tessellator copies the
// vertex data (spline data for patches) as is, with no additional
// calculations. When the tessellator is used, this element is
// interpolated. Otherwise vertex data is copied into the input register.
// The input and output type can be any value, but are always the same type.
DECLMETHOD_DEFAULT = 0
// DECLMETHOD_PARTIALU computes the tangent at a point on the rectangle or
// triangle patch in the U direction. The input type can be one of the
// following: DECLTYPE_D3DCOLOR, DECLTYPE_FLOAT3, DECLTYPE_FLOAT4,
// DECLTYPE_SHORT4, DECLTYPE_UBYTE4.
// The output type is always DECLTYPE_FLOAT3.
DECLMETHOD_PARTIALU = 1
// DECLMETHOD_PARTIALV Computes the tangent at a point on the rectangle or
// triangle patch in the V direction. The input type can be one of the
// following: DECLTYPE_D3DCOLOR, DECLTYPE_FLOAT3, DECLTYPE_FLOAT4,
// DECLTYPE_SHORT4, DECLTYPE_UBYTE4.
// The output type is always DECLTYPE_FLOAT3.
DECLMETHOD_PARTIALV = 2
// DECLMETHOD_CROSSUV computes the normal at a point on the rectangle or
// triangle patch by taking the cross product of two tangents. The input
// type can be one of the following: DECLTYPE_D3DCOLOR, DECLTYPE_FLOAT3,
// DECLTYPE_FLOAT4, DECLTYPE_SHORT4, DECLTYPE_UBYTE4.
// The output type is always DECLTYPE_FLOAT3.
DECLMETHOD_CROSSUV = 3
// DECLMETHOD_UV copies out the U, V values at a point on the rectangle or
// triangle patch. This results in a 2D float. The input type must be set
// to DECLTYPE_UNUSED. The output data type is always DECLTYPE_FLOAT2. The
// input stream and offset are also unused (but must be set to 0).
DECLMETHOD_UV = 4
// DECLMETHOD_LOOKUP looks up a displacement map. The input type can be one
// of the following: DECLTYPE_FLOAT2, DECLTYPE_FLOAT3, DECLTYPE_FLOAT4.
// Only the X and Y components are used for the texture map lookup. The
// output type is always DECLTYPE_FLOAT1. The device must support
// displacement mapping. This constant is supported only by the
// programmable pipeline on N-patch data, if N-patches are enabled.
DECLMETHOD_LOOKUP = 5
// DECLMETHOD_LOOKUPPRESAMPLED looks up a presampled displacement map. The
// input type must be set to DECLTYPE_UNUSED; the stream index and the
// stream offset must be set to 0. The output type for this operation is
// always DECLTYPE_FLOAT1. The device must support displacement mapping.
// This constant is supported only by the programmable pipeline on N-patch
// data, if N-patches are enabled. This method can be used only with
// DECLUSAGE_SAMPLE.
DECLMETHOD_LOOKUPPRESAMPLED = 6
)
// DECLTYPE defines a vertex declaration data type.
type DECLTYPE byte
const (
// DECLTYPE_FLOAT1 is a one-component float expanded to (float, 0, 0, 1).
DECLTYPE_FLOAT1 = 0
// DECLTYPE_FLOAT2 is a two-component float expanded to (float, float, 0,
// 1).
DECLTYPE_FLOAT2 = 1
// DECLTYPE_FLOAT3 is a three-component float expanded to (float, float,
// float, 1).
DECLTYPE_FLOAT3 = 2
// DECLTYPE_FLOAT4 is a four-component float expanded to (float, float,
// float, float).
DECLTYPE_FLOAT4 = 3
// DECLTYPE_D3DCOLOR is a four-component, packed, unsigned bytes mapped to
// 0 to 1 range. Input is a COLOR and is expanded to RGBA order.
DECLTYPE_D3DCOLOR = 4
// DECLTYPE_UBYTE4 is a four-component, unsigned byte.
DECLTYPE_UBYTE4 = 5
// DECLTYPE_SHORT2 is a two-component, signed short expanded to (value,
// value, 0, 1).
DECLTYPE_SHORT2 = 6
// DECLTYPE_SHORT4 is a four-component, signed short expanded to (value,
// value, value, value).
DECLTYPE_SHORT4 = 7
// DECLTYPE_UBYTE4N is a four-component byte with each byte normalized by
// dividing with 255.0f.
DECLTYPE_UBYTE4N = 8
// DECLTYPE_SHORT2N is a normalized, two-component, signed short, expanded
// to (first short/32767.0, second short/32767.0, 0, 1).
DECLTYPE_SHORT2N = 9
// DECLTYPE_SHORT4N is a normalized, four-component, signed short, expanded
// to (first short/32767.0, second short/32767.0, third short/32767.0,
// fourth short/32767.0).
DECLTYPE_SHORT4N = 10
// DECLTYPE_USHORT2N is a normalized, two-component, unsigned short,
// expanded to (first short/65535.0, short short/65535.0, 0, 1).
DECLTYPE_USHORT2N = 11
// DECLTYPE_USHORT4N is a normalized, four-component, unsigned short,
// expanded to (first short/65535.0, second short/65535.0, third
// short/65535.0, fourth short/65535.0).
DECLTYPE_USHORT4N = 12
// DECLTYPE_UDEC3 is a three-component, unsigned, 10 10 10 format expanded
// to (value, value, value, 1).
DECLTYPE_UDEC3 = 13
// DECLTYPE_DEC3N is a three-component, signed, 10 10 10 format normalized
// and expanded to (v[0]/511.0, v[1]/511.0, v[2]/511.0, 1).
DECLTYPE_DEC3N = 14
// DECLTYPE_FLOAT16_2 is a two-component, 16-bit, floating point expanded
// to (value, value, 0, 1).
DECLTYPE_FLOAT16_2 = 15
// DECLTYPE_FLOAT16_4 is a four-component, 16-bit, floating point expanded
// to (value, value, value, value).
DECLTYPE_FLOAT16_4 = 16
// DECLTYPE_UNUSED means the type field in the declaration is unused. This
// is designed for use with DECLMETHOD_UV and DECLMETHOD_LOOKUPPRESAMPLED.
DECLTYPE_UNUSED = 17
)
// DECLUSAGE identifies the intended use of vertex data.
type DECLUSAGE byte
const (
// DECLUSAGE_POSITION means position data ranging from (-1,-1) to (1,1).
// Use DECLUSAGE_POSITION with a usage index of 0 to specify untransformed
// position for fixed function vertex processing and the n-patch
// tessellator. Use DECLUSAGE_POSITION with a usage index of 1 to specify
// untransformed position in the fixed function vertex shader for vertex
// tweening.
DECLUSAGE_POSITION = 0
// DECLUSAGE_BLENDWEIGHT means blending weight data. Use
// DECLUSAGE_BLENDWEIGHT with a usage index of 0 to specify the blend
// weights used in indexed and nonindexed vertex blending.
DECLUSAGE_BLENDWEIGHT = 1
// DECLUSAGE_BLENDINDICES means blending indices data. Use
// DECLUSAGE_BLENDINDICES with a usage index of 0 to specify matrix indices
// for indexed paletted skinning.
DECLUSAGE_BLENDINDICES = 2
// DECLUSAGE_NORMAL means vertex normal data. Use DECLUSAGE_NORMAL with a
// usage index of 0 to specify vertex normals for fixed function vertex
// processing and the n-patch tessellator. Use DECLUSAGE_NORMAL with a
// usage index of 1 to specify vertex normals for fixed function vertex
// processing for vertex tweening.
DECLUSAGE_NORMAL = 3
// DECLUSAGE_PSIZE means point size data. Use DECLUSAGE_PSIZE with a usage
// index of 0 to specify the point-size attribute used by the setup engine
// of the rasterizer to expand a point into a quad for the point-sprite
// functionality.
DECLUSAGE_PSIZE = 4
// DECLUSAGE_TEXCOORD means texture coordinate data. Use
// DECLUSAGE_TEXCOORD, n to specify texture coordinates in fixed function
// vertex processing and in pixel shaders prior to ps_3_0. These can be
// used to pass user defined data.
DECLUSAGE_TEXCOORD = 5
// DECLUSAGE_TANGENT means vertex tangent data.
DECLUSAGE_TANGENT = 6
// DECLUSAGE_BINORMAL means vertex binormal data.
DECLUSAGE_BINORMAL = 7
// DECLUSAGE_TESSFACTOR means a single positive floating point value. Use
// DECLUSAGE_TESSFACTOR with a usage index of 0 to specify a tessellation
// factor used in the tessellation unit to control the rate of tessellation.
DECLUSAGE_TESSFACTOR = 8
// DECLUSAGE_POSITIONT means the vertex data contains transformed position
// data ranging from (0,0) to (viewport width, viewport height). Use
// DECLUSAGE_POSITIONT with a usage index of 0 to specify transformed
// position. When a declaration containing this is set, the pipeline does
// not perform vertex processing.
DECLUSAGE_POSITIONT = 9
// DECLUSAGE_COLOR means the vertex data contains diffuse or specular
// color. Use DECLUSAGE_COLOR with a usage index of 0 to specify the
// diffuse color in the fixed function vertex shader and pixel shaders
// prior to ps_3_0. Use D3DDECLUSAGE_COLOR with a usage index of 1 to
// specify the specular color in the fixed function vertex shader and pixel
// shaders prior to ps_3_0.
DECLUSAGE_COLOR = 10
// DECLUSAGE_FOG means the vertex data contains fog data. Use DECLUSAGE_FOG
// with a usage index of 0 to specify a fog blend value used after pixel
// shading finishes. This applies to pixel shaders prior to version ps_3_0.
DECLUSAGE_FOG = 11
// DECLUSAGE_DEPTH means the vertex data contains depth data.
DECLUSAGE_DEPTH = 12
// DECLUSAGE_SAMPLE means the vertex data contains sampler data. Use
// DECLUSAGE_SAMPLE with a usage index of 0 to specify the displacement
// value to look up. It can be used only with
// DECLUSAGE_LOOKUPPRESAMPLED or DECLUSAGE_LOOKUP.
DECLUSAGE_SAMPLE = 13
)
// DEGREETYPE defines the degree of the variables in the equation that
// describes a curve.
type DEGREETYPE uint32
const (
// DEGREE_LINEAR means the curve is described by variables of first order.
DEGREE_LINEAR = 1
// DEGREE_QUADRATIC means the curve is described by variables of second
// order.
DEGREE_QUADRATIC = 2
// DEGREE_CUBIC means the curve is described by variables of third order.
DEGREE_CUBIC = 3
// DEGREE_QUINTIC means the curve is described by variables of fourth order.
DEGREE_QUINTIC = 5
)
// DEVTYPE defines device types.
type DEVTYPE uint32
const (
// DEVTYPE_HAL indicates hardware rasterization. Shading is done with
// software, hardware, or mixed transform and lighting.
DEVTYPE_HAL = 1
// DEVTYPE_REF means Direct3D features are implemented in software;
// however, the reference rasterizer does make use of special CPU
// instructions whenever it can.
// The reference device is installed by the Windows SDK 8.0 or later and is
// intended as an aid in debugging for development only.
DEVTYPE_REF = 2
// DEVTYPE_SW is a pluggable software device that has been registered with
// Direct3D.RegisterSoftwareDevice.
DEVTYPE_SW = 3
// DEVTYPE_NULLREF initializes Direct3D on a computer that has neither
// hardware nor reference rasterization available, and enable resources for
// 3D content creation.
DEVTYPE_NULLREF = 4
)
// FILLMODE defines constants describing the fill mode.
type FILLMODE uint32
const (
// FILL_POINT fills points.
FILL_POINT = 1
// FILL_WIREFRAME fills wireframes.
FILL_WIREFRAME = 2
// FILL_SOLID fills solids.
FILL_SOLID = 3
)
// FOGMODE defines constants that describe the fog mode.
type FOGMODE uint32
const (
// FOG_NONE means no fog effect.
FOG_NONE = 0
// FOG_EXP means the fog effect intensifies exponentially, according to the
// following formula:
// f = 1/(e^(d*density))
FOG_EXP = 1
// FOG_EXP2 means the fog effect intensifies exponentially with the square
// of the distance, according to the following formula:
// f = 1/(e^[(d*density)^2])
FOG_EXP2 = 2
// FOG_LINEAR means the fog effect intensifies linearly between the start
// and end points, according to the following formula:
// f = (end - d)/(end - start)
// This is the only fog mode currently supported.
FOG_LINEAR = 3
)
// FORMAT defines the various types of surface formats.
type FORMAT uint32
func (f FORMAT) String() string {
switch f {
default:
return "UNKNOWN"
case FMT_R8G8B8:
return "R8G8B8"
case FMT_A8R8G8B8:
return "A8R8G8B8"
case FMT_X8R8G8B8:
return "X8R8G8B8"
case FMT_R5G6B5:
return "R5G6B5"
case FMT_X1R5G5B5:
return "X1R5G5B5"
case FMT_A1R5G5B5:
return "A1R5G5B5"
case FMT_A4R4G4B4:
return "A4R4G4B4"
case FMT_R3G3B2:
return "R3G3B2"
case FMT_A8:
return "A8"
case FMT_A8R3G3B2:
return "A8R3G3B2"
case FMT_X4R4G4B4:
return "X4R4G4B4"
case FMT_A2B10G10R10:
return "A2B10G10R10"
case FMT_A8B8G8R8:
return "A8B8G8R8"
case FMT_X8B8G8R8:
return "X8B8G8R8"
case FMT_G16R16:
return "G16R16"
case FMT_A2R10G10B10:
return "A2R10G10B10"
case FMT_A16B16G16R16:
return "A16B16G16R16"
case FMT_A8P8:
return "A8P8"
case FMT_P8:
return "P8"
case FMT_L8:
return "L8"
case FMT_A8L8:
return "A8L8"
case FMT_A4L4:
return "A4L4"
case FMT_V8U8:
return "V8U8"
case FMT_L6V5U5:
return "L6V5U5"
case FMT_X8L8V8U8:
return "X8L8V8U8"
case FMT_Q8W8V8U8:
return "Q8W8V8U8"
case FMT_V16U16:
return "V16U16"
case FMT_A2W10V10U10:
return "A2W10V10U10"
case FMT_UYVY:
return "UYVY"
case FMT_R8G8_B8G8:
return "R8G8_B8G8"
case FMT_YUY2:
return "YUY2"
case FMT_G8R8_G8B8:
return "G8R8_G8B8"
case FMT_DXT1:
return "DXT1"
case FMT_DXT2:
return "DXT2"
case FMT_DXT3:
return "DXT3"
case FMT_DXT4:
return "DXT4"
case FMT_DXT5:
return "DXT5"
case FMT_D16_LOCKABLE:
return "D16_LOCKABLE"
case FMT_D32:
return "D32"
case FMT_D15S1:
return "D15S1"
case FMT_D24S8:
return "D24S8"
case FMT_D24X8:
return "D24X8"
case FMT_D24X4S4:
return "D24X4S4"
case FMT_D16:
return "D16"
case FMT_L16:
return "L16"
case FMT_D32F_LOCKABLE:
return "D32F_LOCKABLE"
case FMT_D24FS8:
return "D24FS8"
case FMT_VERTEXDATA:
return "VERTEXDATA"
case FMT_INDEX16:
return "INDEX16"
case FMT_INDEX32:
return "INDEX32"
case FMT_Q16W16V16U16:
return "Q16W16V16U16"
case FMT_MULTI2_ARGB8:
return "MULTI2_ARGB8"
case FMT_R16F:
return "R16F"
case FMT_G16R16F:
return "G16R16F"
case FMT_A16B16G16R16F:
return "A16B16G16R16F"
case FMT_R32F:
return "R32F"
case FMT_G32R32F:
return "G32R32F"
case FMT_A32B32G32R32F:
return "A32B32G32R32F"
case FMT_CxV8U8:
return "CxV8U8"
}
}
const (
// FMT_UNKNOWN means the surface format is unknown.
FMT_UNKNOWN = 0
// FMT_R8G8B8 means 24-bit RGB pixel format with 8 bits per channel.
FMT_R8G8B8 = 20
// FMT_A8R8G8B8 means 32-bit ARGB pixel format with alpha, using 8 bits per
// channel.
FMT_A8R8G8B8 = 21
// FMT_X8R8G8B8 means 32-bit RGB pixel format, where 8 bits are reserved
// for each color.
FMT_X8R8G8B8 = 22
// FMT_R5G6B5 means 16-bit RGB pixel format with 5 bits for red, 6 bits for
// green, and 5 bits for blue.
FMT_R5G6B5 = 23
// FMT_X1R5G5B5 means 16-bit pixel format where 5 bits are reserved for
// each color.
FMT_X1R5G5B5 = 24
// FMT_A1R5G5B5 means 16-bit pixel format where 5 bits are reserved for
// each color and 1 bit is reserved for alpha.
FMT_A1R5G5B5 = 25
// FMT_A4R4G4B4 means 16-bit ARGB pixel format with 4 bits for each channel.
FMT_A4R4G4B4 = 26
// FMT_R3G3B2 means 8-bit RGB texture format using 3 bits for red, 3 bits
// for green, and 2 bits for blue.
FMT_R3G3B2 = 27
// FMT_A8 means 8-bit alpha only.
FMT_A8 = 28
// FMT_A8R3G3B2 means 16-bit ARGB texture format using 8 bits for alpha, 3
// bits each for red and green, and 2 bits for blue.
FMT_A8R3G3B2 = 29
// FMT_X4R4G4B4 means 16-bit RGB pixel format using 4 bits for each color.
FMT_X4R4G4B4 = 30
// FMT_A2B10G10R10 means 32-bit pixel format using 10 bits for each color
// and 2 bits for alpha.
FMT_A2B10G10R10 = 31
// FMT_A8B8G8R8 means 32-bit ARGB pixel format with alpha, using 8 bits per
// channel.
FMT_A8B8G8R8 = 32
// FMT_X8B8G8R8 means 32-bit RGB pixel format, where 8 bits are reserved
// for each color.
FMT_X8B8G8R8 = 33
// FMT_G16R16 means 32-bit pixel format using 16 bits each for green and
// red.
FMT_G16R16 = 34
// FMT_A2R10G10B10 means 32-bit pixel format using 10 bits each for red,
// green, and blue, and 2 bits for alpha.
FMT_A2R10G10B10 = 35
// FMT_A16B16G16R16 means 64-bit pixel format using 16 bits for each
// component.
FMT_A16B16G16R16 = 36
// FMT_A8P8 means 8-bit color indexed with 8 bits of alpha.
FMT_A8P8 = 40
// FMT_P8 means 8-bit color indexed.
FMT_P8 = 41
// FMT_L8 means 8-bit luminance only.
FMT_L8 = 50
// FMT_A8L8 means 16-bit using 8 bits each for alpha and luminance.
FMT_A8L8 = 51
// FMT_A4L4 means 8-bit using 4 bits each for alpha and luminance.
FMT_A4L4 = 52
// FMT_V8U8 means 16-bit bump-map format using 8 bits each for u and v data.
FMT_V8U8 = 60
// FMT_L6V5U5 means 16-bit bump-map format with luminance using 6 bits for
// luminance, and 5 bits each for v and u.
FMT_L6V5U5 = 61
// FMT_X8L8V8U8 means 32-bit bump-map format with luminance using 8 bits
// for each channel.
FMT_X8L8V8U8 = 62
// FMT_Q8W8V8U8 means 32-bit bump-map format using 8 bits for each channel.
FMT_Q8W8V8U8 = 63
// FMT_V16U16 means 32-bit bump-map format using 16 bits for each channel.
FMT_V16U16 = 64
// FMT_A2W10V10U10 means 32-bit bump-map format using 2 bits for alpha and
// 10 bits each for w, v, and u.
FMT_A2W10V10U10 = 67
// FMT_UYVY means UYVY format (PC98 compliance).
FMT_UYVY = 1498831189
// FMT_R8G8_B8G8 is a 16-bit packed RGB format analogous to UYVY (U0Y0,
// V0Y1, U2Y2, and so on). It requires a pixel pair in order to properly
// represent the color value. The first pixel in the pair contains 8 bits
// of green (in the low 8 bits) and 8 bits of red (in the high 8 bits). The
// second pixel contains 8 bits of green (in the low 8 bits) and 8 bits of
// blue (in the high 8 bits). Together, the two pixels share the red and
// blue components, while each has a unique green component (R0G0, B0G1,
// R2G2, and so on). The texture sampler does not normalize the colors when
// looking up into a pixel shader; they remain in the range of 0.0f to
// 255.0f. This is true for all programmable pixel shader models. For the
// fixed function pixel shader, the hardware should normalize to the 0.f to
// 1.f range and essentially treat it as the YUY2 texture. Hardware that
// exposes this format must have PixelShader1xMaxValue member of CAPS set
// to a value capable of handling that range.
FMT_R8G8_B8G8 = 1195525970
// FMT_YUY2 means YUY2 format (PC98 compliance).
FMT_YUY2 = 844715353
// FMT_G8R8_G8B8 is a 16-bit packed RGB format analogous to YUY2 (Y0U0,
// Y1V0, Y2U2, and so on). It requires a pixel pair in order to properly
// represent the color value. The first pixel in the pair contains 8 bits
// of green (in the high 8 bits) and 8 bits of red (in the low 8 bits). The
// second pixel contains 8 bits of green (in the high 8 bits) and 8 bits of
// blue (in the low 8 bits). Together, the two pixels share the red and
// blue components, while each has a unique green component (G0R0, G1B0,
// G2R2, and so on). The texture sampler does not normalize the colors when
// looking up into a pixel shader; they remain in the range of 0.0f to
// 255.0f. This is true for all programmable pixel shader models. For the
// fixed function pixel shader, the hardware should normalize to the 0.f to
// 1.f range and essentially treat it as the YUY2 texture. Hardware that
// exposes this format must have the PixelShader1xMaxValue member of CAPS
// set to a value capable of handling that range.
FMT_G8R8_G8B8 = 1111970375
// FMT_DXT1 means DXT1 compression texture format.
FMT_DXT1 = 827611204
// FMT_DXT2 means DXT2 compression texture format.
FMT_DXT2 = 844388420
// FMT_DXT3 means DXT3 compression texture format.
FMT_DXT3 = 861165636
// FMT_DXT4 means DXT4 compression texture format.
FMT_DXT4 = 877942852
// FMT_DXT5 means DXT5 compression texture format.
FMT_DXT5 = 894720068
// FMT_D16_LOCKABLE means 16-bit z-buffer bit depth.
FMT_D16_LOCKABLE = 70
// FMT_D32 means 32-bit z-buffer bit depth.
FMT_D32 = 71
// FMT_D15S1 means 16-bit z-buffer bit depth where 15 bits are reserved for
// the depth channel and 1 bit is reserved for the stencil channel.
FMT_D15S1 = 73
// FMT_D24S8 means 32-bit z-buffer bit depth using 24 bits for the depth
// channel and 8 bits for the stencil channel.
FMT_D24S8 = 75
// FMT_D24X8 means 32-bit z-buffer bit depth using 24 bits for the depth
// channel.
FMT_D24X8 = 77
// FMT_D24X4S4 means 32-bit z-buffer bit depth using 24 bits for the depth
// channel and 4 bits for the stencil channel.
FMT_D24X4S4 = 79
// FMT_D16 means 16-bit z-buffer bit depth.
FMT_D16 = 80
// FMT_L16 means 16-bit luminance only.
FMT_L16 = 81
// FMT_D32F_LOCKABLE is a lockable format where the depth value is
// represented as a standard IEEE floating-point number.
FMT_D32F_LOCKABLE = 82
// FMT_D24FS8 is a non-lockable format that contains 24 bits of depth (in a
// 24-bit floating point format - 20e4) and 8 bits of stencil.
FMT_D24FS8 = 83
// FMT_VERTEXDATA describes a vertex buffer surface.
FMT_VERTEXDATA = 100
// FMT_INDEX16 means 16-bit index buffer bit depth.
FMT_INDEX16 = 101
// FMT_INDEX32 means 32-bit index buffer bit depth.
FMT_INDEX32 = 102
// FMT_Q16W16V16U16 means 64-bit bump-map format using 16 bits for each
// component.
FMT_Q16W16V16U16 = 110
// FMT_MULTI2_ARGB8 means a multiElement texture (not compressed).
FMT_MULTI2_ARGB8 = 827606349
// FMT_R16F means 16-bit float format using 16 bits for the red channel.
FMT_R16F = 111
// FMT_G16R16F means 32-bit float format using 16 bits for the red channel
// and 16 bits for the green channel.
FMT_G16R16F = 112
// FMT_A16B16G16R16F means 64-bit float format using 16 bits for the each
// channel (alpha, blue, green, red).
FMT_A16B16G16R16F = 113
// FMT_R32F means 32-bit float format using 32 bits for the red channel.
FMT_R32F = 114
// FMT_G32R32F means 64-bit float format using 32 bits for the red channel
// and 32 bits for the green channel.
FMT_G32R32F = 115
// FMT_A32B32G32R32F means 128-bit float format using 32 bits for the each
// channel (alpha, blue, green, red).
FMT_A32B32G32R32F = 116
// FMT_CxV8U8 means 16-bit normal compression format. The texture sampler
// computes the C channel from: C = sqrt(1 - U² - V²).
FMT_CxV8U8 = 117
)
// LIGHTTYPE defines the light type.
type LIGHTTYPE uint32
const (
// LIGHT_POINT means the light is a point source. The light has a position
// in space and radiates light in all directions.
LIGHT_POINT = 1
// LIGHT_SPOT means the light is a spotlight source. This light is like a
// point light, except that the illumination is limited to a cone. This
// light type has a direction and several other parameters that determine
// the shape of the cone it produces.
LIGHT_SPOT = 2
// LIGHT_DIRECTIONAL means the light is a directional light source. This is
// equivalent to using a point light source at an infinite distance.
LIGHT_DIRECTIONAL = 3
)
// MATERIALCOLORSOURCE defines the location at which a color or color component
// must be accessed for lighting calculations.
type MATERIALCOLORSOURCE uint32
const (
// MCS_MATERIAL uses the color from the current material.
MCS_MATERIAL = 0
// MCS_COLOR1 uses the diffuse vertex color.
MCS_COLOR1 = 1
// MCS_COLOR2 uses the specular vertex color.
MCS_COLOR2 = 2
)
// MULTISAMPLE_TYPE defines the levels of full-scene multisampling that the
// device can apply.
type MULTISAMPLE_TYPE uint32
const (
// MULTISAMPLE_NONE means no level of full-scene multisampling is available.
MULTISAMPLE_NONE = 0
// MULTISAMPLE_NONMASKABLE enables the multisample quality value.
MULTISAMPLE_NONMASKABLE = 1
// MULTISAMPLE_2_SAMPLES means 2 levels of full-scene multisampling
// available.
MULTISAMPLE_2_SAMPLES = 2
// MULTISAMPLE_3_SAMPLES means 3 levels of full-scene multisampling
// available.
MULTISAMPLE_3_SAMPLES = 3
// MULTISAMPLE_4_SAMPLES means 4 levels of full-scene multisampling
// available.
MULTISAMPLE_4_SAMPLES = 4
// MULTISAMPLE_5_SAMPLES means 5 levels of full-scene multisampling
// available.
MULTISAMPLE_5_SAMPLES = 5
// MULTISAMPLE_6_SAMPLES means 6 levels of full-scene multisampling
// available.
MULTISAMPLE_6_SAMPLES = 6
// MULTISAMPLE_7_SAMPLES means 7 levels of full-scene multisampling
// available.
MULTISAMPLE_7_SAMPLES = 7
// MULTISAMPLE_8_SAMPLES means 8 levels of full-scene multisampling
// available.
MULTISAMPLE_8_SAMPLES = 8
// MULTISAMPLE_9_SAMPLES means 9 levels of full-scene multisampling
// available.
MULTISAMPLE_9_SAMPLES = 9
// MULTISAMPLE_10_SAMPLES means 10 levels of full-scene multisampling
// available.
MULTISAMPLE_10_SAMPLES = 10
// MULTISAMPLE_11_SAMPLES means 11 levels of full-scene multisampling
// available.
MULTISAMPLE_11_SAMPLES = 11
// MULTISAMPLE_12_SAMPLES means 12 levels of full-scene multisampling
// available.
MULTISAMPLE_12_SAMPLES = 12
// MULTISAMPLE_13_SAMPLES means 13 levels of full-scene multisampling
// available.
MULTISAMPLE_13_SAMPLES = 13
// MULTISAMPLE_14_SAMPLES means 14 levels of full-scene multisampling
// available.
MULTISAMPLE_14_SAMPLES = 14
// MULTISAMPLE_15_SAMPLES means 15 levels of full-scene multisampling
// available.
MULTISAMPLE_15_SAMPLES = 15
// MULTISAMPLE_16_SAMPLES means 16 levels of full-scene multisampling
// available.
MULTISAMPLE_16_SAMPLES = 16
)
// PATCHEDGESTYLE defines whether the current tessellation mode is discrete or
// continuous.
type PATCHEDGESTYLE uint32
const (
// PATCHEDGE_DISCRETE means discrete edge style. In discrete mode, you can
// specify float tessellation but it will be truncated to integers.
PATCHEDGE_DISCRETE = 0
// PATCHEDGE_CONTINUOUS means continuous edge style. In continuous mode,
// tessellation is specified as float values that can be smoothly varied to
// reduce "popping" artifacts.
PATCHEDGE_CONTINUOUS = 1
)
// POOL defines the memory class that holds the buffers for a resource.
type POOL uint32
const (
// POOL_DEFAULT means resources are placed in the memory pool most
// appropriate for the set of usages requested for the given resource. This
// is usually video memory, including both local video memory and AGP
// memory. The POOL_DEFAULT pool is separate from POOL_MANAGED and
// POOL_SYSTEMMEM, and it specifies that the resource is placed in the
// preferred memory for device access. Note that POOL_DEFAULT never
// indicates that either POOL_MANAGED or POOL_SYSTEMMEM should be chosen as
// the memory pool type for this resource. Textures placed in the
// POOL_DEFAULT pool cannot be locked unless they are dynamic textures or
// they are private, FOURCC, driver formats. To access unlockable textures,
// you must use functions such as Device.UpdateSurface,
// Device.UpdateTexture, Device.GetFrontBufferData, and
// Device.GetRenderTargetData. POOL_MANAGED is probably a better choice
// than POOL_DEFAULT for most applications. Note that some textures created
// in driver-proprietary pixel formats, unknown to the Direct3D runtime,
// can be locked. Also note that - unlike textures - swap chain back
// buffers, render targets, vertex buffers, and index buffers can be
// locked. When a device is lost, resources created using POOL_DEFAULT must
// be released before calling Device.Reset.
// When creating resources with POOL_DEFAULT, if video card memory is
// already committed, managed resources will be evicted to free enough
// memory to satisfy the request.
POOL_DEFAULT = 0
// POOL_MANAGED means resources are copied automatically to
// device-accessible memory as needed. Managed resources are backed by
// system memory and do not need to be recreated when a device is lost.
// Managed resources can be locked. Only the system-memory copy is directly
// modified. Direct3D copies your changes to driver-accessible memory as
// needed.
// Differences between Direct3D 9 and Direct3D 9Ex: POOL_MANAGED is valid
// with Device; however, it is not valid with DeviceEx.
POOL_MANAGED = 1
// POOL_SYSTEMMEM means resources are placed in memory that is not
// typically accessible by the Direct3D device. This memory allocation
// consumes system RAM but does not reduce pageable RAM. These resources do
// not need to be recreated when a device is lost. Resources in this pool
// can be locked and can be used as the source for a Device.UpdateSurface
// or Device.UpdateTexture operation to a memory resource created with
// POOL_DEFAULT.
POOL_SYSTEMMEM = 2
// POOL_SCRATCH means resources are placed in system RAM and do not need to
// be recreated when a device is lost. These resources are not bound by
// device size or format restrictions. Because of this, these resources
// cannot be accessed by the Direct3D device nor set as textures or render
// targets. However, these resources can always be created, locked, and
// copied.
POOL_SCRATCH = 3
)
// PRIMITIVETYPE defines the primitives supported by Direct3D.
type PRIMITIVETYPE uint32
const (
// PT_POINTLIST renders the vertices as a collection of isolated points.
// This value is unsupported for indexed primitives.
PT_POINTLIST = 1
// PT_LINELIST renders the vertices as a list of isolated straight line
// segments.
PT_LINELIST = 2
// PT_LINESTRIP renders the vertices as a single polyline.
PT_LINESTRIP = 3
// PT_TRIANGLELIST renders the specified vertices as a sequence of isolated
// triangles. Each group of three vertices defines a separate triangle.
// Back-face culling is affected by the current winding-order render state.
PT_TRIANGLELIST = 4
// PT_TRIANGLESTRIP renders the vertices as a triangle strip. The
// backface-culling flag is automatically flipped on even-numbered
// triangles.
PT_TRIANGLESTRIP = 5
// PT_TRIANGLEFAN renders the vertices as a triangle fan.
PT_TRIANGLEFAN = 6
)
// QUERYTYPE identifies the query type.
type QUERYTYPE byte
const (
// QUERYTYPE_VCACHE queries for driver hints about data layout for vertex
// caching.
QUERYTYPE_VCACHE = 4
// QUERYTYPE_RESOURCEMANAGER queryies the resource manager. For this query,
// the device behavior flags must include CREATE_DISABLE_DRIVER_MANAGEMENT.
QUERYTYPE_RESOURCEMANAGER = 5
// QUERYTYPE_VERTEXSTATS queries vertex statistics.
QUERYTYPE_VERTEXSTATS = 6
// QUERYTYPE_EVENT queries for any and all asynchronous events that have
// been issued from API calls.
QUERYTYPE_EVENT = 8
// QUERYTYPE_OCCLUSION returns the number of pixels that pass z-testing.
// These pixels are for primitives drawn between the issue of ISSUE_BEGIN
// and ISSUE_END. This enables an application to check the occlusion result
// against 0. Zero is fully occluded, which means the pixels are not
// visible from the current camera position.
QUERYTYPE_OCCLUSION = 9
// QUERYTYPE_TIMESTAMP returns a 64-bit timestamp.
QUERYTYPE_TIMESTAMP = 10
// QUERYTYPE_TIMESTAMPDISJOINT notifies an application if the counter
// frequency has changed from the QUERYTYPE_TIMESTAMP.
QUERYTYPE_TIMESTAMPDISJOINT = 11
// QUERYTYPE_TIMESTAMPFREQ results in true if the values from
// QUERYTYPE_TIMESTAMP queries cannot be guaranteed to be continuous
// throughout the duration of the QUERYTYPE_TIMESTAMPDISJOINT query.
// Otherwise, the query result is false.
QUERYTYPE_TIMESTAMPFREQ = 12
// QUERYTYPE_PIPELINETIMINGS returns percent of time processing pipeline
// data.
QUERYTYPE_PIPELINETIMINGS = 13
// QUERYTYPE_INTERFACETIMINGS returns percent of time processing data in
// the driver.
QUERYTYPE_INTERFACETIMINGS = 14
// QUERYTYPE_VERTEXTIMINGS returns percent of time processing vertex shader
// data.
QUERYTYPE_VERTEXTIMINGS = 15
// QUERYTYPE_PIXELTIMINGS returns percent of time processing pixel shader
// data.
QUERYTYPE_PIXELTIMINGS = 16
// QUERYTYPE_BANDWIDTHTIMINGS is for throughput measurement comparisons for
// help in understanding the performance of an application.
QUERYTYPE_BANDWIDTHTIMINGS = 17
// QUERYTYPE_CACHEUTILIZATION measures the cache hit-rate performance for
// textures and indexed vertices.
QUERYTYPE_CACHEUTILIZATION = 18
)
// RENDERSTATETYPE defines set-up states for all kinds of vertex and pixel
// processing. Some render states set up vertex processing, and some set up
// pixel processing. Render states can be saved and restored using stateblocks.
type RENDERSTATETYPE uint32
const (
// RS_ZENABLE is the depth-buffering state as one member of the ZBUFFERTYPE
// enumerated type. Set this state to ZB_TRUE to enable z-buffering,
// ZB_USEW to enable w-buffering, or ZB_FALSE to disable depth buffering.
// The default value for this render state is ZB_TRUE if a depth stencil
// was created along with the swap chain by setting the
// EnableAutoDepthStencil member of the PRESENT_PARAMETERS structure to
// true, and ZB_FALSE otherwise.
RS_ZENABLE = 7
// RS_FILLMODE expects one or more members of the D3DFILLMODE enumerated
// type. The default value is D3DFILL_SOLID.
RS_FILLMODE = 8
// RS_SHADEMODE expects one or more members of the D3DSHADEMODE enumerated
// type. The default value is D3DSHADE_GOURAUD.
RS_SHADEMODE = 9
// RS_ZWRITEENABLE can be set to true to enable the application to write to
// the depth buffer. The default value is true. This member enables an
// application to prevent the system from updating the depth buffer with
// new depth values. If false, depth comparisons are still made according
// to the render state RS_ZFUNC, assuming that depth buffering is taking
// place, but depth values are not written to the buffer.
RS_ZWRITEENABLE = 14
// RS_ALPHATESTENABLE can be set to true to enable per pixel alpha testing.
// If the test passes, the pixel is processed by the frame buffer.
// Otherwise, all frame-buffer processing is skipped for the pixel.
// The test is done by comparing the incoming alpha value with the
// reference alpha value, using the comparison function provided by the
// RS_ALPHAFUNC render state. The reference alpha value is determined by
// the value set for RS_ALPHAREF.
// The default value of this parameter is false.
RS_ALPHATESTENABLE = 15
// RS_LASTPIXEL is true by default, which enables drawing of the last pixel
// in a line. To prevent drawing of the last pixel, set this value to false.
RS_LASTPIXEL = 16
// RS_SRCBLEND expectes one member of the BLEND enumerated type. The