New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 921269 link

Starred by 3 users

Issue metadata

Status: Fixed
Owner:
Closed: Jan 17
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Android , Windows , Chrome , Mac
Pri: 1
Type: Bug-Regression



Sign in to add a comment

Using background-size: some-width-in-px auto does not rescale the height of the image

Reported by hait...@squareup.com, Jan 12

Issue description

Steps to reproduce the problem:
1. visit page with the following CSS
body {
  background-image: url(https://payroll-production-f.squarecdn.com/payroll/assets/sprites/payroll/payroll-hidpi-a11ed7186123504dcb4e2007be05b0c15814313d796f6fecac52756feaded821.png);
  background-size: 870px auto;
}

https://jsfiddle.net/kroqw1e3/

What is the expected behavior?
That the image is scaled down proportionally

What went wrong?
Because the height didn't scale the image aspect ratio was thrown off and the image was distorted. 

Did this work before? Yes 69.x

Chrome version: 71.0.3578.99  Channel: stable
OS Version: 8.1
Flash Version:
 
Here's a screenshot of the JS Fiddle ran with the distortion present. 
Capture+_2019-01-11-16-59-21.png
64.6 KB View Download
Labels: Needs-triage-Mobile
Cc: chelamcherla@chromium.org
Components: -UI UI>Browser>Mobile Blink>HTML
Labels: -Pri-2 ReleaseBlock-Stable Target-71 Target-72 Target-73 M-71 Triaged-Mobile FoundIn-71 FoundIn-73 FoundIn-72 Pri-1
Status: Untriaged (was: Unconfirmed)
Tested the issue in Android and able to reproduce the issue. 

Steps Followed:
1. Navigated to https://jsfiddle.net/kroqw1e3/
2. Observed distorted image as shown in screenshot of c#1

Chrome versions tested:
71.0.3557.0 , 71.0.3559.5 , 73.0.3667.2

OS:
Android 9.0.0

Android Devices:
Pixel 2 XL

Using the per-revision bisect providing the bisect results,
Good Build - 71.0.3557.0
Bad Build - 71.0.3559.5 

Manual CL: https://chromium.googlesource.com/chromium/src/+log/71.0.3557.0..71.0.3559.0?pretty=fuller&n=10000

On doing per-revision bisect observed result as "C 1513.746s Main  You are looking for a change made after 593189(GOOD), but before 593399(BAD)." There is lot of difference between Good and Bad versions. Now did bisect 593189 and 593399 -- observed "we don’t have enough builds to bisect" error message

Could someone from dev team please help in assigning to appropriate owner. 

Thanks!

Cc: -chelamcherla@chromium.org sindhu.chelamcherla@chromium.org candr...@chromium.org
Labels: Needs-Bisect
+candrada@, Requesting MTV team to bisect and provide exact culprit cl. PTAL comment #3. Thank you.
Cc: pucchakayala@chromium.org abdulsyed@google.com
Labels: OS-Chrome OS-Linux OS-Mac OS-Windows
As this is Blink, this could be also applicable to Desktop & Chrome OS. 

+pucchakayala@, could you pls try to repro on M72 Desktop?


Cc: prashanthpola@chromium.org krav...@chromium.org
+prashanthpola/kravula to bisect on Android
Labels: -Needs-Bisect -Needs-triage-Mobile -Triaged-Mobile hasbisect-per-revision cannot-perCL-bisect
Owner: rbpotter@chromium.org
Status: Assigned (was: Untriaged)
Re-Bisected the issue.

Bisect info:
Good build:71.0.3558.2
Bad build:71.0.3559.5
Regression range:
https://chromium.googlesource.com/chromium/src/+log/71.0.3558.0..71.0.3559.0?pretty=fuller&n=10000

Unable to do Per-CL bisect as we get an exception don't have enough builds to biscet.

Suspect CL: 
https://chromium.googlesource.com/chromium/src/+/4756a5ebdcd7ced17fe797a74da76725e11f9811

rbpotter@ Could you please look into this issue? Thanks!


Labels: -M-71 -Target-72 M-73 RegressedIn-71
Thank you  prashanthpola@. As this is regressed in M71, not a blocker for M72. Moving to M73.
Labels: -Target-71
Unlikely this is caused by the CL linked, given that it occurs on Android. The CL linked only touches Print Preview code, which isn't included on that platform. I'll try to re-bisect.
Cc: rbpotter@chromium.org
Labels: Needs-triage-Mobile Needs-Bisect
Owner: ----
Status: Untriaged (was: Assigned)
Can't reproduce this on Linux or Windows 10 with Chrome Stable 71.0.3578.98 or on Windows 10 with Chrome Beta 72.0.3626.53. Has anyone else been able to reproduce this on Desktop platforms? I can re-do the bisect if someone can find a way to reproduce this on Linux or Windows.

In the mean time, since this seems to only reproduce on Android and the "suspect CL" does not touch any Android code, I am re-adding Needs-Bisect and Needs-Triage-Mobile labels.
Able to reproduce this issue on Win7/64 bit & Mac OSX 10.13.6 - 72.0.3626.53 Beta Build.
Components: -Blink>HTML Blink>Paint
Labels: -Needs-Bisect
Owner: schenney@chromium.org
Status: Started (was: Untriaged)
It's a zoom for DSF issue, which is why it only reproduces on Android. You could probably reproduce it with zoom on other platforms. Enabling zoom-for-dsf is within the regression range.
Reproduces with zoom-for-DSF on Mac, but not plain zooming. Odd.
Components: -UI>Browser>Mobile
Project Member

Comment 17 by bugdroid1@chromium.org, Jan 17 (6 days ago)

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/2dd4985ba4d4952fd0ea9b85ac2111b161ef389f

commit 2dd4985ba4d4952fd0ea9b85ac2111b161ef389f
Author: Stephen Chenney <schenney@chromium.org>
Date: Thu Jan 17 03:49:23 2019

Fix numerical inaccuracy in background-size auto

We were using intrinsic_width * tile_size / intrinsic_height to
compute the auto size when only one dimension is given. The values
are in LayoutUnits and the expression overflows when the tile is
large and the image is large, resulting in significant distortion
of the background. The effect is most prominant on high-dpi devices
but also manifests at high zoom.

Bug:  921269 
Change-Id: I78c2d0adf3c23b1b9d4158d2ffe8d775b3f5b9f4
Reviewed-on: https://chromium-review.googlesource.com/c/1413175
Reviewed-by: Fredrik Söderquist <fs@opera.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Stephen Chenney <schenney@chromium.org>
Cr-Commit-Position: refs/heads/master@{#623564}
[modify] https://crrev.com/2dd4985ba4d4952fd0ea9b85ac2111b161ef389f/third_party/blink/renderer/core/paint/background_image_geometry.cc
[add] https://crrev.com/2dd4985ba4d4952fd0ea9b85ac2111b161ef389f/third_party/blink/web_tests/external/wpt/css/css-backgrounds/background-image-large-with-auto.html
[add] https://crrev.com/2dd4985ba4d4952fd0ea9b85ac2111b161ef389f/third_party/blink/web_tests/external/wpt/css/css-backgrounds/reference/background-image-large-with-auto-ref.html
[add] https://crrev.com/2dd4985ba4d4952fd0ea9b85ac2111b161ef389f/third_party/blink/web_tests/external/wpt/css/css-backgrounds/support/green-1000x10.png
[add] https://crrev.com/2dd4985ba4d4952fd0ea9b85ac2111b161ef389f/third_party/blink/web_tests/external/wpt/css/css-backgrounds/support/green-10x1000.png

Comment 18 by schenney@chromium.org, Jan 17 (5 days ago)

Status: Fixed (was: Started)

Comment 19 by schenney@chromium.org, Yesterday (35 hours ago)

 Issue 923778  has been merged into this issue.

Comment 20 by schenney@chromium.org, Yesterday (35 hours ago)

Labels: Merge-Request-72
Requesting merge. We've had 2 reports and this is a minor change.
Project Member

Comment 21 by sheriffbot@chromium.org, Yesterday (35 hours ago)

Labels: -Merge-Request-72 Merge-Review-72 Hotlist-Merge-Review
This bug requires manual review: We are only 7 days from stable.
Please contact the milestone owner if you have questions.
Owners: govind@(Android), kariahda@(iOS), djmm@(ChromeOS), abdulsyed@(Desktop)

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot

Comment 22 by abdulsyed@google.com, Yesterday (33 hours ago)

Labels: -Merge-Review-72 Merge-Approved-72

Comment 23 by gov...@chromium.org, Yesterday (33 hours ago)

Pls merge your change to M72 branch 3626 latest by 1:00 PM PT tomorrow, Tuesday (01/22) so we can pick it up for this week last beta release. Thank you.
Project Member

Comment 24 by bugdroid1@chromium.org, Today (16 hours ago)

Labels: -merge-approved-72 merge-merged-3626
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/23817b492070789595de677d7c8e0e35e6eb262e

commit 23817b492070789595de677d7c8e0e35e6eb262e
Author: Stephen Chenney <schenney@chromium.org>
Date: Tue Jan 22 14:28:56 2019

Fix numerical inaccuracy in background-size auto

M-72 merge.

We were using intrinsic_width * tile_size / intrinsic_height to
compute the auto size when only one dimension is given. The values
are in LayoutUnits and the expression overflows when the tile is
large and the image is large, resulting in significant distortion
of the background. The effect is most prominent on high-dpi devices
but also manifests at high zoom.

Bug:  921269 
Change-Id: I78c2d0adf3c23b1b9d4158d2ffe8d775b3f5b9f4
Reviewed-on: https://chromium-review.googlesource.com/c/1413175
Reviewed-by: Fredrik Söderquist <fs@opera.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Stephen Chenney <schenney@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#623564}(cherry picked from commit 2dd4985ba4d4952fd0ea9b85ac2111b161ef389f)
Reviewed-on: https://chromium-review.googlesource.com/c/1426441
Reviewed-by: Stephen Chenney <schenney@chromium.org>
Cr-Commit-Position: refs/branch-heads/3626@{#750}
Cr-Branched-From: d897fb137fbaaa9355c0c93124cc048824eb1e65-refs/heads/master@{#612437}
[modify] https://crrev.com/23817b492070789595de677d7c8e0e35e6eb262e/third_party/blink/renderer/core/paint/background_image_geometry.cc
[add] https://crrev.com/23817b492070789595de677d7c8e0e35e6eb262e/third_party/blink/web_tests/external/wpt/css/css-backgrounds/background-image-large-with-auto.html
[add] https://crrev.com/23817b492070789595de677d7c8e0e35e6eb262e/third_party/blink/web_tests/external/wpt/css/css-backgrounds/reference/background-image-large-with-auto-ref.html
[add] https://crrev.com/23817b492070789595de677d7c8e0e35e6eb262e/third_party/blink/web_tests/external/wpt/css/css-backgrounds/support/green-1000x10.png
[add] https://crrev.com/23817b492070789595de677d7c8e0e35e6eb262e/third_party/blink/web_tests/external/wpt/css/css-backgrounds/support/green-10x1000.png

Project Member

Comment 25 by cr-audit...@appspot.gserviceaccount.com, Today (16 hours ago)

Labels: Merge-Merged-72-3626
The following revision refers to this bug: 
https://chromium.googlesource.com/chromium/src.git/+/23817b492070789595de677d7c8e0e35e6eb262e

Commit: 23817b492070789595de677d7c8e0e35e6eb262e
Author: schenney@chromium.org
Commiter: schenney@chromium.org
Date: 2019-01-22 14:28:56 +0000 UTC

Fix numerical inaccuracy in background-size auto

M-72 merge.

We were using intrinsic_width * tile_size / intrinsic_height to
compute the auto size when only one dimension is given. The values
are in LayoutUnits and the expression overflows when the tile is
large and the image is large, resulting in significant distortion
of the background. The effect is most prominent on high-dpi devices
but also manifests at high zoom.

Bug:  921269 
Change-Id: I78c2d0adf3c23b1b9d4158d2ffe8d775b3f5b9f4
Reviewed-on: https://chromium-review.googlesource.com/c/1413175
Reviewed-by: Fredrik Söderquist <fs@opera.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Stephen Chenney <schenney@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#623564}(cherry picked from commit 2dd4985ba4d4952fd0ea9b85ac2111b161ef389f)
Reviewed-on: https://chromium-review.googlesource.com/c/1426441
Reviewed-by: Stephen Chenney <schenney@chromium.org>
Cr-Commit-Position: refs/branch-heads/3626@{#750}
Cr-Branched-From: d897fb137fbaaa9355c0c93124cc048824eb1e65-refs/heads/master@{#612437}

Sign in to add a comment