Here is an example of a record I've done with tvheadend and my dvb-t2 device:
https://www.dropbox.com/s/foryfsjme0o1jjo/Brisant.ts?dl=0 (https://www.dropbox.com/s/foryfsjme0o1jjo/Brisant.ts?dl=0)
Loading this file into avidemux, avidemux tells me that the file has no audio tracks. The file is played fine (including audio) with mpv. Ffmpeg processes the file as well, e.g:
ffmpeg -i Brisant.ts -codec copy -map 0:0 -map 0:1 -map 0:2 Brisant.mkv
Confirming the issue, thank you for the sample.
Should be fixed by [coreAudioParser,demuxers/MpegTS] Support LATM frames not aligned at PES packet boundaries, demux one LATM frame at a time to reduce the odds to run out of free buffers (https://github.com/mean00/avidemux2/commit/0bf23953288d324efc3a8e320dc4d1057838fd1e), please try a future nightly and don't forget to delete the old *.idx2 file before loading the stream in Avidemux.
Is tvheadend remuxing and repackaging the incoming MPEG-TS stream on-the-fly? Does it matter whether you write the output of /dev/dvb/adapterN/dvr0 to a file (N = 0 for the first DVB card, replace it with the figure matching your setup) or use tvheadend to record the stream?
I had a few DVB-T2 samples with LATM AAC audio tracks here but never encountered something like yours. Usually LATM frames are aligned on PES packet boundaries and the PES packets are rather small (often 1 frame in a single PES packet). In your sample they are not aligned and the PES packets are huge.
Quote from: eumagga0x2a on September 15, 2019, 12:16:35 PM
please try a future nightly
...or just build Avidemux from git master if you are on Linux anyway.
Quote from: eumagga0x2a on September 15, 2019, 12:16:35 PM
... write the output of /dev/dvb/adapterN/dvr0 to a file (N = 0 for the first DVB card, replace it with the figure matching your setup) ...
Ups, I think I am not aware of how to do the trick.
Quote from: eumagga0x2a on September 15, 2019, 12:16:35 PM
Is tvheadend remuxing and repackaging the incoming MPEG-TS stream on-the-fly?
I strongly believe so, the profile I used is called "pass", but since the other profiles allow recording into a mkv-container or even reencoding on the fly, I think "pass" means remuxing with copying the streams.
Doing a test record with vdr and tvheadend of the same program, avidemux again says no audio with the tvheadend file but recognizes one audio stream with the vdr-record. But if I process this file (using copy for audio and video) into a mkv-container, the resulting file plays with no audio in mpv, so the audio seems to get lost even with a vdr-record.
I will try a nightly in the next days. I am not able to build the git version
Make Error at CMakeLists.txt:213 (ADD_SUBDIRECTORY):
The source directory
/mnt/Data_bb/sda8/makepkg/avidemux/avidemux2/avidemux/qt4/i18n
does not contain a CMakeLists.txt file.
**************************
*** Optional Library ***
*** Summary ***
**************************
*** Video Encoder ***
NVENC Yes
*** Miscellaneous ***
gettext Yes
SDL No
XVideo Yes
OpenGL Yes
**************************
*** Release Build ***
**************************
-- No packaging... (package=)
-- Configuring incomplete, errors occurred!
See also "/mnt/Data_bb/sda8/makepkg/avidemux/avidemux2/buildQt5/CMakeFiles/CMakeOutput.log".
See also "/mnt/Data_bb/sda8/makepkg/avidemux/avidemux2/buildQt5/CMakeFiles/CMakeError.log".
** Failed at cmakeZ**
https://avidemux.org/smif/index.php/topic,18826.0.html
Regarding the stream remuxed to mkv, it is ffmpeg not extracting AAC stream from LATM. I was about to investigate whether we can support this in the mkv demuxer.
Thanks for the link, the compilation went through now!
And I could process all my test files (vdr-Recording and tvheadend-recordings), all two audio tracks were cut+copied into a new mkv-container!!!
Quote from: bernd_b on September 15, 2019, 04:00:40 PM
Quote from: eumagga0x2a on September 15, 2019, 12:16:35 PM
... write the output of /dev/dvb/adapterN/dvr0 to a file (N = 0 for the first DVB card, replace it with the figure matching your setup) ...
Ups, I think I am not aware of how to do the trick.
With the old DVB-T, it implied using the tzap utility to tune to the desired program (required a proper ~/.tzap/channels.conf file) and running something like
dd if=/dev/dvb/adapter0/dvr0 of=/path/to/output.ts
optionally with the input-output unit increased from the default 512 bytes to something like 512 kiB by adding bs=512K to the command in order to reduce the number of writes (the whole was never particularly stable because the latency of writing to a hard disk resulted sometimes in internal buffer overflows and recording stopping). I'm not up to date myself regarding DVB-T2, but
mpv --stream-dump=/path/to/output.ts dvb://"Program name"
should work for any kind of DVB.
QuoteDoing a test record with vdr and tvheadend of the same program, avidemux again says no audio with the tvheadend file but recognizes one audio stream with the vdr-record.
Thanks, now we know who is doing strange things (it is tvheadend), so the impact of the former inability of Avidemux to handle badly aligned LATM streams in MPEG-TS should be very, very limited. Nevertheless, thank you for raising the topic.
Quote from: bernd_b on September 15, 2019, 04:00:40 PM
Doing a test record with vdr and tvheadend of the same program, avidemux again says no audio with the tvheadend file but recognizes one audio stream with the vdr-record. But if I process this file (using copy for audio and video) into a mkv-container, the resulting file plays with no audio in mpv, so the audio seems to get lost even with a vdr-record.
I might have misinterpreted the part about vdr-record processed to mkv. Could you please provide a sample ts file produced by vdr-record from DVB-T2 with AAC LATM audio tracks?
Here is the link to the test record I've done:
https://www.dropbox.com/s/2n3358cydvwcsix/Isar_recorded_with_vdr.ts?dl=0 (https://www.dropbox.com/s/2n3358cydvwcsix/Isar_recorded_with_vdr.ts?dl=0)
May it help.
Thank you very much for the sample. There is no difference to the stream recorded with tvheadend. Same huge PES packets and LATM frames not aligned at PES packet boundaries. I'll try to get an independent DVB-T2 sample to be absolutely sure.
If the DVB-T2 broadcast mode has really changed, many more Avidemux users are affected (need to rely on nightly builds for time being).