35 #include "wine/port.h" 169 X(EMR_FORCEUFIMAPPING),
171 X(EMR_COLORCORRECTPALETTE),
172 X(EMR_SETICMPROFILEA),
173 X(EMR_SETICMPROFILEW),
176 X(EMR_TRANSPARENTBLT),
180 X(EMR_SETTEXTJUSTIFICATION),
181 X(EMR_COLORMATCHTOTARGETW),
182 X(EMR_CREATECOLORSPACEW)
212 if (
info->bmiHeader.biBitCount != 1)
return FALSE;
219 if ((
rgb->rgbtRed == 0) && (
rgb->rgbtGreen == 0) && (
rgb->rgbtBlue == 0))
223 return ((
rgb->rgbtRed == 0xff) && (
rgb->rgbtGreen == 0xff)
224 && (
rgb->rgbtBlue == 0xff));
233 if ((
rgb->rgbRed == 0) && (
rgb->rgbGreen == 0) &&
234 (
rgb->rgbBlue == 0) && (
rgb->rgbReserved == 0))
239 return ((
rgb->rgbRed == 0xff) && (
rgb->rgbGreen == 0xff)
240 && (
rgb->rgbBlue == 0xff) && (
rgb->rgbReserved == 0));
262 WARN(
"Invalid emf header type 0x%08x sig 0x%08x.\n",
284 if(!metaObj)
return FALSE;
302 TRACE(
"hmf %p -> enhmetaObj %p\n", hmf, metaObj);
349 WARN(
"could not open %s\n", lpszMetaFile);
398 if(!emh)
return FALSE;
422 if(!emh)
return FALSE;
452 if(!emh)
return FALSE;
522 #define ENUM_GET_PRIVATE_DATA(ht) \ 523 ((enum_emh_data*)(((unsigned char*)(ht))-sizeof (enum_emh_data))) 525 #define WIDTH(rect) ( (rect).right - (rect).left ) 526 #define HEIGHT(rect) ( (rect).bottom - (rect).top ) 528 #define IS_WIN9X() (GetVersion()&0x80000000) 532 XFORM mapping_mode_trans, final_trans;
533 double scaleX, scaleY;
535 scaleX = (
double)
info->state.vportExtX / (
double)
info->state.wndExtX;
536 scaleY = (
double)
info->state.vportExtY / (
double)
info->state.wndExtY;
537 mapping_mode_trans.
eM11 = scaleX;
538 mapping_mode_trans.
eM12 = 0.0;
539 mapping_mode_trans.
eM21 = 0.0;
540 mapping_mode_trans.
eM22 = scaleY;
541 mapping_mode_trans.
eDx = (
double)
info->state.vportOrgX - scaleX * (
double)
info->state.wndOrgX;
542 mapping_mode_trans.
eDy = (
double)
info->state.vportOrgY - scaleY * (
double)
info->state.wndOrgY;
549 ERR(
"World transform failed!\n");
579 TRACE(
"save_level %d\n",
info->save_level);
592 switch(
info->state.mode)
595 info->state.wndExtX = 1;
596 info->state.wndExtY = 1;
597 info->state.vportExtX = 1;
598 info->state.vportExtY = 1;
602 info->state.wndExtX = horzSize * 10;
603 info->state.wndExtY = vertSize * 10;
604 info->state.vportExtX = horzRes;
605 info->state.vportExtY = -vertRes;
608 info->state.wndExtX = horzSize * 100;
609 info->state.wndExtY = vertSize * 100;
610 info->state.vportExtX = horzRes;
611 info->state.vportExtY = -vertRes;
614 info->state.wndExtX =
MulDiv(1000, horzSize, 254);
615 info->state.wndExtY =
MulDiv(1000, vertSize, 254);
616 info->state.vportExtX = horzRes;
617 info->state.vportExtY = -vertRes;
620 info->state.wndExtX =
MulDiv(10000, horzSize, 254);
621 info->state.wndExtY =
MulDiv(10000, vertSize, 254);
622 info->state.vportExtX = horzRes;
623 info->state.vportExtY = -vertRes;
626 info->state.wndExtX =
MulDiv(14400, horzSize, 254);
627 info->state.wndExtY =
MulDiv(14400, vertSize, 254);
628 info->state.vportExtX = horzRes;
629 info->state.vportExtY = -vertRes;
653 INT mincx = (
info->state.vportExtX >= 0) ? 1 : -1;
654 info->state.vportExtX =
floor(
info->state.vportExtX * ydim / xdim + 0.5);
655 if (!
info->state.vportExtX)
info->state.vportExtX = mincx;
659 INT mincy = (
info->state.vportExtY >= 0) ? 1 : -1;
660 info->state.vportExtY =
floor(
info->state.vportExtY * xdim / ydim + 0.5);
661 if (!
info->state.vportExtY)
info->state.vportExtY = mincy;
723 case EMR_SMALLTEXTOUT:
725 case EMR_TRANSPARENTBLT:
759 TRACE(
"hdc = %p, handletable = %p, record = %p, numHandles = %d\n",
761 if (!mr)
return FALSE;
783 if (
info->state.mode == pSetMapMode->
iMode &&
853 TRACE(
"EMR_INTERSECTCLIPRECT: rect %d,%d - %d, %d\n",
863 if( pSelectObject->
ihObject & 0x80000000 ) {
892 TRACE(
"SetWindowOrgEx: %d,%d\n",
info->state.wndOrgX,
info->state.wndOrgY);
910 TRACE(
"SetWindowExtEx: %d,%d\n",
info->state.wndExtX,
info->state.wndExtY);
923 TRACE(
"SetViewportOrgEx: %d,%d\n",
info->state.vportOrgX,
info->state.vportOrgY);
940 TRACE(
"SetViewportExtEx: %d,%d\n",
info->state.vportExtX,
info->state.vportExtY);
963 FIXME(
"EMR_EXTCREATEPEN: Need to copy brush bitmap\n");
1020 for(
i = 0;
i < pPoly->
cpts;
i++)
1036 for(
i = 0;
i < pPoly->
cpts;
i++)
1052 for(
i = 0;
i < pPoly->
cpts;
i++)
1068 for(
i = 0;
i < pPoly->
cpts;
i++)
1084 for(
i = 0;
i < pPoly->
cpts;
i++)
1102 for(
i = 0;
i < pPolyPoly->
cpts;
i++)
1120 for(
i = 0;
i < pPolyPoly->
cpts;
i++)
1135 pStretchDIBits->
xDest,
1136 pStretchDIBits->
yDest,
1139 pStretchDIBits->
xSrc,
1140 pStretchDIBits->
ySrc,
1141 pStretchDIBits->
cxSrc,
1142 pStretchDIBits->
cySrc,
1146 pStretchDIBits->
dwRop);
1161 TRACE(
"EMR_EXTTEXTOUTA: x,y = %d, %d. rect = %s. flags %08x\n",
1197 TRACE(
"EMR_EXTTEXTOUTW: x,y = %d, %d. rect = %s. flags %08x\n",
1236 if( lpSelectPal->
ihPal & 0x80000000 ) {
1280 info->state.world_transform = lpXfrm->
xform;
1399 FIXME(
"OffsetClipRgn\n");
1413 FIXME(
"ExcludeClipRect\n");
1424 if (!lpScaleViewportExtEx->
xNum || !lpScaleViewportExtEx->
xDenom ||
1425 !lpScaleViewportExtEx->
yNum || !lpScaleViewportExtEx->
yDenom)
1428 lpScaleViewportExtEx->
xDenom);
1430 lpScaleViewportExtEx->
yDenom);
1431 if (
info->state.vportExtX == 0)
info->state.vportExtX = 1;
1432 if (
info->state.vportExtY == 0)
info->state.vportExtY = 1;
1436 TRACE(
"EMRSCALEVIEWPORTEXTEX %d/%d %d/%d\n",
1437 lpScaleViewportExtEx->
xNum,lpScaleViewportExtEx->
xDenom,
1438 lpScaleViewportExtEx->
yNum,lpScaleViewportExtEx->
yDenom);
1452 if (!lpScaleWindowExtEx->
xNum || !lpScaleWindowExtEx->
xDenom ||
1453 !lpScaleWindowExtEx->
yNum || !lpScaleWindowExtEx->
yDenom)
1456 lpScaleWindowExtEx->
xDenom);
1458 lpScaleWindowExtEx->
yDenom);
1459 if (
info->state.wndExtX == 0)
info->state.wndExtX = 1;
1460 if (
info->state.wndExtY == 0)
info->state.wndExtY = 1;
1464 TRACE(
"EMRSCALEWINDOWEXTEX %d/%d %d/%d\n",
1465 lpScaleWindowExtEx->
xNum,lpScaleWindowExtEx->
xDenom,
1466 lpScaleWindowExtEx->
yNum,lpScaleWindowExtEx->
yDenom);
1478 switch(lpModifyWorldTrans->
iMode) {
1480 info->state.world_transform.eM11 =
info->state.world_transform.eM22 = 1;
1481 info->state.world_transform.eM12 =
info->state.world_transform.eM21 = 0;
1482 info->state.world_transform.eDx =
info->state.world_transform.eDy = 0;
1488 &
info->state.world_transform);
1494 &lpModifyWorldTrans->
xform);
1499 FIXME(
"Unknown imode %d\n", lpModifyWorldTrans->
iMode);
1778 ERR(
"Invalid EMR_CREATEDIBPATTERNBRUSHPT record\n");
1793 ((
const BYTE *)lpCreate) + lpCreate->offBmi,
1795 memcpy( ((
BYTE*)lpPackedStruct) + lpCreate->cbBmi,
1796 ((
const BYTE *)lpCreate) + lpCreate->offBits,
1801 (
UINT)lpCreate->iUsage );
1823 bm.bmWidth =
pbi->bmiHeader.biWidth;
1824 bm.bmHeight =
abs(
pbi->bmiHeader.biHeight);
1825 bm.bmWidthBytes = 4 * ((
pbi->bmiHeader.biWidth + 31) / 32);
1826 bm.bmPlanes =
pbi->bmiHeader.biPlanes;
1827 bm.bmBitsPixel =
pbi->bmiHeader.biBitCount;
1828 bm.bmBits = (
BYTE *)mr + pCreateMonoBrush->
offBits;
1862 HBRUSH hBrush, hBrushOld;
1863 HBITMAP hBmp = 0, hBmpOld = 0;
1895 TRACE(
"EMR_STRETCHBLT: %d, %d %dx%d -> %d, %d %dx%d. rop %08x offBitsSrc %d\n",
1902 pStretchBlt->
dwRop);
1905 HBRUSH hBrush, hBrushOld;
1906 HBITMAP hBmp = 0, hBmpOld = 0;
1926 pStretchBlt->
dwRop);
1935 case EMR_ALPHABLEND:
1939 TRACE(
"EMR_ALPHABLEND: %d, %d %dx%d -> %d, %d %dx%d. blendfn %08x offBitsSrc %d\n",
1945 FIXME(
"EMR_ALPHABLEND: offBmiSrc == 0\n");
1948 HBITMAP hBmp = 0, hBmpOld = 0;
1974 HBRUSH hBrush, hBrushOld;
1975 HBITMAP hBmp, hBmpOld, hBmpMask;
2022 HBRUSH hBrush, hBrushOld;
2023 HBITMAP hBmp, hBmpOld, hBmpMask;
2074 pSetDIBitsToDevice->
xDest,
2075 pSetDIBitsToDevice->
yDest,
2076 pSetDIBitsToDevice->
cxSrc,
2077 pSetDIBitsToDevice->
cySrc,
2078 pSetDIBitsToDevice->
xSrc,
2079 pSetDIBitsToDevice->
ySrc,
2081 pSetDIBitsToDevice->
cScans,
2093 XFORM xform, xformOld;
2134 XFORM xform, xformOld;
2212 case EMR_SETTEXTJUSTIFICATION:
2221 const EMRSETLAYOUT *pSetLayout = (
const EMRSETLAYOUT *)mr;
2226 case EMR_GRADIENTFILL:
2237 case EMR_DRAWESCAPE:
2240 case EMR_SMALLTEXTOUT:
2241 case EMR_FORCEUFIMAPPING:
2242 case EMR_NAMEDESCAPE:
2243 case EMR_COLORCORRECTPALETTE:
2244 case EMR_SETICMPROFILEA:
2245 case EMR_SETICMPROFILEW:
2246 case EMR_TRANSPARENTBLT:
2248 case EMR_COLORMATCHTOTARGETW:
2249 case EMR_CREATECOLORSPACEW:
2254 FIXME(
"type %d is unimplemented\n",
type);
2317 HBRUSH hBrush =
NULL;
2321 SIZE vp_size, win_size;
2322 POINT vp_org, win_org;
2323 INT mapMode =
MM_TEXT, old_align = 0, old_rop2 = 0, old_arcdir = 0, old_polyfill = 0, old_stretchblt = 0;
2324 COLORREF old_text_color = 0, old_bk_color = 0;
2346 info->state.wndOrgX = 0;
2347 info->state.wndOrgY = 0;
2348 info->state.wndExtX = 1;
2349 info->state.wndExtY = 1;
2350 info->state.vportOrgX = 0;
2351 info->state.vportOrgY = 0;
2352 info->state.vportExtX = 1;
2353 info->state.vportExtY = 1;
2354 info->state.world_transform.eM11 =
info->state.world_transform.eM22 = 1;
2355 info->state.world_transform.eM12 =
info->state.world_transform.eM21 = 0;
2356 info->state.world_transform.eDx =
info->state.world_transform.eDy = 0;
2359 info->save_level = 0;
2363 ht->objectHandle[0] = hmf;
2400 info->init_transform.eM11 = 1.0;
2401 info->init_transform.eM12 = 0.0;
2402 info->init_transform.eM21 = 0.0;
2403 info->init_transform.eM22 = 1.0;
2404 info->init_transform.eDx = 0.0;
2405 info->init_transform.eDy = 0.0;
2410 double xscale, yscale;
2411 xscale = (
double)vp_size.
cx / (
double)win_size.
cx;
2412 yscale = (
double)vp_size.
cy / (
double)win_size.
cy;
2413 info->init_transform.eM11 = xscale;
2414 info->init_transform.eM12 = 0.0;
2415 info->init_transform.eM21 = 0.0;
2416 info->init_transform.eM22 = yscale;
2417 info->init_transform.eDx = (
double)vp_org.
x - xscale * (
double)win_org.
x;
2418 info->init_transform.eDy = (
double)vp_org.
y - yscale * (
double)win_org.
y;
2425 double xSrcPixSize, ySrcPixSize, xscale, yscale;
2438 TRACE(
"xscale = %f, yscale = %f\n", xscale, yscale);
2440 xform.
eM11 = xscale;
2443 xform.
eM22 = yscale;
2503 if( (
ht->objectHandle)[
i] )
2506 while (
info->saved_state)
2509 info->saved_state =
info->saved_state->next;
2561 HENHMETAFILE hmfSrc,
2565 HENHMETAFILE hmfDst;
2567 if(!emrSrc)
return FALSE;
2586 ERR(
"Can't reopen emf for reading\n");
2603 HENHMETAFILE hmfSrc,
2607 HENHMETAFILE hmfDst;
2609 if(!emrSrc)
return FALSE;
2628 ERR(
"Can't reopen emf for reading\n");
2667 TRACE(
"copying 0x%08x palettes\n", dwNumPalToCopy );
2670 sizeof( *(
info->lpPe) ) * dwNumPalToCopy );
2674 info->cEntries = dwNumPalToCopy;
2698 if (!enhHeader)
return 0;
2709 infoForCallBack.
lpPe = lpPe;
2712 &infoForCallBack, 0 ) )
2716 if ( infoForCallBack.
lpPe !=
NULL )
2719 ERR(
"cbEnhPaletteCopy didn't execute correctly\n" );
2741 HENHMETAFILE emf =
NULL;
2743 if (mf_size <
sizeof(*mh))
return NULL;
2756 chunks =
chunk->num_chunks;
2758 if (!emf_bits)
goto done;
2760 if (
chunk->chunk_size > remaining)
goto done;
2761 remaining -=
chunk->chunk_size;
2762 if (
chunk->remaining_size != remaining)
goto done;
2765 if (--chunks == 0)
break;
2798 static const WCHAR szDisplayW[] = {
'D',
'I',
'S',
'P',
'L',
'A',
'Y',
'\0' };
2799 HMETAFILE hmf =
NULL;
2803 LONG mm, xExt, yExt;
2804 INT horzsize, vertsize, horzres, vertres;
2806 TRACE(
"(%d, %p, %p, %p)\n", cbBuffer, lpbBuffer, hdcRef, lpmfp);
2811 WARN(
"SetMetaFileBitsEx failed\n");
2831 TRACE(
"lpmfp == NULL\n");
2841 if (xExt < 0 || yExt < 0)
2860 ERR(
"CreateEnhMetaFile failed\n");
2871 UINT mfcomment_size;
2873 mfcomment_size =
sizeof (*mfcomment) + cbBuffer;
2883 memcpy(&mfcomment[1], lpbBuffer, cbBuffer);
2904 xExt =
MulDiv(xExt, horzres, 100 * horzsize);
2905 yExt =
MulDiv(yExt, vertres, 100 * vertsize);
DWORD WINAPI SetMapperFlags(_In_ HDC, _In_ DWORD)
HGDIOBJ WINAPI GetStockObject(_In_ int)
DWORD WINAPI SetLayout(_In_ HDC hdc, _In_ DWORD dwLayout)
#define ERROR_INVALID_PARAMETER
#define EMR_SETPOLYFILLMODE
BOOL WINAPI ExtTextOutW(_In_ HDC hdc, _In_ int x, _In_ int y, _In_ UINT options, _In_opt_ const RECT *lprect, _In_reads_opt_(c) LPCWSTR lpString, _In_ UINT c, _In_reads_opt_(c) const INT *lpDx)
BOOL WINAPI PolyDraw(_In_ HDC hdc, _In_reads_(cpt) const POINT *apt, _In_reads_(cpt) const BYTE *aj, _In_ int cpt)
HMETAFILE WINAPI SetMetaFileBitsEx(_In_ UINT cbBuffer, _In_reads_bytes_(cbBuffer) CONST BYTE *lpData)
BOOL WINAPI WriteFile(IN HANDLE hFile, IN LPCVOID lpBuffer, IN DWORD nNumberOfBytesToWrite OPTIONAL, OUT LPDWORD lpNumberOfBytesWritten, IN LPOVERLAPPED lpOverlapped OPTIONAL)
struct _RGNDATAHEADER RGNDATAHEADER
int WINAPI StretchDIBits(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_ int, _In_ int, _In_ int, _In_ int, _In_opt_ const VOID *, _In_ const BITMAPINFO *, _In_ UINT, _In_ DWORD)
#define EMR_SETARCDIRECTION
#define memmove(s1, s2, n)
BOOL WINAPI SetViewportOrgEx(_In_ HDC, _In_ int, _In_ int, _Out_opt_ LPPOINT)
#define EMR_SETMITERLIMIT
#define EMR_POLYBEZIERTO16
BOOL WINAPI GdiAlphaBlend(HDC hdcDst, int xDst, int yDst, int widthDst, int heightDst, HDC hdcSrc, int xSrc, int ySrc, int widthSrc, int heightSrc, BLENDFUNCTION blendFunction)
BOOL WINAPI SetWindowExtEx(_In_ HDC, _In_ int, _In_ int, _Out_opt_ LPSIZE)
int WINAPI FillRgn(_In_ HDC, _In_ HRGN, _In_ HBRUSH)
GLubyte GLubyte GLubyte GLubyte w
HBITMAP WINAPI CreateBitmapIndirect(_In_ const BITMAP *pbm)
HCOLORSPACE WINAPI SetColorSpace(_In_ HDC, _In_ HCOLORSPACE)
static struct object_header ** handles
#define WideCharToMultiByte
BOOL WINAPI PaintRgn(_In_ HDC, _In_ HRGN)
BOOL Polygon(CONST PPOINT UnsafePoints, int Count, int polyFillMode)
HGDIOBJ alloc_gdi_handle(void *obj, WORD type, const struct gdi_obj_funcs *funcs) DECLSPEC_HIDDEN
BOOL WINAPI LPtoDP(_In_ HDC hdc, _Inout_updates_(c) LPPOINT lppt, _In_ int c)
BOOL WINAPI Rectangle(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int)
BOOL WINAPI GetWindowOrgEx(_In_ HDC, _Out_ LPPOINT)
#define EMR_STROKEANDFILLPATH
#define EMR_EXCLUDECLIPRECT
#define EMR_STRETCHDIBITS
BOOL WINAPI EndPath(_In_ HDC)
#define ERROR_INVALID_HANDLE
#define EMR_CREATECOLORSPACE
BOOL WINAPI SetMiterLimit(_In_ HDC, _In_ FLOAT, _Out_opt_ PFLOAT)
BOOL WINAPI SelectClipPath(_In_ HDC, _In_ int)
#define EMR_DELETECOLORSPACE
int WINAPI IntersectClipRect(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int)
HGDIOBJ WINAPI SelectObject(_In_ HDC, _In_ HGDIOBJ)
#define ERROR_NOT_ENOUGH_MEMORY
#define INVALID_HANDLE_VALUE
BOOL WINAPI DeleteObject(_In_ HGDIOBJ)
BOOL WINAPI Chord(_In_ HDC hdc, _In_ INT xLeft, _In_ INT yTop, _In_ INT xRight, _In_ INT yBottom, _In_ INT xRadial1, _In_ INT yRadial1, _In_ INT xRadial2, _In_ INT yRadial2)
BOOL WINAPI LineTo(_In_ HDC, _In_ int, _In_ int)
#define EMR_SETPALETTEENTRIES
HDC WINAPI CreateCompatibleDC(_In_opt_ HDC hdc)
#define EMR_CREATEPALETTE
PALETTEENTRY aPalEntries[1]
HDC WINAPI CreateEnhMetaFileW(_In_opt_ HDC, _In_opt_ LPCWSTR, _In_opt_ LPCRECT, _In_opt_ LPCWSTR)
#define EMR_SETBRUSHORGEX
UINT WINAPI SetTextAlign(_In_ HDC, _In_ UINT)
BOOL WINAPI PolylineTo(_In_ HDC hdc, _In_reads_(cpt) const POINT *apt, _In_ DWORD cpt)
GLenum GLuint GLsizei bufsize
#define EMR_EXTCREATEFONTINDIRECTW
BOOL WINAPI PolyTextOutW(_In_ HDC hdc, _In_reads_(nstrings) const POLYTEXTW *ppt, _In_ int nstrings)
#define EMR_SELECTPALETTE
BOOL WINAPI DeleteColorSpace(_In_ HCOLORSPACE)
GLenum GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * bits
BOOL WINAPI PolyTextOutA(_In_ HDC hdc, _In_reads_(nstrings) const POLYTEXTA *ppt, _In_ int nstrings)
BOOL WINAPI StretchBlt(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_opt_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_ DWORD)
#define EMR_SETCOLORSPACE
BOOL WINAPI SetPixelFormat(_In_ HDC, _In_ int, _In_ const PIXELFORMATDESCRIPTOR *)
BOOL WINAPI SetWorldTransform(_In_ HDC, _In_ const XFORM *)
#define AD_COUNTERCLOCKWISE
#define EMR_SETVIEWPORTORGEX
int(CALLBACK * ENHMFENUMPROC)(_In_ HDC hdc, _In_reads_(nHandles) HANDLETABLE FAR *lpht, _In_ CONST ENHMETARECORD *lpmr, _In_ int nHandles, _In_opt_ LPARAM data)
#define EMR_REALIZEPALETTE
COLORREF WINAPI SetBkColor(_In_ HDC, _In_ COLORREF)
void GDI_ReleaseObj(HGDIOBJ) DECLSPEC_HIDDEN
#define EMR_SETSTRETCHBLTMODE
BOOL WINAPI PatBlt(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_ DWORD)
GLenum GLuint GLenum GLsizei const GLchar * buf
BOOL WINAPI MoveToEx(_In_ HDC, _In_ int, _In_ int, _Out_opt_ LPPOINT)
int WINAPI ExtSelectClipRgn(_In_ HDC, _In_opt_ HRGN, _In_ int)
int WINAPI SetBkMode(_In_ HDC, _In_ int)
BOOL WINAPI PlgBlt(_In_ HDC hdcDest, _In_reads_(3) const POINT *lpPoint, _In_ HDC hdcSrc, _In_ int xSrc, _In_ int ySrc, _In_ int width, _In_ int height, _In_opt_ HBITMAP hbmMask, _In_ int xMask, _In_ int yMask)
BOOL WINAPI ResizePalette(_In_ HPALETTE, _In_ UINT)
BOOL WINAPI PolyBezierTo(_In_ HDC hdc, _In_reads_(cpt) const POINT *apt, _In_ DWORD cpt)
#define EMR_INTERSECTCLIPRECT
#define GDICOMMENT_IDENTIFIER
BOOL WINAPI RoundRect(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_ int, _In_ int)
int WINAPI SetMapMode(_In_ HDC, _In_ int)
BOOL WINAPI Arc(_In_ HDC hdc, _In_ INT xLeft, _In_ INT yTop, _In_ INT xRight, _In_ INT yBottom, _In_ INT xStartArc, _In_ INT yStartArc, _In_ INT xEndArc, _In_ INT yEndArc)
int WINAPI SetROP2(_In_ HDC, _In_ int)
int WINAPI OffsetClipRgn(_In_ HDC, _In_ int, _In_ int)
BOOL WINAPI StrokeAndFillPath(_In_ HDC)
static const char mbstate_t *static wchar_t const char mbstate_t *static const wchar_t int *static double
HPALETTE WINAPI SelectPalette(_In_ HDC, _In_ HPALETTE, _In_ BOOL)
HFONT WINAPI CreateFontIndirectW(_In_ const LOGFONTW *)
BOOL WINAPI StrokePath(_In_ HDC)
BOOL WINAPI SetBrushOrgEx(_In_ HDC, _In_ int, _In_ int, _Out_opt_ LPPOINT)
_Inout_ PERBANDINFO * pbi
EMF_dc_state * saved_state
BOOL WINAPI CombineTransform(_Out_ LPXFORM pxformResult, _In_ const XFORM *pxform1, _In_ const XFORM *pxform2)
#define EMR_SETMAPPERFLAGS
int WINAPI SetArcDirection(_In_ HDC, _In_ int)
BOOL WINAPI SetColorAdjustment(_In_ HDC, _In_ const COLORADJUSTMENT *)
HRGN WINAPI CreateRectRgn(_In_ int, _In_ int, _In_ int, _In_ int)
#define EMR_MODIFYWORLDTRANSFORM
HBRUSH WINAPI CreatePatternBrush(_In_ HBITMAP)
#define EMR_CREATEDIBPATTERNBRUSHPT
struct EMF_dc_state * next
MmuTrapHandler callback[0x30]
GLboolean GLboolean GLboolean b
BOOL WINAPI GetWorldTransform(_In_ HDC, _Out_ LPXFORM)
BOOL WINAPI PolyPolygon(_In_ HDC hdc, _In_ const POINT *apt, _In_reads_(csz) const INT *asz, _In_ int csz)
PVOID WINAPI HeapAlloc(HANDLE, DWORD, SIZE_T)
HCOLORSPACE WINAPI CreateColorSpaceA(_In_ LPLOGCOLORSPACEA pLogColorSpace)
BOOL WINAPI SetTextJustification(_In_ HDC, _In_ int, _In_ int)
BOOL WINAPI GetViewportExtEx(_In_ HDC, _Out_ LPSIZE)
BOOL WINAPI Pie(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_ int, _In_ int, _In_ int, _In_ int)
int WINAPI SetPolyFillMode(_In_ HDC, _In_ int)
BOOL WINAPI ModifyWorldTransform(_In_ HDC, _In_opt_ const XFORM *, _In_ DWORD)
HPALETTE WINAPI CreatePalette(_In_reads_(_Inexpressible_(2 *sizeof(WORD)+plpal->palNumEntries *sizeof(PALETTEENTRY))) const LOGPALETTE *)
BOOL WINAPI GetWindowExtEx(_In_ HDC, _Out_ LPSIZE)
BOOL WINAPI WidenPath(_In_ HDC)
const char * wine_dbgstr_rect(const RECT *rect)
int WINAPI ChoosePixelFormat(_In_ HDC hdc, _In_ const PIXELFORMATDESCRIPTOR *ppfd)
BOOL WINAPI GdiComment(_In_ HDC hdc, _In_ UINT nSize, _In_reads_bytes_(nSize) const BYTE *lpData)
BOOL WINAPI GetViewportOrgEx(_In_ HDC, _Out_ LPPOINT)
#define EMR_SCALEWINDOWEXTEX
int WINAPI SetMetaRgn(_In_ HDC)
#define EMR_CREATEBRUSHINDIRECT
#define EMR_SELECTCLIPPATH
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
HENHMETAFILE WINAPI CloseEnhMetaFile(_In_ HDC hdc)
_In_ UINT _In_ UINT cEntries
COLORADJUSTMENT ColorAdjustment
HBITMAP WINAPI CreateDIBitmap(_In_ HDC hdc, _In_opt_ const BITMAPINFOHEADER *pbmih, _In_ DWORD fdwInit, _In_opt_ const VOID *pvInit, _In_opt_ const BITMAPINFO *pbmi, _In_ UINT uUsage)
static const unsigned char enhmetafile[]
int WINAPI GetDeviceCaps(_In_opt_ HDC, _In_ int)
#define memcpy(s1, s2, n)
int WINAPI GetMapMode(_In_ HDC)
static cab_ULONG checksum(const cab_UBYTE *data, cab_UWORD bytes, cab_ULONG csum)
HPEN WINAPI CreatePenIndirect(_In_ const LOGPEN *)
#define ENHMETA_SIGNATURE
GLint GLint GLsizei GLsizei height
BOOL WINAPI PolyPolyline(_In_ HDC hdc, _In_ const POINT *apt, _In_reads_(csz) const DWORD *asz, _In_ DWORD csz)
HBRUSH WINAPI CreateBrushIndirect(_In_ const LOGBRUSH *plb)
int WINAPI SetStretchBltMode(_In_ HDC, _In_ int)
#define EMR_SCALEVIEWPORTEXTEX
#define EMR_SETWINDOWEXTEX
_Check_return_ _CRT_JIT_INTRINSIC double __cdecl fabs(_In_ double x)
#define ERROR_INVALID_DATA
struct tagEMRCREATECOLORSPACE * PEMRCREATECOLORSPACE
COLORREF WINAPI SetTextColor(_In_ HDC, _In_ COLORREF)
HRGN WINAPI ExtCreateRegion(_In_opt_ const XFORM *lpx, _In_ DWORD nCount, _In_reads_bytes_(nCount) const RGNDATA *lpData)
#define EMR_SETCOLORADJUSTMENT
int WINAPI SetDIBitsToDevice(_In_ HDC, _In_ int, _In_ int, _In_ DWORD, _In_ DWORD, _In_ int, _In_ int, _In_ UINT, _In_ UINT, _In_ CONST VOID *, _In_ CONST BITMAPINFO *, _In_ UINT)
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
#define EMR_POLYPOLYGON16
_In_ ULONG _In_ ULONG rgb
BOOL WINAPI DeleteDC(_In_ HDC)
BOOL WINAPI Ellipse(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int)
int WINAPI ExcludeClipRect(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int)
HBITMAP WINAPI CreateDIBSection(HDC hDC, CONST BITMAPINFO *BitmapInfo, UINT Usage, VOID **Bits, HANDLE hSection, DWORD dwOffset)
UINT WINAPI SetPaletteEntries(_In_ HPALETTE hpal, _In_ UINT iStart, _In_ UINT cEntries, _In_reads_(cEntries) CONST PALETTEENTRY *pPalEntries)
static const struct newhuff ht[]
BOOL WINAPI GdiGradientFill(HDC hdc, TRIVERTEX *vert_array, ULONG nvert, void *grad_array, ULONG ngrad, ULONG mode)
int WINAPI SaveDC(_In_ HDC)
HBRUSH WINAPI CreateSolidBrush(_In_ COLORREF)
BOOL WINAPI InvertRgn(_In_ HDC, _In_ HRGN)
BOOL WINAPI ExtTextOutA(_In_ HDC hdc, _In_ int x, _In_ int y, _In_ UINT options, _In_opt_ const RECT *lprect, _In_reads_opt_(c) LPCSTR lpString, _In_ UINT c, _In_reads_opt_(c) const INT *lpDx)
BOOL WINAPI PolyBezier(_In_ HDC hdc, _In_reads_(cpt) const POINT *apt, _In_ DWORD cpt)
BOOL WINAPI AbortPath(_In_ HDC hdc)
HDC WINAPI CreateDCW(_In_opt_ LPCWSTR pszDriver, _In_opt_ LPCWSTR pszDevice, _In_opt_ LPCWSTR psz, _In_opt_ const DEVMODEW *pdmInit)
static DWORD *static HFONT(WINAPI *pCreateFontIndirectExA)(const ENUMLOGFONTEXDVA *)
#define EMR_GLSBOUNDEDRECORD
BOOL WINAPI BeginPath(_In_ HDC hdc)
BOOL WINAPI Polyline(_In_ HDC hdc, _In_reads_(cpt) const POINT *apt, _In_ int cpt)
int WINAPI SetICMMode(_In_ HDC, _In_ int)
BOOL WINAPI FlattenPath(_In_ HDC)
#define EMR_SETWORLDTRANSFORM
BOOL WINAPI SetWindowOrgEx(_In_ HDC, _In_ int, _In_ int, _Out_opt_ LPPOINT)
void * free_gdi_handle(HGDIOBJ handle) DECLSPEC_HIDDEN
BOOL WINAPI DeleteMetaFile(_In_ HMETAFILE)
void * GDI_GetObjPtr(HGDIOBJ, WORD) DECLSPEC_HIDDEN
BOOL WINAPI MaskBlt(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_ HDC, _In_ int, _In_ int, _In_ HBITMAP, _In_ int, _In_ int, _In_ DWORD)
#define EMR_SETVIEWPORTEXTEX
HPEN WINAPI ExtCreatePen(_In_ DWORD iPenStyle, _In_ DWORD cWidth, _In_ const LOGBRUSH *plbrush, _In_ DWORD cStyle, _In_reads_opt_(cStyle) const DWORD *pstyle)
int WINAPI GetClipRgn(_In_ HDC, _In_ HRGN)
#define EMR_POLYPOLYLINE16
GLuint GLuint GLsizei GLenum type
#define EMR_SETDIBITSTODEVICE
#define EMR_SETWINDOWORGEX
BOOL WINAPI SetViewportExtEx(_In_ HDC, _In_ int, _In_ int, _Out_opt_ LPSIZE)
#define GDICOMMENT_WINDOWS_METAFILE
#define CreateFileA(a, b, c, d, e, f, g)
GLboolean GLboolean GLboolean GLboolean a
BOOL WINAPI SetPixelV(_In_ HDC, _In_ int, _In_ int, _In_ COLORREF)
BOOL WINAPI FillPath(_In_ HDC)
_Check_return_ _CRTIMP double __cdecl floor(_In_ double x)
int WINAPI SetGraphicsMode(_In_ HDC, _In_ int)
HBRUSH WINAPI CreateDIBPatternBrushPt(_In_ const VOID *pvPackedDIB, _In_ UINT uUsage)
BOOL WINAPI RestoreDC(_In_ HDC, _In_ int)
#define EMR_RESIZEPALETTE
BOOL WINAPI CloseFigure(_In_ HDC hdc)
int WINAPI SetDIBits(_In_opt_ HDC, _In_ HBITMAP, _In_ UINT, _In_ UINT, _In_ CONST VOID *, _In_ CONST BITMAPINFO *, _In_ UINT)
BOOL WINAPI FrameRgn(_In_ HDC, _In_ HRGN, _In_ HBRUSH, _In_ int, _In_ int)
#define HeapFree(x, y, z)
UINT WINAPI RealizePalette(_In_ HDC)
#define EMR_EXTSELECTCLIPRGN
BOOL WINAPI PlayMetaFile(_In_ HDC, _In_ HMETAFILE)
PSDBQUERYRESULT_VISTA PVOID DWORD * dwSize
HGDIOBJ WINAPI GetCurrentObject(_In_ HDC, _In_ UINT)
BOOL WINAPI AngleArc(_In_ HDC hdc, _In_ INT x, _In_ INT y, _In_ DWORD dwRadius, _In_ FLOAT eStartAngle, _In_ FLOAT eSweepAngle)
HANDLE NTAPI CreateFileMappingA(IN HANDLE hFile, IN LPSECURITY_ATTRIBUTES lpFileMappingAttributes, IN DWORD flProtect, IN DWORD dwMaximumSizeHigh, IN DWORD dwMaximumSizeLow, IN LPCSTR lpName)
static VOID NTAPI BitBlt(_In_ ULONG Left, _In_ ULONG Top, _In_ ULONG Width, _In_ ULONG Height, _In_reads_bytes_(Delta *Height) PUCHAR Buffer, _In_ ULONG BitsPerPixel, _In_ ULONG Delta)
#define EMR_CREATEMONOBRUSH
BOOL WINAPI ExtFloodFill(_In_ HDC, _In_ int, _In_ int, _In_ COLORREF, _In_ UINT)
HBITMAP WINAPI CreateBitmap(_In_ INT cx, _In_ INT cy, _In_ UINT cPlanes, _In_ UINT cBitsPerPel, _In_opt_ const VOID *pvBits)
#define EMR_OFFSETCLIPRGN
#define MWT_RIGHTMULTIPLY
BOOL WINAPI ArcTo(_In_ HDC hdc, _In_ INT xLeft, _In_ INT yTop, _In_ INT xRight, _In_ INT yBottom, _In_ INT xRadial1, _In_ INT yRadial1, _In_ INT xRadial2, _In_ INT yRadial2)