Page 1 of 1

[RESOLVED] 3D Demuxing requests

Posted: Tue Jul 07, 2020 5:01 pm
by arrgh
I have the following remarks and requests, mostly because I'm targetting mkv-remuxes:
first of all thanks for dealing with 3D (MVC) demuxing; it's not so cool anymore nowadays...

to the topic:

- sub titles:
they need an 3D-plane to be projected correctly relative to the video (that is needed info for mkv muxing and ISO muxing);
the 3D-plane can be extracted for example by using tsmuxer.exe which can extract the meta data of the playlist:

Code: Select all

tsmuxer.exe G:\BDMV\PLAYLIST\00022.mpls >tsmuxer.txt
the textfile can be parsed to extract for each PGS stream his individual 3D-plane;
I don't use tsmuxer because I mux to mkv; for mkv the two videostreams must be interlaced, in a for me unknown way, to one video stream so, that mkvtoolnix can stomach it;
threfore I use MakeMKV in a first step; it does the interlacing and stores the 3D-plane info in the tags which can be extracted by MKVToolnix's mkvextract.exe:

Code: Select all

mkvextract.exe  "MakeMKV.mkv" tags "tags.txt"
therefore it would be very good to have already during/after demuxing the 3D-plane in a trackspecific text file, like "00022 PID 1200 eng.txt"; it would make it a one-stop-solution without the need for another tool...

during muxing of the mkv this plane-info can be attached to each PGS with a xml-snipet, like:

Code: Select all

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE Tags SYSTEM "matroskatags.dtd">
 
<Tags>
 <Tag>
    <Simple>
      <Name>3d-plane</Name>
      <String>6</String>
    </Simple>
 </Tag>
</Tags>
- video stream:
now comes the more difficult part, but for mkv muxing crucial... the interlacing of the "264" with the "mvc" stream; this is something MakeMKV can do but MKVToolnix not...;
if one demuxes with mkvextract.exe the videostrean out of a MakeMKV file, one gets a "avc" file which has the size around the combined sizes of the .264 and the .mvc file; MediaInfo reports "MultiView_Count:2";
but: I did not manage yet to remux this extracted video stream with mkvmerge into a new mkv... it does not support this...
here is a discussion on why it is not working as expected...
https://forum.doom9.org/showthread.php? ... ost1917814
https://gitlab.com/mbunkus/mkvtoolnix/-/issues/2709

so, it seem the interlaced "avc" stream would need to be wrapped in a mkv-container...
if needed, I could provide samples of the 264, mvc and resulting (demuxed "avc" streams...

Thanks

Re: DGDemux development

Posted: Wed Jul 08, 2020 6:17 am
by Rocky
3D subs: Will need to look into this. Can you suggest an appropriate disk (with link to purchase) that I can use. I currently have TOY_STORY_4_3D and PROMETHEUS_3D.

3D stream interleaving: I can give you a small app I made back in 2014 that combines the separate base and dependent streams into a single stream. Will that be good enough for you? It could potentially be integrated into DGDemux but that would be lower on my priority list right now as I have several hard bug reports.

Re: DGDemux development

Posted: Wed Jul 08, 2020 1:39 pm
by arrgh
@Rocky
thank you very much; yes, the tool would be very interesting and an option in DGDemux to do this directly during demuxing even more...;
I will still have to check how to get this into a mkv, since the author of mkvtoolnix is not willing to implement this...
but, again, yes, to have such a tool would be good. Is the output of the tool similar (I do not want to use the word "identical") what can be found in the MakeMKV files?

to the pgs:
every 3d-Bluray should have some pgs; the examples uploded above are from Valerian, European/German version, so I'm not sure whether that is available in US; I would assume that at least the English PGS should have the same 3d-plane also in a US version of the disk:

Code: Select all

...
Track ID:    4609
Stream type: PGS
Stream ID:   S_HDMV/PGS
Stream info: Presentation Graphic Stream #1   3d-plane: 1
Stream lang: eng

...

Track ID:    4611
Stream type: PGS
Stream ID:   S_HDMV/PGS
Stream info: Presentation Graphic Stream #3   3d-plane: 3
Stream lang: eng
...
https://www.amazon.com/-/us/Valerian-BD ... 231&sr=8-4

Thanks!

Re: DGDemux development

Posted: Thu Jul 09, 2020 9:42 am
by Rocky
I have updated slipstream 30 to include the combining tool. I cannot help with MKVTOOLNIX. It's authors have been contemplating this for over 5 years.

Looking into the planes thing.

Re: DGDemux development

Posted: Thu Jul 09, 2020 3:33 pm
by arrgh
Rocky wrote:
Thu Jul 09, 2020 9:42 am
I have updated slipstream 30 to include the combining tool.
...
excellent! I have tested it and the resulting file is in respect of size in the correct range; once I have somehow managed to mux it into an mkv, I will report..
Rocky wrote:
Thu Jul 09, 2020 9:42 am
...
I cannot help with MKVTOOLNIX. It's authors have been contemplating this for over 5 years.
...
yesssss, I know :(

Re: 3D Demuxing requests

Posted: Thu Jul 30, 2020 5:10 pm
by Rocky
How about if I include the plane number in the filename of the demuxed PGS stream?

Re: 3D Demuxing requests

Posted: Sat Aug 01, 2020 9:54 pm
by Rocky
If you are no longer interested in this, then I won't be too.

Re: 3D Demuxing requests

Posted: Mon Aug 03, 2020 4:58 pm
by arrgh
of course I'm interested !
I think it would be easier to have this info either in the analysis txt file like...

Code: Select all

...
1109: AC3 5.1 48 640 [pol]
110a: AC3 5.1 48 640 [por]
12a0: PGS subtitles [eng] 3D-plane 3
12a1: PGS subtitles [eng] 3D-plane 6
12a2: PGS subtitles [ara] 3D-plane 1
...
or in a separate txt file like
Track 12a0 eng.txt

Thanks!!

Re: 3D Demuxing requests

Posted: Mon Aug 03, 2020 7:10 pm
by Rocky
OK, do you need me to report the actual offsets too, as read from the SEI message?

Re: 3D Demuxing requests

Posted: Tue Aug 04, 2020 4:47 pm
by arrgh
:o :oops:
difficult question for me...
up to now (where I was "only" muxing with MKVToolnix the video from MakeMKV with customized audio and pgs into a new MKV) I used only the 3D plane and it worked ok;
I'm unsure whether MakeMKV preserves additional data in the video or the MKV-container which are used by MKVToolnix automatically without me knowing ...
and I don't know whether your Combine tool creates files with the same metadata, MakeMKV provides;

it can be that such additional info is more needed for the muxing of an norm-compliant ISO... here I'm out of my turf, sorry...
(but in general obviously every data preserved could be of use later...)

Re: 3D Demuxing requests

Posted: Tue Aug 04, 2020 7:34 pm
by Rocky
Gotcha, thanks.

Re: [RESOLVED] 3D Demuxing requests

Posted: Fri Aug 07, 2020 8:29 am
by Rocky
Marking RESOLVED as slipstream 36 reports the plane numbers and generates tag files.

Re: [RESOLVED] 3D Demuxing requests

Posted: Fri Aug 07, 2020 6:40 pm
by arrgh
:bow:
excellent!!!!
now I have some homework to adjust my batch-procedures. Hopefully MKVToolnix will be also able to use your "combined" video file to mux into mkv; up to now it is still relying on MakeMKV.

anyway: super support, especially concerning the tag files... :D

Re: [RESOLVED] 3D Demuxing requests

Posted: Fri Aug 07, 2020 10:45 pm
by Curly
You're a good guy, arrgh. We're so lucky to have you. I'm known as an acute thinker so don't doubt me:

https://youtu.be/aMqoJG6GDdw?t=25