Searched refs:amount (Results 1 - 25 of 45) sorted by relevance

12

/frameworks/support/design/base/android/support/design/widget/
H A DMathUtils.java21 static int constrain(int amount, int low, int high) { argument
22 return amount < low ? low : (amount > high ? high : amount);
25 static float constrain(float amount, float low, float high) { argument
26 return amount < low ? low : (amount > high ? high : amount);
/frameworks/rs/driver/runtime/arch/
H A 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
[all...]
H A Dgeneric.c20 extern short __attribute__((overloadable, always_inline)) rsClamp(short amount, short low, short high);
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
[all...]
/frameworks/rs/cpu_ref/
H A DrsCpuIntrinsicInlines.h85 static inline int4 clamp(int4 amount, int low, int high) { argument
87 r.x = amount.x < low ? low : (amount.x > high ? high : amount.x);
88 r.y = amount.y < low ? low : (amount.y > high ? high : amount.y);
89 r.z = amount.z < low ? low : (amount.z > high ? high : amount
94 clamp(float4 amount, float low, float high) argument
103 clamp(int2 amount, int low, int high) argument
110 clamp(float2 amount, float low, float high) argument
117 clamp(int amount, int low, int high) argument
121 clamp(float amount, float low, float high) argument
[all...]
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/notification/
H A DNotificationUtils.java43 public static float interpolate(float start, float end, float amount) { argument
44 return start * (1.0f - amount) + end * amount;
47 public static int interpolateColors(int startColor, int endColor, float amount) { argument
49 (int) interpolate(Color.alpha(startColor), Color.alpha(endColor), amount),
50 (int) interpolate(Color.red(startColor), Color.red(endColor), amount),
51 (int) interpolate(Color.green(startColor), Color.green(endColor), amount),
52 (int) interpolate(Color.blue(startColor), Color.blue(endColor), amount));
/frameworks/base/core/jni/android/graphics/
H A DUtils.cpp53 ssize_t amount; local
60 // we want to return amount that was skipped
72 amount = newOffset - oldOffset;
74 amount = fAsset->read(buffer, size);
75 if (amount <= 0) {
76 SkDebugf("---- fAsset->read(%d) returned %d\n", size, amount);
80 if (amount < 0) {
81 amount = 0;
83 return amount;
H A DCreateJavaOutputStreamAdaptor.cpp39 size_t amount = this->doSkip(size - amountSkipped); local
40 if (0 == amount) {
42 amount = this->doRead(&tmp, 1);
43 if (0 == amount) {
49 amountSkipped += amount;
/frameworks/base/services/core/java/com/android/server/twilight/
H A DTwilightState.java30 TwilightState(boolean isNight, float amount) { argument
32 mAmount = amount;
43 * For twilight affects that change gradually over time, this is the amount they
H A DTwilightService.java63 // The amount of time after or before sunrise over which to start adjusting
73 public static final String EXTRA_AMOUNT = "amount";
500 float amount = 0;
503 amount = 1;
505 amount = Math.min(1, (now - todaySunset) / (float) TWILIGHT_ADJUSTMENT_TIME);
507 amount = Math.max(0, 1
512 TwilightState state = new TwilightState(isNight, amount);
527 if (amount == 1 || amount == 0) {
/frameworks/base/core/java/android/util/
H A DMathUtils.java38 public static int constrain(int amount, int low, int high) { argument
39 return amount < low ? low : (amount > high ? high : amount);
42 public static long constrain(long amount, long low, long high) { argument
43 return amount < low ? low : (amount > high ? high : amount);
46 public static float constrain(float amount, float low, float high) { argument
47 return amount < lo
155 lerp(float start, float stop, float amount) argument
175 lerpDeg(float start, float end, float amount) argument
[all...]
/frameworks/base/tools/aapt/
H A DIndentPrinter.h13 void indent(int amount = 1) {
14 mIndent += amount;
/frameworks/base/libs/hwui/
H A DGradientCache.cpp196 void GradientCache::mixBytes(GradientColor& start, GradientColor& end, float amount, argument
198 float oppAmount = 1.0f - amount;
199 const float alpha = start.a * oppAmount + end.a * amount;
202 *dst++ = uint8_t(a * (start.r * oppAmount + end.r * amount));
203 *dst++ = uint8_t(a * (start.g * oppAmount + end.g * amount));
204 *dst++ = uint8_t(a * (start.b * oppAmount + end.b * amount));
208 void GradientCache::mixFloats(GradientColor& start, GradientColor& end, float amount, argument
210 float oppAmount = 1.0f - amount;
211 const float a = start.a * oppAmount + end.a * amount;
214 *d++ = a * (start.r * oppAmount + end.r * amount);
262 float amount = (pos - startPos) / distance; local
[all...]
H A DUvMapper.h115 static float lerp(float start, float stop, float amount) { argument
116 return start + (stop - start) * amount;
H A DCaches.cpp145 uint32_t Caches::getOverdrawColor(uint32_t amount) const {
150 if (amount < 1) amount = 1;
151 if (amount > 4) amount = 4;
154 return sOverdrawColors[overdrawColorIndex][amount - 1];
H A DGradientCache.h168 float amount, uint8_t*& dst) const;
170 void mixBytes(GradientColor& start, GradientColor& end, float amount, uint8_t*& dst) const;
171 void mixFloats(GradientColor& start, GradientColor& end, float amount, uint8_t*& dst) const;
H A DCaches.h112 * amount of overdraw (1 for 1x, 2 for 2x, etc.)
114 uint32_t getOverdrawColor(uint32_t amount) const;
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/stack/
H A DAmbientState.java108 public void setOverScrollAmount(float amount, boolean onTop) { argument
110 mOverScrollTopAmount = amount;
112 mOverScrollBottomAmount = amount;
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/hotspot2/omadm/
H A DOMAConstants.java67 int amount = in.read(octets, offset, octets.length - offset);
68 if (amount <= 0)
70 offset += amount;
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/
H A DTouchAnimator.java28 * but can have a float input as to the amount they should be in effect. This allows
215 float amount = fraction / mFrameWidth;
216 interpolate(i, amount, target);
219 protected abstract void interpolate(int index, float amount, Object target); argument
241 protected void interpolate(int index, float amount, Object target) { argument
244 mProperty.set((T) target, firstFloat + (secondFloat - firstFloat) * amount);
259 protected void interpolate(int index, float amount, Object target) { argument
262 mProperty.set((T) target, (int) (firstFloat + (secondFloat - firstFloat) * amount));
/frameworks/base/services/core/java/com/android/server/display/
H A DRampAnimator.java148 final float amount = timeDelta * mRate / scale;
150 mAnimatedValue = Math.min(mAnimatedValue + amount, mTargetValue);
152 mAnimatedValue = Math.max(mAnimatedValue - amount, mTargetValue);
/frameworks/base/packages/Osu/src/com/android/hotspot2/utils/
H A DHTTPResponse.java38 int amount = in.read(input, offset, input.length - offset);
39 Log.d(OSUManager.TAG, String.format("Reading into %d from %d, amount %d -> %d",
40 input.length, offset, input.length - offset, amount));
41 if (amount < 0) {
45 // + new String(input, 0, offset + amount, StandardCharsets.ISO_8859_1));
48 for (int n = offset; n < offset + amount; n++) {
61 offset += amount;
/frameworks/support/v7/recyclerview/src/android/support/v7/widget/
H A DOrientationHelper.java172 * Offsets all children's positions by the given amount.
174 * @param amount Value to add to each child's layout parameters
176 public abstract void offsetChildren(int amount); argument
190 * @param offset offset amount
263 public void offsetChildren(int amount) {
264 mLayoutManager.offsetChildrenHorizontal(amount);
361 public void offsetChildren(int amount) {
362 mLayoutManager.offsetChildrenVertical(amount);
/frameworks/base/core/java/android/text/method/
H A DBaseMovementMethod.java462 * @param amount The number of characters to scroll by. Must be at least 1.
466 protected boolean scrollLeft(TextView widget, Spannable buffer, int amount) { argument
470 scrollX = Math.max(scrollX - getCharacterWidth(widget) * amount, minScrollX);
483 * @param amount The number of characters to scroll by. Must be at least 1.
487 protected boolean scrollRight(TextView widget, Spannable buffer, int amount) { argument
491 scrollX = Math.min(scrollX + getCharacterWidth(widget) * amount, maxScrollX);
504 * @param amount The number of lines to scroll by. Must be at least 1.
508 protected boolean scrollUp(TextView widget, Spannable buffer, int amount) { argument
518 topLine = Math.max(topLine - amount + 1, 0);
531 * @param amount Th
535 scrollDown(TextView widget, Spannable buffer, int amount) argument
[all...]
/frameworks/support/v4/java/android/support/v4/graphics/
H A DColorUtils.java516 private static float constrain(float amount, float low, float high) { argument
517 return amount < low ? low : (amount > high ? high : amount);
520 private static int constrain(int amount, int low, int high) { argument
521 return amount < low ? low : (amount > high ? high : amount);
/frameworks/base/packages/Osu/src/com/android/hotspot2/omadm/
H A DOMAConstants.java139 int amount = in.read(octets, offset, octets.length - offset);
140 if (amount <= 0)
142 offset += amount;

Completed in 3449 milliseconds

12