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.

126 lines
2.3 KiB

  1. /*++
  2. Copyright (C) 1999- Microsoft Corporation
  3. Module Name:
  4. utils.h
  5. Abstract:
  6. This module declares utilitiy functions
  7. Author:
  8. William Hsieh (williamh) created
  9. Revision History:
  10. --*/
  11. #ifndef UTILS__H_
  12. #define UTILS__H_
  13. WORD
  14. ByteSwapWord(
  15. WORD w
  16. );
  17. DWORD
  18. ByteSwapDword(
  19. DWORD dw
  20. );
  21. DWORD
  22. GetDIBLineSize(
  23. DWORD Width,
  24. DWORD Bitsount
  25. );
  26. DWORD
  27. GetDIBSize(
  28. BITMAPINFO *pbmi
  29. );
  30. DWORD
  31. GetDIBBitsOffset(
  32. BITMAPINFO *pbmi
  33. );
  34. HRESULT
  35. WINAPI
  36. GetTiffDimensions(
  37. BYTE *pTiff,
  38. UINT TiffSize,
  39. UINT *pWidth,
  40. UINT *pHeight,
  41. UINT *pBitDepth
  42. );
  43. HRESULT
  44. WINAPI
  45. Tiff2DIBBitmap(
  46. BYTE *pTiff,
  47. UINT TiffSize,
  48. BYTE *pDIBBmp,
  49. UINT DIBBmpSize,
  50. UINT LineSize,
  51. UINT MaxLines
  52. );
  53. HRESULT
  54. WINAPI
  55. GetJpegDimensions(
  56. BYTE *pJpeg,
  57. UINT JpegSize,
  58. UINT *pWidth,
  59. UINT *pHeight,
  60. UINT *pBitDepth
  61. );
  62. HRESULT
  63. WINAPI
  64. Jpeg2DIBBitmap(
  65. BYTE *pJpeg,
  66. UINT JpegSize,
  67. BYTE *pDIBBmp,
  68. UINT DIBBmpSize,
  69. UINT LineSize,
  70. UINT MaxLines
  71. );
  72. HRESULT
  73. WINAPI
  74. GetImageDimensions(
  75. UINT ptpFormatCode,
  76. BYTE *pCompressedData,
  77. UINT CompressedSize,
  78. UINT *pWidth,
  79. UINT *pHeight,
  80. UINT *pBitDepth
  81. );
  82. HRESULT
  83. WINAPI
  84. ConvertAnyImageToBmp(
  85. BYTE *pImage,
  86. UINT CompressedSize,
  87. UINT *pWidth,
  88. UINT *pHeight,
  89. UINT *pBitDepth,
  90. BYTE **pDIBBmp,
  91. UINT *pImagesize,
  92. UINT *pHeaderSize
  93. );
  94. void
  95. WINAPI
  96. UnInitializeGDIPlus(void);
  97. #endif // #ifndef UTILS__H_