/frameworks/base/services/tests/servicestests/src/com/android/server/notification/ |
H A D | RateEstimatorTest.java | 41 final float rate = mEstimator.getRate(mTestStartTime - 1000L); 42 assertFalse(Float.isInfinite(rate)); 43 assertFalse(Float.isNaN(rate)); 56 final float rate = mEstimator.getRate(mTestStartTime); 57 assertFalse(Float.isInfinite(rate)); 58 assertFalse(Float.isNaN(rate)); 66 final float rate = mEstimator.getRate(nextEventTime); 67 assertLessThan("Rate", rate, 20f); 75 final float rate = mEstimator.getRate(nextEventTime); 76 assertLessThan("Rate", rate, 2 [all...] |
/frameworks/base/services/core/java/com/android/server/notification/ |
H A D | RateEstimator.java | 21 * Exponentially weighted moving average estimator for event rate. 38 float rate; 40 // No last event time, rate is zero. 41 rate = 0f; 45 rate = (float) (1.0 / mInterarrivalTime); 48 return rate; 51 /** @return the estimated rate if there were a new event right now. */
|
/frameworks/base/media/java/android/media/ |
H A D | MediaTimestamp.java | 21 * and the system time. It contains the media clock rate, together with the media timestamp 55 * Get the rate of the media clock in relation to the system time. 73 MediaTimestamp(long mediaUs, long systemNs, float rate) { argument 76 clockRate = rate;
|
/frameworks/base/core/java/android/view/ |
H A D | OrientationListener.java | 53 * @param rate at which sensor events are processed (see also 58 public OrientationListener(Context context, int rate) { argument 59 mOrientationEventLis = new OrientationEventListenerInternal(context, rate); 67 OrientationEventListenerInternal(Context context, int rate) { argument 68 super(context, rate);
|
/frameworks/wilhelm/src/itf/ |
H A D | IVisualization.c | 23 slVisualizationCallback callback, void *pContext, SLmilliHertz rate) 27 if (!(0 < rate && rate <= 20000)) { 34 thiz->mRate = rate; 22 IVisualization_RegisterVisualizationCallback(SLVisualizationItf self, slVisualizationCallback callback, void *pContext, SLmilliHertz rate) argument
|
H A D | IRatePitch.c | 22 static SLresult IRatePitch_SetRate(SLRatePitchItf self, SLpermille rate) argument 27 if (!(thiz->mMinRate <= rate && rate <= thiz->mMaxRate)) { 31 thiz->mRate = rate; 49 SLpermille rate = thiz->mRate; local 51 *pRate = rate;
|
H A D | IPlaybackRate.c | 22 static SLresult IPlaybackRate_SetRate(SLPlaybackRateItf self, SLpermille rate) argument 28 if (!(thiz->mMinRate <= rate && rate <= thiz->mMaxRate)) { 36 result = android_audioPlayer_setPlaybackRateAndConstraints(ap, rate, thiz->mProperties); 44 thiz->mRate = rate; 62 SLpermille rate = thiz->mRate; local 64 *pRate = rate; 128 SLpermille rate, SLuint32 *pCapabilities) 138 if (!(thiz->mMinRate <= rate && rate < 127 IPlaybackRate_GetCapabilitiesOfRate(SLPlaybackRateItf self, SLpermille rate, SLuint32 *pCapabilities) argument [all...] |
/frameworks/av/include/common_time/ |
H A D | local_clock.h | 37 status_t setLocalSlew(int16_t rate);
|
/frameworks/base/media/jni/ |
H A D | android_media_MediaSync.h | 45 status_t setPlaybackParams(const AudioPlaybackRate& rate); 46 void getPlaybackParams(AudioPlaybackRate* rate /* nonnull */); 49 status_t setVideoFrameRateHint(float rate);
|
/frameworks/ml/bordeaux/learning/multiclass_pa/native/ |
H A D | multiclass_pa.cpp | 118 // Compute the learning rate according to PA-I. 123 float rate = loss / twice_norm_square; local 124 if (rate > aggressiveness_) { 125 rate = aggressiveness_; 127 // VLOG(1) << "loss = " << loss << " rate = " << rate; 131 parameters_[target][i] += rate * inputs[i]; 133 parameters_[other_class][i] -= rate * inputs[i]; 151 // Compute the learning rate according to PA-I. 156 float rate local [all...] |
/frameworks/av/media/libstagefright/ |
H A D | MediaClock.cpp | 92 void MediaClock::setPlaybackRate(float rate) { argument 93 CHECK_GE(rate, 0.0); 96 mPlaybackRate = rate; 107 mPlaybackRate = rate;
|
H A D | MediaSync.cpp | 171 ALOGE("setAudioTrack: native sample rate should be positive."); 244 void MediaSync::updatePlaybackRate_l(float rate) { argument 245 if (rate > mPlaybackRate) { 248 mPlaybackRate = rate; 250 mMediaClock->setPlaybackRate(rate); 260 // User should check the playback rate if it doesn't want to receive a 286 "is too high, possibly due to super low playback rate(%f)", mPlaybackRate); 360 status_t MediaSync::setVideoFrameRateHint(float rate) { argument 362 if (rate < 0.f) { 366 mFrameScheduler->init(rate); 423 setPlaybackSettings(const AudioPlaybackRate &rate) argument 434 setPlaybackSettings_l(const AudioPlaybackRate &rate) argument 458 getPlaybackSettings(AudioPlaybackRate *rate) argument [all...] |
/frameworks/base/services/core/java/com/android/server/display/ |
H A D | RampAnimator.java | 25 * a given variable rate until it reaches a particular target value. 53 * If this is the first time the property is being set or if the rate is 0, 57 * @param rate The convergence rate in units per second, or 0 to set the value immediately. 60 public boolean animateTo(int target, int rate) { argument 62 if (mFirstTime || rate <= 0) { 81 // Adjust the rate based on the closest target. 82 // If a faster rate is specified, then use the new rate so that we converge 84 // If a slower rate i [all...] |
/frameworks/av/media/common_time/ |
H A D | local_clock.cpp | 73 status_t LocalClock::setLocalSlew(int16_t rate) { argument 79 return static_cast<status_t>(dev_->set_local_slew(dev_, rate));
|
/frameworks/av/include/media/stagefright/ |
H A D | MediaSync.h | 110 // Set the video frame rate hint - this is used by the video FrameScheduler 111 status_t setVideoFrameRateHint(float rate); 113 // Get the video frame rate measurement from the FrameScheduler 123 // Sets the playback rate using playback settings. 125 status_t setPlaybackSettings(const AudioPlaybackRate &rate); 127 // Gets the playback rate (playback settings parameters). 128 void getPlaybackSettings(AudioPlaybackRate *rate /* nonnull */); 269 // |rate| is the ratio between desired speed and the normal one, and should 270 // be non-negative. The meaning of rate values: 275 void updatePlaybackRate_l(float rate); [all...] |
H A D | MediaClock.h | 44 void setPlaybackRate(float rate);
|
H A D | AudioPlayer.h | 65 status_t setPlaybackRate(const AudioPlaybackRate &rate); 66 status_t getPlaybackRate(AudioPlaybackRate *rate /* nonnull */);
|
/frameworks/wilhelm/tests/mimeUri/ |
H A D | slesTestSlowDownUri.cpp | 71 SLpermille minRate, maxRate, stepSize, rate = 1000; local 75 SLresult res = (*pRateItf)->GetRate(pRateItf, &rate); CheckErr(res); 78 fprintf(stdout, "old rate = %d, minRate=%d, maxRate=%d\n", rate, minRate, maxRate); 79 rate /= 2; 80 if (rate < minRate) { 81 rate = minRate; 83 fprintf(stdout, "new rate = %d\n", rate); 84 res = (*pRateItf)->SetRate(pRateItf, rate); CheckEr 290 SLpermille rate = 1234; local [all...] |
/frameworks/base/media/tests/audiotests/ |
H A D | shared_mem_test.cpp | 77 long rate = 44100; local 84 f0 = pow(2., 32.) * freq / (float)rate; 99 rate,
|
/frameworks/base/media/java/android/media/audiopolicy/ |
H A D | AudioMix.java | 339 // FIXME Can we eliminate this? Will AudioMix work with an unspecified sample rate? 340 int rate = AudioSystem.getPrimaryOutputSamplingRate(); 341 if (rate <= 0) { 342 rate = 44100; 344 mFormat = new AudioFormat.Builder().setSampleRate(rate).build();
|
/frameworks/base/core/java/android/hardware/ |
H A D | LegacySensorManager.java | 89 public boolean registerListener(SensorListener listener, int sensors, int rate) { argument 95 Sensor.TYPE_ACCELEROMETER, listener, sensors, rate) || result; 97 Sensor.TYPE_MAGNETIC_FIELD, listener, sensors, rate) || result; 99 Sensor.TYPE_ORIENTATION, listener, sensors, rate) || result; 101 Sensor.TYPE_ORIENTATION, listener, sensors, rate) || result; 103 Sensor.TYPE_TEMPERATURE, listener, sensors, rate) || result; 108 SensorListener listener, int sensors, int rate) { 134 result = mSensorManager.registerListener(legacyListener, sensor, rate); 107 registerLegacyListener(int legacyType, int type, SensorListener listener, int sensors, int rate) argument
|
/frameworks/av/include/media/ |
H A D | MediaPlayerInterface.h | 141 virtual status_t setPlaybackRate(const AudioPlaybackRate& rate) = 0; 142 virtual status_t getPlaybackRate(AudioPlaybackRate* rate /* nonnull */) = 0; 183 virtual status_t setPlaybackSettings(const AudioPlaybackRate& rate) { argument 184 // by default, players only support setting rate to the default 185 if (!isAudioPlaybackRateEqual(rate, AUDIO_PLAYBACK_RATE_DEFAULT)) { 190 virtual status_t getPlaybackSettings(AudioPlaybackRate* rate /* nonnull */) { 191 *rate = AUDIO_PLAYBACK_RATE_DEFAULT;
|
/frameworks/base/media/jni/soundpool/ |
H A D | SoundPool.h | 92 float rightVolume, int priority, int loop, float rate); 99 float rate() { return mRate; } function in class:android::SoundEvent 121 int priority, int loop, float rate); 130 void setRate(float rate); 169 int loop, float rate); 178 void setRate(int channelID, float rate);
|
H A D | SoundPool.cpp | 250 int priority, int loop, float rate) 252 ALOGV("play sampleID=%d, leftVolume=%f, rightVolume=%f, priority=%d, loop=%d, rate=%f", 253 sampleID, leftVolume, rightVolume, priority, loop, rate); 283 channel->play(sample, channelID, leftVolume, rightVolume, priority, loop, rate); 422 void SoundPool::setRate(int channelID, float rate) argument 424 ALOGV("setRate(%d, %f)", channelID, rate); 428 channel->setRate(rate); 504 uint32_t *rate, int *numChannels, audio_format_t *audioFormat, 637 if (!AMediaFormat_getInt32(format, AMEDIAFORMAT_KEY_SAMPLE_RATE, (int32_t*) rate) || 674 ALOGE("Sample rate ( 249 play(int sampleID, float leftVolume, float rightVolume, int priority, int loop, float rate) argument 503 decode(int fd, int64_t offset, int64_t length, uint32_t *rate, int *numChannels, audio_format_t *audioFormat, sp<MemoryHeapBase> heap, size_t *memsize) argument 705 play(const sp<Sample>& sample, int nextChannelID, float leftVolume, float rightVolume, int priority, int loop, float rate) argument 833 float rate; local 1020 setRate(float rate) argument 1075 set(const sp<Sample>& sample, int channelID, float leftVolume, float rightVolume, int priority, int loop, float rate) argument [all...] |
/frameworks/av/media/libmedia/ |
H A D | IMediaPlayer.cpp | 184 status_t setPlaybackSettings(const AudioPlaybackRate& rate) argument 188 data.writeFloat(rate.mSpeed); 189 data.writeFloat(rate.mPitch); 190 data.writeInt32((int32_t)rate.mFallbackMode); 191 data.writeInt32((int32_t)rate.mStretchMode); 196 status_t getPlaybackSettings(AudioPlaybackRate* rate /* nonnull */) 203 *rate = AUDIO_PLAYBACK_RATE_DEFAULT; 204 rate->mSpeed = reply.readFloat(); 205 rate->mPitch = reply.readFloat(); 206 rate 524 AudioPlaybackRate rate = AUDIO_PLAYBACK_RATE_DEFAULT; local 534 AudioPlaybackRate rate = AUDIO_PLAYBACK_RATE_DEFAULT; local [all...] |