DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Support forum for DGDecNV
Post Reply
DAE avatar
JKyle
Posts: 9
Joined: Sun May 24, 2020 2:29 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by JKyle »

DGIndexNV version: 2053.0.0.228 (64 bit)

Files: downloadable from this site.
  • iOS_P5_GlassBlowing2_1920x1080@59.94fps_15200kbps.mp4 (Profile 5)
Image
  • P81_GlassBlowing2_1920x1080@59.94fps_15200kbps_fmp4.mp4 (Profile 8.1)
DGIndexNV just dies.

They both have HEVC video streams.

By contrast, the same mp4 files remuxed to ts via tsMuxeR open successfully.

tsMuxeR version: 2021-04-30 Nightly Portable Windows 64-bit
User avatar
Rocky
Posts: 3556
Joined: Fri Sep 06, 2019 12:57 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by Rocky »

Thank you for the report Big J. Investigating...
User avatar
Rocky
Posts: 3556
Joined: Fri Sep 06, 2019 12:57 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by Rocky »

I can't see how to download those files. Please tell how.
DAE avatar
JKyle
Posts: 9
Joined: Sun May 24, 2020 2:29 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by JKyle »

Rocky wrote:
Fri May 07, 2021 11:31 pm
I can't see how to download those files. Please tell how.
This and this.
User avatar
Rocky
Posts: 3556
Joined: Fri Sep 06, 2019 12:57 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by Rocky »

Relative to the library we use to parse MP4 there are some unexpected box values. E.g., mdia.mdhd.duration is 0, there are no sample to chunk entries, etc. I'll have to do a research project, so it won't be a quick fix.
DAE avatar
JKyle
Posts: 9
Joined: Sun May 24, 2020 2:29 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by JKyle »

Got it.
User avatar
Rocky
Posts: 3556
Joined: Fri Sep 06, 2019 12:57 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by Rocky »

Update: MP4V2 does not support these fragmented MP4 files (fMP4) and modifying it is not a feasible option. I'm looking into other MP4 libraries, such as Bento4, but licensing may be an issue. We'll see.
User avatar
Rocky
Posts: 3556
Joined: Fri Sep 06, 2019 12:57 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by Rocky »

Here is a workaround. Install MP4Box from GPAC. Then issue:

MP4Box -flat frag.mp4 -out unfrag.mp4

The resulting MP4 will be usable in DGDecNV.
User avatar
Rocky
Posts: 3556
Joined: Fri Sep 06, 2019 12:57 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by Rocky »

I found demuxer code without licensing issues that can be used:

https://github.com/DolbyLaboratories/dlb_mp4demux

It properly demuxes both of the test files. Need to add support for other audio types but this looks like the way to go to get support for fMP4 and DolbyVision in DGDecNV. Bonus: works for linux too.
User avatar
Rocky
Posts: 3556
Joined: Fri Sep 06, 2019 12:57 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by Rocky »

Forked off DGIndexNV to begin the upgrade to the MP4 support.
User avatar
Sherman
Posts: 576
Joined: Mon Jan 06, 2020 10:19 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by Sherman »

I got this, Rocky. Get some rest.
DAE avatar
Guest 2
Posts: 903
Joined: Mon Sep 20, 2010 2:18 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by Guest 2 »

Rocky wrote:
Wed Jul 21, 2021 1:46 pm
Forked off DGIndexNV to begin the upgrade to the MP4 support.
What about AV1 decode on newer cards? Not that I could permit one... :D
User avatar
Rocky
Posts: 3556
Joined: Fri Sep 06, 2019 12:57 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by Rocky »

Please use the feature requests thread. Kinda OT here.
User avatar
hydra3333
Posts: 394
Joined: Wed Oct 06, 2010 3:34 am
Contact:

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by hydra3333 »

Rocky wrote:
Wed Jul 21, 2021 1:46 pm
Forked off DGIndexNV to begin the upgrade to the MP4 support.
:hat:
User avatar
Rocky
Posts: 3556
Joined: Fri Sep 06, 2019 12:57 pm

DGIndexNV fails to open Dolby Vision Profile 5/Profile 8.1 mp4/HEVC files

Post by Rocky »

So, Sherman punted and I agree that it is a massive development effort. Therefore, we've decided not to change the MP4 library but rather to provide a workaround for these files. I append below the file from the 2030 slipstream that contains the demuxer and explains things.
How to process fragmented MP4 files with DGDecNV
------------------------------------------------

A fragmented MP4 contains a series of segments (fragments) that
can be requested individually. This allows for transferring unbounded
streams of multimedia data, i.e., streaming. DGDecNV uses the MP4V2
library for parsing MP4 files. This library does not support fragmented
MP4 files.

Replacing the MP4V2 library in DGDecNV with code that supports fragmented MP4
files is a very large coding effort that cannot currently be justified. Neither
are many people asking for support nor do I have any personal use for it.
Also, now that DGDecNV is freeware, it is hard to justify spending lots of
development time on this feature. Instead, therefore, I provide and document
a workaround that will allow you to process fragmented MP4 files with DGDecNV.

One option is to try to convert the fragmented MP4 file to an unfragmented
MP4 file. For example, this can be achieved by using MP4Box (from GPAC) as
follows:

MP4Box -flat frag.mp4 -out unfrag.mp4

While this works fine for plain-vanilla fragmented MP4 files,
it fails for some files, e.g., for fragmented files containing DolbyVision
metadata streams (dvh1). That appears to be a deficiency of MP4Box. Accordingly,
I do not recommend this method and instead provide an MP4 demultiplexer that
works with fragmented MP4 files, including those containing DolbyVision dvh1
streams. This demultiplexer is named 'mp4demuxer' and is derived from Dolby's
program named dlb_mp4demux. It is shipped with DGDecNV under the BSD 3-clause
license. The video elementary streams demuxed by mp4demuxer can be processed
straightforwardly with DGDecNV and the audio elementary streams can be processed
by standard audio tools.

For usage details issue the command:

mp4demuxer --help

The demuxer currently supports demuxing of the following stream types:

MPEG2 video
AVC video
HEVC video (including DolbyVision metadata streams)
AC3 audio
EAC3 audio
AAC audio

MPEG and DTS audio may be added at a future time. These may be falsely detected
as AAC with the current implementation of mp4demuxer.

Note that mp4demuxer can also be used on unfragmented files as long as they
include the supported stream types.

Copyright (c) 2021 Donald A. Graft, All rights reserved.
Post Reply