Home
last modified time | relevance | path

Searched refs:amount (Results 1 – 25 of 119) sorted by relevance

12345

/frameworks/rs/driver/runtime/arch/
Dclamp.c25 extern T __attribute__((overloadable)) clamp(T amount, T low, T high) { \
26 return amount < low ? low : (amount > high ? high : amount); \
46 extern T##2 __attribute__((overloadable)) clamp(T##2 amount, T##2 low, T##2 high) { \
48 r.x = amount.x < low.x ? low.x : (amount.x > high.x ? high.x : amount.x); \
49 r.y = amount.y < low.y ? low.y : (amount.y > high.y ? high.y : amount.y); \
53 extern T##3 __attribute__((overloadable)) clamp(T##3 amount, T##3 low, T##3 high) { \
55 r.x = amount.x < low.x ? low.x : (amount.x > high.x ? high.x : amount.x); \
56 r.y = amount.y < low.y ? low.y : (amount.y > high.y ? high.y : amount.y); \
57 r.z = amount.z < low.z ? low.z : (amount.z > high.z ? high.z : amount.z); \
61 extern T##4 __attribute__((overloadable)) clamp(T##4 amount, T##4 low, T##4 high) { \
[all …]
Dgeneric.c20 extern short __attribute__((overloadable, always_inline)) rsClamp(short amount, short low, short hi…
30 extern T __attribute__((overloadable)) clamp(T amount, T low, T high) { \
31 return amount < low ? low : (amount > high ? high : amount); \
34 extern T##2 __attribute__((overloadable)) clamp(T##2 amount, T##2 low, T##2 high) { \
36 r.x = amount.x < low.x ? low.x : (amount.x > high.x ? high.x : amount.x); \
37 r.y = amount.y < low.y ? low.y : (amount.y > high.y ? high.y : amount.y); \
41 extern T##3 __attribute__((overloadable)) clamp(T##3 amount, T##3 low, T##3 high) { \
43 r.x = amount.x < low.x ? low.x : (amount.x > high.x ? high.x : amount.x); \
44 r.y = amount.y < low.y ? low.y : (amount.y > high.y ? high.y : amount.y); \
45 r.z = amount.z < low.z ? low.z : (amount.z > high.z ? high.z : amount.z); \
[all …]
/frameworks/rs/cpu_ref/
DrsCpuIntrinsicInlines.h85 static inline int4 clamp(int4 amount, int low, int high) { in CVT_FUNC()
87 r.x = amount.x < low ? low : (amount.x > high ? high : amount.x); in CVT_FUNC()
88 r.y = amount.y < low ? low : (amount.y > high ? high : amount.y); in CVT_FUNC()
89 r.z = amount.z < low ? low : (amount.z > high ? high : amount.z); in CVT_FUNC()
90 r.w = amount.w < low ? low : (amount.w > high ? high : amount.w); in CVT_FUNC()
94 static inline float4 clamp(float4 amount, float low, float high) { in clamp() argument
96 r.x = amount.x < low ? low : (amount.x > high ? high : amount.x); in clamp()
97 r.y = amount.y < low ? low : (amount.y > high ? high : amount.y); in clamp()
98 r.z = amount.z < low ? low : (amount.z > high ? high : amount.z); in clamp()
99 r.w = amount.w < low ? low : (amount.w > high ? high : amount.w); in clamp()
[all …]
DrsCpuIntrinsicBlend.cpp114 static inline uchar4 convertClipped(TI amount) { in convertClipped() argument
115 return uchar4 { static_cast<uchar>(amount.x > 255 ? 255 : amount.x), in convertClipped()
116 static_cast<uchar>(amount.y > 255 ? 255 : amount.y), in convertClipped()
117 static_cast<uchar>(amount.z > 255 ? 255 : amount.z), in convertClipped()
118 static_cast<uchar>(amount.w > 255 ? 255 : amount.w)}; in convertClipped()
/frameworks/rs/toolkit/
DUtils.h92 inline int4 clamp(int4 amount, int low, int high) { in clamp() argument
94 r.x = amount.x < low ? low : (amount.x > high ? high : amount.x); in clamp()
95 r.y = amount.y < low ? low : (amount.y > high ? high : amount.y); in clamp()
96 r.z = amount.z < low ? low : (amount.z > high ? high : amount.z); in clamp()
97 r.w = amount.w < low ? low : (amount.w > high ? high : amount.w); in clamp()
101 inline float4 clamp(float4 amount, float low, float high) { in clamp() argument
103 r.x = amount.x < low ? low : (amount.x > high ? high : amount.x); in clamp()
104 r.y = amount.y < low ? low : (amount.y > high ? high : amount.y); in clamp()
105 r.z = amount.z < low ? low : (amount.z > high ? high : amount.z); in clamp()
106 r.w = amount.w < low ? low : (amount.w > high ? high : amount.w); in clamp()
[all …]
DBlend.cpp78 static inline uchar4 convertClipped(TI amount) { in convertClipped() argument
79 return uchar4 { static_cast<uchar>(amount.x > 255 ? 255 : amount.x), in convertClipped()
80 static_cast<uchar>(amount.y > 255 ? 255 : amount.y), in convertClipped()
81 static_cast<uchar>(amount.z > 255 ? 255 : amount.z), in convertClipped()
82 static_cast<uchar>(amount.w > 255 ? 255 : amount.w)}; in convertClipped()
/frameworks/base/core/java/android/util/
DMathUtils.java41 public static int constrain(int amount, int low, int high) { in constrain() argument
42 return amount < low ? low : (amount > high ? high : amount); in constrain()
45 public static long constrain(long amount, long low, long high) { in constrain() argument
46 return amount < low ? low : (amount > high ? high : amount); in constrain()
50 public static float constrain(float amount, float low, float high) { in constrain() argument
51 return amount < low ? low : (amount > high ? high : amount); in constrain()
165 public static float lerp(float start, float stop, float amount) { in lerp() argument
166 return start + (stop - start) * amount; in lerp()
169 public static float lerp(int start, int stop, float amount) { in lerp() argument
170 return lerp((float) start, (float) stop, amount); in lerp()
[all …]
/frameworks/base/native/graphics/jni/
Daassetstreamadaptor.cpp83 ssize_t amount; in read() local
103 amount = newOffset - oldOffset; in read()
105 amount = AAsset_read(mAAsset, buffer, size); in read()
108 if (amount < 0) { in read()
109 amount = 0; in read()
111 return amount; in read()
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/notification/
DNotificationUtils.java50 public static float interpolate(float start, float end, float amount) { in interpolate() argument
51 return start * (1.0f - amount) + end * amount; in interpolate()
54 public static int interpolateColors(int startColor, int endColor, float amount) { in interpolateColors() argument
56 (int) interpolate(Color.alpha(startColor), Color.alpha(endColor), amount), in interpolateColors()
57 (int) interpolate(Color.red(startColor), Color.red(endColor), amount), in interpolateColors()
58 (int) interpolate(Color.green(startColor), Color.green(endColor), amount), in interpolateColors()
59 (int) interpolate(Color.blue(startColor), Color.blue(endColor), amount)); in interpolateColors()
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/
DLightRevealScrim.kt34 fun setRevealAmountOnScrim(amount: Float, scrim: LightRevealScrim) in setRevealAmountOnScrim()
73 override fun setRevealAmountOnScrim(amount: Float, scrim: LightRevealScrim) { in setRevealAmountOnScrim()
74 val interpolatedAmount = INTERPOLATOR.getInterpolation(amount) in setRevealAmountOnScrim()
82 1f - getPercentPastThreshold(amount, FADE_END_COLOR_OUT_THRESHOLD) in setRevealAmountOnScrim()
104 override fun setRevealAmountOnScrim(amount: Float, scrim: LightRevealScrim) { in setRevealAmountOnScrim()
105 val interpolatedAmount = interpolator.getInterpolation(amount) in setRevealAmountOnScrim()
161 override fun setRevealAmountOnScrim(amount: Float, scrim: LightRevealScrim) { in setRevealAmountOnScrim()
162 scrim.interpolatedRevealAmount = amount in setRevealAmountOnScrim()
164 getPercentPastThreshold(1 - amount, threshold = 1 - START_COLOR_REVEAL_PERCENTAGE) in setRevealAmountOnScrim()
168 amount, in setRevealAmountOnScrim()
[all …]
/frameworks/libs/systemui/toruslib/torus-math/src/main/java/com/google/android/torus/math/
DMathUtils.kt115 fun lerp(start: Double, end: Double, amount: Double, clamp: Boolean = true): Double { in lerp()
117 clamp(amount, 0.0, 1.0) in lerp()
119 amount in lerp()
141 fun lerp(init: Float, end: Float, amount: Float, clamp: Boolean = true): Float { in lerp()
143 clamp(amount, 0.0f, 1.0f) in lerp()
145 amount in lerp()
/frameworks/libs/systemui/weathereffects/graphics/src/main/java/com/google/android/wallpaper/weathereffects/graphics/utils/
DMathUtils.kt110 fun lerp(start: Double, end: Double, amount: Double, clamp: Boolean = true): Double { in lerp()
113 clamp(amount, 0.0, 1.0) in lerp()
115 amount in lerp()
136 fun lerp(init: Float, end: Float, amount: Float, clamp: Boolean = true): Float { in lerp()
139 clamp(amount, 0.0f, 1.0f) in lerp()
141 amount in lerp()
/frameworks/libs/modules-utils/java/com/android/modules/expresslog/
DCounter.java49 public static void logIncrement(@NonNull String metricId, long amount) { in logIncrement() argument
52 StatsExpressLog.write(StatsExpressLog.EXPRESS_EVENT_REPORTED, metricIdHash, amount); in logIncrement()
61 public static void logIncrementWithUid(@NonNull String metricId, int uid, long amount) { in logIncrementWithUid() argument
65 StatsExpressLog.EXPRESS_UID_EVENT_REPORTED, metricIdHash, amount, uid); in logIncrementWithUid()
/frameworks/base/libs/hwui/jni/
DUtils.cpp89 ssize_t amount; in read() local
108 amount = newOffset - oldOffset; in read()
110 amount = fAsset->read(buffer, size); in read()
113 if (amount < 0) { in read()
114 amount = 0; in read()
116 return amount; in read()
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/touch/
DOverScroll.java44 public static int dampedScroll(float amount, int max) { in dampedScroll() argument
45 if (Float.compare(amount, 0) == 0) return 0; in dampedScroll()
47 float f = amount / max; in dampedScroll()
/frameworks/base/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/animation/
DOverScroll.java44 public static int dampedScroll(float amount, int max) { in dampedScroll() argument
45 if (Float.compare(amount, 0) == 0) return 0; in dampedScroll()
47 float f = amount / max; in dampedScroll()
/frameworks/base/tools/aapt2/text/
DUtf8Iterator.cpp50 void Utf8Iterator::Skip(int amount) { in Skip() argument
51 while (amount > 0 && HasNext()) { in Skip()
53 --amount; in Skip()
/frameworks/base/core/java/android/util/proto/
DEncodedBuffer.java173 public void skipRead(int amount) { in skipRead() argument
174 if (amount < 0) { in skipRead()
175 throw new RuntimeException("skipRead with negative amount=" + amount); in skipRead()
177 if (amount == 0) { in skipRead()
180 if (amount <= mChunkSize - mReadIndex) { in skipRead()
181 mReadIndex += amount; in skipRead()
183 amount -= mChunkSize - mReadIndex; in skipRead()
184 mReadIndex = amount % mChunkSize; in skipRead()
187 mReadBufIndex += (amount / mChunkSize); in skipRead()
189 mReadBufIndex += 1 + (amount / mChunkSize); in skipRead()
/frameworks/base/services/core/java/com/android/server/uri/
DUriMetricsHelper.java60 void reportPersistentUriFlushed(int amount) { in reportPersistentUriFlushed() argument
63 amount in reportPersistentUriFlushed()
86 final int amount = perUidCount.valueAt(i); in reportPersistentUriPermissionsPerPackage() local
92 amount in reportPersistentUriPermissionsPerPackage()
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/
DTouchAnimator.java226 float amount = (fraction - mFrameWidth * (i - 1)) / mFrameWidth; in setValue() local
227 interpolate(i, amount, target); in setValue()
230 protected abstract void interpolate(int index, float amount, Object target); in interpolate() argument
252 protected void interpolate(int index, float amount, Object target) { in interpolate() argument
255 mProperty.set((T) target, firstFloat + (secondFloat - firstFloat) * amount); in interpolate()
270 protected void interpolate(int index, float amount, Object target) { in interpolate() argument
273 mProperty.set((T) target, (int) (firstFloat + (secondFloat - firstFloat) * amount)); in interpolate()
/frameworks/base/packages/SystemUI/animation/src/com/android/systemui/surfaceeffects/utils/
DMathUtils.kt21 fun lerp(start: Float, stop: Float, amount: Float): Float { in lerp()
22 return start + (stop - start) * amount in lerp()
/frameworks/base/packages/SystemUI/src/com/android/systemui/navigationbar/gestural/
DBackPanel.kt263 fun stretchBy(finalPosition: Float?, amount: Float) { in stretchBy()
264 val stretchedAmount = amount * ((finalPosition ?: 0f) - restingPosition) in stretchBy()
334 amount = horizontalTranslationStretchAmount in setStretch()
338 amount = arrowStretchAmount in setStretch()
342 amount = arrowStretchAmount in setStretch()
346 amount = arrowAlphaStretchAmount in setStretch()
350 amount = backgroundAlphaStretchAmount in setStretch()
354 amount = backgroundWidthStretchAmount in setStretch()
358 amount = backgroundHeightStretchAmount in setStretch()
362 amount = edgeCornerStretchAmount in setStretch()
[all …]
/frameworks/base/core/java/com/android/internal/widget/
DOrientationHelper.java176 public abstract void offsetChildren(int amount); in offsetChildren() argument
263 public void offsetChildren(int amount) { in createHorizontalHelper() argument
264 mLayoutManager.offsetChildrenHorizontal(amount); in createHorizontalHelper()
361 public void offsetChildren(int amount) {
362 mLayoutManager.offsetChildrenVertical(amount);
/frameworks/base/tests/graphics/SilkFX/src/com/android/test/silkfx/materials/
DBackgroundBlurActivity.kt156 fun setDimAmount(amount: Float) { in <lambda>()
158 mDimAmountWithBlur = amount in <lambda>()
160 mDimAmountNoBlur = amount in <lambda>()
162 (requireViewById(R.id.dim_amount) as TextView).setText("%.2f".format(amount)) in <lambda>()
163 window.getAttributes().dimAmount = amount in <lambda>()
/frameworks/base/packages/SystemUI/src/com/android/systemui/keyguard/ui/binder/
DLightRevealScrimViewBinder.kt33 viewModel.revealAmount.collect { amount -> revealScrim.revealAmount = amount } in <lambda>() method

12345