A fork of audio-analyzer-for-android in Google code, with a lot of enhancement.

Overview

Audio Spectrum Analyzer for Android

A fork of Audio spectrum Analyzer for Android (See README.old for its original readme)

This software shows the frequency components' magnitude distribution (called spectrum) of the sound heard by your cell phone. Can be used to help tuning musical instrument or tone in singing, (tentative) measure environmental noise and sound revent education or experiments.

Get it on F-Droid

Features

  • Show spectrum or spectrogram in real-time, with decent axis labels.
  • Linear, Logarithm and (Musical) Note frequency axis support.
  • You can put a cursor in the plot, for measurement or as a marker.
  • Easy gestures to fine exam the spectrum: i.e. pinch for scaling and swipe for view move.
  • Show peak frequency in a moderate accuracy (FFT + interpolation).
  • Show dB or A-weighting dB (dBA), although not suitable for serious application.
  • Possible to take averages of several spectrum then plot, make the spectrum smoother.
  • You may record the sound (while analyzing!) to a WAV file (PCM format). Then you can deal with it with your favorite tool.
  • Support all recorder sources except those need root privilege (see list in Android reference: MediaRecorder.AudioSource)
  • Support all possible sampling rates that your phone is capable. e.g. useful to find out the native (or best) sampling format for you phone.

Permissions

  • Microphone, of course.
  • External storage (e.g MicroSD card), if you want to record the sound.

Privacy

Information we collect and you share

This app does not send any personal or non-personal information in any form over network.

Only with user's permission and explicit order, this app can store microphone data on the user's device.

Data processing

The permission to read microphone is required because that is the essential data this app needs to compute and display the spectrum and spectrogram.

The permission to read and write storage is for saving microphone data (in WAV PCM format) only and is optional. This is provided for convenience of user (e.g. user might want to use another app to process the recorded data). It is user's responsibility to remove the recorded data if they are no longer needed.

License

This software, Audio Spectrum Analyzer for Android, is released under the Apache License, Version 2.0.

Copyright thinkingcow, bewantbe, woheller69

Code structure

The whole program structure is roughly follows the MVC model:

AnalyzerActivity.java is the controler, as the main activity, it receives user inputs and system events, then sent corresponding commands to views or sampling and analyzing procedures.

AnalyzerViews.java is the view in MVC. It is used to manage (initialization, display, refresh) UI texts, buttons, dialogs and graphics. AnalyzerGraphic.java is a main sub-view which manage display of spectrum(SpectrumPlot.java) and spectrogram(SpectrogramPlot.java).

SamplingLoop.java is more or less the "model" part. It performs the sampling and FFT analysis, and inform the graphics update.

Processing of audio samples

The data process loop is located in run() in SamplingLoop.java (after commit c9e430b (Feb 06, 2017), but basicly this process didn't change since the initial commit), as well as the trigger of graphics refresh.

In every loop of while (isRunning), it reads a chunk of audio samples by

record.read(audioSamples, 0, readChunkSize);

, then "stream" it to STFT.java by

stft.feedData(audioSamples, numOfReadShort);

which calculates RMS and FFT whenever enough data is collected. The view is then informed through

activity.analyzerViews.update(spectrumDBcopy);

which ultimately calls invalidate() of the graphic view to request an update, then the AnalyzerGraphic.onDraw(Canvas c) will be called automatically.

Try my other apps

RadarWeather Gas Prices Smart Eggtimer Level hEARtest GPS Cockpit Audio Analyzer
You might also like...
Song lyrics ... turned code, regardless of the language.

Song lyrics ... turned code, regardless of the language. Just browse the src folder, pick the artist, select a song from the artist, and follow throug

mpv-android is a video player for Android based on libmpv.

mpv-android is a video player for Android based on libmpv.

FFmpeg compiled for Android. Execute FFmpeg commands with ease in your Android app.
FFmpeg compiled for Android. Execute FFmpeg commands with ease in your Android app.

FFMPEG video operations FFmpeg compiled for Android. Execute FFmpeg commands with ease in your Android app. Getting Started This project is provide in

Echo is a lightweight and minimal music player for Android, built with Android Studio and written in Kotlin
Echo is a lightweight and minimal music player for Android, built with Android Studio and written in Kotlin

Echo - Echo, A light-weight, minimal music player for Android, with shuffle, favorites and audio visualization

Youtube Android Clone 🚀an Android Youtube Clone made out of XML and Kotlin
Youtube Android Clone 🚀an Android Youtube Clone made out of XML and Kotlin

Youtube Android Clone 🚀 This app consumes The Youtube Api to fetch and display a list of popular videos, The app uses MVVM design pattern to allow se

An extensible media player for Android

ExoPlayer ExoPlayer is an application level media player for Android. It provides an alternative to Android’s MediaPlayer API for playing audio and vi

Android/iOS video player based on FFmpeg n3.4, with MediaCodec, VideoToolbox support.

ijkplayer Platform Build Status Android iOS Video player based on ffplay Download Android: Gradle # required allprojects { repositories {

Custom Android view with video player, loader and placeholder image
Custom Android view with video player, loader and placeholder image

VideoPlayerView Custom Android view with video player, loader and placeholder image. To stay up-to-date with news about the library Usage Here is an e

This is a project designed to help controlling Android MediaPlayer class. It makes it easier to use MediaPlayer ListView and RecyclerView. Also it tracks the most visible item in scrolling list. When new item in the list become the most visible, this library gives an API to track it.
Comments
  • FFT Window Length and Time Window overlap

    FFT Window Length and Time Window overlap

    Hi! First of all, a big thank you for developing this app. In fact, it has all the funtions I've been looking for for years.

    Nevertheless, I would like to ask if it would be possible to extend two functions:

    1. FFT Window Length: there are currently settings of 512 - 32768 possible. Would it be possible to add 128-256 (or even 64)? When analysing recordings of birds, these settings are often essential to be able to recognize details.
    2. Time window overlap: Currently there are settings from 0-87.5%. Would even higher values be possible here? This feature is not as relevant as the first point, though.

    Thanks again for the great app! Best wishes, Ralph

    opened by RalphMOekoFor 9
  • Add support for zero padding

    Add support for zero padding

    Ich wollte mal vorsichtig fragen, ob Sie vielleicht ein bestimmtes kleines Feature einbauen könnten, nämlich Zero Padding um das 2^N fache der Fensterlänge. Bspw. bei einem 1024 Sample Fensterlänge und N=3, also 8-fach, einfach die ersten 1024 Sample hinten mit Nullen auf 8192 Sample auffüllen. Das erhöht nämlich die (scheinbare?) Auflösung im Spektrogramm, ohne dass es über einen endlos langen Zeitbereich verschmiert ist. Das ist besonders bei musikalischen Anwendungsfällen und tieferen Frequenzen ein großer Gewinn.

    Wenn irgendwo Frequenzantworten von Fensterfunktionen dargestellt werden, wird ĂĽbrigens die selbe Methode verwendet. Dadurch kann man dann auch sehr gut sehen, ob und wo der genaue Peak zwischen zwei Bins liegt, wenn die Fensterfunktion einen Schmalen Peak hat (i.e. Rechteckfenster vs. Flat-Top-Fenster mit sehr breitem Peak).

    opened by woheller69 7
  • Feature request: screenshot button

    Feature request: screenshot button

    If I press the side buttons on my Android to create a screenshot, this will generate noise visible in the spectrogram.

    Maybe there can be a small camera or "save" icon somewhere to save the current display?

    opened by lucasteinke 2
  • Document how the

    Document how the "load calibration" menu function works and how to use it

    Hi, thanks for creating this cool application and making it FOSS.

    I assume the function ⋮ → Load calibration is for loading a sine wave to calibrate the microphone to the frequencies which can then be displayed?

    How do I generate such a sine wave? How should the file look like?

    opened by lucasteinke 2
Releases(V2.1)
Owner
null
Audio Tagger library for Flutter (Android only)

audio_tagger A Flutter (Android only) plugin for editing and extracting information from your music, at the moment it only works on AAC and OGG (last

SongTube 3 Apr 15, 2022
Silky - Android application to convert videos from applications such as YouTube, Facebook, Twitter into audio (.mp3)

Silky Español (actualmente la app se encuentra en desarrollo ) Descripcion Aplic

null 2 Aug 24, 2022
Video/Audio Downloader for Android, written with Jetpack Compose.

Seal Video/Audio Downloader for Android, written with Jetpack Compose.

junkfood 2.1k Dec 29, 2022
A radio player mobile application which streams audio from Radio Sai Global Harmony.

A radio player mobile application which streams audio from Radio Sai Global Harmony.

Sai Rajendra Immadi 11 Nov 26, 2022
Fermata Media Player is a free, open source audio and video player with a simple and intuitive interface.

Fermata Media Player About Fermata Media Player is a free, open source audio and video player with a simple and intuitive interface. It is focused on

Andrey 227 Jan 6, 2023
Fork of kord, mainly used for Voice

Kord Kord is still in an experimental stage, as such we can't guarantee API stability between releases. While we'd love for you to try out our library

Mixtape OSS 4 Jun 7, 2022
Radio Player - A Flutter plugin to play streaming audio content with background support and lock screen controls.

A Flutter plugin to play streaming audio content with background support and lock screen controls. Installation To use this package, add

Ayotunde abdulsalam 1 Mar 14, 2022
Android Application that plays music through a Spotify API based on a user's current location found through Google Maps API and also checking Google Weather API.

GeoStereo Android Application that plays music through a Spotify API based on a user's current location found through Google Maps API and also checkin

Jonah Douglas 1 Jun 16, 2022
Google's ML-Kit-Vision demo (android) for pre encoded video.

Google's ML-Kit-Vision demo (android) for pre encoded video. Demos for camera preview and still image are also included. This project is actually extension of Google's own sample.

null 17 Dec 29, 2022
Music Player: From UI Proposal to Code

Some developers have difficult to code when the UI proposal is a bit “sophisticated” or “complex”. Many of them strip a lot of significant portion of the UI or even the Motion when they are coding, and the result ends up quite different of the original proposal.

André Mion 3.5k Dec 28, 2022