History log of /frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
83143d005b38bf4d629825aaac037e759c68b8a6 15-Mar-2018 Seigo Nonaka <nona@google.com> Remove mtOffset from drawTextRun

Bug: 72998298
Test: atest CtsWidgetTestCases:EditTextTest
CtsWidgetTestCases:TextViewFadingEdgeTest
FrameworksCoreTests:TextViewFallbackLineSpacingTest
FrameworksCoreTests:TextViewTest FrameworksCoreTests:TypefaceTest
CtsGraphicsTestCases:TypefaceTest CtsWidgetTestCases:TextViewTest
CtsTextTestCases FrameworksCoreTests:android.text
CtsWidgetTestCases:TextViewPrecomputedTextTest

Change-Id: Ia886c1ce9f7387559d7fe00b34ce03378d56ecec
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
da252ac5c17426f28b8e18a2b8942c6880e4055b 29-Jan-2018 Seigo Nonaka <nona@google.com> Update argument of Layout methods.

Bug: 65024629
Test: minikin_tests
Test: bit CtsTextTestCases:*
Test: bit CtsWidgetTestCases:android.widget.cts.TextViewTest
Change-Id: I659bff2385db44011abbb55e287ed893d50846ec
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
976f707fbf15296ea98ece91c506ae4e64dc7e66 28-Jan-2018 Seigo Nonaka <nona@google.com> Store FontCollection in MinikinPaint

Test: N/A
Bug: 65024629
Change-Id: I38fe305c5444a6f2b6786be2005b1725f01bf961
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
783f961d2fa6f916009844dafeaa08ffaf96a4d3 20-Jan-2018 Seigo Nonaka <nona@google.com> Compute full text layout in MeasuredText and use it for drawing

The full layout is required for drawing text on UI thread.
To save this work, store the full layout result in MeasuredText and
compose the final layout from stored full layout if possible.

Currently justification/hyphenation is not supported but works normally
as before. Nothing changes on existing non measured text.

StaticLayout creation time for no style text (w/o patch -> w/ patch, N=30)
MeasuredText Balanced Hyphenation : 721,297 -> 720,657: (-0.1%)
MeasuredText Balanced NoHyphenation: 550,588 -> 546,069: (-0.8%)
MeasuredText Greedy Hyphenation : 503,582 -> 498,009: (-1.1%)
MeasuredText Greedy NoHyphenation : 502,344 -> 498,507: (-0.8%)
RandomText Balanced Hyphenation : 19,351,802 -> 19,176,024: (-0.9%)
RandomText Balanced NoHyphenation : 8,033,830 -> 7,973,336: (-0.8%)
RandomText Greedy Hyphenation : 7,957,335 -> 7,927,316: (-0.4%)
RandomText Greedy NoHyphenation : 7,988,884 -> 7,929,717: (-0.7%)

StaticLayout.draw time for no style text (w/o patch -> w/ patch, N=30)
MeasuredText NoStyled : 644,453 -> 660,684: (+2.5%)
MeasuredText NoStyled WithoutCache : 9,251,919 -> 648,992: (-93.0%)
MeasuredText Styled : 3,092,353 -> 870,702: (-71.8%)
MeasuredText Styled WithoutCache : 12,544,014 -> 1,114,557: (-91.1%)
RandomText NoStyled : 582,167 -> 572,092: (-1.7%)
RandomText NoStyled WithoutCache : 9,167,670 -> 9,056,447: (-1.2%)
RandomText Styled : 3,064,490 -> 3,029,028: (-1.2%)
RandomText Styled WithoutCache : 12,314,863 -> 12,283,026: (-0.3%)

Test: minikin_test
Test: bit CtsTextTestCases:*
Test: bit CtsWidgetTestCases:android.widget.cts.TextViewTest
Test: bit FrameworksCoreTests:android.text.MeasuredParagraphTest
Bug: 63897135

Change-Id: I7e6ec5c953d7d0f767aba4f61f94e62b6f3a3a2b
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
c52075ee2bcfde4cf9b091e404517a74ff7cec60 18-Nov-2017 Seigo Nonaka <nona@google.com> Update FontStyle location in minikin.

Bug: 65024629
Test: hwui_unit_tests
Change-Id: I54d701945dfb0792f08a4c26cc1f8b6a6ab9e67e
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
1c4ab704d14c047775b3e42f87ea4081fa204e37 11-Nov-2017 Seigo Nonaka <nona@google.com> Revert "Store FontCollection in MinikinPaint"

This regresses the performance.

Bug: 69165958

This reverts commit c0a35e7b0ecbd35c9c39205fec6ef2555e86db8b.

Change-Id: I86f0b55dc83fdde4ca04659ec0f7bb3589f571fa
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
c0a35e7b0ecbd35c9c39205fec6ef2555e86db8b 09-Nov-2017 Seigo Nonaka <nona@google.com> Store FontCollection in MinikinPaint

Bug: 65024629
Test: hwui_unit_tests
Change-Id: Ibe9b20f782702e0536997727f1cc788789c47552
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
20866c140438a9aca3e1ad09fe646308678e9383 27-Oct-2017 Seigo Nonaka <nona@google.com> Use enum class for FontVariation and update MinikinUtils

This CL contains followins:
- Use enum class FontVariation instead of legacy enum.
- Store FontStyle in MinikinPaint.

Bug: 65024629
Test: minikin_tests
Change-Id: I86bf64fd5d9a8c08eff47db851fa4655da84b1e4
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
1bcacfdcab0eaa0cee92bd7f5a1b5e271dd68e52 03-Nov-2017 John Reck <jreck@google.com> Format the world (or just HWUI)

Test: No code changes, just ran through clang-format
Change-Id: Id23aa4ec7eebc0446fe3a30260f33e7fd455bb8c
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
7c93e868825225a270c993ac058687adde682626 26-Oct-2017 Seigo Nonaka <nona@google.com> Make casting to bidi flags explicit

Bug: 65024629
Test: checkbuild
Change-Id: I0771036359cc1ee5471e9fd4da304598a2f8bf98
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
0aa07a712984a655215f20e664915b67833be709 30-Aug-2017 Roozbeh Pournader <roozbeh@google.com> Update for changes in Minikin interface for overhangs

Bug: 63938206
Test: mmm -j frameworks/base/libs/hwui
Change-Id: Iecf0204e28450adf06e3aecbc27fd35ec76ded10
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
737dfead64dd24a431beff85b685594dc0efb49a 10-Aug-2017 Roozbeh Pournader <roozbeh@google.com> Support extra linespacing based on fallback fonts

* Increase the ascent and descent of individual lines in StaticLayout
as needed, if any fallback fonts that end up getting used call for
it. For backward compatibility, this is hidden behind a builder
flag.
* Document in Paint.java that the returned parameters are only for
the default font, and a layout may need more space based on
fallbacks used.

Also update for changes in minikin API:

* MinikinFont now requires a method for getting vertical extents
(ascent, descent, and line gap).
* minikin API now allows asking for vertical extents of laid out
text.
* minikin API's LineBreaker now returns ascents and descents for each
line.

Finally, added performances test for creating a StaticLayout.
Follwing are the numbers on a marlin with a stable clock before and
after this CL.

For fixed text almost always hitting the cache:
Before: mean=260684 median=260188 min=258532 standardDeviation=1897
After: mean=262432 median=261509 min=260429 standardDeviation=2185

For random text almost never hitting the cache:
Before: mean=5971827 median=5991126 min=5886871 standardDeviation=83724
After: mean=6337093 median=6317010 min=6311222 standardDeviation=40213

Bug: 28963299
Bug: 29063863
Bug: 32057121
Bug: 37756858
Test: bit FrameworksCoreTests:android.text.
Test: bit CtsTextTestCases:*
Change-Id: I482a98ff8f472e8bab4f0ba9d1d7b368858038ff
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
318ca04079bd6242cb6186d9005b9caeee22e845 02-Aug-2017 Seigo Nonaka <nona@google.com> Refactoring: Deprecate Paint.mNativeTypeface.

Bug: 64269689
Test: m checkbuild
Test: bit CtsGraphicsTestCases:*
Test: bit CtsViewTestCases:*
Test: bit CtsTextTestCases:*
Change-Id: Idc9f2b4612741be949204cd06efc41e1738d6587
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
a130a6cf4cf9f8294dcd95b94ed6e45bbddbfe40 21-Jul-2017 Seigo Nonaka <nona@google.com> Revive fractional value of text size.

Test: Manual
Bug: 37042531
Change-Id: I3a6e0bf4d2aae690323032eef325e198851b5e6a
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
51218e80f70601193e43d90aaf1599a7f6d11062 14-Mar-2017 Seigo Nonaka <nona@google.com> Pass FontCollection to doLayout's argument instead of ctor

Test: minikin_unit_tests
Test: minikin_stress_tests
Bug: 36223724
Change-Id: I55aca62eab4df0c138fec764d616984b50bd73f1
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
c7064146f959caec058980ced144942c8044a169 10-Feb-2017 Seigo Nonaka <nona@google.com> Follow Minikin's signature changes.

Minikin now uses shared_ptr instead of MinikinRefCounted.

Bug: 28119474
Test: manually tested
Test: hwui_unit_tests passed.
Change-Id: Ie0564851a8a798af112679e15f7a07db000a977e
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
db15537e6e0d35c7ed3b1bef45e421760be70683 11-Jan-2017 Mark Salyzyn <salyzyn@google.com> resolve merge conflicts of 082a1721b516 to master

Test: compile
Bug: 26552300
Bug: 31289077
Change-Id: I17f178f425975c1c0dbd48091d25b101956d505e
52eb4e01a49fe2e94555c000de38bbcbbb13401b 29-Sep-2016 Mark Salyzyn <salyzyn@google.com> Replace cutils/log.h and log/logger.h with log/log.h

Test: compile
Bug: 26552300
Bug: 31289077
Change-Id: I578b15b48f0fc2807a92abbc69a377c3d2191496
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
219e2c79490296b03e58ec36a3a4ff4a2ebf52e3 15-Nov-2016 Seigo Nonaka <nona@google.com> Add wordSpacing parameter to Paint

Adds the ability to control word spacing from Java, wiring up the
plumbing to the corresponding change that adds it at the Minikin
level.

Bug: 31707212
Test: ran graphicstests
Change-Id: I568186aca961d51ee5231cb0331f882b7b005e90
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
ae1aa85d0c7305bb621f1f8003bd674285aa3b63 09-Jun-2016 Seigo Nonaka <nona@google.com> Follow the minikin namespace changes

Bug: 29233740
Change-Id: I0ec7c5c88e64daa626751d3a03e24b9c36521c17
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
bad99183916ba2bac6659efc8a28273e344ba511 17-Mar-2016 sergeyv <sergeyv@google.com> Clean up and rename TypefaceImpl

bug:25865834
Change-Id: I77e8a627163e040a5c25865054a8a936052af367
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
dccca44ffda4836b56a21da95a046c9708ffd49c 21-Mar-2016 sergeyv <sergeyv@google.com> Reland: Move text logic from jni to hwui level

Initial CL: https://googleplex-android-review.git.corp.google.com/#/c/886854/

Change-Id: I9dfd85fe1d2a2c44f4360c8a29fd58d80e6f31c8
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
afbd0f1fef46ef0ddf633dfde0de724db3da1405 21-Mar-2016 Sergei Vasilinetc <sergeyv@google.com> Revert "Move text logic from jni to hwui level"

This reverts commit a7f6bba1a3565c19715e878dfe7f0e01022944ff.

Change-Id: If4f36f87a85411b6128fd92d391313803ccaf9dd
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp
a7f6bba1a3565c19715e878dfe7f0e01022944ff 16-Mar-2016 sergeyv <sergeyv@google.com> Move text logic from jni to hwui level

bug:25865834
Change-Id: I2d8c9c9544afcb5ce1784f732aed3e54e0eda372
/frameworks/base/libs/hwui/hwui/MinikinUtils.cpp