m4a

AVAudioRecorder does not create .m4a files that can be opened and played

為{幸葍}努か 提交于 2021-02-06 20:01:45
问题 I am trying to modify an iOS app that can send audio files (securely/encrypted) to other iOS devices. It uses AVAudioRecorder to record the audio files, and it uses AVAudioPlayer to play back any received audio files. I am now trying to modify the app to create and send files that are compatible with Android. I modified the existing AVAudioRecorder code to this: [settings setValue:[NSNumber numberWithInt:kAudioFormatMPEG4AAC] forKey:AVFormatIDKey]; [settings setValue:[NSNumber numberWithInt

AVAudioRecorder does not create .m4a files that can be opened and played

前提是你 提交于 2021-02-06 19:56:40
问题 I am trying to modify an iOS app that can send audio files (securely/encrypted) to other iOS devices. It uses AVAudioRecorder to record the audio files, and it uses AVAudioPlayer to play back any received audio files. I am now trying to modify the app to create and send files that are compatible with Android. I modified the existing AVAudioRecorder code to this: [settings setValue:[NSNumber numberWithInt:kAudioFormatMPEG4AAC] forKey:AVFormatIDKey]; [settings setValue:[NSNumber numberWithInt

ffmpeg - what is the default format for .m4a output?

自古美人都是妖i 提交于 2021-01-29 08:44:13
问题 I have two commands, one in which I specify the output format as -f mp4 : ffmpeg -i input.wav -ac 1 -c:a libfdk_aac -profile:a aac_he -vbr 2 -f mp4 test_export_1.m4a And one which lets ffmpeg guess based on the extension: ffmpeg -i input.wav -ac 1 -c:a libfdk_aac -profile:a aac_he -vbr 2 test_export_2.m4a This gives me two different results. The first one: $ffprobe test_export_1.m4a Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'test_export_1.m4a': Metadata: major_brand : isom minor_version : 512

FFmpeg, how to embed cover art (image) to .m4a

假装没事ソ 提交于 2020-04-08 05:44:40
问题 Is there any way to embed cover art to m4a files? This one works well for mp3 but doesn't work for m4a ffmpeg -i tests/in.m4a -i cover.jpg -map 0:0 -map 1:0 -acodec copy \ -id3v2_version 3 tests/out.m4a 回答1: FFmpeg has an open issue on this functionality. In the meantime, covers can be added with the TagEditor project. To add: tageditor -s cover=ju.jpg --max-padding 100000 -f ki.m4a To remove: tageditor -s cover= --max-padding 100000 -f ki.m4a 回答2: mp4art from mp4v2 can also do this: mp4art -

FFmpeg, how to embed cover art (image) to .m4a

风流意气都作罢 提交于 2020-04-08 05:43:47
问题 Is there any way to embed cover art to m4a files? This one works well for mp3 but doesn't work for m4a ffmpeg -i tests/in.m4a -i cover.jpg -map 0:0 -map 1:0 -acodec copy \ -id3v2_version 3 tests/out.m4a 回答1: FFmpeg has an open issue on this functionality. In the meantime, covers can be added with the TagEditor project. To add: tageditor -s cover=ju.jpg --max-padding 100000 -f ki.m4a To remove: tageditor -s cover= --max-padding 100000 -f ki.m4a 回答2: mp4art from mp4v2 can also do this: mp4art -

我对M4A文件格式的理解

时间秒杀一切 提交于 2020-03-11 13:18:32
m4a 格式文件中的内容是有很多的box 组成的,box 格式如下: box length(4B 大端格式) + box type(4B)+ box content(box length - 8) 例如如下是ftyp这个box 的数据内容,可以看到该box 长度是0x20字节。 从m4a文件中找到moov box是重点,因为找到了这个box ,需要从box 找出来每个采样帧的位置及大小。 一般是需要从m4a中找到如下的结构,重点是知道stsd stts stsc stsz stco这几个box。 moov --->trak --->mdia --->minf --->stbl --->stsd --->mp4a ===》从这里可以得到channel num、sample bits、sample rate; --->esds ===》从这里可以得到audio type、max bitrate、avg bitrate、decoder config data; --->stts ===》可以获取该trak下面有多少的samples,如下第一个参数是0x00000001,那么后面四个字节组成的就是 这个trak中的samples count=0x00002c64; --->stsc ===》会得到一个表格,关于这个表的数据如何去理解,用一个实际例子来说明。第个参数0x00000002,那么

how to load m4a file in python

非 Y 不嫁゛ 提交于 2020-02-04 01:18:10
问题 Is there an easy way to load m4a sound file in python. I've came across audiotools lib but I'm getting an error while using to_pcm fn audiotools.open('file.m4a').to_pcm() --------------------------------------------------------------------------- FileNotFoundError Traceback (most recent call last) <ipython-input-76-e12405d92ce3> in <module>() ----> 1 audiotools.open(p).to_pcm() /path/to/m4a.py in to_pcm(self) 456 stdout=subprocess.PIPE, 457 stderr=subprocess.DEVNULL if hasattr(subprocess,

Background music in a php/html webpage

扶醉桌前 提交于 2020-01-14 05:23:15
问题 I used an iPhone to record a piece of piano music as .m4a format. I would like to chop it and convert it into a suitable format to be used as the background music in a php/html website. I have the following questions:- 1. what kind of format is the best (e.g. mp3, WAV, etc)? 2. shall I chop the .m4a followed by conversion, or shall I convert it to another format then chop? 3. may I just apply the file in the webpage, to produce a looping effect? but I worry about, after each refresh, the

Can non-standard sampling rates be used with AAC encoding?

≡放荡痞女 提交于 2020-01-05 09:14:43
问题 I am trying to up-sampling an M4a file from 41000 to another non-standard sampling rate let's say 5000. ffmpeg -i audio.wav -ar 5000 audio_.wav This worked fine with wav files whoever it didn't work with m4a. Any ideas why? If non-standard sampling rates don't work with AAC I need any documentation or reference for that. 回答1: The set of available sampling frequencies is limited by AAC ADIF (Audio Data Interchange Format) and ADTS (Audio Data Transport Stream). So other rates just can't be