Changeset 1a74ac3 for src/mathutils.c
- Timestamp:
- Feb 4, 2011, 10:26:10 AM (13 years ago)
- Branches:
- feature/autosink, feature/cnn, feature/cnn_org, feature/constantq, feature/crepe, feature/crepe_org, feature/pitchshift, feature/pydocstrings, feature/timestretch, fix/ffmpeg5, master, pitchshift, sampler, timestretch, yinfft+
- Children:
- 34422b4, 42515ac
- Parents:
- b583b9fb
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/mathutils.c
rb583b9fb r1a74ac3 215 215 energy += SQR (f->data[j]); 216 216 } 217 return energy ;217 return energy / f->length; 218 218 } 219 219 … … 450 450 aubio_db_spl (fvec_t * o) 451 451 { 452 smpl_t val = SQRT (fvec_local_energy (o)); 453 val /= (smpl_t) o->length; 454 return LIN2DB (val); 452 return 10. * LOG10 (fvec_local_energy (o)); 455 453 } 456 454
Note: See TracChangeset
for help on using the changeset viewer.