Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

63 lines
1.7 KiB

  1. /*++
  2. Copyright (c) 1997-1999 Microsoft Corporation
  3. --*/
  4. #ifndef _PDEV_H
  5. #define _PDEV_H
  6. #include <minidrv.h>
  7. #include <stdio.h>
  8. #include <prcomoem.h>
  9. #include <strsafe.h>
  10. //
  11. // OEM Signature and version.
  12. //
  13. #define OEM_SIGNATURE 'QPLK' // QPL resource DLL
  14. #define DLLTEXT(s) "QPLK: " s
  15. #define OEM_VERSION 0x00010000L
  16. #define SCANLINE_BUFFER_SIZE 1280 // A3 landscape scanline length + extra
  17. // Worst case is like "ABB". It is compressed to
  18. // "[non-continuous count]A[continuous count]B".
  19. // So, we need RLE buffer whose size is 4/3 times as large as scanline buffer.
  20. // But just to make sure, 2x size of buffer is prepared.
  21. #define COMPRESS_BUFFER_SIZE SCANLINE_BUFFER_SIZE*2
  22. // Color support
  23. #define CC_CYAN 5 //current plain is cyan
  24. #define CC_MAGENTA 6 //current plain is magenta
  25. #define CC_YELLOW 7 //current plain is yellow
  26. #define CC_BLACK 4 //current plain is black
  27. ////////////////////////////////////////////////////////
  28. // OEM UD Type Defines
  29. ////////////////////////////////////////////////////////
  30. // #289908: pOEMDM -> pdevOEM
  31. typedef struct tag_OEM_EXTRADATA {
  32. OEM_DMEXTRAHEADER dmExtraHdr;
  33. } OEM_EXTRADATA, *POEM_EXTRADATA;
  34. typedef struct tag_QPLKPDEV {
  35. // Private extention
  36. BOOL bFirst;
  37. DWORD dwCompType;
  38. // Color support
  39. DWORD dwCyanLastScanLineLen;
  40. DWORD dwMagentaLastScanLineLen;
  41. DWORD dwYellowLastScanLineLen;
  42. DWORD dwBlackLastScanLineLen;
  43. BYTE lpCyanLastScanLine[SCANLINE_BUFFER_SIZE];
  44. BYTE lpMagentaLastScanLine[SCANLINE_BUFFER_SIZE];
  45. BYTE lpYellowLastScanLine[SCANLINE_BUFFER_SIZE];
  46. BYTE lpBlackLastScanLine[SCANLINE_BUFFER_SIZE];
  47. BOOL bColor;
  48. UINT fColor;
  49. } QPLKPDEV, *PQPLKPDEV;
  50. #endif // _PDEV_H