audio-recording

How to downsample audio recorded from mic realtime in javascript?

巧了我就是萌 提交于 2019-12-09 23:13:01
问题 I am using following javascript to record audio and send it to a websocket server: const recordAudio = () => new Promise(async resolve => { const constraints = { audio: { sampleSize: 16, channelCount: 1, sampleRate: 8000 }, video: false }; var mediaRecorder; const stream = await navigator.mediaDevices.getUserMedia(constraints); var options = { audioBitsPerSecond: 128000, mimeType: 'audio/webm;codecs=pcm' }; mediaRecorder = new MediaRecorder(stream, options); var track = stream.getAudioTracks(

iOS: How to trim silence from start and end of .aif audio recording?

◇◆丶佛笑我妖孽 提交于 2019-12-09 12:59:49
问题 My app includes the ability for the user to record a brief message; I'd like to trim off any silence (or, to be more precise, any audio whose volume falls below a given threshold) from the beginning and end of the recording. I'm recording the audio with an AVAudioRecorder, and saving it to an .aif file. I've seen some mention elsewhere of methods by which I could have it wait to start recording until the audio level reaches a threshold; that'd get me halfway there, but won't help with

Recording audio from external source in an android application

痞子三分冷 提交于 2019-12-09 06:41:26
I saw there was a similar question here: Is it possible to record from the external mic when recording video in Android? However, the question was never really answered and android documentation does not clearly state how this is done. This person in this thread states that it is possible, but does not say how. Real-time audio capture and playback from an external mic It would make sense for you to make the selection in the "setAudioSource" section, but none of the options are for external sources. MediaRecorder recorder = new MediaRecorder(); recorder.setAudioSource(MediaRecorder.AudioSource

How to record audio in a Chrome Extension?

陌路散爱 提交于 2019-12-08 20:38:43
问题 What's the simplest way to setup a chrome extension to record audio from the microphone? I see there is a working experimental speech input API but how come you don't have access to the recorded file? Seems like hooking up into that should be simple enough, as it's a step earlier in the process, no? Especially as there is also a text-to-speech API, so you could effectively record into text and then have the computer speak it back out, but unless you want a standard voice, how lame, redundant

How To Read Sound Frequency using Mobile Microphone?

a 夏天 提交于 2019-12-08 15:05:25
问题 I am working on an application. Here I want to read various sounds using Android Application. I know how to record in Android. Now what I want to do is to read a sound and based on its frequency I want to display it on Android Screen. So how can I read the frequency in Hz or KHz? 回答1: You will need to perform a discrete Fourier transform on your recorded audio samples. You can write code yourself or use a library for it. Unfortunately I have no idea which FFT libraries exist for Java, but I

How to remove background Noise in Audio Track?

若如初见. 提交于 2019-12-08 11:56:07
问题 I am developing VOIP kind of application. Sending the voice is perfect but when i receive the same voice from the webserver, i am playing back that using AudioTrack API. I am calling at.play() and at.write in a Thread so that i should get all the voice which is recorded and sent from the other device. But, now the problem here i m facing is, if there is no voice than its still playing like some bullet sound, i mean there is a continuos background sound when i try to play . I m using this

How to record audio in format of mp3/m4a JavaScript- recorder.js

可紊 提交于 2019-12-08 10:03:29
In recorderjs rec.exportWAV([callback][, type]) is used to generate a Blob object containing the recorded audio in WAV format. But the WAV file is taking large space, for 30sec it is approximately 1mb. So I want to record the audio in format of mp3/m4a which takes less space. Is there any way to record audio in format of mp3/m4a. rampravesh i think you should check this link : HTML5 record audio to file here u can change the audio type like this : type = type || config.type || 'audio/wav'; Recorder.js does NOT support encoding captured audio as mp3. It can only record 16 bit mono or stereo

Is there any way to know if an outgoing call is accepted?

回眸只為那壹抹淺笑 提交于 2019-12-08 09:31:30
问题 I'm doing an app that record call (both of them, incoming and outgoing calls). I've just resolved the problem of recording audio from incoming calls, but I've found some troubles with outgoing calls. My situation is next. I'd like to record audio only when the call is accepted, but I don't know how to do it. I've just tried using PhoneStateListener class, but the call state doesn't change when the call is accepted. I've next code: package com.call.record.listeners; import android.telephony

How can I change the voice data iPhone sends to cellular network

微笑、不失礼 提交于 2019-12-08 09:10:53
问题 I have this code that records a voice call in iPhone. What I'm trying to is change the data that goes to the cellular network. Specifically I think I need access to the voice data after they are modulated in dsp and are ready to send to the cellular network. I want to apply some stream cipher to the data that already are modulated. Is this the right class to look for? Any suggestions are welcome. original code from How can I record a conversation / phone call on iOS? #import <AudioToolbox