Home | History | Annotate | Download | only in itf

Lines Matching defs:band

145 static SLresult IEqualizer_SetBandLevel(SLEqualizerItf self, SLuint16 band, SLmillibel level)
151 (band >= thiz->mNumBands)) {
156 thiz->mLevels[band] = level;
164 android_eq_setParam(thiz->mEqEffect, EQ_PARAM_BAND_LEVEL, band, &level);
175 static SLresult IEqualizer_GetBandLevel(SLEqualizerItf self, SLuint16 band, SLmillibel *pLevel)
184 if (band >= thiz->mNumBands) {
190 level = thiz->mLevels[band];
197 android_eq_getParam(thiz->mEqEffect, EQ_PARAM_BAND_LEVEL, band, &level);
210 static SLresult IEqualizer_GetCenterFreq(SLEqualizerItf self, SLuint16 band, SLmilliHertz *pCenter)
218 if (band >= thiz->mNumBands) {
223 *pCenter = thiz->mBands[band].mCenter;
232 android_eq_getParam(thiz->mEqEffect, EQ_PARAM_CENTER_FREQ, band, &center);
245 static SLresult IEqualizer_GetBandFreqRange(SLEqualizerItf self, SLuint16 band,
254 if (band >= thiz->mNumBands) {
260 *pMin = thiz->mBands[band].mMin;
262 *pMax = thiz->mBands[band].mMax;
271 android_eq_getParam(thiz->mEqEffect, EQ_PARAM_BAND_FREQ_RANGE, band, range);
298 // search for band whose center frequency has the closest ratio to 1.0
302 const struct EqualizerBand *band;
306 for (band = thiz->mBands; band < &thiz->mBands[thiz->mNumBands]; ++band) {
307 if (!(band->mMin <= frequency && frequency <= band->mMax))
309 assert(band->mMin <= band->mCenter && band->mCenter <= band->mMax);
310 assert(band->mCenter != 0);
311 float ratio = frequency <= band->mCenter ?
312 floatFreq / band->mCenter : band->mCenter / floatFreq;
315 bestBand = band - thiz->mBands;
321 uint16_t band = 0;
327 android_eq_getParam(thiz->mEqEffect, EQ_PARAM_GET_BAND, frequency, &band);
331 *pBand = (SLuint16)band;
384 SLuint16 band;
385 for (band = 0; band < thiz->mNumBands; ++band)
386 thiz->mLevels[band] = EqualizerPresets[index].mLevels[band];
480 unsigned band;
481 for (band = 0; band < MAX_EQ_BANDS; ++band)
482 thiz->mLevels[band] = 0;