DGDemux development

User avatar
Rocky
Posts: 3555
Joined: Fri Sep 06, 2019 12:57 pm

Re: DGDemux development

Post by Rocky »

gonca wrote:
Sat Dec 07, 2019 8:27 pm
Both are affected and yet DGIndexNV demuxes what appears to be a good mpeg file
You must have an earlier version of DGIndexNV.
DAE avatar
Guest

Re: DGDemux development

Post by Guest »

Yes, I am on slipstream 191, been meaning to update to the latest release
User avatar
Rocky
Posts: 3555
Joined: Fri Sep 06, 2019 12:57 pm

Re: DGDemux development

Post by Rocky »

Better hold off until 195 tomorrow. I'm swilling Brut right now, so that's it for today.

Thank you so much for this trouble report, gonca. You're saving our asses. Hoo-yah. :lol:
User avatar
redbtn
Posts: 44
Joined: Sat Nov 16, 2019 2:35 pm

Re: DGDemux development

Post by redbtn »

Happy Birthday, Rocky!
User avatar
Rocky
Posts: 3555
Joined: Fri Sep 06, 2019 12:57 pm

Re: DGDemux development

Post by Rocky »

Thank you, redbtn.

@zqslzwzw

I have your system locale issue fixed on my Chinese PC. :D I'll port it back to The Beast and make a release.
User avatar
Rocky
Posts: 3555
Joined: Fri Sep 06, 2019 12:57 pm

Re: DGDemux development

Post by Rocky »

Here is version 1.0.0.12:

* Fixed system locale handling for the Browse Output function.

* Now list shortened names for the M2TS list.

* Don't include newlines on the GUI stream entry strings.

http://rationalqm.us/dgdemux/DGDemux_1.0.0.12.rar
DAE avatar
Guest

Re: DGDemux development

Post by Guest »

* Now list shortened names for the M2TS list.
Version .11
11.png
Version .12
12.png
The m2ts list looks identical, or am I missing something
User avatar
Rocky
Posts: 3555
Joined: Fri Sep 06, 2019 12:57 pm

Re: DGDemux development

Post by Rocky »

Make sure the GUI 1.0.0.11 is using DGDemux 1.0.0.11 and not DGDemux 1.0.0.12. Failing that I cannot see how you could achieve this result.
DAE avatar
zqslzwzw
Posts: 18
Joined: Fri Nov 29, 2019 8:35 am

Re: DGDemux development

Post by zqslzwzw »

Rocky wrote:
Sun Dec 08, 2019 2:56 pm
Here is version 1.0.0.12:

* Fixed system locale handling for the Browse Output function.

* Now list shortened names for the M2TS list.

* Don't include newlines on the GUI stream entry strings.

http://rationalqm.us/dgdemux/DGDemux_1.0.0.12.rar
Cool! Surprise comes from almighty Rocky every morning in GMT+8. Now I do not know any major issue of DGDemux.
DAE avatar
Guest

Re: DGDemux development

Post by Guest »

I have deleted all instances of DGDemux and re downloaded version .12
I still get the same results
You can see the cmd line entries in the images. The right exe is being used
User avatar
Bullwinkle
Posts: 338
Joined: Thu Sep 05, 2019 6:37 pm

Re: DGDemux development

Post by Bullwinkle »

Maybe that got put in for 1.0.0.11. Is it working good for you?
DAE avatar
Guest

Re: DGDemux development

Post by Guest »

The demuxing is working really well for me
I was just wondering about the list shortened names for the M2TS list since I didn't see any difference
User avatar
Bullwinkle
Posts: 338
Joined: Thu Sep 05, 2019 6:37 pm

Re: DGDemux development

Post by Bullwinkle »

Maybe compare to 1.0.0.10.
User avatar
redbtn
Posts: 44
Joined: Sat Nov 16, 2019 2:35 pm

Re: DGDemux development

Post by redbtn »

Could not detect frame rate. Skip first doesn't help. If force 23.976 manually it works well. Maybe it's an issue, maybe not.
01281.mpls, files on ftp (4.21gb)
User avatar
Rocky
Posts: 3555
Joined: Fri Sep 06, 2019 12:57 pm

Re: DGDemux development

Post by Rocky »

Thank you for your report, redbtn, acute and precise as always. There is a corner case where it can happen (HEVC with no VPS, need to parse the VI). Hope springs eternal in a young man's breast. Need to get rid of that nonsense. Let's see if that's what you've found...
User avatar
Rocky
Posts: 3555
Joined: Fri Sep 06, 2019 12:57 pm

Re: DGDemux development

Post by Rocky »

He he, AVC. OK, have it fixed locally. Will release tomorrow morning. Thank you.
User avatar
Rocky
Posts: 3555
Joined: Fri Sep 06, 2019 12:57 pm

Re: DGDemux development

Post by Rocky »

Here is version 1.0.0.13:

* Fixed problem with FPS detection for some AVC playlists. [redbtn]

http://rationalqm.us/dgdemux/DGDemux_1.0.0.13.rar
DAE avatar
dragon
Posts: 2
Joined: Fri Nov 15, 2019 3:11 am

Re: DGDemux development

Post by dragon »

Thanks for you hard work on this great tool. I'd like to request a feature. I hope it's alright. Maybe suggest, more then request, you guys be the judge.

Let's take "Odette" as a BD Folder with a standard structure: Odette\BDMV\PLAYLIST

Feature: Making demuxing more flexible.

Code: Select all

DGDemux -i Odette
should give us the list of available playlists from which we can choose which one to demux. This is important because BD may have 20 or 100 different playlists, I need for a demuxing tool to be able to tell me something about them.
Info that eac3to gives is something like this:

Code: Select all

1) 00000.mpls, 00000.m2ts, 1:57:30
   - Chapters, 12 chapters
   - h264/AVC, 1080p24 (16:9)
   - RAW/PCM, English, stereo, 48kHz

2) 00007.mpls, 00011.m2ts, 0:27:09
   - h264/AVC, 1080p24 (16:9)
   - RAW/PCM, English, stereo, 48kHz

3) 00002.mpls, 00003.m2ts, 0:20:43
   - h264/AVC, 1080p24 (16:9)
   - RAW/PCM, English, stereo, 48kHz

4) 00003.mpls, 00004.m2ts, 0:19:35
   - h264/AVC, 1080p24 (16:9)
   - RAW/PCM, English, stereo, 48kHz
Which is kind of a general overview of playlists, their playtimes, which m2ts files they contain and so on.
Then you should be able to choose which one you want to demux.

Code: Select all

DGDemux -i Odette -p 1
where -p is playlist number.

The next screen should be numbered list of streams inside that playlist, kinda like how dgdemux lists them.
dgdemux:

Code: Select all

Streams:
1011: Video [AVC]
1100: PCM 48K 24bit 2/0 [eng]
1200: PGS subtitles [eng]
1201: PGS subtitles [eng]
eac3to:

Code: Select all

M2TS, 1 video track, 1 audio track, 2 subtitle tracks, 1:57:30, 24p
1: Chapters, 12 chapters
2: h264/AVC, 1080p24 (16:9)
3: RAW/PCM, English, 2.0 channels, 24 bits, 48kHz
4: Subtitle (PGS), English
5: Subtitle (PGS), English
I think it's more convenient to have them listed as base10 numbers instead of base16.

After this, 1 version would be to let you demux them.

Code: Select all

DGDemux -i Odette -p 1 -o output\
As a second version, I think it's very important that we are able to name them.

Code: Select all

DGDemux -i Odette -p 1 -demux 1:chapters 2:video 3:audio 4:eng_subtitles_1 5:eng_subtitles_2 -o output\
output of which should be:

Code: Select all

chapters.txt video.264 audio.pcm eng_subtitles_1.sup eng_subtitles_2.sup
Also, it'd be great if we were allowed to omit the -o ... option. If not provided, dgdemux should assume that we want to demux into the folder that are at that moment.

In which case, it would just be:

Code: Select all

DGDemux -i Odette -p 1
or

Code: Select all

DGDemux -i Odette -p 1 -demux 1:chapters 2:video 3:audio 4:eng_subtitles_1 5:eng_subtitles_2
Note that for -o ... option, I just included a folder named "output". I think dgdemux should deduce a naming scheme based on something from the -i ... option.
For example, if I'm demuxing -p 1, which is playlist 00000.mpls, sensible automatic naming scheme for the tracks might be:

Code: Select all

1: Chapters, 12 chapters				: 00000_1.txt
2: h264/AVC, 1080p24 (16:9)				: 00000_2.264
3: RAW/PCM, English, 2.0 channels, 24 bits, 48kHz	: 00000_3.pcm
4: Subtitle (PGS), English				: 00000_4.sup
5: Subtitle (PGS), English				: 00000_1.sup
so basically, playlist_track_number.extension, this only matters of course if user doesn't provide individual track names with -demux.

Sorry about a very long post, none of this is a criticism of your work, I just want this tool to be better, I hope you will consider these suggestions and implement them in time.
User avatar
Rocky
Posts: 3555
Joined: Fri Sep 06, 2019 12:57 pm

Re: DGDemux development

Post by Rocky »

Thank you, dragon, and welcome to the forum. Yes, I have that on my to-do list and will surely keep your suggestions in mind when I go to implement that stuff.
User avatar
Rocky
Posts: 3555
Joined: Fri Sep 06, 2019 12:57 pm

Re: DGDemux development

Post by Rocky »

Got the garbage skipping working for CROUPIER. I'd like to ask users whether they think garbage skipping should be optional, i.e., should there be an option to not skip garbage? I always prefer not to have unnecessary options. Can anyone see a use case where it might be desirable to retain content outside the playlist in<-->out times? After this is decided I'll make a release.

BTW, I also enhanced the GUI to do an automatic re-browse when the skip first or skip last boxes are checked/unchecked after an MPLS has been loaded. Much more friendly!
DAE avatar
dragon
Posts: 2
Joined: Fri Nov 15, 2019 3:11 am

Re: DGDemux development

Post by dragon »

Rocky wrote:
Sun Dec 15, 2019 11:19 am
Got the garbage skipping working for CROUPIER. I'd like to ask users whether they think garbage skipping should be optional, i.e., should there be an option to not skip garbage? I always prefer not to have unnecessary options. Can anyone see a use case where it might be desirable to retain content outside the playlist in<-->out times? After this is decided I'll make a release.

BTW, I also enhanced the GUI to do an automatic re-browse when the skip first or skip last boxes are checked/unchecked after an MPLS has been loaded. Much more friendly!
By garbage skipping do you mean cases were "skip first" is applicable? Like Kino Lorber discs that have 11.010s m2ts clip at the beginning that causes audio/subtitle out-of-sync issue because intro m2ts just consists of the video stream and not the audio/subtitle streams?
If that's what you mean, then I'd say that it's not always an issue. Sometimes intro/outro content is useful and skipping them is not a good option.

I do agree with you though, I also prefer for there not to be any unnecessary options. I'm not a huge fan of -sf and -sl options. They kind of bloat the program in my view.

As far as understand, this particular issue arises only when m2ts files that in the playlist don't consist of the same streams. That particular situation raises not only the out-of-sync problem, but other problems such as when some of the m2ts files have 640kbps ac3 audio for example, and some have 448kbps, in the same playlist. What is the output in that case? The way eac3to deals with it is it re-encodes the audio into 640kbps using libAften encoder that it comes with.

Both problems stem from non-consistent list of streams. I think one decent way of dealing with the first problem (out-of-sync issue due to intro) would be for dgdemux to scan m2ts files before demuxing starts, if it discovers that list of streams in all m2ts files of the playlist aren't consistent, then it asks you something like this:

Code: Select all

dgdemux -i MOVIE\BDMV\PLAYLIST\00000.mpls -o output\

Code: Select all

dgdemux
The streams in 00000.mpls [00001.m2ts + 00003.m2ts + 00006.m2ts] aren't consistent:

00001.m2ts		00003.m2ts
1011: Video [AVC]	1011: Video [AVC]		✔
			1100: DTS HDMA L+R 48 1536	✘
			1101: PGS subtitles [eng]	✘
Do you want demux 00000.mpls entirely or skip first m2ts? [d] - demux, [sf] - skip first, [sl] - skip last: ...
Something similar or same could be done for skip last. I think this is a better way then adding command line options that are applicable for less then 1% of blu-ray discs.
Especially when sometimes, 00001.m2ts may not cause issues if audio/video tracks in 00003.m2ts have delay added to them, some studios do this, and in cases like that, demuxing the entire mpls even when first m2ts has no audio/subtitle tracks causes no issues as long as dgdemux respects the delay of the playlist on those tracks.

The second issue, where the audio bit rate/type changes between m2ts files is more difficult to solve I think. I haven't tested how dgdemux handles those, I assume it won't re-encode like eac3to does, and it can't "combine" 2 different bit rate audios so I assume it will demux first one, and skip the second one.
for example, if mpls is 00001.m2ts+00002.m2ts+00003.m2ts, and if 00001.m2ts & 00002.m2ts both have AC3@640kbps audio, but 00003.m2ts has AC3@448kbps audio, I assume dgdemux will demux audio just from first two m2ts files and skip the last one, or it will have an error. But again, I haven't tested it so I don't know. There should be a warning in any case, like the above warning when there are inconsistent streams in m2ts files, so that user is aware that demuxed audio is not viable, then he can decide how to handle it. (hopefully in future, there will be a detailed log where all this will be logged.)
User avatar
Rocky
Posts: 3555
Joined: Fri Sep 06, 2019 12:57 pm

Re: DGDemux development

Post by Rocky »

Garbage refers to content in a playlist that is outside the range defined by the IN_time of the first M2TS and the OUT_time of the last M2TS. This is distinct from -sf and -sl. The IN_time of an M2TS need not correspond to the first video access unit of an M2TS. For example, CROUPIER (one M2TS in the playlist) has almost a full minute of colors bars and blackness before the IN_time, and then some more blackness after the OUT_time.

I appreciate your detailed info and requests, dragon. However, I'm not going to revisit things we have already discussed and decided. -sf and -sl are staying. There are too many weird cases and corner cases to try to automate things. Always prefer the human mind. Also I'm not going to do anything based on just your theory and experience. You will need to cite specific disks with links to purchase and say how they are being misprocessed in your view.
User avatar
Bullwinkle
Posts: 338
Joined: Thu Sep 05, 2019 6:37 pm

Re: DGDemux development

Post by Bullwinkle »

"Always prefer the human mind."

Snort! Moose minds work way better. Moose are awesome!

https://www.youtube.com/watch?v=9T27xFSsxxs
https://www.youtube.com/watch?v=JS2MNeUSDa8

Natasha told me she could help me become a moderator. She knows Forum Mr. Big!
User avatar
Rocky
Posts: 3555
Joined: Fri Sep 06, 2019 12:57 pm

Re: DGDemux development

Post by Rocky »

That's great, Bullwinkle, but we really need a GUI concept for the playlist scanning. Let's go!
User avatar
Boris
Posts: 92
Joined: Sun Nov 10, 2019 2:55 pm

Re: DGDemux development

Post by Boris »

Pottsylvanian coders have already solved your problems. Natasha is explaining it to Bullwinkle right now. He is very excited.

Will it be curtains for Bullwinkle, or we all learn to code?
Post Reply