diff options
author | Seigo Nonaka <nona@google.com> | 2023-09-20 09:37:42 +0900 |
---|---|---|
committer | Seigo Nonaka <nona@google.com> | 2023-09-20 15:58:22 +0900 |
commit | f50b62934915cf20e0b8fb157839376f4750f0de (patch) | |
tree | 370ee55160548f93194a291069fc384079533eb4 | |
parent | cc22ab0d8d11526794360b640e3ed521c0810c3e (diff) | |
download | minikin-f50b62934915cf20e0b8fb157839376f4750f0de.tar.gz |
Add trace point to the bounding box calculation
Bug: 63938206
Test: N/A
Change-Id: I3d795797ae9b30e8cedd1ef499fb3b3c41a847bb
-rw-r--r-- | libs/minikin/Android.bp | 1 | ||||
-rw-r--r-- | libs/minikin/LayoutCore.cpp | 3 | ||||
-rw-r--r-- | tests/perftests/Android.bp | 2 | ||||
-rw-r--r-- | tests/stresstest/Android.bp | 1 | ||||
-rw-r--r-- | tests/unittest/Android.bp | 1 |
5 files changed, 7 insertions, 1 deletions
diff --git a/libs/minikin/Android.bp b/libs/minikin/Android.bp index c406015..4cb76a2 100644 --- a/libs/minikin/Android.bp +++ b/libs/minikin/Android.bp @@ -76,6 +76,7 @@ cc_library { shared_libs: [ "liblog", "libharfbuzz_ng", + "libcutils", ], header_libs: [ "libbase_headers", diff --git a/libs/minikin/LayoutCore.cpp b/libs/minikin/LayoutCore.cpp index bc907fd..b89958e 100644 --- a/libs/minikin/LayoutCore.cpp +++ b/libs/minikin/LayoutCore.cpp @@ -15,6 +15,7 @@ */ #define LOG_TAG "Minikin" +#define ATRACE_TAG ATRACE_TAG_VIEW #include "minikin/LayoutCore.h" @@ -24,6 +25,7 @@ #include <unicode/ubidi.h> #include <unicode/utf16.h> #include <utils/LruCache.h> +#include <utils/Trace.h> #include <cmath> #include <iostream> @@ -497,6 +499,7 @@ LayoutPiece::LayoutPiece(const U16StringPiece& textBuf, const Range& range, bool // static MinikinRect LayoutPiece::calculateBounds(const LayoutPiece& layout, const MinikinPaint& paint) { + ATRACE_CALL(); MinikinRect out; for (uint32_t i = 0; i < layout.glyphCount(); ++i) { MinikinRect bounds; diff --git a/tests/perftests/Android.bp b/tests/perftests/Android.bp index dcf5b98..cf57667 100644 --- a/tests/perftests/Android.bp +++ b/tests/perftests/Android.bp @@ -44,6 +44,6 @@ cc_benchmark { "libharfbuzz_ng", "libicu", "liblog", - + "libcutils", ], } diff --git a/tests/stresstest/Android.bp b/tests/stresstest/Android.bp index d963a09..e08a984 100644 --- a/tests/stresstest/Android.bp +++ b/tests/stresstest/Android.bp @@ -40,6 +40,7 @@ cc_test { "liblog", "libutils", "libz", + "libcutils", ], srcs: [ diff --git a/tests/unittest/Android.bp b/tests/unittest/Android.bp index 01953e0..27d8cc6 100644 --- a/tests/unittest/Android.bp +++ b/tests/unittest/Android.bp @@ -40,6 +40,7 @@ cc_test { "liblog", "libutils", "libz", + "libcutils", ], srcs: [ |