WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
203355
EXIF orientation is ignored for some CSS images
https://bugs.webkit.org/show_bug.cgi?id=203355
Summary
EXIF orientation is ignored for some CSS images
Simon Fraser (smfr)
Reported
2019-10-23 22:31:57 PDT
Created
attachment 381775
[details]
Testcase We ignore EXIF orientation when hitting the rendering codepaths that go through GraphicsContext::drawTiledImage(), so fail to respect EXIF orientation for CSS images in tiled background-image, border-image etc.
Attachments
Testcase
(8.82 KB, application/zip)
2019-10-23 22:31 PDT
,
Simon Fraser (smfr)
no flags
Details
Patch
(19.96 KB, patch)
2020-01-16 15:47 PST
,
Said Abou-Hallawa
no flags
Details
Formatted Diff
Diff
Patch
(28.22 KB, patch)
2020-01-17 15:07 PST
,
Said Abou-Hallawa
no flags
Details
Formatted Diff
Diff
Patch
(28.31 KB, patch)
2020-01-17 15:34 PST
,
Said Abou-Hallawa
no flags
Details
Formatted Diff
Diff
Patch
(28.30 KB, patch)
2020-01-17 16:49 PST
,
Said Abou-Hallawa
no flags
Details
Formatted Diff
Diff
Patch
(30.23 KB, patch)
2020-01-20 11:14 PST
,
Said Abou-Hallawa
no flags
Details
Formatted Diff
Diff
Show Obsolete
(4)
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2019-10-23 22:33:57 PDT
<
rdar://problem/56568303
>
Said Abou-Hallawa
Comment 2
2020-01-16 15:47:55 PST
Created
attachment 387973
[details]
Patch
Said Abou-Hallawa
Comment 3
2020-01-17 15:07:36 PST
Created
attachment 388093
[details]
Patch
Said Abou-Hallawa
Comment 4
2020-01-17 15:08:49 PST
(In reply to Said Abou-Hallawa from
comment #3
)
> Created
attachment 388093
[details]
> Patch
In this patch the EXIF orientation is respected with css background images and css border images.
Said Abou-Hallawa
Comment 5
2020-01-17 15:34:24 PST
Created
attachment 388097
[details]
Patch
Simon Fraser (smfr)
Comment 6
2020-01-17 16:31:01 PST
Comment on
attachment 388097
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=388097&action=review
> Source/WebCore/platform/graphics/BitmapImage.cpp:162 > + FloatRect rect = { IntPoint::zero(), size() };
It's a bit weird to initialize the location of a FloatRect with IntPoint::zero Is size() computed respecting orientation? I.e. do we know this code won't distort the image?
Said Abou-Hallawa
Comment 7
2020-01-17 16:38:23 PST
Comment on
attachment 388097
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=388097&action=review
>> Source/WebCore/platform/graphics/BitmapImage.cpp:162 >> + FloatRect rect = { IntPoint::zero(), size() }; > > It's a bit weird to initialize the location of a FloatRect with IntPoint::zero > > Is size() computed respecting orientation? I.e. do we know this code won't distort the image?
I will replace the IntPoint::zero() by FloatPoint(). Yes size() is computed respecting orientation since it takes an ImageOrientation argument which has a default value 'FromImage'. The definition of it in Image.h is virtual FloatSize size(ImageOrientation = ImageOrientation::FromImage) const = 0;
Said Abou-Hallawa
Comment 8
2020-01-17 16:49:26 PST
Created
attachment 388116
[details]
Patch
Said Abou-Hallawa
Comment 9
2020-01-20 11:14:35 PST
Created
attachment 388248
[details]
Patch
WebKit Commit Bot
Comment 10
2020-01-20 18:54:27 PST
Comment on
attachment 388248
[details]
Patch Clearing flags on attachment: 388248 Committed
r254841
: <
https://trac.webkit.org/changeset/254841
>
WebKit Commit Bot
Comment 11
2020-01-20 18:54:28 PST
All reviewed patches have been landed. Closing bug.
Jonathan Bedard
Comment 12
2020-01-21 15:41:18 PST
Test was landed broken:
https://results.webkit.org/?suite=layout-tests&test=scrollingcoordinator%2Fmac%2Ffixed-scrolled-body.html
Jonathan Bedard
Comment 13
2020-01-21 15:50:50 PST
Oops, wrong tests:
https://results.webkit.org/?suite=layout-tests&suite=layout-tests&test=fast%2Fimages%2Fexif-orientation-border-image.html&test=fast%2Fimages%2Fexif-orientation-background-image-no-repeat.html
Said Abou-Hallawa
Comment 14
2020-01-21 15:53:51 PST
(In reply to Jonathan Bedard from
comment #13
)
> Oops, wrong tests: >
https://results.webkit.org/?suite=layout-tests&suite=layout
- > tests&test=fast%2Fimages%2Fexif-orientation-border-image. > html&test=fast%2Fimages%2Fexif-orientation-background-image-no-repeat.html
Yes. The non CG ports have to skip these tests or to respect the EXIF image orientation when drawing the native image for CSS background and border.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug