PDF with ImageMask prints incorrectly |
||
Issue descriptionChrome Version: 65.0.3325.146 OS: Windows What steps will reproduce the problem? (1) See https://bugs.chromium.org/p/pdfium/issues/detail?id=1036 (2) (3) The printed output is red, but should be blue.
,
Mar 14 2018
And since it's EMF, we need to talk to win32. In this case, we call CreateSolidBrush() with a COLORREF. COLORREFs are BGR, but since they are really just DWORDs underneath, it's really easy to assign another unsigned int into it. In this case, the input is RGB. So there ya go.
,
Mar 14 2018
,
Mar 15 2018
The following revision refers to this bug: https://pdfium.googlesource.com/pdfium/+/0202adeb5a042ca43f29439ef59e7bc3d4f8268f commit 0202adeb5a042ca43f29439ef59e7bc3d4f8268f Author: Lei Zhang <thestig@chromium.org> Date: Thu Mar 15 14:59:47 2018 Fix a red-blue channel flip when rendering masks to EMF. Use BGR instead of RGB in CGdiDeviceDriver::GDI_StretchBitMask(). Many win32 GDI APIs take COLORREF as input, and COLORREF is BGR. In this case, a win32 API was being called with RGB data. BUG= chromium:821672 Change-Id: Ia530c7ef5582eed13ac7119935851cfe0ad57323 Reviewed-on: https://pdfium-review.googlesource.com/28573 Commit-Queue: Ryan Harrison <rharrison@chromium.org> Reviewed-by: Ryan Harrison <rharrison@chromium.org> [modify] https://crrev.com/0202adeb5a042ca43f29439ef59e7bc3d4f8268f/core/fxge/win32/fx_win32_device.cpp
,
Mar 15 2018
,
Mar 15 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/3389b74210104fb6d3a82df85cf7c121d0c2fcf6 commit 3389b74210104fb6d3a82df85cf7c121d0c2fcf6 Author: pdfium-chromium-autoroll@skia-buildbots.google.com.iam.gserviceaccount.com <pdfium-chromium-autoroll@skia-buildbots.google.com.iam.gserviceaccount.com> Date: Thu Mar 15 22:12:48 2018 Roll src/third_party/pdfium/ d1ffda2ac..35841fa4e (6 commits) https://pdfium.googlesource.com/pdfium.git/+log/d1ffda2acaee..35841fa4e3db $ git log d1ffda2ac..35841fa4e --date=short --no-merges --format='%ad %ae %s' 2018-03-15 hnakashima Create FPDFPage_RemoveObject(). 2018-03-15 rharrison Fixing order of guards to avoid potential segvs 2018-03-15 thestig Rename FX_COLORREF variables from "rgb" to "bgr". 2018-03-15 thestig Use Width()/Height() methods from rectangles. 2018-03-15 thestig Remove unused CPDFSDK_BAAnnot methods. 2018-03-15 thestig Fix a red-blue channel flip when rendering masks to EMF. Created with: roll-dep src/third_party/pdfium BUG= 821672 The AutoRoll server is located here: https://pdfium-roll.skia.org Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+/master/autoroll/README.md If the roll is causing failures, please contact the current sheriff, who should be CC'd on the roll, and stop the roller if necessary. TBR=dsinclair@chromium.org Change-Id: If141edae0fe9d00e024a14545336834d172420e9 Reviewed-on: https://chromium-review.googlesource.com/964620 Commit-Queue: pdfium-chromium-autoroll <pdfium-chromium-autoroll@skia-buildbots.google.com.iam.gserviceaccount.com> Reviewed-by: pdfium-chromium-autoroll <pdfium-chromium-autoroll@skia-buildbots.google.com.iam.gserviceaccount.com> Cr-Commit-Position: refs/heads/master@{#543513} [modify] https://crrev.com/3389b74210104fb6d3a82df85cf7c121d0c2fcf6/DEPS |
||
►
Sign in to add a comment |
||
Comment 1 by thestig@chromium.org
, Mar 14 2018Status: Assigned (was: Untriaged)