0

I have attempted to convert a TrueHD stream to PCM as well as FLAC. Throughout the encoding process, errors occur: "lossless check failed" and others. The same set of errors occurred when converting to FLAC as well. Here's my full output:

C:\Users\henry>ffmpeg -i "D:\Movies\SELF-RIPPED MOVIES [1080p]\Hacksaw Ridge (2016) [TO COMPRESS]\Hacksaw Ri dge.mkv" -map 0:1 -c:a pcm_s24le "D:\Movies\SELF-RIPPED MOVIES [1080p]\Hacksaw Ridge (2016) [TO COMPRESS]\Hacksaw Ridge (soundtrack).mka"
ffmpeg version 4.1.3 Copyright (c) 2000-2019 the FFmpeg developers
  built with gcc 8.3.1 (GCC) 20190414
  configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-libvidstab --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa --enable-libspeex --enable-libxvid --enable-libaom --enable-libmfx --enable-amf --enable-ffnvcodec --enable-cuvid --enable-d3d11va --enable-nvenc --enable-nvdec --enable-dxva2 --enable-avisynth
  libavutil      56. 22.100 / 56. 22.100
  libavcodec     58. 35.100 / 58. 35.100
  libavformat    58. 20.100 / 58. 20.100
  libavdevice    58.  5.100 / 58.  5.100
  libavfilter     7. 40.101 /  7. 40.101
  libswscale      5.  3.100 /  5.  3.100
  libswresample   3.  3.100 /  3.  3.100
  libpostproc    55.  3.100 / 55.  3.100
[matroska,webm @ 000001f055828c80] Could not find codec parameters for stream 5 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size
Consider increasing the value for the 'analyzeduration' and 'probesize' options
Input #0, matroska,webm, from 'D:\Movies\SELF-RIPPED MOVIES [1080p]\Hacksaw Ridge (2016) [TO COMPRESS]\Hacksaw Ri dge.mkv':
  Metadata:
    title           : Hacksaw Ridge
    encoder         : libmakemkv v1.14.3 (1.3.5/1.4.7) win(x64-release)
    creation_time   : 2019-06-06T19:54:18.000000Z
  Duration: 02:19:19.42, start: 0.000000, bitrate: 30771 kb/s
    Chapter #0:0: start 0.000000, end 558.766542
    Metadata:
      title           : Chapter 01
    Chapter #0:1: start 558.766542, end 1121.995875
    Metadata:
      title           : Chapter 02
    Chapter #0:2: start 1121.995875, end 1594.509583
    Metadata:
      title           : Chapter 03
    Chapter #0:3: start 1594.509583, end 1980.561917
    Metadata:
      title           : Chapter 04
    Chapter #0:4: start 1980.561917, end 2404.151750
    Metadata:
      title           : Chapter 05
    Chapter #0:5: start 2404.151750, end 3007.212542
    Metadata:
      title           : Chapter 06
    Chapter #0:6: start 3007.212542, end 3421.543125
    Metadata:
      title           : Chapter 07
    Chapter #0:7: start 3421.543125, end 3861.649458
    Metadata:
      title           : Chapter 08
    Chapter #0:8: start 3861.649458, end 4670.207208
    Metadata:
      title           : Chapter 09
    Chapter #0:9: start 4670.207208, end 5038.700333
    Metadata:
      title           : Chapter 10
    Chapter #0:10: start 5038.700333, end 5481.726250
    Metadata:
      title           : Chapter 11
    Chapter #0:11: start 5481.726250, end 5942.811875
    Metadata:
      title           : Chapter 12
    Chapter #0:12: start 5942.811875, end 6367.569542
    Metadata:
      title           : Chapter 13
    Chapter #0:13: start 6367.569542, end 7188.306125
    Metadata:
      title           : Chapter 14
    Chapter #0:14: start 7188.306125, end 7633.292333
    Metadata:
      title           : Chapter 15
    Chapter #0:15: start 7633.292333, end 8359.424000
    Metadata:
      title           : Chapter 16
    Stream #0:0(eng): Video: h264 (High), yuv420p(progressive), 1920x1080 [SAR 1:1 DAR 16:9], 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc
    Metadata:
      BPS-eng         : 25437577
      DURATION-eng    : 02:19:19.392708333
      NUMBER_OF_FRAMES-eng: 200425
      NUMBER_OF_BYTES-eng: 26580335044
      SOURCE_ID-eng   : 001011
      _STATISTICS_WRITING_APP-eng: MakeMKV v1.14.3 win(x64-release)
      _STATISTICS_WRITING_DATE_UTC-eng: 2019-06-06 19:54:18
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES SOURCE_ID
    Stream #0:1(eng): Audio: truehd, 48000 Hz, 7.1, s32 (24 bit) (default)
    Metadata:
      title           : Surround 7.1
      BPS-eng         : 4198137
      DURATION-eng    : 02:19:19.394166666
      NUMBER_OF_FRAMES-eng: 10031273
      NUMBER_OF_BYTES-eng: 4386735194
      SOURCE_ID-eng   : 001100
      _STATISTICS_WRITING_APP-eng: MakeMKV v1.14.3 win(x64-release)
      _STATISTICS_WRITING_DATE_UTC-eng: 2019-06-06 19:54:18
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES SOURCE_ID
    Stream #0:2(eng): Audio: ac3, 48000 Hz, 5.1(side), fltp, 640 kb/s
    Metadata:
      title           : Surround 5.1
      BPS-eng         : 640000
      DURATION-eng    : 02:19:19.424000000
      NUMBER_OF_FRAMES-eng: 261232
      NUMBER_OF_BYTES-eng: 668753920
      SOURCE_ID-eng   : 001100
      _STATISTICS_WRITING_APP-eng: MakeMKV v1.14.3 win(x64-release)
      _STATISTICS_WRITING_DATE_UTC-eng: 2019-06-06 19:54:18
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES SOURCE_ID
    Stream #0:3(eng): Audio: ac3, 48000 Hz, stereo, fltp, 224 kb/s
    Metadata:
      title           : Stereo
      BPS-eng         : 224000
      DURATION-eng    : 02:19:19.456000000
      NUMBER_OF_FRAMES-eng: 261233
      NUMBER_OF_BYTES-eng: 234064768
      SOURCE_ID-eng   : 001102
      _STATISTICS_WRITING_APP-eng: MakeMKV v1.14.3 win(x64-release)
      _STATISTICS_WRITING_DATE_UTC-eng: 2019-06-06 19:54:18
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES SOURCE_ID
    Stream #0:4(eng): Audio: ac3, 48000 Hz, stereo, fltp, 224 kb/s
    Metadata:
      title           : Stereo
      BPS-eng         : 224000
      DURATION-eng    : 02:19:19.456000000
      NUMBER_OF_FRAMES-eng: 261233
      NUMBER_OF_BYTES-eng: 234064768
      SOURCE_ID-eng   : 001103
      _STATISTICS_WRITING_APP-eng: MakeMKV v1.14.3 win(x64-release)
      _STATISTICS_WRITING_DATE_UTC-eng: 2019-06-06 19:54:18
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES SOURCE_ID
    Stream #0:5(eng): Subtitle: hdmv_pgs_subtitle
    Metadata:
      BPS-eng         : 34867
      DURATION-eng    : 02:09:48.843562500
      NUMBER_OF_FRAMES-eng: 3316
      NUMBER_OF_BYTES-eng: 33947630
      SOURCE_ID-eng   : 001200
      _STATISTICS_WRITING_APP-eng: MakeMKV v1.14.3 win(x64-release)
      _STATISTICS_WRITING_DATE_UTC-eng: 2019-06-06 19:54:18
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES SOURCE_ID
Stream mapping:
  Stream #0:1 -> #0:0 (truehd (native) -> pcm_s24le (native))
Press [q] to stop, [?] for help
Output #0, matroska, to 'D:\Movies\SELF-RIPPED MOVIES [1080p]\Hacksaw Ridge (2016) [TO COMPRESS]\Hacksaw Ridge (soundtrack).mka':
  Metadata:
    title           : Hacksaw Ridge
    encoder         : Lavf58.20.100
    Chapter #0:0: start 0.000000, end 558.766542
    Metadata:
      title           : Chapter 01
    Chapter #0:1: start 558.766542, end 1121.995875
    Metadata:
      title           : Chapter 02
    Chapter #0:2: start 1121.995875, end 1594.509583
    Metadata:
      title           : Chapter 03
    Chapter #0:3: start 1594.509583, end 1980.561917
    Metadata:
      title           : Chapter 04
    Chapter #0:4: start 1980.561917, end 2404.151750
    Metadata:
      title           : Chapter 05
    Chapter #0:5: start 2404.151750, end 3007.212542
    Metadata:
      title           : Chapter 06
    Chapter #0:6: start 3007.212542, end 3421.543125
    Metadata:
      title           : Chapter 07
    Chapter #0:7: start 3421.543125, end 3861.649458
    Metadata:
      title           : Chapter 08
    Chapter #0:8: start 3861.649458, end 4670.207208
    Metadata:
      title           : Chapter 09
    Chapter #0:9: start 4670.207208, end 5038.700333
    Metadata:
      title           : Chapter 10
    Chapter #0:10: start 5038.700333, end 5481.726250
    Metadata:
      title           : Chapter 11
    Chapter #0:11: start 5481.726250, end 5942.811875
    Metadata:
      title           : Chapter 12
    Chapter #0:12: start 5942.811875, end 6367.569542
    Metadata:
      title           : Chapter 13
    Chapter #0:13: start 6367.569542, end 7188.306125
    Metadata:
      title           : Chapter 14
    Chapter #0:14: start 7188.306125, end 7633.292333
    Metadata:
      title           : Chapter 15
    Chapter #0:15: start 7633.292333, end 8359.424000
    Metadata:
      title           : Chapter 16
    Stream #0:0(eng): Audio: pcm_s24le ([1][0][0][0] / 0x0001), 48000 Hz, 7.1, s32 (24 bit), 9216 kb/s (default)
    Metadata:
      title           : Surround 7.1
      BPS-eng         : 4198137
      DURATION-eng    : 02:19:19.394166666
      NUMBER_OF_FRAMES-eng: 10031273
      NUMBER_OF_BYTES-eng: 4386735194
      SOURCE_ID-eng   : 001100
      _STATISTICS_WRITING_APP-eng: MakeMKV v1.14.3 win(x64-release)
      _STATISTICS_WRITING_DATE_UTC-eng: 2019-06-06 19:54:18
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES SOURCE_ID
      encoder         : Lavc58.35.100 pcm_s24le
[truehd @ 000001f057a93c00] Lossless check failed - expected 00, calculated a5.
[truehd @ 000001f057a93c00] Lossless check failed - expected 27, calculated fa.
[truehd @ 000001f057a93c00] Lossless check failed - expected 26, calculated d4.
[truehd @ 000001f057a93c00] Lossless check failed - expected ff, calculated 64.
[truehd @ 000001f057a93c00] Lossless check failed - expected 29, calculated 50.
[truehd @ 000001f057a93c00] Lossless check failed - expected 53, calculated 2e.
[truehd @ 000001f057a93c00] Lossless check failed - expected 44, calculated 7e.
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x1b5e)
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x1418)
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x1b5c)
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x09c6)
[truehd @ 000001f057a93c00] substream 2 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x184d)
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x19d1)
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 1 times
[truehd @ 000001f057a93c00] Invalid channel 14 specified as output from matrix.
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 1 times
[truehd @ 000001f057a93c00] Invalid channel 9 specified as output from matrix.
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x07a2)
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 2 times
[truehd @ 000001f057a93c00] Number of primitive matrices cannot be greater than 8.
    Last message repeated 1 times
[truehd @ 000001f057a93c00] substream 2 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 6 times
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 1 times
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 1 times
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] Number of primitive matrices cannot be greater than 8.
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x15e9)
[truehd @ 000001f057a93c00] substream 2 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 4 times
[truehd @ 000001f057a93c00] Invalid huff_lsbs.
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 1 times
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 2 times
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x1cbf)
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 1 times
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x03a7)
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 2 times
[truehd @ 000001f057a93c00] Lossless check failed - expected 86, calculated ed.
[truehd @ 000001f057a93c00] Lossless check failed - expected 00, calculated 01.
[truehd @ 000001f057a93c00] Lossless check failed - expected 26, calculated 59.
[truehd @ 000001f057a93c00] Lossless check failed - expected 5b, calculated 6f.
[truehd @ 000001f057a93c00] Lossless check failed - expected 72, calculated 53.
[truehd @ 000001f057a93c00] Lossless check failed - expected 91, calculated da.
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x15b5)
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] Invalid blocksize.
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x1110)
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 1 times
[truehd @ 000001f057a93c00] Invalid blocksize.
[truehd @ 000001f057a93c00] substream 1 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] Invalid blocksize.
[truehd @ 000001f057a93c00] substream 1 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] Invalid blocksize.
[truehd @ 000001f057a93c00] substream 1 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 1 times
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x05aa)
[truehd @ 000001f057a93c00] substream 1 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 2 times
[truehd @ 000001f057a93c00] Invalid blocksize.
[truehd @ 000001f057a93c00] substream 1 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 1 times
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x1c60)
[truehd @ 000001f057a93c00] substream 1 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x10e0)
[truehd @ 000001f057a93c00] substream 1 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 2 times
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x00e1)
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 4 times
[truehd @ 000001f057a93c00] Number of primitive matrices cannot be greater than 8.
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 1 times
[truehd @ 000001f057a93c00] Lossless check failed - expected 3d, calculated 29.
[truehd @ 000001f057a93c00] Lossless check failed - expected 00, calculated f4.
[truehd @ 000001f057a93c00] Number of primitive matrices cannot be greater than 8.
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x1cec)
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 2 times
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x1b2e)
[truehd @ 000001f057a93c00] too many audio samples in frame
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 2 times
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x1408)
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 1 times
[truehd @ 000001f057a93c00] Invalid blocksize.
[truehd @ 000001f057a93c00] substream 1 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 11 times
[truehd @ 000001f057a93c00] quant_step_size larger than huff_lsbs
[truehd @ 000001f057a93c00] substream 1 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 2 times
[truehd @ 000001f057a93c00] Invalid blocksize.
[truehd @ 000001f057a93c00] substream 1 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 5 times
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x1081)
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 13 times
[truehd @ 000001f057a93c00] Invalid blocksize.
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 1 times
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x1693)
[truehd @ 000001f057a93c00] substream 1 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 3 times
[truehd @ 000001f057a93c00] Invalid channel 3 specified as output from matrix.
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 7 times
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x1b09)
[truehd @ 000001f057a93c00] substream 1 length mismatch
Error while decoding stream #0:1: Invalid data found when processing input
[truehd @ 000001f057a93c00] restart header sync incorrect (got 0x1b3d)
Error while decoding stream #0:1: Invalid data found when processing input
    Last message repeated 2 times
[truehd @ 000001f057a93c00] Lossless check failed - expected af, calculated 5f.
[truehd @ 000001f057a93c00] Lossless check failed - expected 00, calculated c7.
[truehd @ 000001f057a93c00] Lossless check failed - expected 26, calculated 8d.
[truehd @ 000001f057a93c00] Lossless check failed - expected 8f, calculated 9b.
size= 9472805kB time=02:19:19.39 bitrate=9283.1kbits/s speed=15.8x
video:0kB audio:9404189kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.729632%

C:\Users\henry>

Is there anything that can be done about these errors? Is it that my TrueHD audio is corrupt? Shall I ignore the errors altogether? Any response would be very useful to me. Thank you.

  • Yes, the stream appears corrupt in parts. How does the output sound? – Gyan Jun 19 '19 at 4:56
  • The output seems to sound fine, but I'm unsure if this encode is worth it. – Henry7720 Jun 19 '19 at 21:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.