The following commits modify the behaviours of the following GDI functions:
- StretchDIBits - SetDIBitsToDevice
To match more closely to that of Windows 10, build 2108, subject to the following constraints:
- The source image is not a JPEG (BI_JPEG) or a PNG (BI_PNG) image. - The source image is a *bottom-up* device-independent bitmap.
Changelog:
- v1 -> v2: add more tests, do extra work so that EMF outputs match - v2 -> v3: emf_parse_user_bitmapinfo: zero out *dst (BITMAPINFOHEADER) (gdi32: allow passing BITMAPINFO with bmiHeader.biSizeImage == 0 for EMF DC.) - v3 -> v4: no changes (resend due to borked up patch orders) - v4 -> v5: change subject (no more RFC); address review comments so far - v5 -> v6: remove two EMFDRV functions entirely clarify code in EMF DC patch uppercase subjects
Jinoh Kang (6): win32u: Remove EMFDRV_StretchDIBits and EMFDRV_SetDIBitsToDevice. gdi32/tests: Add tests for recording StretchDIBits in EMFs. gdi32/tests: Add tests for recording SetDIBitsToDevice in EMFs. gdi32: Fix bounding box calculation for EMR_STRETCHDIBITS. gdi32: Allow passing BITMAPINFO with bmiHeader.biSizeImage == 0 for EMF DC. gdi32: Calculate effective number of scan lines and truncate bitmap bits for EMR_SETDIBITSTODEVICE.
dlls/gdi32/emfdc.c | 234 ++- dlls/gdi32/tests/metafile.c | 2803 +++++++++++++++++++++++++++++++++++ dlls/win32u/emfdrv.c | 22 +- 3 files changed, 3021 insertions(+), 38 deletions(-)