Home
last modified time | relevance | path

Searched refs:getAmplitude (Results 1 – 15 of 15) sorted by relevance

/frameworks/base/core/tests/vibrator/src/android/os/vibrator/
DStepSegmentTest.java44 assertEquals(1f, step.getAmplitude()); in testCreation()
80 assertEquals(1f, original.resolve(VibrationEffect.MAX_AMPLITUDE).getAmplitude()); in testResolve()
81 assertEquals(0.2f, original.resolve(51).getAmplitude(), TOLERANCE); in testResolve()
99 assertEquals(1f, initial.scale(1).getAmplitude(), TOLERANCE); in testScale_fullAmplitude()
100 assertEquals(0.34f, initial.scale(0.5f).getAmplitude(), TOLERANCE); in testScale_fullAmplitude()
102 assertEquals(1f, initial.scale(1.5f).getAmplitude(), TOLERANCE); in testScale_fullAmplitude()
103 assertEquals(0.53f, initial.scale(1.5f).scale(2 / 3f).getAmplitude(), TOLERANCE); in testScale_fullAmplitude()
105 assertEquals(0.71f, initial.scale(0.8f).getAmplitude(), TOLERANCE); in testScale_fullAmplitude()
106 assertEquals(0.84f, initial.scale(0.8f).scale(1.25f).getAmplitude(), TOLERANCE); in testScale_fullAmplitude()
113 assertEquals(0.5f, initial.scale(1).getAmplitude(), TOLERANCE); in testScale_halfAmplitude()
[all …]
/frameworks/base/services/tests/vibrator/src/com/android/server/vibrator/
DVibrationScalerTest.java243 assertTrue(resolved.getAmplitude() > 0); in scale_withOneShotAndWaveform_resolvesAmplitude()
249 assertTrue(resolved.getAmplitude() > 0); in scale_withOneShotAndWaveform_resolvesAmplitude()
264 assertTrue(scaled.getAmplitude() > 0.5); in scale_withOneShotAndWaveform_scalesAmplitude()
270 assertTrue(scaled.getAmplitude() < 0.5); in scale_withOneShotAndWaveform_scalesAmplitude()
275 assertEquals(128f / 255, scaled.getAmplitude(), 1e-5); in scale_withOneShotAndWaveform_scalesAmplitude()
315 assertTrue(scaled.getAmplitude() < 0.5);
321 assertTrue(scaled.getAmplitude() < 0.5);
337 assertTrue(scaled.getAmplitude() > 0.5);
343 assertTrue(scaled.getAmplitude() > 0.5);
359 assertTrue(scaled.getAmplitude() < 0.5);
[all …]
/frameworks/base/services/core/java/com/android/server/vibrator/
DRampDownAdapter.java92 float previousAmplitude = ((StepSegment) previousSegment).getAmplitude(); in addRampDownToZeroAmplitudeSegments()
179 float previousAmplitude = ((StepSegment) lastSegment).getAmplitude(); in addRampDownToLoop()
220 return new StepSegment(step.getAmplitude(), step.getFrequencyHz(), (int) newDuration); in updateDuration()
229 return ramp.getAmplitude() == 0; in isOffSegment()
240 return ((StepSegment) segment).getAmplitude() != 0; in endsWithNonZeroAmplitude()
DStepToRampAdapter.java70 return new RampSegment(segment.getAmplitude(), segment.getAmplitude(), in convertStepToRamp()
DSetAmplitudeVibratorStep.java108 float amplitude = stepSegment.getAmplitude(); in play()
184 || (segment.getDuration() > 0 && ((StepSegment) segment).getAmplitude() == 0)) { in getVibratorOnDuration()
DVibration.java427 proto.write(StepSegmentProto.AMPLITUDE, segment.getAmplitude()); in dumpEffect()
/frameworks/base/core/tests/vibrator/src/android/os/
DVibrationEffectTest.java638 assertEquals(0.2f, ((StepSegment) resolved.getSegments().get(0)).getAmplitude()); in testResolveOneShot()
646 assertEquals(0.4f, ((StepSegment) resolved.getSegments().get(2)).getAmplitude()); in testResolveWaveform()
668 assertEquals(0.2f, ((StepSegment) resolved.getSegments().get(0)).getAmplitude()); in testResolveComposed()
674 assertTrue(100 / 255f < ((StepSegment) scaledUp.getSegments().get(0)).getAmplitude()); in testScaleOneShot()
677 assertTrue(100 / 255f > ((StepSegment) scaledDown.getSegments().get(0)).getAmplitude()); in testScaleOneShot()
683 assertEquals(1f, ((StepSegment) scaledUp.getSegments().get(0)).getAmplitude(), 1e-5f); in testScaleWaveform()
686 assertTrue(1f > ((StepSegment) scaledDown.getSegments().get(0)).getAmplitude()); in testScaleWaveform()
710 assertTrue(100 / 255f < ((StepSegment) scaledUp.getSegments().get(1)).getAmplitude()); in testScaleComposed()
714 assertTrue(100 / 255f > ((StepSegment) scaledDown.getSegments().get(1)).getAmplitude()); in testScaleComposed()
/frameworks/av/media/libaaudio/examples/utils/
DSineGenerator.h99 double getAmplitude() const { in getAmplitude() function
/frameworks/base/core/java/android/os/vibrator/
DStepSegment.java70 public float getAmplitude() { in getAmplitude() method in StepSegment
/frameworks/base/core/java/com/android/internal/vibrator/persistence/
DVibrationEffectXmlSerializer.java120 segment.getDuration(), toAmplitudeInt(segment.getAmplitude())); in serializeWaveformEffect()
/frameworks/base/core/xsd/vibrator/vibration/schema/
Dcurrent.txt74 method public String getAmplitude();
/frameworks/base/core/java/android/os/
DVibrationEffect.java772 boolean isSegmentOff = stepSegment.getAmplitude() == 0; in computeCreateWaveformOffOnTimingsOrNull()
1007 float amplitude = stepSegment.getAmplitude(); in castToValidStepSegmentForOffOnTimingsOrNull()
/frameworks/base/services/core/java/com/android/server/input/
DInputManagerService.java1364 float amplitude = ((StepSegment) segment).getAmplitude(); in VibrationInfo()
/frameworks/base/core/api/
Dtest-current.txt2737 method public float getAmplitude();
/frameworks/base/boot/hiddenapi/
Dhiddenapi-max-target-o.txt39478 Landroid/os/VibrationEffect$OneShot;->getAmplitude()I