ReactOS  0.4.14-dev-317-g96040ec
screen.c
Go to the documentation of this file.
1 /*
2  * PROJECT: ReactOS Framebuffer Display Driver
3  * LICENSE: Microsoft NT4 DDK Sample Code License
4  * FILE: win32ss/drivers/displays/framebuf_new/screen.c
5  * PURPOSE: Surface, Screen and PDEV support/initialization
6  * PROGRAMMERS: Copyright (c) 1992-1995 Microsoft Corporation
7  * ReactOS Portable Systems Group
8  */
9 
10 #include "driver.h"
11 
12 #define SYSTM_LOGFONT {16,7,0,0,700,0,0,0,ANSI_CHARSET,OUT_DEFAULT_PRECIS,CLIP_DEFAULT_PRECIS,DEFAULT_QUALITY,VARIABLE_PITCH | FF_DONTCARE,L"System"}
13 #define HELVE_LOGFONT {12,9,0,0,400,0,0,0,ANSI_CHARSET,OUT_DEFAULT_PRECIS,CLIP_STROKE_PRECIS,PROOF_QUALITY,VARIABLE_PITCH | FF_DONTCARE,L"MS Sans Serif"}
14 #define COURI_LOGFONT {12,9,0,0,400,0,0,0,ANSI_CHARSET,OUT_DEFAULT_PRECIS,CLIP_STROKE_PRECIS,PROOF_QUALITY,FIXED_PITCH | FF_DONTCARE, L"Courier"}
15 
16 // This is the basic devinfo for a default driver. This is used as a base and customized based
17 // on information passed back from the miniport driver.
18 
21 // eVb: 2.8 [DDK CHANGE] - No dithering support
22 // eVb: 2.8 [END]
23  ), /* Graphics capabilities */
24  SYSTM_LOGFONT, /* Default font description */
25  HELVE_LOGFONT, /* ANSI variable font description */
26  COURI_LOGFONT, /* ANSI fixed font description */
27  0, /* Count of device fonts */
28  0, /* Preferred DIB format */
29 // eVb: 2.9 [DDK CHANGE] - No dithering support
30  0, /* Width of color dither */
31  0, /* Height of color dither */
32 // eVb: 2.9 [END]
33  0 /* Default palette to use for this device */
34 };
35 
36 /******************************Public*Routine******************************\
37 * bInitSURF
38 *
39 * Enables the surface. Maps the frame buffer into memory.
40 *
41 \**************************************************************************/
42 
43 BOOL NTAPI bInitSURF(PPDEV ppdev, BOOL bFirst)
44 {
45  DWORD returnedDataLength;
46  DWORD MaxWidth, MaxHeight;
47  VIDEO_MEMORY videoMemory;
48  VIDEO_MEMORY_INFORMATION videoMemoryInformation;
49 // eVb: 2.1 [DDK Change] - Support new VGA Miniport behavior w.r.t updated framebuffer remapping
50  ULONG RemappingNeeded = 0;
51 // eVb: 2.1 [END]
52  //
53  // Set the current mode into the hardware.
54  //
55 
56  if (EngDeviceIoControl(ppdev->hDriver,
58  &(ppdev->ulMode),
59  sizeof(ULONG),
60 // eVb: 2.2 [DDK Change] - Support new VGA Miniport behavior w.r.t updated framebuffer remapping
61  &RemappingNeeded,
62  sizeof(ULONG),
63 // eVb: 2.2 [END]
64  &returnedDataLength))
65  {
66  RIP("DISP bInitSURF failed IOCTL_SET_MODE\n");
67  return(FALSE);
68  }
69 
70  //
71  // If this is the first time we enable the surface we need to map in the
72  // memory also.
73  //
74 // eVb: 2.3 [DDK Change] - Support new VGA Miniport behavior w.r.t updated framebuffer remapping
75  if (bFirst || RemappingNeeded)
76  {
77 // eVb: 2.3 [END]
78  videoMemory.RequestedVirtualAddress = NULL;
79 
80  if (EngDeviceIoControl(ppdev->hDriver,
82  &videoMemory,
83  sizeof(VIDEO_MEMORY),
84  &videoMemoryInformation,
86  &returnedDataLength))
87  {
88  RIP("DISP bInitSURF failed IOCTL_VIDEO_MAP\n");
89  return(FALSE);
90  }
91 
92  ppdev->pjScreen = (PBYTE)(videoMemoryInformation.FrameBufferBase);
93 
94  if (videoMemoryInformation.FrameBufferBase !=
95  videoMemoryInformation.VideoRamBase)
96  {
97  RIP("VideoRamBase does not correspond to FrameBufferBase\n");
98  }
99 // eVb: 2.4 [DDK Change] - Make sure frame buffer mapping worked
100  //
101  // Make sure we can access this video memory
102  //
103 
104  *(PULONG)(ppdev->pjScreen) = 0xaa55aa55;
105 
106  if (*(PULONG)(ppdev->pjScreen) != 0xaa55aa55) {
107 
108  DISPDBG((1, "Frame buffer memory is not accessible.\n"));
109  return(FALSE);
110  }
111 // eVb: 2.4 [END]
112  ppdev->cScreenSize = videoMemoryInformation.VideoRamLength;
113 
114  //
115  // Initialize the head of the offscreen list to NULL.
116  //
117 
118  ppdev->pOffscreenList = NULL;
119 
120  // It's a hardware pointer; set up pointer attributes.
121 
122  MaxHeight = ppdev->PointerCapabilities.MaxHeight;
123 
124  // Allocate space for two DIBs (data/mask) for the pointer. If this
125  // device supports a color Pointer, we will allocate a larger bitmap.
126  // If this is a color bitmap we allocate for the largest possible
127  // bitmap because we have no idea of what the pixel depth might be.
128 
129  // Width rounded up to nearest byte multiple
130 
132  {
133  MaxWidth = (ppdev->PointerCapabilities.MaxWidth + 7) / 8;
134  }
135  else
136  {
137  MaxWidth = ppdev->PointerCapabilities.MaxWidth * sizeof(DWORD);
138  }
139 
140  ppdev->cjPointerAttributes =
141  sizeof(VIDEO_POINTER_ATTRIBUTES) +
142  ((sizeof(UCHAR) * MaxWidth * MaxHeight) * 2);
143 
146 
147  if (ppdev->pPointerAttributes == NULL) {
148 
149  DISPDBG((0, "bInitPointer EngAllocMem failed\n"));
150  return(FALSE);
151  }
152 
154  ppdev->pPointerAttributes->WidthInBytes = MaxWidth;
156  ppdev->pPointerAttributes->Height = MaxHeight;
157  ppdev->pPointerAttributes->Column = 0;
158  ppdev->pPointerAttributes->Row = 0;
159  ppdev->pPointerAttributes->Enable = 0;
160  }
161 
162  return(TRUE);
163 }
164 
165 /******************************Public*Routine******************************\
166 * vDisableSURF
167 *
168 * Disable the surface. Un-Maps the frame in memory.
169 *
170 \**************************************************************************/
171 
173 {
174  DWORD returnedDataLength;
175  VIDEO_MEMORY videoMemory;
176 
177  videoMemory.RequestedVirtualAddress = (PVOID) ppdev->pjScreen;
178 
179  if (EngDeviceIoControl(ppdev->hDriver,
181  &videoMemory,
182  sizeof(VIDEO_MEMORY),
183  NULL,
184  0,
185  &returnedDataLength))
186  {
187  RIP("DISP vDisableSURF failed IOCTL_VIDEO_UNMAP\n");
188  }
189 }
190 
191 
192 /******************************Public*Routine******************************\
193 * bInitPDEV
194 *
195 * Determine the mode we should be in based on the DEVMODE passed in.
196 * Query mini-port to get information needed to fill in the DevInfo and the
197 * GdiInfo .
198 *
199 \**************************************************************************/
200 
202 PPDEV ppdev,
203 DEVMODEW *pDevMode,
204 GDIINFO *pGdiInfo,
205 DEVINFO *pDevInfo)
206 {
207  ULONG cModes;
208  PVIDEO_MODE_INFORMATION pVideoBuffer, pVideoModeSelected, pVideoTemp;
209  VIDEO_COLOR_CAPABILITIES colorCapabilities;
210  ULONG ulTemp;
211  BOOL bSelectDefault;
212  ULONG cbModeSize;
213 
214  //
215  // calls the miniport to get mode information.
216  //
217 
218  cModes = getAvailableModes(ppdev->hDriver, &pVideoBuffer, &cbModeSize);
219 
220  if (cModes == 0)
221  {
222  return(FALSE);
223  }
224 
225  //
226  // Now see if the requested mode has a match in that table.
227  //
228 
229  pVideoModeSelected = NULL;
230  pVideoTemp = pVideoBuffer;
231 
232  if ((pDevMode->dmPelsWidth == 0) &&
233  (pDevMode->dmPelsHeight == 0) &&
234  (pDevMode->dmBitsPerPel == 0) &&
235  (pDevMode->dmDisplayFrequency == 0))
236  {
237  DISPDBG((2, "Default mode requested"));
238  bSelectDefault = TRUE;
239  }
240  else
241  {
242 // eVb: 2.5 [DDK Change] - Add missing newlines to debug output
243  DISPDBG((2, "Requested mode...\n"));
244  DISPDBG((2, " Screen width -- %li\n", pDevMode->dmPelsWidth));
245  DISPDBG((2, " Screen height -- %li\n", pDevMode->dmPelsHeight));
246  DISPDBG((2, " Bits per pel -- %li\n", pDevMode->dmBitsPerPel));
247  DISPDBG((2, " Frequency -- %li\n", pDevMode->dmDisplayFrequency));
248 // eVb: 2.5 [END]
249  bSelectDefault = FALSE;
250  }
251 
252  while (cModes--)
253  {
254  if (pVideoTemp->Length != 0)
255  {
256  if (bSelectDefault ||
257  ((pVideoTemp->VisScreenWidth == pDevMode->dmPelsWidth) &&
258  (pVideoTemp->VisScreenHeight == pDevMode->dmPelsHeight) &&
259  (pVideoTemp->BitsPerPlane *
260  pVideoTemp->NumberOfPlanes == pDevMode->dmBitsPerPel) &&
261  (pVideoTemp->Frequency == pDevMode->dmDisplayFrequency)))
262  {
263  pVideoModeSelected = pVideoTemp;
264  DISPDBG((3, "Found a match\n")) ;
265  break;
266  }
267  }
268 
269  pVideoTemp = (PVIDEO_MODE_INFORMATION)
270  (((PUCHAR)pVideoTemp) + cbModeSize);
271  }
272 
273  //
274  // If no mode has been found, return an error
275  //
276 
277  if (pVideoModeSelected == NULL)
278  {
279  EngFreeMem(pVideoBuffer);
280  DISPDBG((0,"DISP bInitPDEV failed - no valid modes\n"));
281  return(FALSE);
282  }
283 
284  //
285  // Fill in the GDIINFO data structure with the information returned from
286  // the kernel driver.
287  //
288 
289  ppdev->ulMode = pVideoModeSelected->ModeIndex;
290  ppdev->cxScreen = pVideoModeSelected->VisScreenWidth;
291  ppdev->cyScreen = pVideoModeSelected->VisScreenHeight;
292  ppdev->ulBitCount = pVideoModeSelected->BitsPerPlane *
293  pVideoModeSelected->NumberOfPlanes;
294  ppdev->lDeltaScreen = pVideoModeSelected->ScreenStride;
295 
296  ppdev->flRed = pVideoModeSelected->RedMask;
297  ppdev->flGreen = pVideoModeSelected->GreenMask;
298  ppdev->flBlue = pVideoModeSelected->BlueMask;
299 
300 
301  pGdiInfo->ulVersion = GDI_DRIVER_VERSION;
302  pGdiInfo->ulTechnology = DT_RASDISPLAY;
303  pGdiInfo->ulHorzSize = pVideoModeSelected->XMillimeter;
304  pGdiInfo->ulVertSize = pVideoModeSelected->YMillimeter;
305 
306  pGdiInfo->ulHorzRes = ppdev->cxScreen;
307  pGdiInfo->ulVertRes = ppdev->cyScreen;
308  pGdiInfo->ulPanningHorzRes = ppdev->cxScreen;
309  pGdiInfo->ulPanningVertRes = ppdev->cyScreen;
310  pGdiInfo->cBitsPixel = pVideoModeSelected->BitsPerPlane;
311  pGdiInfo->cPlanes = pVideoModeSelected->NumberOfPlanes;
312  pGdiInfo->ulVRefresh = pVideoModeSelected->Frequency;
313  pGdiInfo->ulBltAlignment = 1; // We don't have accelerated screen-
314  // to-screen blts, and any
315  // window alignment is okay
316 
317  pGdiInfo->ulLogPixelsX = pDevMode->dmLogPixels;
318  pGdiInfo->ulLogPixelsY = pDevMode->dmLogPixels;
319 
320 #ifdef MIPS
321  if (ppdev->ulBitCount == 8)
322  pGdiInfo->flTextCaps = (TC_RA_ABLE | TC_SCROLLBLT);
323  else
324 #endif
325  pGdiInfo->flTextCaps = TC_RA_ABLE;
326 
327  pGdiInfo->flRaster = 0; // flRaster is reserved by DDI
328 
329  pGdiInfo->ulDACRed = pVideoModeSelected->NumberRedBits;
330  pGdiInfo->ulDACGreen = pVideoModeSelected->NumberGreenBits;
331  pGdiInfo->ulDACBlue = pVideoModeSelected->NumberBlueBits;
332 
333  pGdiInfo->ulAspectX = 0x24; // One-to-one aspect ratio
334  pGdiInfo->ulAspectY = 0x24;
335  pGdiInfo->ulAspectXY = 0x33;
336 
337  pGdiInfo->xStyleStep = 1; // A style unit is 3 pels
338  pGdiInfo->yStyleStep = 1;
339  pGdiInfo->denStyleStep = 3;
340 
341  pGdiInfo->ptlPhysOffset.x = 0;
342  pGdiInfo->ptlPhysOffset.y = 0;
343  pGdiInfo->szlPhysSize.cx = 0;
344  pGdiInfo->szlPhysSize.cy = 0;
345 
346  // RGB and CMY color info.
347 
348  //
349  // try to get it from the miniport.
350  // if the miniport doesn ot support this feature, use defaults.
351  //
352 
353  if (EngDeviceIoControl(ppdev->hDriver,
355  NULL,
356  0,
357  &colorCapabilities,
358  sizeof(VIDEO_COLOR_CAPABILITIES),
359  &ulTemp))
360  {
361 
362  DISPDBG((2, "getcolorCapabilities failed \n"));
363 
364  pGdiInfo->ciDevice.Red.x = 6700;
365  pGdiInfo->ciDevice.Red.y = 3300;
366  pGdiInfo->ciDevice.Red.Y = 0;
367  pGdiInfo->ciDevice.Green.x = 2100;
368  pGdiInfo->ciDevice.Green.y = 7100;
369  pGdiInfo->ciDevice.Green.Y = 0;
370  pGdiInfo->ciDevice.Blue.x = 1400;
371  pGdiInfo->ciDevice.Blue.y = 800;
372  pGdiInfo->ciDevice.Blue.Y = 0;
373  pGdiInfo->ciDevice.AlignmentWhite.x = 3127;
374  pGdiInfo->ciDevice.AlignmentWhite.y = 3290;
375  pGdiInfo->ciDevice.AlignmentWhite.Y = 0;
376 
377  pGdiInfo->ciDevice.RedGamma = 20000;
378  pGdiInfo->ciDevice.GreenGamma = 20000;
379  pGdiInfo->ciDevice.BlueGamma = 20000;
380 
381  }
382  else
383  {
384  pGdiInfo->ciDevice.Red.x = colorCapabilities.RedChromaticity_x;
385  pGdiInfo->ciDevice.Red.y = colorCapabilities.RedChromaticity_y;
386  pGdiInfo->ciDevice.Red.Y = 0;
387  pGdiInfo->ciDevice.Green.x = colorCapabilities.GreenChromaticity_x;
388  pGdiInfo->ciDevice.Green.y = colorCapabilities.GreenChromaticity_y;
389  pGdiInfo->ciDevice.Green.Y = 0;
390  pGdiInfo->ciDevice.Blue.x = colorCapabilities.BlueChromaticity_x;
391  pGdiInfo->ciDevice.Blue.y = colorCapabilities.BlueChromaticity_y;
392  pGdiInfo->ciDevice.Blue.Y = 0;
393  pGdiInfo->ciDevice.AlignmentWhite.x = colorCapabilities.WhiteChromaticity_x;
394  pGdiInfo->ciDevice.AlignmentWhite.y = colorCapabilities.WhiteChromaticity_y;
395  pGdiInfo->ciDevice.AlignmentWhite.Y = colorCapabilities.WhiteChromaticity_Y;
396 
397  // if we have a color device store the three color gamma values,
398  // otherwise store the unique gamma value in all three.
399 
400  if (colorCapabilities.AttributeFlags & VIDEO_DEVICE_COLOR)
401  {
402  pGdiInfo->ciDevice.RedGamma = colorCapabilities.RedGamma;
403  pGdiInfo->ciDevice.GreenGamma = colorCapabilities.GreenGamma;
404  pGdiInfo->ciDevice.BlueGamma = colorCapabilities.BlueGamma;
405  }
406  else
407  {
408  pGdiInfo->ciDevice.RedGamma = colorCapabilities.WhiteGamma;
409  pGdiInfo->ciDevice.GreenGamma = colorCapabilities.WhiteGamma;
410  pGdiInfo->ciDevice.BlueGamma = colorCapabilities.WhiteGamma;
411  }
412 
413  };
414 
415  pGdiInfo->ciDevice.Cyan.x = 0;
416  pGdiInfo->ciDevice.Cyan.y = 0;
417  pGdiInfo->ciDevice.Cyan.Y = 0;
418  pGdiInfo->ciDevice.Magenta.x = 0;
419  pGdiInfo->ciDevice.Magenta.y = 0;
420  pGdiInfo->ciDevice.Magenta.Y = 0;
421  pGdiInfo->ciDevice.Yellow.x = 0;
422  pGdiInfo->ciDevice.Yellow.y = 0;
423  pGdiInfo->ciDevice.Yellow.Y = 0;
424 
425  // No dye correction for raster displays.
426 
427  pGdiInfo->ciDevice.MagentaInCyanDye = 0;
428  pGdiInfo->ciDevice.YellowInCyanDye = 0;
429  pGdiInfo->ciDevice.CyanInMagentaDye = 0;
430  pGdiInfo->ciDevice.YellowInMagentaDye = 0;
431  pGdiInfo->ciDevice.CyanInYellowDye = 0;
432  pGdiInfo->ciDevice.MagentaInYellowDye = 0;
433 
434  pGdiInfo->ulDevicePelsDPI = 0; // For printers only
435  pGdiInfo->ulPrimaryOrder = PRIMARY_ORDER_CBA;
436 
437  // BUGBUG this should be modified to take into account the size
438  // of the display and the resolution.
439 
440  pGdiInfo->ulHTPatternSize = HT_PATSIZE_4x4_M;
441 
442  pGdiInfo->flHTFlags = HT_FLAG_ADDITIVE_PRIMS;
443 
444  // Fill in the basic devinfo structure
445 
446  *pDevInfo = gDevInfoFrameBuffer;
447 
448  // Fill in the rest of the devinfo and GdiInfo structures.
449 
450  if (ppdev->ulBitCount == 8)
451  {
452  // It is Palette Managed.
453 
454  pGdiInfo->ulNumColors = 20;
455  pGdiInfo->ulNumPalReg = 1 << ppdev->ulBitCount;
456 // eVb: 2.7 [DDK CHANGE] - No dithering support
457  pDevInfo->flGraphicsCaps |= GCAPS_PALMANAGED;
458 // eVb: 2.7 [END]
459  pGdiInfo->ulHTOutputFormat = HT_FORMAT_8BPP;
460  pDevInfo->iDitherFormat = BMF_8BPP;
461 
462  // Assuming palette is orthogonal - all colors are same size.
463 
464  ppdev->cPaletteShift = 8 - pGdiInfo->ulDACRed;
465  }
466  else
467  {
468  pGdiInfo->ulNumColors = (ULONG) (-1);
469  pGdiInfo->ulNumPalReg = 0;
470 
471  if (ppdev->ulBitCount == 16)
472  {
473  pGdiInfo->ulHTOutputFormat = HT_FORMAT_16BPP;
474  pDevInfo->iDitherFormat = BMF_16BPP;
475  }
476  else if (ppdev->ulBitCount == 24)
477  {
478  pGdiInfo->ulHTOutputFormat = HT_FORMAT_24BPP;
479  pDevInfo->iDitherFormat = BMF_24BPP;
480  }
481  else
482  {
483  pGdiInfo->ulHTOutputFormat = HT_FORMAT_32BPP;
484  pDevInfo->iDitherFormat = BMF_32BPP;
485  }
486  }
487 
488  EngFreeMem(pVideoBuffer);
489 
490  return(TRUE);
491 }
492 
493 
494 /******************************Public*Routine******************************\
495 * getAvailableModes
496 *
497 * Calls the miniport to get the list of modes supported by the kernel driver,
498 * and returns the list of modes supported by the diplay driver among those
499 *
500 * returns the number of entries in the videomode buffer.
501 * 0 means no modes are supported by the miniport or that an error occured.
502 *
503 * NOTE: the buffer must be freed up by the caller.
504 *
505 \**************************************************************************/
506 
509 PVIDEO_MODE_INFORMATION *modeInformation,
510 DWORD *cbModeSize)
511 {
512  ULONG ulTemp;
513  VIDEO_NUM_MODES modes;
514  PVIDEO_MODE_INFORMATION pVideoTemp;
515 
516  //
517  // Get the number of modes supported by the mini-port
518  //
519 
520  if (EngDeviceIoControl(hDriver,
522  NULL,
523  0,
524  &modes,
525  sizeof(VIDEO_NUM_MODES),
526  &ulTemp))
527  {
528  DISPDBG((0, "getAvailableModes failed VIDEO_QUERY_NUM_AVAIL_MODES\n"));
529  return(0);
530  }
531 
532  *cbModeSize = modes.ModeInformationLength;
533 
534  //
535  // Allocate the buffer for the mini-port to write the modes in.
536  //
537 
538  *modeInformation = (PVIDEO_MODE_INFORMATION)
539  EngAllocMem(0, modes.NumModes *
541 
542  if (*modeInformation == (PVIDEO_MODE_INFORMATION) NULL)
543  {
544  DISPDBG((0, "getAvailableModes failed EngAllocMem\n"));
545 
546  return 0;
547  }
548 
549  //
550  // Ask the mini-port to fill in the available modes.
551  //
552 
553  if (EngDeviceIoControl(hDriver,
555  NULL,
556  0,
557  *modeInformation,
558  modes.NumModes * modes.ModeInformationLength,
559  &ulTemp))
560  {
561 
562  DISPDBG((0, "getAvailableModes failed VIDEO_QUERY_AVAIL_MODES\n"));
563 
564  EngFreeMem(*modeInformation);
565  *modeInformation = (PVIDEO_MODE_INFORMATION) NULL;
566 
567  return(0);
568  }
569 
570  //
571  // Now see which of these modes are supported by the display driver.
572  // As an internal mechanism, set the length to 0 for the modes we
573  // DO NOT support.
574  //
575 
576  ulTemp = modes.NumModes;
577  pVideoTemp = *modeInformation;
578 
579  //
580  // Mode is rejected if it is not one plane, or not graphics, or is not
581  // one of 8, 16 or 32 bits per pel.
582  //
583 
584  while (ulTemp--)
585  {
586  if ((pVideoTemp->NumberOfPlanes != 1 ) ||
587  !(pVideoTemp->AttributeFlags & VIDEO_MODE_GRAPHICS) ||
588 // eVb: 2.6 [DDK CHANGE] - Do not process banked video modes
589  (pVideoTemp->AttributeFlags & VIDEO_MODE_BANKED) ||
590 // eVb: 2.6 [END]
591  ((pVideoTemp->BitsPerPlane != 8) &&
592  (pVideoTemp->BitsPerPlane != 16) &&
593  (pVideoTemp->BitsPerPlane != 24) &&
594  (pVideoTemp->BitsPerPlane != 32)))
595  {
596  pVideoTemp->Length = 0;
597  }
598 
599  pVideoTemp = (PVIDEO_MODE_INFORMATION)
600  (((PUCHAR)pVideoTemp) + modes.ModeInformationLength);
601  }
602 
603  return modes.NumModes;
604 
605 }
ULONG ulDevicePelsDPI
Definition: winddi.h:904
SIZEL szlPhysSize
Definition: winddi.h:901
#define IOCTL_VIDEO_QUERY_COLOR_CAPABILITIES
Definition: ntddvdeo.h:110
#define BMF_24BPP
Definition: winddi.h:359
ULONG ModeInformationLength
Definition: ntddvdeo.h:328
#define VIDEO_DEVICE_COLOR
Definition: ntddvdeo.h:403
LDECI4 MagentaInCyanDye
Definition: winddi.h:295
VIDEO_POINTER_CAPABILITIES PointerCapabilities
Definition: driver.h:44
struct _VIDEO_POINTER_ATTRIBUTES VIDEO_POINTER_ATTRIBUTES
LDECI4 y
Definition: winddi.h:241
#define TRUE
Definition: types.h:120
LDECI4 CyanInYellowDye
Definition: winddi.h:299
#define VIDEO_MODE_COLOR_POINTER
Definition: ntddvdeo.h:455
#define BMF_32BPP
Definition: winddi.h:360
ULONG ulDACRed
Definition: winddi.h:891
CIECHROMA Yellow
Definition: winddi.h:290
CIECHROMA Green
Definition: winddi.h:286
Definition: xlate.c:10
#define HT_FORMAT_16BPP
Definition: winddi.h:820
ULONG ulHTOutputFormat
Definition: winddi.h:907
ULONG ulMode
Definition: driver.h:31
ULONG ulPrimaryOrder
Definition: winddi.h:905
#define EngFreeMem
Definition: polytest.cpp:56
unsigned char * PUCHAR
Definition: retypes.h:3
CIECHROMA Blue
Definition: winddi.h:287
LDECI4 YellowInCyanDye
Definition: winddi.h:296
ULONG ulAspectY
Definition: winddi.h:895
#define RIP(x)
Definition: debug.h:24
_In_ LPWSTR _In_ ULONG _In_ ULONG _In_ ULONG _Out_ DEVINFO _In_ HDEV _In_ LPWSTR _In_ HANDLE hDriver
Definition: winddi.h:3553
LONG denStyleStep
Definition: winddi.h:899
ULONG ulLogPixelsY
Definition: winddi.h:889
LDECI4 MagentaInYellowDye
Definition: winddi.h:300
ULONG ulPanningHorzRes
Definition: winddi.h:911
#define IOCTL_VIDEO_MAP_VIDEO_MEMORY
Definition: ntddvdeo.h:104
PVOID RequestedVirtualAddress
Definition: ntddvdeo.h:274
ULONG cPlanes
Definition: winddi.h:885
DWORD dmBitsPerPel
Definition: wingdi.h:1642
ULONG flTextCaps
Definition: winddi.h:890
CIECHROMA Cyan
Definition: winddi.h:288
#define DT_RASDISPLAY
Definition: wingdi.h:707
#define DWORD
Definition: nt_native.h:44
LONG y
Definition: windef.h:315
#define IOCTL_VIDEO_SET_CURRENT_MODE
Definition: ntddvdeo.h:152
ULONG flHTFlags
Definition: winddi.h:908
LDECI4 GreenGamma
Definition: winddi.h:293
#define ALLOC_TAG
Definition: btrfs_drv.h:91
ULONG ulNumPalReg
Definition: winddi.h:902
FLONG flGreen
Definition: driver.h:37
ULONG ulVertSize
Definition: winddi.h:881
LDECI4 BlueGamma
Definition: winddi.h:294
ULONG cyScreen
Definition: driver.h:30
struct _VIDEO_MODE_INFORMATION * PVIDEO_MODE_INFORMATION
#define GDI_DRIVER_VERSION
Definition: winddi.h:109
ULONG ulDACGreen
Definition: winddi.h:892
NTSTATUS(* NTAPI)(IN PFILE_FULL_EA_INFORMATION EaBuffer, IN ULONG EaLength, OUT PULONG ErrorOffset)
Definition: IoEaTest.cpp:117
POINTL ptlPhysOffset
Definition: winddi.h:900
ULONG ulVersion
Definition: winddi.h:878
WORD dmLogPixels
Definition: wingdi.h:1641
unsigned int BOOL
Definition: ntddk_ex.h:94
CIECHROMA AlignmentWhite
Definition: winddi.h:291
HANDLE hDriver
Definition: framebuf.h:35
#define TC_SCROLLBLT
Definition: wingdi.h:822
DWORD cjPointerAttributes
Definition: driver.h:46
CIECHROMA Magenta
Definition: winddi.h:289
ULONG ulHorzRes
Definition: winddi.h:882
smooth NULL
Definition: ftsmooth.c:416
LONG cx
Definition: windef.h:319
ULONG ulTechnology
Definition: winddi.h:879
BOOL NTAPI bInitPDEV(PPDEV ppdev, DEVMODEW *pDevMode, GDIINFO *pGdiInfo, DEVINFO *pDevInfo)
Definition: screen.c:201
LONG yStyleStep
Definition: winddi.h:898
const DEVINFO gDevInfoFrameBuffer
Definition: screen.c:19
void * PVOID
Definition: retypes.h:9
ULONG iDitherFormat
Definition: winddi.h:395
ULONG ulAspectXY
Definition: winddi.h:896
#define BMF_16BPP
Definition: winddi.h:358
ULONG cScreenSize
Definition: driver.h:33
LDECI4 YellowInMagentaDye
Definition: winddi.h:298
#define IOCTL_VIDEO_UNMAP_VIDEO_MEMORY
Definition: ntddvdeo.h:179
FLONG flRed
Definition: driver.h:36
ULONG ulBitCount
Definition: driver.h:42
ULONG ulBltAlignment
Definition: winddi.h:910
ULONG ulDACBlue
Definition: winddi.h:893
if(!(yy_init))
Definition: macro.lex.yy.c:714
#define TC_RA_ABLE
Definition: wingdi.h:819
LDECI4 x
Definition: winddi.h:240
unsigned long DWORD
Definition: ntddk_ex.h:95
LONG x
Definition: windef.h:314
LDECI4 Y
Definition: winddi.h:242
ULONG ulHTPatternSize
Definition: winddi.h:906
#define VIDEO_MODE_BANKED
Definition: ntddvdeo.h:300
#define HT_FLAG_ADDITIVE_PRIMS
Definition: winddi.h:827
ULONG ulHorzSize
Definition: winddi.h:880
DWORD dmPelsWidth
Definition: wingdi.h:1643
#define DISPDBG(arg)
Definition: debug.h:23
struct _VIDEO_POINTER_ATTRIBUTES * PVIDEO_POINTER_ATTRIBUTES
void * EngAllocMem(int zero, unsigned long size, int tag=0)
Definition: polytest.cpp:70
Definition: framebuf.h:33
unsigned char UCHAR
Definition: xmlstorage.h:181
#define PRIMARY_ORDER_CBA
Definition: winddi.h:785
ULONG flRaster
Definition: winddi.h:887
ULONG ulVRefresh
Definition: winddi.h:909
#define GCAPS_OPAQUERECT
Definition: winddi.h:331
#define IOCTL_VIDEO_QUERY_NUM_AVAIL_MODES
Definition: ntddvdeo.h:122
LDECI4 CyanInMagentaDye
Definition: winddi.h:297
#define IOCTL_VIDEO_QUERY_AVAIL_MODES
Definition: ntddvdeo.h:107
ULONG cBitsPixel
Definition: winddi.h:884
ULONG ulAspectX
Definition: winddi.h:894
ULONG cPaletteShift
Definition: driver.h:39
DWORD dmDisplayFrequency
Definition: wingdi.h:1649
PVIDEO_POINTER_ATTRIBUTES pPointerAttributes
Definition: driver.h:45
PBYTE pjScreen
Definition: driver.h:28
FLONG flGraphicsCaps
Definition: winddi.h:390
VOID NTAPI vDisableSURF(PPDEV ppdev)
Definition: screen.c:172
LDECI4 RedGamma
Definition: winddi.h:292
#define COURI_LOGFONT
Definition: screen.c:14
unsigned int * PULONG
Definition: retypes.h:1
BOOL NTAPI bInitSURF(PPDEV ppdev, BOOL bFirst)
Definition: screen.c:43
#define SYSTM_LOGFONT
Definition: screen.c:12
ULONG ulPanningVertRes
Definition: winddi.h:912
ULONG ulNumColors
Definition: winddi.h:886
DWORD dmPelsHeight
Definition: wingdi.h:1644
#define HT_PATSIZE_4x4_M
Definition: winddi.h:792
#define HT_FORMAT_24BPP
Definition: winddi.h:821
COLORINFO ciDevice
Definition: winddi.h:903
unsigned int ULONG
Definition: retypes.h:1
CIECHROMA Red
Definition: winddi.h:285
LONG lDeltaScreen
Definition: driver.h:32
ULONG ulLogPixelsX
Definition: winddi.h:888
ULONG ulVertRes
Definition: winddi.h:883
#define HT_FORMAT_32BPP
Definition: winddi.h:822
#define GCAPS_PALMANAGED
Definition: winddi.h:341
DWORD NTAPI getAvailableModes(HANDLE hDriver, PVIDEO_MODE_INFORMATION *modeInformation, DWORD *cbModeSize)
Definition: screen.c:507
#define HT_FORMAT_8BPP
Definition: winddi.h:819
FLONG flBlue
Definition: driver.h:38
LONG cy
Definition: windef.h:320
BYTE * PBYTE
Definition: pedump.c:66
ULONG cxScreen
Definition: driver.h:29
#define HELVE_LOGFONT
Definition: screen.c:13
LONG xStyleStep
Definition: winddi.h:897
PVOID pOffscreenList
Definition: driver.h:35
#define VIDEO_MODE_GRAPHICS
Definition: ntddvdeo.h:294