[CMAKE]
[reactos.git] / subsystems / win32 / win32k / include / inteng.h
1 #pragma once
2
3 typedef ULONG HCLIP;
4
5 #define ENUM_RECT_LIMIT 50
6
7 typedef struct _RECT_ENUM
8 {
9 ULONG c;
10 RECTL arcl[ENUM_RECT_LIMIT];
11 } RECT_ENUM;
12
13 typedef struct tagSPAN
14 {
15 LONG Y;
16 LONG X;
17 ULONG Width;
18 } SPAN, *PSPAN;
19
20 #define R3_OPINDEX_SRCCOPY 0xcc
21 #define R3_OPINDEX_NOOP 0xaa
22 #define R4_NOOP ((R3_OPINDEX_NOOP << 8) | R3_OPINDEX_NOOP)
23 #define R4_MASK ((R3_OPINDEX_NOOP << 8) | R3_OPINDEX_SRCCOPY)
24
25 #define ROP2_TO_MIX(Rop2) (((Rop2) << 8) | (Rop2))
26 #define ROP3_USES_DEST(Rop3) ((((Rop3) & 0xAA0000) >> 1) != ((Rop3) & 0x550000))
27 #define ROP4_USES_DEST(Rop4) (((((Rop4) & 0xAA) >> 1) != ((Rop4) & 0x55)) || ((((Rop4) & 0xAA00) >> 1) != ((Rop4) & 0x5500)))
28 #define ROP3_USES_SOURCE(Rop3) ((((Rop3) & 0xCC0000) >> 2) != ((Rop3) & 0x330000))
29 #define ROP4_USES_SOURCE(Rop4) (((((Rop4) & 0xCC) >> 2) != ((Rop4) & 0x33)) || ((((Rop4) & 0xCC00) >> 2) != ((Rop4) & 0x3300)))
30 #define ROP3_USES_PATTERN(Rop3) ((((Rop3) & 0xF00000) >> 4) != ((Rop3) & 0x0F0000))
31 #define ROP4_USES_PATTERN(Rop4) (((((Rop4) & 0xF0) >> 4) != ((Rop4) & 0x0F)) || ((((Rop4) & 0xF000) >> 4) != ((Rop4) & 0x0F00)))
32 #define ROP3_TO_ROP4(Rop3) ((((Rop3) >> 8) & 0xff00) | (((Rop3) >> 16) & 0x00ff))
33
34 /* Definitions of IntEngXxx functions */
35
36 BOOL APIENTRY
37 IntEngLineTo(SURFOBJ *Surface,
38 CLIPOBJ *Clip,
39 BRUSHOBJ *Brush,
40 LONG x1,
41 LONG y1,
42 LONG x2,
43 LONG y2,
44 RECTL *RectBounds,
45 MIX mix);
46
47 BOOL APIENTRY
48 IntEngBitBlt(SURFOBJ *DestObj,
49 SURFOBJ *SourceObj,
50 SURFOBJ *Mask,
51 CLIPOBJ *ClipRegion,
52 XLATEOBJ *ColorTranslation,
53 RECTL *DestRect,
54 POINTL *SourcePoint,
55 POINTL *MaskOrigin,
56 BRUSHOBJ *Brush,
57 POINTL *BrushOrigin,
58 ROP4 Rop4);
59
60 BOOL APIENTRY
61 IntEngStretchBlt(SURFOBJ *DestObj,
62 SURFOBJ *SourceObj,
63 SURFOBJ *Mask,
64 CLIPOBJ *ClipRegion,
65 XLATEOBJ *ColorTranslation,
66 RECTL *DestRect,
67 RECTL *SourceRect,
68 POINTL *pMaskOrigin,
69 BRUSHOBJ *Brush,
70 POINTL *BrushOrigin,
71 ULONG Mode);
72
73 BOOL APIENTRY
74 IntEngGradientFill(SURFOBJ *psoDest,
75 CLIPOBJ *pco,
76 XLATEOBJ *pxlo,
77 TRIVERTEX *pVertex,
78 ULONG nVertex,
79 PVOID pMesh,
80 ULONG nMesh,
81 RECTL *prclExtents,
82 POINTL *pptlDitherOrg,
83 ULONG ulMode);
84
85 BOOL APIENTRY
86 IntEngPolyline(SURFOBJ *DestSurf,
87 CLIPOBJ *Clip,
88 BRUSHOBJ *Brush,
89 CONST LPPOINT pt,
90 LONG dCount,
91 MIX mix);
92
93 CLIPOBJ* FASTCALL
94 IntEngCreateClipRegion(ULONG count,
95 PRECTL pRect,
96 PRECTL rcBounds);
97
98 VOID FASTCALL
99 IntEngDeleteClipRegion(CLIPOBJ *ClipObj);
100
101 BOOLEAN FASTCALL
102 ClipobjToSpans(PSPAN *Spans,
103 UINT *Count,
104 CLIPOBJ *ClipRegion,
105 PRECTL Boundary);
106
107 BOOL FASTCALL
108 IntEngTransparentBlt(SURFOBJ *Dest,
109 SURFOBJ *Source,
110 CLIPOBJ *Clip,
111 XLATEOBJ *ColorTranslation,
112 PRECTL DestRect,
113 PRECTL SourceRect,
114 ULONG iTransColor,
115 ULONG Reserved);
116
117 BOOL APIENTRY
118 IntEngPaint(IN SURFOBJ *Surface,
119 IN CLIPOBJ *ClipRegion,
120 IN BRUSHOBJ *Brush,
121 IN POINTL *BrushOrigin,
122 IN MIX Mix);
123
124 VOID APIENTRY
125 IntEngMovePointer(IN SURFOBJ *pso,
126 IN LONG x,
127 IN LONG y,
128 IN RECTL *prcl);
129
130 ULONG APIENTRY
131 IntEngSetPointerShape(
132 IN SURFOBJ *pso,
133 IN SURFOBJ *psoMask,
134 IN SURFOBJ *psoColor,
135 IN XLATEOBJ *pxlo,
136 IN LONG xHot,
137 IN LONG yHot,
138 IN LONG x,
139 IN LONG y,
140 IN RECTL *prcl,
141 IN FLONG fl);
142
143 BOOL APIENTRY
144 IntEngAlphaBlend(IN SURFOBJ *Dest,
145 IN SURFOBJ *Source,
146 IN CLIPOBJ *ClipRegion,
147 IN XLATEOBJ *ColorTranslation,
148 IN PRECTL DestRect,
149 IN PRECTL SourceRect,
150 IN BLENDOBJ *BlendObj);
151
152 BOOL APIENTRY
153 IntEngCopyBits(SURFOBJ *psoDest,
154 SURFOBJ *psoSource,
155 CLIPOBJ *pco,
156 XLATEOBJ *pxlo,
157 RECTL *prclDest,
158 POINTL *ptlSource);