Home
last modified time | relevance | path

Searched refs:mt (Results 1 – 17 of 17) sorted by relevance

/frameworks/base/core/tests/coretests/src/android/text/
DMeasuredParagraphTest.java65 MeasuredParagraph mt = null; in buildForBidi() local
67 mt = MeasuredParagraph.buildForBidi("XXX", 0, 3, LTR, null); in buildForBidi()
68 assertNotNull(mt); in buildForBidi()
69 assertNotNull(mt.getChars()); in buildForBidi()
70 assertEquals("XXX", charsToString(mt.getChars())); in buildForBidi()
71 assertEquals(Layout.DIR_LEFT_TO_RIGHT, mt.getParagraphDir()); in buildForBidi()
72 assertNotNull(mt.getDirections(0, 3)); in buildForBidi()
73 assertEquals(0, mt.getWholeWidth(), 0); in buildForBidi()
74 assertEquals(0, mt.getWidths().size()); in buildForBidi()
75 assertEquals(0, mt.getSpanEndCache().size()); in buildForBidi()
[all …]
/frameworks/minikin/tests/unittest/
DMeasuredTextTest.cpp69 auto mt = builder.build(text, true /* hyphenation */, true /* full layout */, in TEST() local
72 EXPECT_EQ(MinikinRect(0.0f, 0.0f, 0.0f, 0.0f), mt->getBounds(text, Range(0, 0))); in TEST()
73 EXPECT_EQ(MinikinRect(0.0f, 10.0f, 10.0f, 0.0f), mt->getBounds(text, Range(0, 1))); in TEST()
74 EXPECT_EQ(MinikinRect(0.0f, 10.0f, 20.0f, 0.0f), mt->getBounds(text, Range(0, 2))); in TEST()
75 EXPECT_EQ(MinikinRect(0.0f, 10.0f, 10.0f, 0.0f), mt->getBounds(text, Range(1, 2))); in TEST()
76 EXPECT_EQ(MinikinRect(0.0f, 10.0f, 130.0f, 0.0f), mt->getBounds(text, Range(0, text.size()))); in TEST()
87 auto mt = builder.build(text, true /* hyphenation */, true /* full layout */, in TEST() local
90 EXPECT_EQ(MinikinRect(0.0f, 10.0f, 10.0f, 0.0f), mt->getBounds(text, Range(0, 1))); in TEST()
101 auto mt = builder.build(text, true /* hyphenation */, true /* full layout */, in TEST() local
104 EXPECT_EQ(MinikinRect(0.0f, 30.0f, 30.0f, 0.0f), mt->getBounds(text, Range(0, 2))); in TEST()
[all …]
DSparseBitSetTest.cpp30 std::mt19937 mt; // Fix seeds to be able to reproduce the result. in TEST() local
33 std::vector<uint32_t> range{distribution(mt)}; in TEST()
35 range.push_back((range.back() - 1) + distribution(mt)); in TEST()
/frameworks/base/core/java/android/text/
DMeasuredParagraph.java67 final MeasuredParagraph mt = sPool.acquire(); in obtain() local
68 return mt != null ? mt : new MeasuredParagraph(); in obtain()
316 final MeasuredParagraph mt = recycle == null ? obtain() : recycle; in buildForBidi() local
317 mt.resetAndAnalyzeBidi(text, start, end, textDir); in buildForBidi()
318 return mt; in buildForBidi()
342 final MeasuredParagraph mt = recycle == null ? obtain() : recycle; in buildForMeasurement() local
343 mt.resetAndAnalyzeBidi(text, start, end, textDir); in buildForMeasurement()
345 mt.mWidths.resize(mt.mTextLength); in buildForMeasurement()
346 if (mt.mTextLength == 0) { in buildForMeasurement()
347 return mt; in buildForMeasurement()
[all …]
DTextUtils.java1329 MeasuredParagraph mt = null; in ellipsize() local
1331 mt = MeasuredParagraph.buildForMeasurement(paint, text, 0, text.length(), textDir, mt); in ellipsize()
1332 float width = mt.getWholeWidth(); in ellipsize()
1352 right = len - mt.breakText(len, false, avail); in ellipsize()
1354 left = mt.breakText(len, true, avail); in ellipsize()
1356 right = len - mt.breakText(len, false, avail / 2); in ellipsize()
1357 avail -= mt.measure(right, len); in ellipsize()
1358 left = mt.breakText(right, true, avail); in ellipsize()
1365 final char[] buf = mt.getChars(); in ellipsize()
1405 if (mt != null) { in ellipsize()
[all …]
DLayout.java2147 MeasuredParagraph mt = null;
2150 mt = MeasuredParagraph.buildForBidi(text, start, end, textDir, mt);
2151 final char[] chars = mt.getChars();
2153 final Directions directions = mt.getDirections(0, len);
2154 final int dir = mt.getParagraphDir();
2188 if (mt != null) {
2189 mt.recycle();
/frameworks/minikin/tests/stresstest/
DMultithreadTest.cpp45 static std::vector<uint16_t> generateTestText(std::mt19937* mt, int lettersInWord, in generateTestText() argument
56 text.emplace_back(dist(*mt)); in generateTestText()
69 std::mt19937 mt(tid); in thread_main() local
77 std::vector<uint16_t> text = generateTestText(&mt, 3, 10); in thread_main()
/frameworks/layoutlib/bridge/src/com/android/layoutlib/bridge/util/
DCachedPathIteratorFactory.java130 float mt = t0 + (t1 - t0) / 2; in quadCurveSegment() local
131 float mu = 1 - mt; in quadCurveSegment()
132 float mx = mu * mu * coords[0] + 2 * mu * mt * coords[2] + mt * mt * coords[4]; in quadCurveSegment()
133 float my = mu * mu * coords[1] + 2 * mu * mt * coords[3] + mt * mt * coords[5]; in quadCurveSegment()
/frameworks/base/libs/hwui/hwui/
DMinikinUtils.cpp56 minikin::MeasuredText* mt) { in doLayout() argument
65 if (mt == nullptr) { in doLayout()
69 return mt->buildLayout(textBuf, range, contextRange, minikinPaint, startHyphen, endHyphen); in doLayout()
DMinikinUtils.h49 minikin::MeasuredText* mt);
DCanvas.cpp163 const Paint& origPaint, const Typeface* typeface, minikin::MeasuredText* mt) { in drawText() argument
173 start, count, contextStart, contextCount, mt); in drawText()
DCanvas.h252 const Paint& origPaint, const Typeface* typeface, minikin::MeasuredText* mt);
/frameworks/rs/tests/java_api/CannyLive/src/com/android/example/cannylive/
DViewfinderProcessor.java210 long mt = System.nanoTime(); in run() local
214 mt = System.nanoTime() - mt; in run()
215 Log.v(TAG, " hough = " + df.format(mt * 1E-6) + "ms"); in run()
/frameworks/base/libs/hwui/jni/text/
DMeasuredText.cpp101 minikin::MeasuredText* mt = toMeasuredParagraph(ptr); in nGetWidth() local
104 r += mt->widths[i]; in nGetWidth()
/frameworks/base/core/jni/
Deventlog_helper.h55 struct { jclass *c; const char *name, *mt; jmethodID *id; } gMethods[] = { in Init() member
71 *gMethods[i].c, gMethods[i].name, gMethods[i].mt); in Init()
/frameworks/base/libs/hwui/jni/
Dandroid_graphics_Canvas.cpp593 minikin::MeasuredText* mt = reinterpret_cast<minikin::MeasuredText*>(mtHandle); in drawTextRunChars() local
604 bidiFlags, *paint, typeface, mt); in drawTextRunChars()
/frameworks/av/media/extractors/mp4/
DMPEG4Extractor.cpp1276 int32_t mt; in parseChunk() local
1278 !mDataSource->getUInt32(entriesoffset + 4, (uint32_t*)&mt)) { in parseChunk()
1282 media_time = mt; in parseChunk()