I have an audiobook that I'm trying to play on my phone. My audio app of choice is struggling with the file, and I think it's because there's an additional stream in the file that it can't handle. VLC for Android plays the file without issue, but I'd rather use my audio app of choice.
When I open the m4a file in VLC for Windows, I see two streams:
I want to get rid of the tx3g stream, and just keep the audio stream. So I turned to ffmpeg to try to copy over only the audio stream. However, no matter what I try, the tx3g stream seems to come along for the ride. I referred to this post to figure out how to remove the tx3g stream, but so far I've been unsuccessful. Can anyone help me figure out how to remove just the tx3g track? Ideally, I'd like to keep the metadata and album art as well.
I tried to run ffmpeg -i input.m4a -map 0:a:0 -sn -dn -c copy output.m4a
, but the tx3g stream is still there. Here is the command output:
ffmpeg version 2021-12-06-git-ef00d40e32-essentials_build-www.gyan.dev Copyright (c) 2000-2021 the FFmpeg developers
built with gcc 11.2.0 (Rev2, Built by MSYS2 project)
configuration: --enable-gpl --enable-version3 --enable-static --disable-w32threads --disable-autodetect --enable-fontconfig --enable-iconv --enable-gnutls --enable-libxml2 --enable-gmp --enable-lzma --enable-zlib --enable-libsrt --enable-libssh --enable-libzmq --enable-avisynth --enable-sdl2 --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxvid --enable-libaom --enable-libopenjpeg --enable-libvpx --enable-libass --enable-libfreetype --enable-libfribidi --enable-libvidstab --enable-libvmaf --enable-libzimg --enable-amf --enable-cuda-llvm --enable-cuvid --enable-ffnvcodec --enable-nvdec --enable-nvenc --enable-d3d11va --enable-dxva2 --enable-libmfx --enable-libgme --enable-libopenmpt --enable-libopencore-amrwb --enable-libmp3lame --enable-libtheora --enable-libvo-amrwbenc --enable-libgsm --enable-libopencore-amrnb --enable-libopus --enable-libspeex --enable-libvorbis --enable-librubberband
libavutil 57. 10.101 / 57. 10.101
libavcodec 59. 14.100 / 59. 14.100
libavformat 59. 9.102 / 59. 9.102
libavdevice 59. 0.101 / 59. 0.101
libavfilter 8. 19.100 / 8. 19.100
libswscale 6. 1.101 / 6. 1.101
libswresample 4. 0.100 / 4. 0.100
libpostproc 56. 0.100 / 56. 0.100
[mov,mp4,m4a,3gp,3g2,mj2 @ 000002773b2db200] stream 0, timescale not set
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '.\input.m4a':
Metadata:
major_brand : M4A
minor_version : 512
compatible_brands: isomiso2
artist : [removed]
title : [removed]
album : [removed]
date : 2020
genre : Audiobook
track : 1/22
disc : 1/1
comment : [removed]
copyright : [removed]
encoder : Lavf58.29.100
Duration: 00:01:45.14, start: 0.000000, bitrate: 132 kb/s
Chapters:
Chapter #0:0: start 0.000000, end 105.000000
Metadata:
title : [removed]
Stream #0:0[0x1](und): Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 125 kb/s (default)
Metadata:
handler_name : SoundHandler
vendor_id : [0][0][0][0]
Stream #0:1[0x2](und): Data: bin_data (text / 0x74786574), 0 kb/s
Metadata:
creation_time : 2021-11-29T16:23:41.000000Z
Stream #0:2[0x0]: Video: mjpeg (Baseline), yuvj420p(pc, bt470bg/unknown/unknown), 500x500 [SAR 1:1 DAR 1:1], 90k tbr, 90k tbn (attached pic)
Output #0, ipod, to 'output.m4a':
Metadata:
major_brand : M4A
minor_version : 512
compatible_brands: isomiso2
artist : [removed]
title : [removed]
album : [removed]
date : 2020
genre : Audiobook
track : 1/22
disc : 1/1
comment : [removed]
copyright : [removed]
encoder : Lavf59.9.102
Chapters:
Chapter #0:0: start 0.000000, end 105.000000
Metadata:
title : [removed]
Stream #0:0(und): Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 125 kb/s (default)
Metadata:
handler_name : SoundHandler
vendor_id : [0][0][0][0]
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Press [q] to stop, [?] for help
size= 1632kB time=00:01:45.11 bitrate= 127.2kbits/s speed=1.48e+04x
video:0kB audio:1612kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 1.233040%