• Stars
    star
    1,622
  • Rank 28,851 (Top 0.6 %)
  • Language
    Java
  • Created over 8 years ago
  • Updated about 3 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A fancy audio recorder lib for Android. Supports WAV format at 48kHz.

Android Arsenal Release

AndroidAudioRecorder

A fancy audio recorder for Android. It supports WAV format at 48kHz.

Screenshots

Screenshots

How To Use

1 - Add these permissions into your AndroidManifest.xml and request for them in Android 6.0+

<uses-permission android:name="android.permission.RECORD_AUDIO"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.WAKE_LOCK" />

2 - Open the recorder activity

String filePath = Environment.getExternalStorageDirectory() + "/recorded_audio.wav";
int color = getResources().getColor(R.color.colorPrimaryDark);
int requestCode = 0;
AndroidAudioRecorder.with(this)
    // Required
    .setFilePath(filePath)
    .setColor(color)
    .setRequestCode(requestCode)
    
    // Optional
    .setSource(AudioSource.MIC)
    .setChannel(AudioChannel.STEREO)
    .setSampleRate(AudioSampleRate.HZ_48000)
    .setAutoStart(true)
    .setKeepDisplayOn(true)
    
    // Start recording
    .record();

3 - Wait for result

@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
    super.onActivityResult(requestCode, resultCode, data);
    if (requestCode == 0) {
        if (resultCode == RESULT_OK) {
            // Great! User has recorded and saved the audio file
        } else if (resultCode == RESULT_CANCELED) {
            // Oops! User has canceled the recording
        }
    }
}

Import to your project

Put this into your app/build.gradle:

repositories {
  maven {
    url "https://jitpack.io"
  }
}

dependencies {
  compile 'com.github.adrielcafe:AndroidAudioRecorder:0.3.0'
}

FEATURES

  • Record audio
  • Tint images to black when background color is too bright (thanks to @prakh25)
  • Wave visualization based on this player concept
  • Play recorded audio
  • Pause recording
  • Configure audio source (Mic/Camcorder), channel (Stereo/Mono) and sample rate (8kHz to 48kHz)
  • Auto start recording when open activity
  • Keep display on while recording
  • Skip silence
  • Animations
  • Landscape screen orientation (only supports portrait at the moment)

Dependencies

Want to CONVERT AUDIO into your app?

Take a look at AndroidAudioConverter! Example of usage here.

License

The MIT License (MIT)

Copyright (c) 2016 Adriel Café

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

More Repositories

1

voyager

🛸 A pragmatic navigation library for Jetpack Compose
Kotlin
2,466
star
2

AndroidAudioConverter

Convert audio files inside your Android app easily. Supported formats: AAC, MP3, M4A, WMA, WAV and FLAC.
Java
1,319
star
3

lyricist

🌎 The missing I18N/L10N (internationalization/localization) multiplatform library for Jetpack Compose!
Kotlin
677
star
4

bonsai

🌳 A multiplatform tree view for Jetpack Compose
Kotlin
350
star
5

krumbsview

🍞 The ultimate breadcrumbs view for Android!
Kotlin
186
star
6

chroma

🎶 Chromatic tuner app for Android
Kotlin
111
star
7

pufferdb

🐡 An Android & JVM key-value storage powered by Protobuf and Coroutines
Kotlin
100
star
8

broker

💬 Publish-Subscribe (a.k.a Pub/Sub, EventBus) library for Android and JVM built with Coroutines
Kotlin
95
star
9

AndroidOAuth

A simple way to authenticate with Google and Facebook using OAuth 2.0 in Android
Java
88
star
10

hal

🔴 A non-deterministic finite-state machine for Android & JVM that won't let you down
Kotlin
79
star
11

satchel

🎒 A fast, secure and modular key-value storage with batteries-included for Android and JVM.
Kotlin
71
star
12

KBus

Dead simple EventBus for Android made with Kotlin and RxJava 2
Kotlin
46
star
13

NoMansWallpaperApp

Looking for your next No Man's Sky wallpaper?
Kotlin
38
star
14

kaptain

👨‍✈️ multi-module navigation on Android has never been so easier!
Kotlin
27
star
15

AndroidStreamable

Unofficial https://streamable.com API Wrapper for Android
Java
27
star
16

dalek

🤖 UI driven state machine for Android & JVM that will exterminate your bugs
Kotlin
26
star
17

CrypAndroidApp

A cryptocurrency portfolio tracker app for Android
Kotlin
26
star
18

NMSAlphabetAndroidApp

An unofficial translator app for No Man's Sky
Java
25
star
19

AndroidCoroutineScopes

This lib implements the most common CoroutineScopes used in Android apps.
Kotlin
17
star
20

gwent-wallpapers

🃏🐺Unofficial Android app with more than 1.000 cards from GWENT: The Witcher Card Game as mobile wallpapers
Kotlin
16
star
21

ReadnBuyAndroidApp

Android app developed at the Vanhackathon for Shopify's challenge. Coded with Kotlin, RxJava and MVP.
Kotlin
16
star
22

BeMyEyesXamarinApp

Describes photos via audio to the visually impaired user
C#
13
star
23

VoxRecorderAndroidApp

An audio recorder app for Android built with Kotlin, RxJava and MVP
Kotlin
10
star
24

MoovAndroidApp

Concept Android app
Kotlin
9
star
25

GreenHellCompanionApp

Unofficial companion app for the game Green Hell
Kotlin
4
star
26

gwent-cards

🃏🐺 All cards from GWENT: The Witcher Card Game
4
star
27

RecifeBomDeBola

Versão mobile de https://recifebomdebola.wordpress.com
Java
3
star
28

cryp-website

Cryp app's website
HTML
2
star
29

MinhaEscola

Minha Escola é um aplicativo Android que pode ser usado por qualquer escola para exibir os horários e histórico escolar de seus alunos.
Java
2
star
30

Scryp

REST API powered by Moneywagon: the universal cryptocurrency multichain library
Python
2
star
31

S-Task

Just a simple, beautiful, offline and open source To Do list for Android 4.0.3+
Java
2
star
32

VaiChoverRecife

App para Firefox OS
JavaScript
2
star
33

PlaystationTrophiesConceptApp

Concept Android app
Kotlin
2
star
34

NMSAlphabetWeb

An unofficial Android app for No Man's Sky (WIP)
CSS
2
star
35

LifeBand

An app + wearable device that can change your life
Java
1
star
36

CryptoUtil

Utility class for encryption
C#
1
star
37

responsive-headings.css

Bring responsiveness to HTML headings
CSS
1
star
38

GuiaServicosSP

Guia de Serviços SP é um aplicativo Android que ajuda os cidadãos paulistas a encontrarem informações sobre serviços públicos do estado de São Paulo mais facilmente.
Java
1
star
39

adriel.cafe

1
star
40

MessagesAndroidApp

A simple app to showcase Kotlin, MVP, RxJava, Realm, Moshi
Kotlin
1
star
41

ChuckNorrisFacts

A Chuck Norris facts Android app
Kotlin
1
star
42

GryphonFramework

A Framework for integrating ontologies and relational databases
Web Ontology Language
1
star
43

DissertacaoDeMestrado

Dissertação de Mestrado defendida por Adriel Café no CIn-UFPE em 04/09/15
1
star
44

PlanetaSustentavel

Planeta Sustentável é um aplicativo Android com diversas dicas essências de práticas sustentáveis. Aprenda a consumir menos recursos da natureza e torne-se um cidadão melhor!
Java
1
star