Module: wine Branch: master Commit: 1c35d29ed5580c2c8c44f93494e96e04e6090622 URL: https://source.winehq.org/git/wine.git/?a=commit;h=1c35d29ed5580c2c8c44f9349...
Author: Zhiyi Zhang zzhang@codeweavers.com Date: Wed Apr 14 15:26:52 2021 +0800
winedump: Dump EMR_STRETCHBLT record.
Signed-off-by: Zhiyi Zhang zzhang@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
tools/winedump/emf.c | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-)
diff --git a/tools/winedump/emf.c b/tools/winedump/emf.c index d5630f6812b..2f54f73153b 100644 --- a/tools/winedump/emf.c +++ b/tools/winedump/emf.c @@ -325,7 +325,30 @@ static int dump_emfrecord(void) }
EMRCASE(EMR_BITBLT); - EMRCASE(EMR_STRETCHBLT); + + case EMR_STRETCHBLT: + { + const EMRSTRETCHBLT *blt = PRD(offset, sizeof(*blt)); + const BITMAPINFOHEADER *bmih = (const BITMAPINFOHEADER *)((const unsigned char *)blt + blt->offBmiSrc); + + printf("%-20s %08x\n", "EMR_STRETCHBLT", length); + printf("bounds (%d,%d - %d,%d) dst %d,%d %dx%d src %d,%d %dx%d rop %#x xform (%f, %f, %f, %f, %f, %f)\n" + "bk_color %#x usage %#x bmi_offset %#x bmi_size %#x bits_offset %#x bits_size %#x\n", + blt->rclBounds.left, blt->rclBounds.top, blt->rclBounds.right, blt->rclBounds.bottom, + blt->xDest, blt->yDest, blt->cxDest, blt->cyDest, + blt->xSrc, blt->ySrc, blt->cxSrc, blt->cySrc, blt->dwRop, + blt->xformSrc.eM11, blt->xformSrc.eM12, blt->xformSrc.eM21, + blt->xformSrc.eM22, blt->xformSrc.eDx, blt->xformSrc.eDy, + blt->crBkColorSrc, blt->iUsageSrc, blt->offBmiSrc, blt->cbBmiSrc, + blt->offBitsSrc, blt->cbBitsSrc); + printf("BITMAPINFOHEADER biSize %#x biWidth %d biHeight %d biPlanes %d biBitCount %d biCompression %#x\n" + "biSizeImage %#x biXPelsPerMeter %d biYPelsPerMeter %d biClrUsed %#x biClrImportant %#x\n", + bmih->biSize, bmih->biWidth, bmih->biHeight, bmih->biPlanes, bmih->biBitCount, + bmih->biCompression, bmih->biSizeImage, bmih->biXPelsPerMeter, bmih->biYPelsPerMeter, + bmih->biClrUsed, bmih->biClrImportant); + break; + } + EMRCASE(EMR_MASKBLT); EMRCASE(EMR_PLGBLT); EMRCASE(EMR_SETDIBITSTODEVICE);