1 /*
2 * PROJECT: Win32 subsystem
3 * LICENSE: GNU GPL, see COPYING in the top level directory
4 * FILE: win32ss/gdi/eng/drvdbg.c
5 * PURPOSE: Debug hooks for display driver callbacks
6 * PROGRAMMERS: Timo Kreuzer
7 */
8
9 #include <win32k.h>
10 DBG_DEFAULT_CHANNEL(EngDev);
11
12 PPDEVOBJ
13 NTAPI
14 DbgLookupDHPDEV(DHPDEV dhpdev);
15
16 VOID
DbgDrvReserved(void)17 DbgDrvReserved(void)
18 {
19 ASSERT(FALSE);
20 }
21
22 DHPDEV
23 APIENTRY
DbgDrvEnablePDEV(_In_ DEVMODEW * pdm,_In_ LPWSTR pwszLogAddress,ULONG cPat,_In_opt_ HSURF * phsurfPatterns,ULONG cjCaps,_Out_ ULONG * pdevcaps,ULONG cjDevInfo,_Out_ DEVINFO * pdi,HDEV hdev,_In_ LPWSTR pwszDeviceName,HANDLE hDriver)24 DbgDrvEnablePDEV(
25 _In_ DEVMODEW *pdm,
26 _In_ LPWSTR pwszLogAddress,
27 ULONG cPat,
28 _In_opt_ HSURF *phsurfPatterns,
29 ULONG cjCaps,
30 _Out_ ULONG *pdevcaps,
31 ULONG cjDevInfo,
32 _Out_ DEVINFO *pdi,
33 HDEV hdev,
34 _In_ LPWSTR pwszDeviceName,
35 HANDLE hDriver)
36 {
37 PPDEVOBJ ppdev = (PPDEVOBJ)hdev;
38
39 ASSERT(pdm);
40 ASSERT(hdev);
41
42 return ppdev->pldev->pfn.EnablePDEV(pdm,
43 pwszLogAddress,
44 cPat,
45 phsurfPatterns,
46 cjCaps,
47 pdevcaps,
48 cjDevInfo,
49 pdi,
50 hdev,
51 pwszDeviceName,
52 hDriver);
53 }
54
55 VOID
56 APIENTRY
DbgDrvCompletePDEV(DHPDEV dhpdev,HDEV hdev)57 DbgDrvCompletePDEV(
58 DHPDEV dhpdev,
59 HDEV hdev)
60 {
61 PPDEVOBJ ppdev = (PPDEVOBJ)hdev;
62
63 ASSERT(ppdev);
64
65 ppdev->pldev->pfn.CompletePDEV(dhpdev, hdev);
66 }
67
68 VOID
69 APIENTRY
DbgDrvDisablePDEV(DHPDEV dhpdev)70 DbgDrvDisablePDEV(
71 DHPDEV dhpdev)
72 {
73 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
74
75 ASSERT(ppdev);
76
77 ppdev->pldev->pfn.DisablePDEV(dhpdev);
78 }
79
80 HSURF
81 APIENTRY
DbgDrvEnableSurface(DHPDEV dhpdev)82 DbgDrvEnableSurface(
83 DHPDEV dhpdev)
84 {
85 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
86
87 ASSERT(ppdev);
88
89 return ppdev->pldev->pfn.EnableSurface(dhpdev);
90 }
91
92 VOID
93 APIENTRY
DbgDrvDisableSurface(DHPDEV dhpdev)94 DbgDrvDisableSurface(
95 DHPDEV dhpdev)
96 {
97 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
98
99 ASSERT(ppdev);
100
101 ppdev->pldev->pfn.DisableSurface(dhpdev);
102 }
103
104 BOOL
105 APIENTRY
DbgDrvAssertMode(_In_ DHPDEV dhpdev,_In_ BOOL bEnable)106 DbgDrvAssertMode(
107 _In_ DHPDEV dhpdev,
108 _In_ BOOL bEnable)
109 {
110 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
111
112 ASSERT(ppdev);
113
114 return ppdev->pldev->pfn.AssertMode(dhpdev, bEnable);
115 }
116
117 BOOL
118 APIENTRY
DbgDrvOffset(SURFOBJ * pso,LONG x1,LONG x2,FLONG fl)119 DbgDrvOffset(
120 SURFOBJ* pso,
121 LONG x1,
122 LONG x2,
123 FLONG fl)
124 {
125 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
126
127 ASSERT(FALSE);
128 return 0;
129 }
130
131 ULONG
132 APIENTRY
DbgDrvResetPDEV(DHPDEV dhpdev,PVOID Reserved)133 DbgDrvResetPDEV(
134 DHPDEV dhpdev,
135 PVOID Reserved)
136 {
137 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
138
139 ASSERT(ppdev);
140
141 return ppdev->pldev->pfn.ResetDevice(dhpdev, Reserved);
142 }
143
144 VOID
145 APIENTRY
DbgDrvDisableDriver(void)146 DbgDrvDisableDriver(void)
147 {
148 ASSERT(FALSE);
149 }
150
151 HBITMAP
152 APIENTRY
DbgDrvCreateDeviceBitmap(DHPDEV dhpdev,SIZEL sizl,ULONG iFormat)153 DbgDrvCreateDeviceBitmap(
154 DHPDEV dhpdev,
155 SIZEL sizl,
156 ULONG iFormat)
157 {
158 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
159
160 ASSERT(ppdev);
161
162 return ppdev->pldev->pfn.CreateDeviceBitmap(dhpdev, sizl, iFormat);
163 }
164
165 VOID
166 APIENTRY
DbgDrvDeleteDeviceBitmap(DHSURF dhsurf)167 DbgDrvDeleteDeviceBitmap(
168 DHSURF dhsurf)
169 {
170 ASSERT(FALSE);
171 }
172
173 BOOL
174 APIENTRY
DbgDrvRealizeBrush(_In_ BRUSHOBJ * pbo,_Inout_ SURFOBJ * psoTarget,_In_ SURFOBJ * psoPattern,_In_opt_ SURFOBJ * psoMask,_In_ XLATEOBJ * pxlo,_In_ ULONG iHatch)175 DbgDrvRealizeBrush(
176 _In_ BRUSHOBJ *pbo,
177 _Inout_ SURFOBJ *psoTarget,
178 _In_ SURFOBJ *psoPattern,
179 _In_opt_ SURFOBJ *psoMask,
180 _In_ XLATEOBJ *pxlo,
181 _In_ ULONG iHatch)
182 {
183 PPDEVOBJ ppdev = (PPDEVOBJ)psoTarget->hdev;
184 ASSERT(FALSE);
185 return 0;
186 }
187
188 ULONG
189 APIENTRY
DbgDrvDitherColor(_In_ DHPDEV dhpdev,_In_ ULONG iMode,_In_ ULONG rgb,_Inout_ ULONG * pul)190 DbgDrvDitherColor(
191 _In_ DHPDEV dhpdev,
192 _In_ ULONG iMode,
193 _In_ ULONG rgb,
194 _Inout_ ULONG *pul)
195 {
196 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
197
198 ASSERT(ppdev);
199
200 return ppdev->pldev->pfn.DitherColor(dhpdev, iMode, rgb, pul);
201 }
202
203 BOOL
204 APIENTRY
DbgDrvStrokePath(_Inout_ SURFOBJ * pso,_In_ PATHOBJ * ppo,_In_ CLIPOBJ * pco,_In_opt_ XFORMOBJ * pxo,_In_ BRUSHOBJ * pbo,_In_ POINTL * pptlBrushOrg,_In_ LINEATTRS * plineattrs,_In_ MIX mix)205 DbgDrvStrokePath(
206 _Inout_ SURFOBJ *pso,
207 _In_ PATHOBJ *ppo,
208 _In_ CLIPOBJ *pco,
209 _In_opt_ XFORMOBJ *pxo,
210 _In_ BRUSHOBJ *pbo,
211 _In_ POINTL *pptlBrushOrg,
212 _In_ LINEATTRS *plineattrs,
213 _In_ MIX mix)
214 {
215 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
216 ASSERT(FALSE);
217 return 0;
218 }
219
220 BOOL
221 APIENTRY
DbgDrvFillPath(_Inout_ SURFOBJ * pso,_In_ PATHOBJ * ppo,_In_ CLIPOBJ * pco,_In_ BRUSHOBJ * pbo,_In_ POINTL * pptlBrushOrg,_In_ MIX mix,_In_ FLONG flOptions)222 DbgDrvFillPath(
223 _Inout_ SURFOBJ *pso,
224 _In_ PATHOBJ *ppo,
225 _In_ CLIPOBJ *pco,
226 _In_ BRUSHOBJ *pbo,
227 _In_ POINTL *pptlBrushOrg,
228 _In_ MIX mix,
229 _In_ FLONG flOptions)
230 {
231 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
232 ASSERT(FALSE);
233 return 0;
234 }
235
236 BOOL
237 APIENTRY
DbgDrvStrokeAndFillPath(_Inout_ SURFOBJ * pso,_Inout_ PATHOBJ * ppo,_In_ CLIPOBJ * pco,_In_opt_ XFORMOBJ * pxo,_In_ BRUSHOBJ * pboStroke,_In_ LINEATTRS * plineattrs,_In_ BRUSHOBJ * pboFill,_In_ POINTL * pptlBrushOrg,_In_ MIX mixFill,_In_ FLONG flOptions)238 DbgDrvStrokeAndFillPath(
239 _Inout_ SURFOBJ *pso,
240 _Inout_ PATHOBJ *ppo,
241 _In_ CLIPOBJ *pco,
242 _In_opt_ XFORMOBJ *pxo,
243 _In_ BRUSHOBJ *pboStroke,
244 _In_ LINEATTRS *plineattrs,
245 _In_ BRUSHOBJ *pboFill,
246 _In_ POINTL *pptlBrushOrg,
247 _In_ MIX mixFill,
248 _In_ FLONG flOptions)
249 {
250 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
251 ASSERT(FALSE);
252 return 0;
253 }
254
255 BOOL
256 APIENTRY
DbgDrvPaint(IN SURFOBJ * pso,IN CLIPOBJ * pco,IN BRUSHOBJ * pbo,IN POINTL * pptlBrushOrg,IN MIX mix)257 DbgDrvPaint(
258 IN SURFOBJ *pso,
259 IN CLIPOBJ *pco,
260 IN BRUSHOBJ *pbo,
261 IN POINTL *pptlBrushOrg,
262 IN MIX mix)
263 {
264 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
265 return 0;
266 }
267
268 BOOL
269 APIENTRY
DbgDrvBitBlt(_Inout_ SURFOBJ * psoTrg,_In_opt_ SURFOBJ * psoSrc,_In_opt_ SURFOBJ * psoMask,_In_opt_ CLIPOBJ * pco,_In_opt_ XLATEOBJ * pxlo,_In_ RECTL * prclTrg,_When_ (psoSrc,_In_)POINTL * pptlSrc,_When_ (psoMask,_In_)POINTL * pptlMask,_In_opt_ BRUSHOBJ * pbo,_When_ (pbo,_In_)POINTL * pptlBrush,_In_ ROP4 rop4)270 DbgDrvBitBlt(
271 _Inout_ SURFOBJ *psoTrg,
272 _In_opt_ SURFOBJ *psoSrc,
273 _In_opt_ SURFOBJ *psoMask,
274 _In_opt_ CLIPOBJ *pco,
275 _In_opt_ XLATEOBJ *pxlo,
276 _In_ RECTL *prclTrg,
277 _When_(psoSrc, _In_) POINTL *pptlSrc,
278 _When_(psoMask, _In_) POINTL *pptlMask,
279 _In_opt_ BRUSHOBJ *pbo,
280 _When_(pbo, _In_) POINTL *pptlBrush,
281 _In_ ROP4 rop4)
282 {
283 PSURFACE psurfTrg = CONTAINING_RECORD(psoTrg, SURFACE, SurfObj);
284 PSURFACE psurfSrc = CONTAINING_RECORD(psoSrc, SURFACE, SurfObj);
285 PPDEVOBJ ppdev;
286
287 /* Get the right BitBlt function */
288 if (psurfTrg->flags & HOOK_BITBLT)
289 {
290 ppdev = (PPDEVOBJ)psoTrg->hdev;
291 }
292 else
293 {
294 ASSERT(ROP4_USES_SOURCE(rop4));
295 ASSERT(psurfSrc->flags & HOOK_BITBLT);
296 ppdev = (PPDEVOBJ)psoSrc->hdev;
297 }
298
299 /* Sanity checks */
300 ASSERT(IS_VALID_ROP4(rop4));
301 ASSERT(psoTrg);
302 ASSERT(psoTrg->iBitmapFormat >= BMF_1BPP);
303 ASSERT(psoTrg->iBitmapFormat <= BMF_32BPP);
304 ASSERT(prclTrg);
305 ASSERT(prclTrg->left >= 0);
306 ASSERT(prclTrg->top >= 0);
307 ASSERT(prclTrg->right <= psoTrg->sizlBitmap.cx);
308 ASSERT(prclTrg->bottom <= psoTrg->sizlBitmap.cy);
309 ASSERT(RECTL_bIsWellOrdered(prclTrg));
310 ASSERT(pco);
311 ASSERT(pco->iDComplexity != DC_RECT);
312
313 if (ROP4_USES_SOURCE(rop4))
314 {
315 ASSERT(psoSrc);
316 ASSERT(psoSrc->iBitmapFormat >= BMF_1BPP);
317 ASSERT(psoSrc->iBitmapFormat <= BMF_8RLE);
318 ASSERT(pptlSrc);
319 ASSERT(pptlSrc->x >= 0);
320 ASSERT(pptlSrc->y >= 0);
321 ASSERT(pptlSrc->x <= psoTrg->sizlBitmap.cx);
322 ASSERT(pptlSrc->y <= psoTrg->sizlBitmap.cy);
323 }
324
325 if (ROP4_USES_MASK(rop4))
326 {
327 ASSERT(psoMask);
328 ASSERT(psoMask->iBitmapFormat == BMF_1BPP);
329 ASSERT(pptlMask);
330 ASSERT(pptlMask->x >= 0);
331 ASSERT(pptlMask->y >= 0);
332 ASSERT(pptlMask->x <= psoMask->sizlBitmap.cx);
333 ASSERT(pptlMask->y <= psoMask->sizlBitmap.cy);
334
335 }
336
337 if (ROP4_USES_PATTERN(rop4))
338 {
339 ASSERT(pbo);
340 ASSERT(pptlBrush);
341 }
342
343
344 return ppdev->pldev->pfn.BitBlt(psoTrg,
345 psoSrc,
346 psoMask,
347 pco,
348 pxlo,
349 prclTrg,
350 pptlSrc,
351 pptlMask,
352 pbo,
353 pptlBrush,
354 rop4);
355 }
356
357 BOOL
358 APIENTRY
DbgDrvCopyBits(SURFOBJ * psoTrg,SURFOBJ * psoSrc,CLIPOBJ * pco,XLATEOBJ * pxlo,RECTL * prclTrg,POINTL * pptlSrc)359 DbgDrvCopyBits(
360 SURFOBJ *psoTrg,
361 SURFOBJ *psoSrc,
362 CLIPOBJ *pco,
363 XLATEOBJ *pxlo,
364 RECTL *prclTrg,
365 POINTL *pptlSrc)
366 {
367 PSURFACE psurfTrg = CONTAINING_RECORD(psoTrg, SURFACE, SurfObj);
368 PSURFACE psurfSrc = CONTAINING_RECORD(psoSrc, SURFACE, SurfObj);
369 PPDEVOBJ ppdev;
370
371 /* Get the right BitBlt function */
372 if (psurfTrg->flags & HOOK_COPYBITS)
373 {
374 ppdev = (PPDEVOBJ)psoTrg->hdev;
375 }
376 else
377 {
378 ASSERT(psurfSrc->flags & HOOK_COPYBITS);
379 ppdev = (PPDEVOBJ)psoSrc->hdev;
380 }
381
382 return ppdev->pldev->pfn.CopyBits(psoTrg,
383 psoSrc,
384 pco,
385 pxlo,
386 prclTrg,
387 pptlSrc);
388
389 }
390
391 BOOL
392 APIENTRY
DbgDrvStretchBlt(_Inout_ SURFOBJ * psoTrg,_Inout_ SURFOBJ * psoSrc,_In_opt_ SURFOBJ * psoMask,_In_ CLIPOBJ * pco,_In_opt_ XLATEOBJ * pxlo,_In_opt_ COLORADJUSTMENT * pca,_In_ POINTL * pptlHTOrg,_In_ RECTL * prclDest,_In_ RECTL * prclSrc,_In_opt_ POINTL * pptlMask,_In_ ULONG iMode)393 DbgDrvStretchBlt(
394 _Inout_ SURFOBJ *psoTrg,
395 _Inout_ SURFOBJ *psoSrc,
396 _In_opt_ SURFOBJ *psoMask,
397 _In_ CLIPOBJ *pco,
398 _In_opt_ XLATEOBJ *pxlo,
399 _In_opt_ COLORADJUSTMENT *pca,
400 _In_ POINTL *pptlHTOrg,
401 _In_ RECTL *prclDest,
402 _In_ RECTL *prclSrc,
403 _In_opt_ POINTL *pptlMask,
404 _In_ ULONG iMode)
405 {
406 PSURFACE psurfTrg = CONTAINING_RECORD(psoTrg, SURFACE, SurfObj);
407 PSURFACE psurfSrc = CONTAINING_RECORD(psoSrc, SURFACE, SurfObj);
408
409 return 0;
410 }
411
412 BOOL
413 APIENTRY
DbgDrvSetPalette(DHPDEV dhpdev,PALOBJ * ppalo,FLONG fl,ULONG iStart,ULONG cColors)414 DbgDrvSetPalette(
415 DHPDEV dhpdev,
416 PALOBJ *ppalo,
417 FLONG fl,
418 ULONG iStart,
419 ULONG cColors)
420 {
421 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
422
423 ASSERT(ppdev);
424
425 return ppdev->pldev->pfn.SetPalette(dhpdev, ppalo, fl, iStart, cColors);
426 }
427
428 BOOL
429 APIENTRY
DbgDrvTextOut(SURFOBJ * pso,STROBJ * pstro,FONTOBJ * pfo,CLIPOBJ * pco,RECTL * prclExtra,RECTL * prclOpaque,BRUSHOBJ * pboFore,BRUSHOBJ * pboOpaque,POINTL * pptlOrg,MIX mix)430 DbgDrvTextOut(
431 SURFOBJ *pso,
432 STROBJ *pstro,
433 FONTOBJ *pfo,
434 CLIPOBJ *pco,
435 RECTL *prclExtra ,
436 RECTL *prclOpaque,
437 BRUSHOBJ *pboFore,
438 BRUSHOBJ *pboOpaque,
439 POINTL *pptlOrg,
440 MIX mix)
441 {
442 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
443 return 0;
444 }
445
446 ULONG
447 APIENTRY
DbgDrvEscape(_In_ SURFOBJ * pso,_In_ ULONG iEsc,_In_ ULONG cjIn,_In_ PVOID pvIn,_In_ ULONG cjOut,_Out_ PVOID pvOut)448 DbgDrvEscape(
449 _In_ SURFOBJ *pso,
450 _In_ ULONG iEsc,
451 _In_ ULONG cjIn,
452 _In_ PVOID pvIn,
453 _In_ ULONG cjOut,
454 _Out_ PVOID pvOut)
455 {
456 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
457 return 0;
458 }
459
460 ULONG
461 APIENTRY
DbgDrvDrawEscape(_In_ SURFOBJ * pso,_In_ ULONG iEsc,_In_ CLIPOBJ * pco,_In_ RECTL * prcl,_In_ ULONG cjIn,_In_ PVOID pvIn)462 DbgDrvDrawEscape(
463 _In_ SURFOBJ *pso,
464 _In_ ULONG iEsc,
465 _In_ CLIPOBJ *pco,
466 _In_ RECTL *prcl,
467 _In_ ULONG cjIn,
468 _In_ PVOID pvIn)
469 {
470 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
471 return 0;
472 }
473
474 PIFIMETRICS
475 APIENTRY
DbgDrvQueryFont(DHPDEV dhpdev,ULONG_PTR iFile,ULONG iFace,ULONG_PTR * pid)476 DbgDrvQueryFont(
477 DHPDEV dhpdev,
478 ULONG_PTR iFile,
479 ULONG iFace,
480 ULONG_PTR *pid)
481 {
482 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
483
484 ASSERT(ppdev);
485
486 return ppdev->pldev->pfn.QueryFont(dhpdev, iFile, iFace, pid);
487 }
488
489 PVOID
490 APIENTRY
DbgDrvQueryFontTree(DHPDEV dhpdev,ULONG_PTR iFile,ULONG iFace,ULONG iMode,ULONG_PTR * pid)491 DbgDrvQueryFontTree(
492 DHPDEV dhpdev,
493 ULONG_PTR iFile,
494 ULONG iFace,
495 ULONG iMode,
496 ULONG_PTR *pid)
497 {
498 return 0;
499 }
500
501 LONG
502 APIENTRY
DbgDrvQueryFontData(DHPDEV dhpdev,FONTOBJ * pfo,ULONG iMode,HGLYPH hg,GLYPHDATA * pgd,_Out_ PVOID pv,ULONG cjSize)503 DbgDrvQueryFontData(
504 DHPDEV dhpdev,
505 FONTOBJ *pfo,
506 ULONG iMode,
507 HGLYPH hg,
508 GLYPHDATA *pgd,
509 _Out_ PVOID pv,
510 ULONG cjSize)
511 {
512 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
513
514 ASSERT(ppdev);
515
516 return ppdev->pldev->pfn.QueryFontData(dhpdev, pfo, iMode, hg, pgd, pv, cjSize);
517 }
518
519 ULONG
520 APIENTRY
DbgDrvSetPointerShape(_In_ SURFOBJ * pso,_In_ SURFOBJ * psoMask,_In_ SURFOBJ * psoColor,_In_ XLATEOBJ * pxlo,_In_ LONG xHot,_In_ LONG yHot,_In_ LONG x,_In_ LONG y,_In_ RECTL * prcl,_In_ FLONG fl)521 DbgDrvSetPointerShape(
522 _In_ SURFOBJ *pso,
523 _In_ SURFOBJ *psoMask,
524 _In_ SURFOBJ *psoColor,
525 _In_ XLATEOBJ *pxlo,
526 _In_ LONG xHot,
527 _In_ LONG yHot,
528 _In_ LONG x,
529 _In_ LONG y,
530 _In_ RECTL *prcl,
531 _In_ FLONG fl)
532 {
533 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
534 return 0;
535 }
536
537 VOID
538 APIENTRY
DbgDrvMovePointer(_In_ SURFOBJ * pso,_In_ LONG x,_In_ LONG y,_In_ RECTL * prcl)539 DbgDrvMovePointer(
540 _In_ SURFOBJ *pso,
541 _In_ LONG x,
542 _In_ LONG y,
543 _In_ RECTL *prcl)
544 {
545 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
546 }
547
548 BOOL
549 APIENTRY
DbgDrvLineTo(SURFOBJ * pso,CLIPOBJ * pco,BRUSHOBJ * pbo,LONG x1,LONG y1,LONG x2,LONG y2,RECTL * prclBounds,MIX mix)550 DbgDrvLineTo(
551 SURFOBJ *pso,
552 CLIPOBJ *pco,
553 BRUSHOBJ *pbo,
554 LONG x1,
555 LONG y1,
556 LONG x2,
557 LONG y2,
558 RECTL *prclBounds,
559 MIX mix)
560 {
561 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
562 return 0;
563 }
564
565 BOOL
566 APIENTRY
DbgDrvSendPage(_In_ SURFOBJ * pso)567 DbgDrvSendPage(
568 _In_ SURFOBJ *pso)
569 {
570 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
571 return 0;
572 }
573
574 BOOL
575 APIENTRY
DbgDrvStartPage(_In_ SURFOBJ * pso)576 DbgDrvStartPage(
577 _In_ SURFOBJ *pso)
578 {
579 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
580 return 0;
581 }
582
583 BOOL
584 APIENTRY
DbgDrvEndDoc(_In_ SURFOBJ * pso,_In_ FLONG fl)585 DbgDrvEndDoc(
586 _In_ SURFOBJ *pso,
587 _In_ FLONG fl)
588 {
589 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
590 return 0;
591 }
592
593 BOOL
594 APIENTRY
DbgDrvStartDoc(_In_ SURFOBJ * pso,_In_ LPWSTR pwszDocName,_In_ DWORD dwJobId)595 DbgDrvStartDoc(
596 _In_ SURFOBJ *pso,
597 _In_ LPWSTR pwszDocName,
598 _In_ DWORD dwJobId)
599 {
600 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
601 return 0;
602 }
603
604 ULONG
605 APIENTRY
DbgDrvGetGlyphMode(_In_ DHPDEV dhpdev,_In_ FONTOBJ * pfo)606 DbgDrvGetGlyphMode(
607 _In_ DHPDEV dhpdev,
608 _In_ FONTOBJ *pfo)
609 {
610 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
611
612 ASSERT(ppdev);
613
614 return ppdev->pldev->pfn.GetGlyphMode(dhpdev, pfo);
615 }
616
617 VOID
618 APIENTRY
DbgDrvSynchronize(DHPDEV dhpdev,RECTL * prcl)619 DbgDrvSynchronize(
620 DHPDEV dhpdev,
621 RECTL *prcl)
622 {
623 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
624
625 ASSERT(ppdev);
626
627 ppdev->pldev->pfn.Synchronize(dhpdev, prcl);
628 }
629
630 ULONG_PTR
631 APIENTRY
DbgDrvSaveScreenBits(SURFOBJ * pso,ULONG iMode,ULONG_PTR ident,RECTL * prcl)632 DbgDrvSaveScreenBits(
633 SURFOBJ *pso,
634 ULONG iMode,
635 ULONG_PTR ident,
636 RECTL *prcl)
637 {
638 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
639 return 0;
640 }
641
642 ULONG
643 APIENTRY
DbgDrvGetModes(_In_ HANDLE hDriver,ULONG cjSize,_Out_opt_ DEVMODEW * pdm)644 DbgDrvGetModes(
645 _In_ HANDLE hDriver,
646 ULONG cjSize,
647 _Out_opt_ DEVMODEW *pdm)
648 {
649 return 0;
650 }
651
652 VOID
653 APIENTRY
DbgDrvFree(PVOID pv,ULONG_PTR id)654 DbgDrvFree(
655 PVOID pv,
656 ULONG_PTR id)
657 {
658 }
659
660 VOID
661 APIENTRY
DbgDrvDestroyFont(FONTOBJ * pfo)662 DbgDrvDestroyFont(
663 FONTOBJ *pfo)
664 {
665 }
666
667 LONG
668 APIENTRY
DbgDrvQueryFontCaps(ULONG culCaps,ULONG * pulCaps)669 DbgDrvQueryFontCaps(
670 ULONG culCaps,
671 ULONG *pulCaps)
672 {
673 return 0;
674 }
675
676 ULONG_PTR
677 APIENTRY
DbgDrvLoadFontFile(ULONG cFiles,ULONG_PTR * piFile,PVOID * ppvView,ULONG * pcjView,DESIGNVECTOR * pdv,ULONG ulLangID,ULONG ulFastCheckSum)678 DbgDrvLoadFontFile(
679 ULONG cFiles,
680 ULONG_PTR *piFile,
681 PVOID *ppvView,
682 ULONG *pcjView,
683 DESIGNVECTOR *pdv,
684 ULONG ulLangID,
685 ULONG ulFastCheckSum)
686 {
687 return 0;
688 }
689
690 BOOL
691 APIENTRY
DbgDrvUnloadFontFile(ULONG_PTR iFile)692 DbgDrvUnloadFontFile(
693 ULONG_PTR iFile)
694 {
695 return 0;
696 }
697
698 ULONG
699 APIENTRY
DbgDrvFontManagement(_In_ SURFOBJ * pso,_In_opt_ FONTOBJ * pfo,_In_ ULONG iMode,_In_ ULONG cjIn,_In_ PVOID pvIn,_In_ ULONG cjOut,_Out_ PVOID pvOut)700 DbgDrvFontManagement(
701 _In_ SURFOBJ *pso,
702 _In_opt_ FONTOBJ *pfo,
703 _In_ ULONG iMode,
704 _In_ ULONG cjIn,
705 _In_ PVOID pvIn,
706 _In_ ULONG cjOut,
707 _Out_ PVOID pvOut)
708 {
709 return 0;
710 }
711
712 LONG
713 APIENTRY
DbgDrvQueryTrueTypeTable(ULONG_PTR iFile,ULONG ulFont,ULONG ulTag,PTRDIFF dpStart,ULONG cjBuf,BYTE * pjBuf,PBYTE * ppjTable,ULONG * pcjTable)714 DbgDrvQueryTrueTypeTable(
715 ULONG_PTR iFile,
716 ULONG ulFont,
717 ULONG ulTag,
718 PTRDIFF dpStart,
719 ULONG cjBuf,
720 BYTE *pjBuf,
721 PBYTE *ppjTable,
722 ULONG *pcjTable)
723 {
724 return 0;
725 }
726
727 LONG
728 APIENTRY
DbgDrvQueryTrueTypeOutline(DHPDEV dhpdev,FONTOBJ * pfo,HGLYPH hglyph,BOOL bMetricsOnly,GLYPHDATA * pgldt,ULONG cjBuf,TTPOLYGONHEADER * ppoly)729 DbgDrvQueryTrueTypeOutline(
730 DHPDEV dhpdev,
731 FONTOBJ *pfo,
732 HGLYPH hglyph,
733 BOOL bMetricsOnly,
734 GLYPHDATA *pgldt,
735 ULONG cjBuf,
736 TTPOLYGONHEADER *ppoly)
737 {
738 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
739 return 0;
740 }
741
742 PVOID
743 APIENTRY
DbgDrvGetTrueTypeFile(ULONG_PTR iFile,ULONG * pcj)744 DbgDrvGetTrueTypeFile(
745 ULONG_PTR iFile,
746 ULONG *pcj)
747 {
748 return 0;
749 }
750
751 LONG
752 APIENTRY
DbgDrvQueryFontFile(ULONG_PTR iFile,ULONG ulMode,ULONG cjBuf,ULONG * pulBuf)753 DbgDrvQueryFontFile(
754 ULONG_PTR iFile,
755 ULONG ulMode,
756 ULONG cjBuf,
757 ULONG *pulBuf)
758 {
759 return 0;
760 }
761
762 VOID
763 APIENTRY
DbgDrvMovePanning(LONG x,LONG y,FLONG fl)764 DbgDrvMovePanning(
765 LONG x,
766 LONG y,
767 FLONG fl)
768 {
769 ERR("Obsolete driver function %s called!\n", __FUNCTION__);
770 ASSERT(FALSE);
771 }
772
773 BOOL
774 APIENTRY
DbgDrvQueryAdvanceWidths(DHPDEV dhpdev,FONTOBJ * pfo,ULONG iMode,_In_ HGLYPH * phg,_Out_ PVOID pvWidths,ULONG cGlyphs)775 DbgDrvQueryAdvanceWidths(
776 DHPDEV dhpdev,
777 FONTOBJ *pfo,
778 ULONG iMode,
779 _In_ HGLYPH *phg,
780 _Out_ PVOID pvWidths,
781 ULONG cGlyphs)
782 {
783 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
784 return 0;
785 }
786
787 BOOL
788 APIENTRY
DbgDrvSetPixelFormat(SURFOBJ * pso,LONG iPixelFormat,HWND hwnd)789 DbgDrvSetPixelFormat(
790 SURFOBJ *pso,
791 LONG iPixelFormat,
792 HWND hwnd)
793 {
794 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
795 return 0;
796 }
797
798 LONG
799 APIENTRY
DbgDrvDescribePixelFormat(DHPDEV dhpdev,LONG iPixelFormat,ULONG cjpfd,PIXELFORMATDESCRIPTOR * ppfd)800 DbgDrvDescribePixelFormat(
801 DHPDEV dhpdev,
802 LONG iPixelFormat,
803 ULONG cjpfd,
804 PIXELFORMATDESCRIPTOR *ppfd)
805 {
806 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
807
808 ASSERT(ppdev);
809
810 return ppdev->pldev->pfn.DescribePixelFormat(dhpdev, iPixelFormat, cjpfd, ppfd);
811 }
812
813 BOOL
814 APIENTRY
DbgDrvSwapBuffers(SURFOBJ * pso,WNDOBJ * pwo)815 DbgDrvSwapBuffers(
816 SURFOBJ *pso,
817 WNDOBJ *pwo)
818 {
819 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
820 return 0;
821 }
822
823 BOOL
824 APIENTRY
DbgDrvStartBanding(_In_ SURFOBJ * pso,_In_ POINTL * pptl)825 DbgDrvStartBanding(
826 _In_ SURFOBJ *pso,
827 _In_ POINTL *pptl)
828 {
829 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
830 return 0;
831 }
832
833 BOOL
834 APIENTRY
DbgDrvNextBand(_In_ SURFOBJ * pso,_In_ POINTL * pptl)835 DbgDrvNextBand(
836 _In_ SURFOBJ *pso,
837 _In_ POINTL *pptl)
838 {
839 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
840 return 0;
841 }
842
843 BOOL
844 APIENTRY
DbgDrvGetDirectDrawInfo(DHPDEV dhpdev,DD_HALINFO * pHalInfo,DWORD * pdwNumHeaps,VIDEOMEMORY * pvmList,DWORD * pdwNumFourCCCodes,DWORD * pdwFourCC)845 DbgDrvGetDirectDrawInfo(
846 DHPDEV dhpdev,
847 DD_HALINFO *pHalInfo,
848 DWORD *pdwNumHeaps,
849 VIDEOMEMORY *pvmList,
850 DWORD *pdwNumFourCCCodes,
851 DWORD *pdwFourCC)
852 {
853 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
854
855 ASSERT(ppdev);
856
857 return ppdev->pldev->pfn.GetDirectDrawInfo(dhpdev,
858 pHalInfo,
859 pdwNumHeaps,
860 pvmList,
861 pdwNumFourCCCodes,
862 pdwFourCC);
863 }
864
865 BOOL
866 APIENTRY
DbgDrvEnableDirectDraw(DHPDEV dhpdev,DD_CALLBACKS * pCallBacks,DD_SURFACECALLBACKS * pSurfaceCallBacks,DD_PALETTECALLBACKS * pPaletteCallBacks)867 DbgDrvEnableDirectDraw(
868 DHPDEV dhpdev,
869 DD_CALLBACKS *pCallBacks,
870 DD_SURFACECALLBACKS *pSurfaceCallBacks,
871 DD_PALETTECALLBACKS *pPaletteCallBacks)
872 {
873 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
874
875 ASSERT(ppdev);
876
877 return ppdev->pldev->pfn.EnableDirectDraw(dhpdev,
878 pCallBacks,
879 pSurfaceCallBacks,
880 pPaletteCallBacks);
881 }
882
883 VOID
884 APIENTRY
DbgDrvDisableDirectDraw(DHPDEV dhpdev)885 DbgDrvDisableDirectDraw(
886 DHPDEV dhpdev)
887 {
888 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
889
890 ASSERT(ppdev);
891
892 ppdev->pldev->pfn.DisableDirectDraw(dhpdev);
893 }
894
895 BOOL
896 APIENTRY
DbgDrvQuerySpoolType(DHPDEV PDev,LPWSTR SpoolType)897 DbgDrvQuerySpoolType(DHPDEV PDev, LPWSTR SpoolType)
898 {
899 ERR("Obsolete driver function %s called!\n", __FUNCTION__);
900 ASSERT(FALSE);
901 return 0;
902 }
903
904 HANDLE
905 APIENTRY
DbgDrvIcmCreateColorTransform(_In_ DHPDEV dhpdev,_In_ LPLOGCOLORSPACEW pLogColorSpace,_In_opt_ PVOID pvSourceProfile,_In_ ULONG cjSourceProfile,_In_ PVOID pvDestProfile,_In_ ULONG cjDestProfile,_In_opt_ PVOID pvTargetProfile,_In_ ULONG cjTargetProfile,_In_ DWORD dwReserved)906 DbgDrvIcmCreateColorTransform(
907 _In_ DHPDEV dhpdev,
908 _In_ LPLOGCOLORSPACEW pLogColorSpace,
909 _In_opt_ PVOID pvSourceProfile,
910 _In_ ULONG cjSourceProfile,
911 _In_ PVOID pvDestProfile,
912 _In_ ULONG cjDestProfile,
913 _In_opt_ PVOID pvTargetProfile,
914 _In_ ULONG cjTargetProfile,
915 _In_ DWORD dwReserved)
916 {
917 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
918
919 ASSERT(ppdev);
920
921 return ppdev->pldev->pfn.IcmCreateColorTransform(dhpdev,
922 pLogColorSpace,
923 pvSourceProfile,
924 cjSourceProfile,
925 pvDestProfile,
926 cjDestProfile,
927 pvTargetProfile,
928 cjTargetProfile,
929 dwReserved);
930 }
931
932 BOOL
933 APIENTRY
DbgDrvIcmDeleteColorTransform(_In_ DHPDEV dhpdev,_In_ HANDLE hcmXform)934 DbgDrvIcmDeleteColorTransform(
935 _In_ DHPDEV dhpdev,
936 _In_ HANDLE hcmXform)
937 {
938 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
939
940 ASSERT(ppdev);
941
942 return ppdev->pldev->pfn.IcmDeleteColorTransform(dhpdev, hcmXform);
943 }
944
945 BOOL
946 APIENTRY
DbgDrvIcmCheckBitmapBits(DHPDEV dhpdev,HANDLE hColorTransform,SURFOBJ * pso,PBYTE paResults)947 DbgDrvIcmCheckBitmapBits(
948 DHPDEV dhpdev,
949 HANDLE hColorTransform,
950 SURFOBJ *pso,
951 PBYTE paResults)
952 {
953 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
954
955 ASSERT(ppdev);
956
957 return ppdev->pldev->pfn.IcmCheckBitmapBits(dhpdev,
958 hColorTransform,
959 pso,
960 paResults);
961 }
962
963 BOOL
964 APIENTRY
DbgDrvIcmSetDeviceGammaRamp(DHPDEV dhpdev,ULONG iFormat,LPVOID lpRamp)965 DbgDrvIcmSetDeviceGammaRamp(
966 DHPDEV dhpdev,
967 ULONG iFormat,
968 LPVOID lpRamp)
969 {
970 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
971
972 ASSERT(ppdev);
973
974 return ppdev->pldev->pfn.IcmSetDeviceGammaRamp(dhpdev, iFormat, lpRamp);
975 }
976
977 BOOL
978 APIENTRY
DbgDrvGradientFill(_Inout_ SURFOBJ * psoTrg,_In_ CLIPOBJ * pco,_In_opt_ XLATEOBJ * pxlo,_In_ TRIVERTEX * pVertex,_In_ ULONG nVertex,_In_ PVOID pMesh,_In_ ULONG nMesh,_In_ RECTL * prclExtents,_In_ POINTL * pptlDitherOrg,_In_ ULONG ulMode)979 DbgDrvGradientFill(
980 _Inout_ SURFOBJ *psoTrg,
981 _In_ CLIPOBJ *pco,
982 _In_opt_ XLATEOBJ *pxlo,
983 _In_ TRIVERTEX *pVertex,
984 _In_ ULONG nVertex,
985 _In_ PVOID pMesh,
986 _In_ ULONG nMesh,
987 _In_ RECTL *prclExtents,
988 _In_ POINTL *pptlDitherOrg,
989 _In_ ULONG ulMode)
990 {
991 PPDEVOBJ ppdev = (PPDEVOBJ)psoTrg->hdev;
992 return 0;
993 }
994
995 BOOL
996 APIENTRY
DbgDrvStretchBltROP(_Inout_ SURFOBJ * psoTrg,_Inout_ SURFOBJ * psoSrc,_In_opt_ SURFOBJ * psoMask,_In_ CLIPOBJ * pco,_In_opt_ XLATEOBJ * pxlo,_In_opt_ COLORADJUSTMENT * pca,_In_ POINTL * pptlHTOrg,_In_ RECTL * prclDest,_In_ RECTL * prclSrc,_In_opt_ POINTL * pptlMask,_In_ ULONG iMode,_In_ BRUSHOBJ * pbo,_In_ DWORD rop4)997 DbgDrvStretchBltROP(
998 _Inout_ SURFOBJ *psoTrg,
999 _Inout_ SURFOBJ *psoSrc,
1000 _In_opt_ SURFOBJ *psoMask,
1001 _In_ CLIPOBJ *pco,
1002 _In_opt_ XLATEOBJ *pxlo,
1003 _In_opt_ COLORADJUSTMENT *pca,
1004 _In_ POINTL *pptlHTOrg,
1005 _In_ RECTL *prclDest,
1006 _In_ RECTL *prclSrc,
1007 _In_opt_ POINTL *pptlMask,
1008 _In_ ULONG iMode,
1009 _In_ BRUSHOBJ *pbo,
1010 _In_ DWORD rop4)
1011 {
1012 PPDEVOBJ ppdev = (PPDEVOBJ)psoTrg->hdev;
1013 return 0;
1014 }
1015
1016 BOOL
1017 APIENTRY
DbgDrvPlgBlt(_Inout_ SURFOBJ * psoTrg,_Inout_ SURFOBJ * psoSrc,_In_opt_ SURFOBJ * psoMsk,_In_ CLIPOBJ * pco,_In_opt_ XLATEOBJ * pxlo,_In_opt_ COLORADJUSTMENT * pca,_In_opt_ POINTL * pptlBrushOrg,_In_ POINTFIX * pptfx,_In_ RECTL * prcl,_In_opt_ POINTL * pptl,_In_ ULONG iMode)1018 DbgDrvPlgBlt(
1019 _Inout_ SURFOBJ *psoTrg,
1020 _Inout_ SURFOBJ *psoSrc,
1021 _In_opt_ SURFOBJ *psoMsk,
1022 _In_ CLIPOBJ *pco,
1023 _In_opt_ XLATEOBJ *pxlo,
1024 _In_opt_ COLORADJUSTMENT *pca,
1025 _In_opt_ POINTL *pptlBrushOrg,
1026 _In_ POINTFIX *pptfx,
1027 _In_ RECTL *prcl,
1028 _In_opt_ POINTL *pptl,
1029 _In_ ULONG iMode)
1030 {
1031 PPDEVOBJ ppdev = (PPDEVOBJ)psoTrg->hdev;
1032 return 0;
1033 }
1034
1035 BOOL
1036 APIENTRY
DbgDrvAlphaBlend(_Inout_ SURFOBJ * psoDest,_In_ SURFOBJ * psoSrc,_In_ CLIPOBJ * pco,_In_opt_ XLATEOBJ * pxlo,_In_ RECTL * prclDest,_In_ RECTL * prclSrc,_In_ BLENDOBJ * pBlendObj)1037 DbgDrvAlphaBlend(
1038 _Inout_ SURFOBJ *psoDest,
1039 _In_ SURFOBJ *psoSrc,
1040 _In_ CLIPOBJ *pco,
1041 _In_opt_ XLATEOBJ *pxlo,
1042 _In_ RECTL *prclDest,
1043 _In_ RECTL *prclSrc,
1044 _In_ BLENDOBJ *pBlendObj)
1045 {
1046 return 0;
1047 }
1048
1049 VOID
1050 APIENTRY
DbgSynthesizeFont(void)1051 DbgSynthesizeFont(void)
1052 {
1053 ASSERT(FALSE);
1054 }
1055
1056 VOID
1057 APIENTRY
DbgGetSynthesizedFontFiles(void)1058 DbgGetSynthesizedFontFiles(void)
1059 {
1060 ASSERT(FALSE);
1061 }
1062
1063 BOOL
1064 APIENTRY
DbgDrvTransparentBlt(_Inout_ SURFOBJ * psoTrg,_In_ SURFOBJ * psoSrc,_In_ CLIPOBJ * pco,_In_opt_ XLATEOBJ * pxlo,_In_ RECTL * prclDst,_In_ RECTL * prclSrc,_In_ ULONG iTransColor,_In_ ULONG ulReserved)1065 DbgDrvTransparentBlt(
1066 _Inout_ SURFOBJ *psoTrg,
1067 _In_ SURFOBJ *psoSrc,
1068 _In_ CLIPOBJ *pco,
1069 _In_opt_ XLATEOBJ *pxlo,
1070 _In_ RECTL *prclDst,
1071 _In_ RECTL *prclSrc,
1072 _In_ ULONG iTransColor,
1073 _In_ ULONG ulReserved)
1074 {
1075 PPDEVOBJ ppdev = (PPDEVOBJ)psoTrg->hdev;
1076 return 0;
1077 }
1078
1079 ULONG
1080 APIENTRY
DbgDrvQueryPerBandInfo(_In_ SURFOBJ * pso,_Inout_ PERBANDINFO * pbi)1081 DbgDrvQueryPerBandInfo(
1082 _In_ SURFOBJ *pso,
1083 _Inout_ PERBANDINFO *pbi)
1084 {
1085 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
1086 return 0;
1087 }
1088
1089 BOOL
1090 APIENTRY
DbgDrvQueryDeviceSupport(SURFOBJ * pso,XLATEOBJ * pxlo,XFORMOBJ * pxo,ULONG iType,ULONG cjIn,_In_ PVOID pvIn,ULONG cjOut,_Out_ PVOID pvOut)1091 DbgDrvQueryDeviceSupport(
1092 SURFOBJ *pso,
1093 XLATEOBJ *pxlo,
1094 XFORMOBJ *pxo,
1095 ULONG iType,
1096 ULONG cjIn,
1097 _In_ PVOID pvIn,
1098 ULONG cjOut,
1099 _Out_ PVOID pvOut)
1100 {
1101 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
1102 ASSERT(ppdev);
1103
1104 return ppdev->pldev->pfn.QueryDeviceSupport(pso,
1105 pxlo,
1106 (PVOID)pxo, // FIXME!!!
1107 iType,
1108 cjIn,
1109 pvIn,
1110 cjOut,
1111 pvOut);
1112 }
1113
1114 HBITMAP
1115 APIENTRY
DbgDrvDeriveSurface(DD_DIRECTDRAW_GLOBAL * pDirectDraw,DD_SURFACE_LOCAL * pSurface)1116 DbgDrvDeriveSurface(
1117 DD_DIRECTDRAW_GLOBAL *pDirectDraw,
1118 DD_SURFACE_LOCAL *pSurface)
1119 {
1120 return 0;
1121 }
1122
1123 PFD_GLYPHATTR
1124 APIENTRY
DbgDrvQueryGlyphAttrs(_In_ FONTOBJ * pfo,_In_ ULONG iMode)1125 DbgDrvQueryGlyphAttrs(
1126 _In_ FONTOBJ *pfo,
1127 _In_ ULONG iMode)
1128 {
1129 return 0;
1130 }
1131
1132 VOID
1133 APIENTRY
DbgDrvNotify(SURFOBJ * pso,ULONG iType,PVOID pvData)1134 DbgDrvNotify(
1135 SURFOBJ *pso,
1136 ULONG iType,
1137 PVOID pvData)
1138 {
1139 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
1140 ASSERT(ppdev);
1141
1142 ppdev->pldev->pfn.Notify(pso, iType, pvData);
1143 }
1144
1145 VOID
1146 APIENTRY
DbgDrvSynchronizeSurface(SURFOBJ * pso,RECTL * prcl,FLONG fl)1147 DbgDrvSynchronizeSurface(
1148 SURFOBJ *pso,
1149 RECTL *prcl,
1150 FLONG fl)
1151 {
1152 PPDEVOBJ ppdev = (PPDEVOBJ)pso->hdev;
1153 ASSERT(ppdev);
1154
1155 ppdev->pldev->pfn.SynchronizeSurface(pso, prcl, fl);
1156 }
1157
1158 ULONG
1159 APIENTRY
DbgDrvResetDevice(DHPDEV dhpdev,PVOID Reserved)1160 DbgDrvResetDevice(
1161 DHPDEV dhpdev,
1162 PVOID Reserved)
1163 {
1164 PPDEVOBJ ppdev = DbgLookupDHPDEV(dhpdev);
1165 ASSERT(ppdev);
1166
1167 return ppdev->pldev->pfn.ResetDevice(dhpdev, Reserved);
1168 }
1169
1170 PVOID
1171 apfnDbgDrvFunctions[] =
1172 {
1173 DbgDrvEnablePDEV,
1174 DbgDrvCompletePDEV,
1175 DbgDrvDisablePDEV,
1176 DbgDrvEnableSurface,
1177 DbgDrvDisableSurface,
1178 DbgDrvAssertMode,
1179 DbgDrvOffset,
1180 DbgDrvResetPDEV,
1181 NULL, //DbgDrvDisableDriver,
1182 DbgDrvReserved, // Unknown1
1183 DbgDrvCreateDeviceBitmap,
1184 NULL, //DbgDrvDeleteDeviceBitmap,
1185 DbgDrvRealizeBrush,
1186 DbgDrvDitherColor,
1187 DbgDrvStrokePath,
1188 DbgDrvFillPath,
1189 DbgDrvStrokeAndFillPath,
1190 DbgDrvPaint,
1191 DbgDrvBitBlt,
1192 NULL, //DbgDrvCopyBits,
1193 NULL, //DbgDrvStretchBlt,
1194 DbgDrvReserved,
1195 DbgDrvSetPalette,
1196 NULL, //DbgDrvTextOut,
1197 NULL, //DbgDrvEscape,
1198 NULL, //DbgDrvDrawEscape,
1199 DbgDrvQueryFont,
1200 NULL, //DbgDrvQueryFontTree,
1201 DbgDrvQueryFontData,
1202 NULL, //DbgDrvSetPointerShape,
1203 NULL, //DbgDrvMovePointer,
1204 NULL, //DbgDrvLineTo,
1205 NULL, //DbgDrvSendPage,
1206 NULL, //DbgDrvStartPage,
1207 NULL, //DbgDrvEndDoc,
1208 NULL, //DbgDrvStartDoc,
1209 DbgDrvReserved,
1210 DbgDrvGetGlyphMode,
1211 DbgDrvSynchronize,
1212 DbgDrvReserved,
1213 NULL, //DbgDrvSaveScreenBits,
1214 NULL, //DbgDrvGetModes,
1215 NULL, //DbgDrvFree,
1216 NULL, //DbgDrvDestroyFont,
1217 NULL, //DbgDrvQueryFontCaps,
1218 NULL, //DbgDrvLoadFontFile,
1219 NULL, //DbgDrvUnloadFontFile,
1220 NULL, //DbgDrvFontManagement,
1221 NULL, //DbgDrvQueryTrueTypeTable,
1222 NULL, //DbgDrvQueryTrueTypeOutline,
1223 NULL, //DbgDrvGetTrueTypeFile,
1224 NULL, //DbgDrvQueryFontFile,
1225 DbgDrvMovePanning,
1226 NULL, //DbgDrvQueryAdvanceWidths,
1227 NULL, //DbgDrvSetPixelFormat,
1228 DbgDrvDescribePixelFormat,
1229 NULL, //DbgDrvSwapBuffers,
1230 NULL, //DbgDrvStartBanding,
1231 NULL, //DbgDrvNextBand,
1232 DbgDrvGetDirectDrawInfo,
1233 DbgDrvEnableDirectDraw,
1234 DbgDrvDisableDirectDraw,
1235 DbgDrvQuerySpoolType,
1236 DbgDrvReserved,
1237 DbgDrvIcmCreateColorTransform,
1238 DbgDrvIcmDeleteColorTransform,
1239 DbgDrvIcmCheckBitmapBits,
1240 DbgDrvIcmSetDeviceGammaRamp,
1241 NULL, //DbgDrvGradientFill,
1242 NULL, //DbgDrvStretchBltROP,
1243 NULL, //DbgDrvPlgBlt,
1244 NULL, //DbgDrvAlphaBlend,
1245 NULL, //DbgSynthesizeFont,
1246 NULL, //DbgGetSynthesizedFontFiles,
1247 NULL, //DbgDrvTransparentBlt,
1248 NULL, //DbgDrvQueryPerBandInfo,
1249 DbgDrvQueryDeviceSupport,
1250 DbgDrvReserved,
1251 DbgDrvReserved,
1252 DbgDrvReserved,
1253 DbgDrvReserved,
1254 DbgDrvReserved,
1255 DbgDrvReserved,
1256 DbgDrvReserved,
1257 DbgDrvReserved,
1258 NULL, //DbgDrvDeriveSurface,
1259 NULL, //DbgDrvQueryGlyphAttrs,
1260 DbgDrvNotify,
1261 DbgDrvSynchronizeSurface,
1262 DbgDrvResetDevice,
1263 DbgDrvReserved,
1264 DbgDrvReserved,
1265 DbgDrvReserved
1266 };
1267