120 int xDest,
int yDest,
int nDestWidth,
int nDestHeight,
121 int xSrc,
int ySrc,
int nSrcWidth,
int nSrcHeight,
134 m_hDC, xSrc, ySrc, nSrcWidth, nSrcHeight, bf);
149 return AlphaBlend(hDestDC, pointDest.
x, pointDest.
y, bSrcAlpha, bBlendOp);
160 bSrcAlpha, bBlendOp);
164 int nDestWidth,
int nDestHeight,
165 int xSrc,
int ySrc,
DWORD dwROP =
SRCCOPY)
const noexcept
169 m_hDC, xSrc, ySrc, dwROP);
176 return BitBlt(hDestDC, xDest, yDest,
182 return BitBlt(hDestDC, pointDest.x, pointDest.y, dwROP);
187 return BitBlt(hDestDC, rectDest.left, rectDest.top,
188 rectDest.right - rectDest.left,
189 rectDest.bottom - rectDest.top,
190 pointSrc.x, pointSrc.y, dwROP);
212 BOOL Draw(
HDC hDestDC,
int xDest,
int yDest,
int nDestWidth,
int nDestHeight,
213 int xSrc,
int ySrc,
int nSrcWidth,
int nSrcHeight)
const noexcept
218 return AlphaBlend(hDestDC, xDest, yDest, nDestWidth, nDestHeight,
219 xSrc, ySrc, nSrcWidth, nSrcHeight);
228 return TransparentBlt(hDestDC, xDest, yDest, nDestWidth, nDestHeight,
229 xSrc, ySrc, nSrcWidth, nSrcHeight,
rgb);
233 return StretchBlt(hDestDC, xDest, yDest, nDestWidth, nDestHeight,
234 xSrc, ySrc, nSrcWidth, nSrcHeight);
239 return Draw(hDestDC, rectDest.left, rectDest.top,
240 rectDest.right - rectDest.left,
241 rectDest.bottom - rectDest.top,
242 rectSrc.left, rectSrc.top,
243 rectSrc.right - rectSrc.left,
244 rectSrc.bottom - rectSrc.top);
252 return Draw(hDestDC, pointDest.x, pointDest.y);
255 int nDestWidth,
int nDestHeight)
const noexcept
257 return Draw(hDestDC, xDest, yDest, nDestWidth, nDestHeight,
262 return Draw(hDestDC, rectDest.left, rectDest.top,
263 rectDest.right - rectDest.left,
264 rectDest.bottom - rectDest.top);
285 RGBQUAD* prgbColors)
const noexcept
304 case 1:
case 4:
case 8:
307 case 16:
case 24:
case 32:
378 using namespace Gdiplus;
404 using namespace Gdiplus;
438 int nDestWidth,
int nDestHeight,
int xSrc,
int ySrc,
439 HBITMAP hbmMask,
int xMask,
int yMask,
446 hbmMask, xMask, yMask, dwROP);
454 return MaskBlt(hDestDC, rectDest.left, rectDest.top,
455 rectDest.right - rectDest.left, rectDest.bottom - rectDest.top,
456 pointSrc.x, pointSrc.y, hbmMask, pointMask.x, pointMask.y, dwROP);
462 0, 0, hbmMask, 0, 0, dwROP);
467 return MaskBlt(hDestDC, pointDest.x, pointDest.y, hbmMask, dwROP);
471 int xSrc,
int ySrc,
int nSrcWidth,
int nSrcHeight,
473 int xMask = 0,
int yMask = 0)
const noexcept
478 xSrc, ySrc, nSrcWidth, nSrcHeight,
479 hbmMask, xMask, yMask);
492 return PlgBlt(hDestDC, pPoints, rectSrc.left, rectSrc.top,
493 rectSrc.right - rectSrc.left, rectSrc.bottom - rectSrc.top,
494 hbmMask, pointMask.x, pointMask.y);
499 POINT pointMask = {0, 0};
500 return PlgBlt(hDestDC, pPoints, rectSrc, hbmMask, pointMask);
508 using namespace Gdiplus;
539 using namespace Gdiplus;
576 const RGBQUAD* prgbColors)
noexcept
613 int nDestWidth,
int nDestHeight,
614 int xSrc,
int ySrc,
int nSrcWidth,
int nSrcHeight,
619 m_hDC, xSrc, ySrc, nSrcWidth, nSrcHeight, dwROP);
624 int nDestWidth,
int nDestHeight,
627 return StretchBlt(hDestDC, xDest, yDest, nDestWidth, nDestHeight,
633 return StretchBlt(hDestDC, rectDest.left, rectDest.top,
634 rectDest.right - rectDest.left,
635 rectDest.bottom - rectDest.top, dwROP);
640 return StretchBlt(hDestDC, rectDest.left, rectDest.top,
641 rectDest.right - rectDest.left,
642 rectDest.bottom - rectDest.top,
643 rectSrc.left, rectSrc.top,
644 rectSrc.right - rectSrc.left,
645 rectSrc.bottom - rectSrc.top, dwROP);
649 int nDestWidth,
int nDestHeight,
650 int xSrc,
int ySrc,
int nSrcWidth,
int nSrcHeight,
656 nDestWidth, nDestHeight,
658 nSrcWidth, nSrcHeight, crTransparent);
663 int nDestWidth,
int nDestHeight,
666 return TransparentBlt(hDestDC, xDest, yDest, nDestWidth, nDestHeight,
673 rectDest.right - rectDest.left,
674 rectDest.bottom - rectDest.top, crTransparent);
677 HDC hDestDC,
const RECT& rectDest,
681 rectDest.right - rectDest.left, rectDest.bottom - rectDest.left,
682 rectSrc.left, rectSrc.top, rectSrc.right - rectSrc.left,
683 rectSrc.bottom - rectSrc.top, crTransparent);
729 const Gdiplus::ImageCodecInfo* pCodecs,
733 LPCTSTR pszAllFilesDescription,
737 if (!pCodecs || !cCodecs)
739 strFilter += chSeparator;
743 if (pszAllFilesDescription)
745 strFilter += pszAllFilesDescription;
749 for (
UINT i = 0;
i < cCodecs; ++
i)
757 extensions +=
TEXT(
';');
763 strFilter += chSeparator;
764 strFilter += extensions;
765 strFilter += chSeparator;
770 for (
UINT i = 0;
i < cCodecs; ++
i)
775 CString extensions(pCodecs[
i].FilenameExtension);
779 strFilter +=
TEXT(
" (");
780 strFilter += extensions;
781 strFilter +=
TEXT(
")");
782 strFilter += chSeparator;
783 strFilter += extensions;
784 strFilter += chSeparator;
786 aguidFileTypes.
Add(pCodecs[
i].FormatID);
789 strFilter += chSeparator;
810 pszAllFilesDescription,
833 pszAllFilesDescription,
889 template <
typename T_FUN>
953 using namespace Gdiplus;
1044 for (
UINT i = 0;
i < nCodecs; ++
i)
1046 CString strSpecs(pCodecs[
i].FilenameExtension);
1047 int ichOld = 0, ichSep;
1050 ichSep = strSpecs.
Find(
TEXT(
';'), ichOld);
1054 strSpec = strSpecs.
Mid(ichOld);
1056 strSpec = strSpecs.
Mid(ichOld, ichSep - ichOld);
1060 strSpec = strSpec.
Mid(ichDot);
1063 return pCodecs[
i].Clsid;
1068 ichOld = ichSep + 1;
1077 for (
UINT iInfo = 0; iInfo < nCodecs; ++iInfo)
1080 return pCodecs[iInfo].Clsid;
1087 UINT total_size = 0;
1089 if (total_size == 0)
1092 Gdiplus::ImageCodecInfo *
ret;
1093 ret =
new Gdiplus::ImageCodecInfo[total_size /
sizeof(
ret[0])];
1106 UINT total_size = 0;
1108 if (total_size == 0)
1111 Gdiplus::ImageCodecInfo *
ret;
1112 ret =
new Gdiplus::ImageCodecInfo[total_size /
sizeof(
ret[0])];
1192 if (nBPP == 16 || nBPP == 32)
1196 pdwMask[0] = pdwBitmasks[0];
1197 pdwMask[1] = pdwBitmasks[1];
1198 pdwMask[2] = pdwBitmasks[2];
1264#ifndef _ATL_NO_AUTOMATIC_NAMESPACE
#define InterlockedIncrement
#define InterlockedDecrement
virtual ~CImageDC() noexcept
CImageDC(const CImageDC &)=delete
CImageDC & operator=(const CImageDC &)=delete
CImageDC(const CImage &image)
decltype(&Gdiplus::GdiplusStartup) FUN_Startup
decltype(&Gdiplus::DllExports::GdipGetImageDecodersSize) FUN_GetImageDecoderSize
decltype(&Gdiplus::GdiplusShutdown) FUN_Shutdown
FUN_SaveImageToStream SaveImageToStream
decltype(&Gdiplus::DllExports::GdipSaveImageToStream) FUN_SaveImageToStream
decltype(&Gdiplus::DllExports::GdipGetImageEncoders) FUN_GetImageEncoder
decltype(&Gdiplus::DllExports::GdipCreateBitmapFromStream) FUN_CreateBitmapFromStream
decltype(&Gdiplus::DllExports::GdipCreateBitmapFromFile) FUN_CreateBitmapFromFile
FUN_DisposeImage DisposeImage
void ReleaseGDIPlus() noexcept
FUN_CreateBitmapFromFile CreateBitmapFromFile
void DecreaseCImageCount() noexcept
void _clear_funs() noexcept
FUN_CreateHBITMAPFromBitmap CreateHBITMAPFromBitmap
decltype(&Gdiplus::DllExports::GdipDisposeImage) FUN_DisposeImage
FUN_CreateBitmapFromHBITMAP CreateBitmapFromHBITMAP
FUN_GetImageDecoder GetImageDecoders
FUN_CreateBitmapFromStream CreateBitmapFromStream
FUN_GetImageDecoderSize GetImageDecodersSize
T_FUN _get_fun(T_FUN &fun, LPCSTR name) noexcept
void IncreaseCImageCount() noexcept
FUN_GetImageEncoderSize GetImageEncodersSize
decltype(&Gdiplus::DllExports::GdipSaveImageToFile) FUN_SaveImageToFile
decltype(&Gdiplus::DllExports::GdipCreateBitmapFromHBITMAP) FUN_CreateBitmapFromHBITMAP
decltype(&Gdiplus::DllExports::GdipGetImageDecoders) FUN_GetImageDecoder
FUN_SaveImageToFile SaveImageToFile
FUN_GetImageEncoder GetImageEncoders
decltype(&Gdiplus::DllExports::GdipCreateHBITMAPFromBitmap) FUN_CreateHBITMAPFromBitmap
decltype(&Gdiplus::DllExports::GdipGetImageEncodersSize) FUN_GetImageEncoderSize
BOOL Create(int nWidth, int nHeight, int nBPP, DWORD dwFlags=0) noexcept
static CLSID FindCodecForExtension(LPCTSTR dotext, const Gdiplus::ImageCodecInfo *pCodecs, UINT nCodecs)
BOOL MaskBlt(HDC hDestDC, int xDest, int yDest, int nDestWidth, int nDestHeight, int xSrc, int ySrc, HBITMAP hbmMask, int xMask, int yMask, DWORD dwROP=SRCCOPY) const noexcept
BOOL TransparentBlt(HDC hDestDC, const RECT &rectDest, UINT crTransparent=CLR_INVALID) const noexcept
BOOL Draw(HDC hDestDC, int xDest, int yDest, int nDestWidth, int nDestHeight) const noexcept
BOOL MaskBlt(HDC hDestDC, int xDest, int yDest, HBITMAP hbmMask, DWORD dwROP=SRCCOPY) const noexcept
BOOL MaskBlt(HDC hDestDC, const POINT &pointDest, HBITMAP hbmMask, DWORD dwROP=SRCCOPY) const noexcept
HDC GetDC() const noexcept
BOOL CreateInternal(int nWidth, int nHeight, int nBPP, DWORD eCompression, const DWORD *pdwBitmasks=NULL, DWORD dwFlags=0) noexcept
BOOL TransparentBlt(HDC hDestDC, int xDest, int yDest, int nDestWidth, int nDestHeight, int xSrc, int ySrc, int nSrcWidth, int nSrcHeight, UINT crTransparent=CLR_INVALID) const noexcept
BOOL AlphaBlend(HDC hDestDC, int xDest, int yDest, int nDestWidth, int nDestHeight, int xSrc, int ySrc, int nSrcWidth, int nSrcHeight, BYTE bSrcAlpha=0xFF, BYTE bBlendOp=AC_SRC_OVER) const
BOOL PlgBlt(HDC hDestDC, const POINT *pPoints, HBITMAP hbmMask=NULL) const noexcept
BOOL Draw(HDC hDestDC, int xDest, int yDest, int nDestWidth, int nDestHeight, int xSrc, int ySrc, int nSrcWidth, int nSrcHeight) const noexcept
void SetPixelIndexed(int x, int y, int iIndex) noexcept
bool IsDIBSection() const noexcept
BOOL Draw(HDC hDestDC, const RECT &rectDest) const noexcept
BOOL AlphaBlend(HDC hDestDC, const POINT &pointDest, BYTE bSrcAlpha=0xFF, BYTE bBlendOp=AC_SRC_OVER) const
BOOL Draw(HDC hDestDC, int xDest, int yDest) const noexcept
COLORREF GetPixel(int x, int y) const noexcept
COLORREF GetTransparentColor() const noexcept
BOOL StretchBlt(HDC hDestDC, int xDest, int yDest, int nDestWidth, int nDestHeight, int xSrc, int ySrc, int nSrcWidth, int nSrcHeight, DWORD dwROP=SRCCOPY) const noexcept
void SetPixel(int x, int y, COLORREF color) noexcept
static HRESULT BuildCodecFilterString(const Gdiplus::ImageCodecInfo *pCodecs, UINT cCodecs, CSimpleString &strFilter, CSimpleArray< GUID > &aguidFileTypes, LPCTSTR pszAllFilesDescription, DWORD dwExclude, TCHAR chSeparator)
BOOL StretchBlt(HDC hDestDC, const RECT &rectDest, DWORD dwROP=SRCCOPY) const noexcept
HRESULT Save(IStream *pStream, GUID *guidFileType) const noexcept
static HRESULT GetImporterFilterString(CSimpleString &strImporters, CSimpleArray< GUID > &aguidFileTypes, LPCTSTR pszAllFilesDescription=NULL, DWORD dwExclude=excludeDefaultLoad, TCHAR chSeparator=TEXT('|'))
COLORREF m_clrTransparentColor
static Gdiplus::ImageCodecInfo * _getAllEncoders(UINT &cEncoders)
BOOL StretchBlt(HDC hDestDC, int xDest, int yDest, int nDestWidth, int nDestHeight, DWORD dwROP=SRCCOPY) const noexcept
static BOOL IsTransparencySupported() noexcept
HRESULT Load(IStream *pStream) noexcept
static CLSID FindCodecForFileType(REFGUID guidFileType, const Gdiplus::ImageCodecInfo *pCodecs, UINT nCodecs)
void * GetBits() noexcept
void AttachInternal(HBITMAP hBitmap, DIBOrientation eOrientation, LONG iTransColor) noexcept
void ReleaseDC() const noexcept
BOOL PlgBlt(HDC hDestDC, const POINT *pPoints, const RECT &rectSrc, HBITMAP hbmMask=NULL) const noexcept
COLORREF SetTransparentColor(COLORREF rgbTransparent) noexcept
HBITMAP Detach() noexcept
int GetHeight() const noexcept
bool IsIndexed() const noexcept
CImage & operator=(const CImage &)=delete
const void * GetPixelAddress(int x, int y) const noexcept
BOOL CreateEx(int nWidth, int nHeight, int nBPP, DWORD eCompression, const DWORD *pdwBitmasks=NULL, DWORD dwFlags=0) noexcept
virtual ~CImage() noexcept
void LoadFromResource(HINSTANCE hInstance, LPCTSTR pszResourceName) noexcept
int GetWidth() const noexcept
int GetMaxColorTableEntries() const noexcept
BOOL PlgBlt(HDC hDestDC, const POINT *pPoints, int xSrc, int ySrc, int nSrcWidth, int nSrcHeight, HBITMAP hbmMask=NULL, int xMask=0, int yMask=0) const noexcept
void LoadFromResource(HINSTANCE hInstance, UINT nIDResource) noexcept
static bool InitGDIPlus() noexcept
void GetColorTable(UINT iFirstColor, UINT nColors, RGBQUAD *prgbColors) const noexcept
static void ReleaseGDIPlus()
void SetPixelRGB(int x, int y, BYTE r, BYTE g, BYTE b) noexcept
BOOL TransparentBlt(HDC hDestDC, int xDest, int yDest, int nDestWidth, int nDestHeight, UINT crTransparent=CLR_INVALID) const noexcept
BOOL StretchBlt(HDC hDestDC, const RECT &rectDest, const RECT &rectSrc, DWORD dwROP=SRCCOPY) const noexcept
void SetColorTable(UINT iFirstColor, UINT nColors, const RGBQUAD *prgbColors) noexcept
BOOL PlgBlt(HDC hDestDC, const POINT *pPoints, const RECT &rectSrc, HBITMAP hbmMask, const POINT &pointMask) const noexcept
BOOL BitBlt(HDC hDestDC, const POINT &pointDest, DWORD dwROP=SRCCOPY) const noexcept
BOOL BitBlt(HDC hDestDC, int xDest, int yDest, DWORD dwROP=SRCCOPY) const noexcept
BOOL TransparentBlt(HDC hDestDC, const RECT &rectDest, const RECT &rectSrc, UINT crTransparent=CLR_INVALID) const noexcept
int GetBPP() const noexcept
LPCWSTR GetFileExtension(LPCWSTR pszFileName) const
BOOL Draw(HDC hDestDC, const POINT &pointDest) const noexcept
static HRESULT GetExporterFilterString(CSimpleString &strExporters, CSimpleArray< GUID > &aguidFileTypes, LPCTSTR pszAllFilesDescription=NULL, DWORD dwExclude=excludeDefaultSave, TCHAR chSeparator=TEXT('|'))
BOOL BitBlt(HDC hDestDC, int xDest, int yDest, int nDestWidth, int nDestHeight, int xSrc, int ySrc, DWORD dwROP=SRCCOPY) const noexcept
const void * GetBits() const noexcept
BOOL AlphaBlend(HDC hDestDC, const RECT &rectDest, const RECT &rectSrc, BYTE bSrcAlpha=0xFF, BYTE bBlendOp=AC_SRC_OVER) const
void Attach(HBITMAP hBitmap, DIBOrientation eOrientation=DIBOR_DEFAULT) noexcept
HRESULT Save(LPCTSTR pszFileName, REFGUID guidFileType=GUID_NULL) const noexcept
BOOL MaskBlt(HDC hDestDC, const RECT &rectDest, const POINT &pointSrc, HBITMAP hbmMask, const POINT &pointMask, DWORD dwROP=SRCCOPY) const noexcept
COLORREF RGBFromPaletteIndex(int iIndex) const
bool IsNull() const noexcept
void * GetPixelAddress(int x, int y) noexcept
BOOL BitBlt(HDC hDestDC, const RECT &rectDest, const POINT &pointSrc, DWORD dwROP=SRCCOPY) const noexcept
CImage(const CImage &)=delete
static CInitGDIPlus s_gdiplus
BOOL Draw(HDC hDestDC, const RECT &rectDest, const RECT &rectSrc) const noexcept
static bool ShouldExcludeFormat(REFGUID guidFileType, DWORD dwExclude)
int GetPitch() const noexcept
static Gdiplus::ImageCodecInfo * _getAllDecoders(UINT &cDecoders)
BOOL AlphaBlend(HDC hDestDC, int xDest, int yDest, BYTE bSrcAlpha=0xFF, BYTE bBlendOp=AC_SRC_OVER) const
HRESULT Load(LPCTSTR pszFileName) noexcept
int CompareNoCase(_In_z_ PCXSTR psz) const
int Find(_In_ PCXSTR pszSub, _In_opt_ int iStart=0) const noexcept
CStringT Mid(int iFirst, int nCount) const
int ReverseFind(_In_ XCHAR ch) const noexcept
#define GetProcAddress(x, y)
static const WCHAR *const ext[]
GLint GLint GLint GLint GLint x
GLint GLint GLint GLint GLint GLint y
GLint GLint GLsizei GLsizei height
GLdouble GLdouble GLdouble r
GLint GLint GLsizei width
GLboolean GLboolean GLboolean b
GLenum GLenum GLenum input
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
static const WCHAR desc[]
#define IsEqualGUID(rguid1, rguid2)
#define DECLSPEC_SELECTANY
static void quad(GLcontext *ctx, GLuint v0, GLuint v1, GLuint v2, GLuint v3, GLuint pv)
RGBQUAD bmiColorsExtra[256 - 1]
BITMAPINFOHEADER bmiHeader
VOID WINAPI InitializeCriticalSection(OUT LPCRITICAL_SECTION lpCriticalSection)
WORD WORD PSZ PSZ pszFileName
HBITMAP WINAPI CreateDIBSection(HDC hDC, CONST BITMAPINFO *BitmapInfo, UINT Usage, VOID **Bits, HANDLE hSection, DWORD dwOffset)
UINT WINAPI GetDIBColorTable(HDC hDC, UINT iStartIndex, UINT cEntries, RGBQUAD *pColors)
void WINAPI LeaveCriticalSection(LPCRITICAL_SECTION)
void WINAPI EnterCriticalSection(LPCRITICAL_SECTION)
void WINAPI DeleteCriticalSection(PCRITICAL_SECTION)
_In_ PCCERT_CONTEXT _In_ DWORD dwFlags
_In_ SURFOBJ _In_ CLIPOBJ _In_opt_ XLATEOBJ _In_ RECTL _In_ RECTL _In_ ULONG iTransColor
_In_ ULONG _In_ ULONG rgb
int WINAPI GetObjectW(_In_ HANDLE h, _In_ int c, _Out_writes_bytes_opt_(c) LPVOID pv)
HGDIOBJ WINAPI SelectObject(_In_ HDC, _In_ HGDIOBJ)
HDC WINAPI CreateCompatibleDC(_In_opt_ HDC hdc)
UINT WINAPI SetDIBColorTable(_In_ HDC hdc, _In_ UINT iStart, _In_ UINT cEntries, _In_reads_(cEntries) const RGBQUAD *prgbq)
BOOL WINAPI SetPixelV(_In_ HDC, _In_ int, _In_ int, _In_ COLORREF)
BOOL WINAPI DeleteDC(_In_ HDC)
#define LR_CREATEDIBSECTION
HDC WINAPI GetDC(_In_opt_ HWND)