[RESOLVED] Demuxed h264 video: unable to open
[RESOLVED] Demuxed h264 video: unable to open
Hi,
I found out that I can not make any use of the .h264 files demuxed from Blu-ray-sourced .m2ts files by DGIndexNV. I tried importing demuxed .h264 files to Scenarist BD at work and EasyBD Lite at home, both throw errors on input.
Of course usually this is not a problem because there are plenty of tools out there to extract .h264 streams from .m2ts files so that BD authoring tools accept them (ffmpeg does this nicely too). But the problem is I don't have source .m2ts anymore, there are gone and not obtainable again. The .h264 files demuxed by DGIndexNV are obviously OK (DGIndexNV opens and plays them), I just can't make BD authoring tools accept the files.
Is there a solution for me (except for re-encoding through DGDecNV)?
I found out that I can not make any use of the .h264 files demuxed from Blu-ray-sourced .m2ts files by DGIndexNV. I tried importing demuxed .h264 files to Scenarist BD at work and EasyBD Lite at home, both throw errors on input.
Of course usually this is not a problem because there are plenty of tools out there to extract .h264 streams from .m2ts files so that BD authoring tools accept them (ffmpeg does this nicely too). But the problem is I don't have source .m2ts anymore, there are gone and not obtainable again. The .h264 files demuxed by DGIndexNV are obviously OK (DGIndexNV opens and plays them), I just can't make BD authoring tools accept the files.
Is there a solution for me (except for re-encoding through DGDecNV)?
Re: Demuxed h264 video: unable to open
Mux them to mkv with mkvmerge or eac3to? Or to m2ts with tsMuxer?
Why are you demuxing it in the first place?
Why are you demuxing it in the first place?
Re: Demuxed h264 video: unable to open
@artol
Please give me your ffmpeg command for demuxing. Then I can compare what it produces to what DGIndexNV produces. Alternatively, using a M2TS that you have, demux with both and give me links to the two resulting raw files. It doesn't have to be very large, 50MB or so should be fine.
Please give me your ffmpeg command for demuxing. Then I can compare what it produces to what DGIndexNV produces. Alternatively, using a M2TS that you have, demux with both and give me links to the two resulting raw files. It doesn't have to be very large, 50MB or so should be fine.
Re: Demuxed h264 video: unable to open
@admin,
My bad, I found that ffmpeg demux is also problematic. It is actually eac3to which does demuxes that I can import to the BD-authoring suites:
Two samples are here: http://www.sendspace.com/filegroup/RE9d ... ETbuxsw7Zw .
@ Nick007,
I did try to make .m2ts using tsMuxer to demux it to "valid" .h264. It didn't work, such files are still rejected.
My goal is to author standard-complaint Blu-ray (HDMV, not AVCHD) using this video. I can't use tsMuxer for final disc because its HDMV generation is too unreliable.
My bad, I found that ffmpeg demux is also problematic. It is actually eac3to which does demuxes that I can import to the BD-authoring suites:
Code: Select all
eac3to.exe 00000.m2ts -demux
@ Nick007,
I did try to make .m2ts using tsMuxer to demux it to "valid" .h264. It didn't work, such files are still rejected.
My goal is to author standard-complaint Blu-ray (HDMV, not AVCHD) using this video. I can't use tsMuxer for final disc because its HDMV generation is too unreliable.
Re: Demuxed h264 video: unable to open
The differences are very interesting. Can you please give me the M2TS that you demuxed those two from (again, 50MB of the M2TS should be fine)? With that I'll be able to get to the bottom of this. Thank you.
Re: Demuxed h264 video: unable to open
There are two differences between the eac3to and dgindexnv demuxed files:
1. The dgindexnv file has an extra copy of the first SPS at the start of the file. This *should* be harmless.
2. This change to every SPS (eac3to has changed these from the original SPS):
> num_units_in_tick: 1 [ORIGINAL]
> time_scale: 48
---
< num_units_in_tick: 1000 [EAC3TO]
< time_scale: 48000
These two *should* be equivalent.
To find out which of these is causing a problem for your tools, I have patched the dgindexnv demuxed stream to remove the extra SPS but leave the original num_units_in_tick and time_scale. Please download this patched stream and advise whether your tools accept it.
http://rationalqm.us/misc/dg_patched.h264
1. The dgindexnv file has an extra copy of the first SPS at the start of the file. This *should* be harmless.
2. This change to every SPS (eac3to has changed these from the original SPS):
> num_units_in_tick: 1 [ORIGINAL]
> time_scale: 48
---
< num_units_in_tick: 1000 [EAC3TO]
< time_scale: 48000
These two *should* be equivalent.
To find out which of these is causing a problem for your tools, I have patched the dgindexnv demuxed stream to remove the extra SPS but leave the original num_units_in_tick and time_scale. Please download this patched stream and advise whether your tools accept it.
http://rationalqm.us/misc/dg_patched.h264
Re: Demuxed h264 video: unable to open
Works with EasyBD Lite! Will check also with Scenarist BD tomorrow.
Re: Demuxed h264 video: unable to open
Good to hear.
I'm thinking it is not so much the extra SPS that causes the problem, but that it is the lack of an AUD NALU before it. So can you please also check this file (which has the extra SPS also preceded by an AUD):
http://rationalqm.us/misc/dg_patched_2.h264
Once we arrive at the crucial factor I will release a fix for DGIndexNV. Thank you for pointing this out and assisting me to find the cause.
I'm thinking it is not so much the extra SPS that causes the problem, but that it is the lack of an AUD NALU before it. So can you please also check this file (which has the extra SPS also preceded by an AUD):
http://rationalqm.us/misc/dg_patched_2.h264
Once we arrive at the crucial factor I will release a fix for DGIndexNV. Thank you for pointing this out and assisting me to find the cause.
Re: Demuxed h264 video: unable to open
This one is quirky: EasyBD Lite imports the file and compiles the Blu-ray, though the "Video File Properties" button gets disabled in EasyBD Lite interface (it was working with the previous file).
Re: Demuxed h264 video: unable to open
There's more: my Panasonic DMP-BD75 does not play the Blu-ray compiled with the last file (black screen, than "playback stopped").
Blu-ray compiled with the previous version (dg_patched.h264) is playable.
Blu-ray compiled with the previous version (dg_patched.h264) is playable.
Re: Demuxed h264 video: unable to open
OK, thank you. I will make a fixed version for you to test.
Re: Demuxed h264 video: unable to open
Scenarist BD: dg_patched.h264 is fine, dg_patched_2.h264 gives "ERROR: The picture is not encoded as multi-slice picture with 4 or more slices per picture in case of Level 4.1.(Slice:0)".
Re: Demuxed h264 video: unable to open
I plan to add an option called "strict demuxing". It will avoid outputting the extra SPS/PPS's at the start. This will help you for future projects but not the ones you have already demuxed. You can fix those with a binary editor (such as Hex Editor Neo) by deleting the extra leading SPS/PPS's.
Re: Demuxed h264 video: unable to open
Thank you for the upcoming feature. As for my existing files, the SPS/PPS tip was priceless - I was able to fix them manually after some research on h264 binary structure. Kudos for exceptionally quick response!
Re: Demuxed h264 video: unable to open
I wonder if you might kindly relate for posterity an example of one of these repairs.artol wrote:As for my existing files, the SPS/PPS tip was priceless - I was able to fix them manually after some research on h264 binary structure.
Re: Demuxed h264 video: unable to open
My quick-and-dirty way was to find third occurrence of 00 00 01 byte sequence in the stream (NAL Unit header start) and delete everything before.
Re: Demuxed h264 video: unable to open
Thanks for telling!artol wrote:My quick-and-dirty way was to find third occurrence of 00 00 01 byte sequence in the stream (NAL Unit header start) and delete everything before.
Re: Demuxed h264 video: unable to open
That may not always be correct, because there may be multiple extra SPS/PPS's.
The reliable way is to look for the first AUD 00 00 01 09, and delete all the preceding NALUs, i.e., everything before the 00 00 01 09.
The reliable way is to look for the first AUD 00 00 01 09, and delete all the preceding NALUs, i.e., everything before the 00 00 01 09.
Re: Demuxed h264 video: unable to open
I have released version 2046 that contains a workaround for this. Set Bare_Demux=1 in your INI file. Then demuxed files will be compatible with your authoring application.
Re: [RESOLVED] Demuxed h264 video: unable to open
I have tested the new version. It works nicely. Thank you very much.
Re: [RESOLVED] Demuxed h264 video: unable to open
Thanks for the status update and for bringing this issue to my attention.