audio

Play raw PCM audio received in UDP packets

风流意气都作罢 提交于 2020-06-25 18:30:04
问题 The remote device is sending live raw PCM audio(no header included) in UDP packets and I need to implement a program in java to receive these packets and play them on the PC live. As I know that raw PCM's attributes are 16bit, mono, sampling rate 24KHz, so I tried to add a wav header to this raw PCM audio and play but the problem is I don't have File size of the audio. I also implemented a program based on this link but it only gives noise in output. I am bound to use UDP and I can get only

Firebase Cloud Storage: resource: the server responded with a status of 403 ()

怎甘沉沦 提交于 2020-06-17 09:45:11
问题 I make a simple audio recording web app using Firebase Hosting. I would like to record audio on browser and upload it to Cloud Storage. When I deploy and access my app, I can record audio. However the app failed to upload the audio to Cloud Storage. (I use Windows 10, Windows Subsystems for Linux, Debian 10.3 and Google Chrome browser. ) This is an error message in browser's console. firebasestorage.googleapis.com/v0/b/ondoku-dc29c.appspot.com/o?name=audio%2Fspeech.wav:1 Failed to load

Can an audio unit (v3) replace inter-app audio to send audio to a host app?

浪子不回头ぞ 提交于 2020-06-17 07:36:50
问题 My music performance app plays audio with AVAudioEngine , and uses inter-app audio to publish the engine's output to other apps. This allows users to feed the audio into a mixer app running on the same device. Since IAA is deprecated on iOS and not supported on Mac, I'm trying to replace this functionality with Audio Units. I've added an audio unit extension of type augn using the Xcode template, and I understand the internalRenderBlock is what actually returns the audio data. But how can the

How to Correlate Two Audio Events (Detect if they are Similar) in Python

陌路散爱 提交于 2020-06-16 19:09:44
问题 For my project I have to detect if two audio files are similar and when the first audio file is contained in the second. My problem is that I tried to use librosa the numpy.correlate. I don't know if I'm doing it in the right way. How can I detect if audio is contained in another audio file? import librosa import numpy long_audio_series, long_audio_rate = librosa.load("C:\\Users\\Jerry\\Desktop\\long_file.mp3") short_audio_series, short_audio_rate = librosa.load("C:\\Users\\Jerry\\Desktop\

How to Correlate Two Audio Events (Detect if they are Similar) in Python

℡╲_俬逩灬. 提交于 2020-06-16 19:07:28
问题 For my project I have to detect if two audio files are similar and when the first audio file is contained in the second. My problem is that I tried to use librosa the numpy.correlate. I don't know if I'm doing it in the right way. How can I detect if audio is contained in another audio file? import librosa import numpy long_audio_series, long_audio_rate = librosa.load("C:\\Users\\Jerry\\Desktop\\long_file.mp3") short_audio_series, short_audio_rate = librosa.load("C:\\Users\\Jerry\\Desktop\

How to Correlate Two Audio Events (Detect if they are Similar) in Python

∥☆過路亽.° 提交于 2020-06-16 19:05:20
问题 For my project I have to detect if two audio files are similar and when the first audio file is contained in the second. My problem is that I tried to use librosa the numpy.correlate. I don't know if I'm doing it in the right way. How can I detect if audio is contained in another audio file? import librosa import numpy long_audio_series, long_audio_rate = librosa.load("C:\\Users\\Jerry\\Desktop\\long_file.mp3") short_audio_series, short_audio_rate = librosa.load("C:\\Users\\Jerry\\Desktop\

Why is this sound only displaying on chrome

允我心安 提交于 2020-06-16 17:25:34
问题 I'm displaying a sound when paypal captures an order and it gets approved. The problem is that the sound is only getting displayed on google chrome, only on computers. Not working in safari, neither in chrome devices. But it's more strange that It once worked on safari for mac, then, when i tried again, it stopped working and now it only works in chrome. This is my code, thanks in advance: <script> paypal.Buttons({ createOrder: function(data, actions) { // This function sets up the details of

How do I decode opus file to pcm file using libavcodec from ffmpeg?

孤街醉人 提交于 2020-06-16 03:37:09
问题 I am trying to decode opus to pcm file using libavcodec.So,I use ffmpeg example from https://ffmpeg.org/doxygen/trunk/decode_audio_8c-example.html .And I change AV_CODEC_ID_MP2 to AV_CODEC_ID_OPUS.But I get an error. codec = avcodec_find_decoder((AV_CODEC_ID_MP2); codec = avcodec_find_decoder(AV_CODEC_ID_OPUS); error: codec ./decode_audio ./out.opus ./out.pcm [opus @ 0x7ff361800000] Error parsing Opus packet header. [opus @ 0x7ff361800000] Error parsing Opus packet header. [opus @

How do I decode opus file to pcm file using libavcodec from ffmpeg?

ぐ巨炮叔叔 提交于 2020-06-16 03:37:09
问题 I am trying to decode opus to pcm file using libavcodec.So,I use ffmpeg example from https://ffmpeg.org/doxygen/trunk/decode_audio_8c-example.html .And I change AV_CODEC_ID_MP2 to AV_CODEC_ID_OPUS.But I get an error. codec = avcodec_find_decoder((AV_CODEC_ID_MP2); codec = avcodec_find_decoder(AV_CODEC_ID_OPUS); error: codec ./decode_audio ./out.opus ./out.pcm [opus @ 0x7ff361800000] Error parsing Opus packet header. [opus @ 0x7ff361800000] Error parsing Opus packet header. [opus @

librosa.load() takes too long to load(sample) mp3 files

白昼怎懂夜的黑 提交于 2020-06-16 02:16:27
问题 I am trying to sample (convert analog to digital) mp3 files via the following Python code using the librosa library, but it takes too much time (around 4 seconds for one file). I suspect this is because librosa doesn't support mp3 and hence uses the slower audioread to sample mp3 Code: import time import librosa s = time.time() for i in mp3_list[:10]: # list of mp3 file paths, doing for 10 files y, sr = librosa.load(i) print('time taken =', time.time() - s) time taken = 36.55561399459839 I