New issue
Advanced search Search tips

Issue 882844 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Sep 21
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows , Mac
Pri: 2
Type: Bug

Blocking:
issue 617379



Sign in to add a comment

Introduce FreeType fallback for Windows and Mac OS versions without COLR/CPAL support

Project Member Reported by drott@chromium.org, Sep 11

Issue description

In FreeType & Skia's FreeType backend, we have COLR/CPAL support now. Also, we have COLR/CPAL support in Skia's DWrite backend on supported Windows versions.

We need to version check Chrome on Mac and Windows and fallback to Skia's FreeType backend when no native support is available.

Spun off from  issue 617379 .
 
Project Member

Comment 1 by bugdroid1@chromium.org, Sep 12

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

commit b0c0c19e35c474bc6d45ffb17e99db26f45b3a4f
Author: Dominik Röttsches <drott@chromium.org>
Date: Wed Sep 12 14:29:20 2018

Move DWriteFactory2 availability detection to blink/public/common

According to information from Microsoft we can use the presence of the
DWriteFactory2 interface (which contains TranslateColorGlyphsRun) as an
availability detector for the COLR/CPAL rendering capability of
DirectWrite. Since we already have a presence detector for this
interface in the DWriteFontProxy unit tests, move this to
blink/public/common so it can be shared by Blink's text code and the
unit test in content/test/.

Preparation for enabling COLR/CPAL support on pre Windows 8.1.

Bug:  882844 
Change-Id: I9a9d9952a37143a72bf360f59bfecb61810bd620
Reviewed-on: https://chromium-review.googlesource.com/1219686
Commit-Queue: Dominik Röttsches <drott@chromium.org>
Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
Reviewed-by: Emil A Eklund <eae@chromium.org>
Cr-Commit-Position: refs/heads/master@{#590670}
[modify] https://crrev.com/b0c0c19e35c474bc6d45ffb17e99db26f45b3a4f/content/browser/renderer_host/dwrite_font_proxy_message_filter_win_unittest.cc
[modify] https://crrev.com/b0c0c19e35c474bc6d45ffb17e99db26f45b3a4f/content/test/BUILD.gn
[modify] https://crrev.com/b0c0c19e35c474bc6d45ffb17e99db26f45b3a4f/third_party/blink/common/BUILD.gn
[modify] https://crrev.com/b0c0c19e35c474bc6d45ffb17e99db26f45b3a4f/third_party/blink/common/DEPS
[add] https://crrev.com/b0c0c19e35c474bc6d45ffb17e99db26f45b3a4f/third_party/blink/common/dwrite_rasterizer_support/dwrite_rasterizer_support.cc
[modify] https://crrev.com/b0c0c19e35c474bc6d45ffb17e99db26f45b3a4f/third_party/blink/public/common/BUILD.gn
[add] https://crrev.com/b0c0c19e35c474bc6d45ffb17e99db26f45b3a4f/third_party/blink/public/common/dwrite_rasterizer_support/dwrite_rasterizer_support.h

Project Member

Comment 2 by bugdroid1@chromium.org, Sep 20

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

commit ef5b4a0104b340581cd6fa2e4b378795a2a042d8
Author: Dominik Röttsches <drott@chromium.org>
Date: Thu Sep 20 09:57:26 2018

Fallback to FreeType for COLR/CPAL on pre Windows 8.1 systems

The availability of IDWriteFontFactory2 (which has the
TranslateColorGlyphRun method on it) is equivalent to the ability of the
underlying DirectWrite implementation to render COLR/CPAL fonts. We are
using this detection to find out whether we are running on a system that
can render COLR/CPAL natively, otherwise pass the web font to a
COLR/CPAL SkFontMgr based on FreeType.

Tests updated to reliably test rendering results for COLR/CPAL including
our Windows 7 bots.

Mac detection to do the same fallback for OS versions below Mac OS 10.13
will follow in a subsequent CL.

Bug:  882844 
Cq-Include-Trybots: luci.chromium.try:linux_layout_tests_layout_ng;luci.chromium.try:linux_layout_tests_slimming_paint_v2;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: I5f5aa16cbb176d22d229dee05619419cbb8bb892
Reviewed-on: https://chromium-review.googlesource.com/1219887
Commit-Queue: Dominik Röttsches <drott@chromium.org>
Reviewed-by: Emil A Eklund <eae@chromium.org>
Cr-Commit-Position: refs/heads/master@{#592743}
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/fast/text/font-format-support-cbdt-sbix-cff2-vertical.html
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/fast/text/font-format-support-color-cff2-vertical.html
[rename] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/fast/text/font-format-support-color-cff2.html
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/text/font-format-support-cbdt-sbix-cff2-vertical-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/flag-specific/enable-blink-features=LayoutNG/fast/text/font-format-support-color-cff2-vertical-expected.png
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/fast/text/font-format-support-cbdt-sbix-cff2-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/flag-specific/enable-slimming-paint-v2/fast/text/font-format-support-color-cff2-expected.png
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/platform/linux/fast/text/font-format-support-cbdt-sbix-cff2-expected.png
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/platform/linux/fast/text/font-format-support-cbdt-sbix-cff2-vertical-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/platform/linux/fast/text/font-format-support-color-cff2-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/platform/linux/fast/text/font-format-support-color-cff2-vertical-expected.png
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/platform/mac-mac10.10/fast/text/font-format-support-cbdt-sbix-cff2-expected.png
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/platform/mac-mac10.10/fast/text/font-format-support-cbdt-sbix-cff2-vertical-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/platform/mac-mac10.10/fast/text/font-format-support-color-cff2-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/platform/mac-mac10.10/fast/text/font-format-support-color-cff2-vertical-expected.png
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/platform/mac-mac10.12/fast/text/font-format-support-cbdt-sbix-cff2-expected.png
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/platform/mac-mac10.12/fast/text/font-format-support-cbdt-sbix-cff2-vertical-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/platform/mac-mac10.12/fast/text/font-format-support-color-cff2-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/platform/mac-mac10.12/fast/text/font-format-support-color-cff2-vertical-expected.png
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/platform/mac/fast/text/font-format-support-cbdt-sbix-cff2-expected.png
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/platform/mac/fast/text/font-format-support-cbdt-sbix-cff2-vertical-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/platform/mac/fast/text/font-format-support-color-cff2-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/platform/mac/fast/text/font-format-support-color-cff2-vertical-expected.png
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/platform/win/fast/text/font-format-support-cbdt-sbix-cff2-expected.png
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/platform/win/fast/text/font-format-support-cbdt-sbix-cff2-vertical-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/platform/win/fast/text/font-format-support-color-cff2-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/platform/win/fast/text/font-format-support-color-cff2-vertical-expected.png
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/platform/win7/fast/text/font-format-support-cbdt-sbix-cff2-expected.png
[delete] https://crrev.com/493245617aeeb1bd5ecdcbbbf2eb62282379b48c/third_party/WebKit/LayoutTests/platform/win7/fast/text/font-format-support-cbdt-sbix-cff2-vertical-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/platform/win7/fast/text/font-format-support-color-cff2-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/platform/win7/fast/text/font-format-support-color-cff2-vertical-expected.png
[add] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/WebKit/LayoutTests/third_party/ChromaCheck/chromacheck-colr.woff
[modify] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/blink/renderer/platform/fonts/opentype/font_format_check.cc
[modify] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/blink/renderer/platform/fonts/opentype/font_format_check.h
[modify] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/blink/renderer/platform/fonts/web_font_typeface_factory.cc
[modify] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/third_party/blink/renderer/platform/fonts/web_font_typeface_factory.h
[modify] https://crrev.com/ef5b4a0104b340581cd6fa2e4b378795a2a042d8/tools/metrics/histograms/enums.xml

Project Member

Comment 3 by bugdroid1@chromium.org, Sep 20

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

commit 7a95ad3567708717416e53bbd9d65db9ba2bc4f1
Author: Dominik Röttsches <drott@chromium.org>
Date: Thu Sep 20 17:37:44 2018

CoreText COLR/CPAL fallback to FreeType

Fallback to FreeType on Mac OS < 10.13 as there is no support for
COLR/CPAL layered fonts in CoreText before this version.

Bug:  882844 
Change-Id: I80ed16d1e6e23ee36dd5ad179e7712a53381e7c4
Reviewed-on: https://chromium-review.googlesource.com/1235995
Commit-Queue: Emil A Eklund <eae@chromium.org>
Reviewed-by: Emil A Eklund <eae@chromium.org>
Cr-Commit-Position: refs/heads/master@{#592857}
[modify] https://crrev.com/7a95ad3567708717416e53bbd9d65db9ba2bc4f1/third_party/WebKit/LayoutTests/platform/mac-mac10.10/fast/text/font-format-support-color-cff2-expected.png
[modify] https://crrev.com/7a95ad3567708717416e53bbd9d65db9ba2bc4f1/third_party/WebKit/LayoutTests/platform/mac-mac10.10/fast/text/font-format-support-color-cff2-vertical-expected.png
[modify] https://crrev.com/7a95ad3567708717416e53bbd9d65db9ba2bc4f1/third_party/WebKit/LayoutTests/platform/mac-mac10.12/fast/text/font-format-support-color-cff2-expected.png
[modify] https://crrev.com/7a95ad3567708717416e53bbd9d65db9ba2bc4f1/third_party/WebKit/LayoutTests/platform/mac-mac10.12/fast/text/font-format-support-color-cff2-vertical-expected.png
[modify] https://crrev.com/7a95ad3567708717416e53bbd9d65db9ba2bc4f1/third_party/blink/renderer/platform/BUILD.gn
[rename] https://crrev.com/7a95ad3567708717416e53bbd9d65db9ba2bc4f1/third_party/blink/renderer/platform/fonts/mac/core_text_font_format_support.cc
[rename] https://crrev.com/7a95ad3567708717416e53bbd9d65db9ba2bc4f1/third_party/blink/renderer/platform/fonts/mac/core_text_font_format_support.h
[modify] https://crrev.com/7a95ad3567708717416e53bbd9d65db9ba2bc4f1/third_party/blink/renderer/platform/fonts/web_font_typeface_factory.cc

Labels: -Pri-3 OS-Mac OS-Windows Pri-2
Owner: drott@chromium.org
Status: Fixed (was: Started)

Sign in to add a comment