[SOLVED] Demux Support & CLI

Support forum for DGDecNV
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: Demux Support & CLI

Post by admin »

Please test the attached version (x86). Thanks. It's working for me.
DAE avatar
Zathor
Posts: 94
Joined: Sun Nov 28, 2010 5:06 am

Re: Demux Support & CLI

Post by Zathor »

It does now work, thanks! :D

Have you changed anything? And it even seems to be a full log :bow:
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: Demux Support & CLI

Post by admin »

Well, sure I changed things. :P I didn't change the GUI destroy behavior, I just do the full log now for CLI. To be honest, I don't know why it wasn't working for you before. I would never even suggest PEBCAK.

I'll slipstream the 137 slipstream now. :lol:

Deleting the attached version above.

Haven't forgotten about DGDecIM. Let's wait and see if your MEGUI changes need any further tweaks before doing it.
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: Demux Support & CLI

Post by admin »

I suggest using :salute: now and reserving :bow: for really deserving occasions.

So for Zathor and MEGUI we have :bow:

;)
DAE avatar
Guest 2
Posts: 903
Joined: Mon Sep 20, 2010 2:18 pm

Re: Demux Support & CLI

Post by Guest 2 »

admin wrote:
Sat Mar 24, 2018 11:15 am
BTW, if I can be permitted to brag a little, one of my swimmers won 4 first places at Illinois age group championships last weekend (11-12 age group). I'm taking partial credit. :D
Great.

I restarted to swim at 45. Better: I started to learn modern swimming. It's a great sport.
DAE avatar
Zathor
Posts: 94
Joined: Sun Nov 28, 2010 5:06 am

Re: Demux Support & CLI

Post by Zathor »

admin wrote:
Sun Mar 25, 2018 11:28 am
I suggest using :salute: now and reserving :bow: for really deserving occasions.
As long as those smilies are available they should used ;)
admin wrote:
Sun Mar 25, 2018 11:28 am
So for Zathor and MEGUI we have :bow:
;)
:oops:

Back to topic 8-)
I do not have much time this week and therefore the adjustements are not finished yet. This is only a "FYI" that I am still not ready :?

EDIT: Forgot to ask - is the writing of the log tied to some ini switches? E.g. Enable_Info_Log or Full_Info?
EDIT2: Just saw: viewtopic.php?f=8&t=637
Maybe it makes sense to only write the log when Enable_Info_Log=1 is set?
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: [SOLVED] Demux Support & CLI

Post by admin »

No hurry on your changes and sorry for :oops: you.

MEGUI requires the log for full operation (or it will when you are done). I don't see a downside to assuming the log is enabled for CLI. I do the same thing for the -a option; it ignores the enable demux processing option.
DAE avatar
Zathor
Posts: 94
Joined: Sun Nov 28, 2010 5:06 am

Re: [SOLVED] Demux Support & CLI

Post by Zathor »

While further working on it :
Would it be possible to name the track type beside the file name, too? Something like a prefix (video: audio: subtitle: chapter:)
In the current logic I have only to deal with audio files - now also with the other types. As these are in most scenarious not needed I would delete them but to be sure the track type would be needed (yes, I can do it based on file extension but that would be a static list which can fail).

And is it safe to assume that the files are listed in their track order? So will a file for audio track 2 always written after a file for audio track 1?
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: [SOLVED] Demux Support & CLI

Post by admin »

Understood. Currently, only the audio files are listed. If you need all the others with their type like that I might as well move the track number up front too, as you asked for earlier. And then I could sort by track number also. I'll look into all this today and reply later.

Do you really need all the types listed rather than just the audio?
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: [SOLVED] Demux Support & CLI

Post by admin »

Bump for edit above. I currently only list audio. Do you really need all the others?
DAE avatar
Zathor
Posts: 94
Joined: Sun Nov 28, 2010 5:06 am

Re: [SOLVED] Demux Support & CLI

Post by Zathor »

Ah, I only have tested yet with files containing only audio and only with -a. :oops:
For MeGUI it is sufficient if only audio files are added. Then of course the track type would not be needed.
But maybe others would want to have all extracted files and their types added there? No clue.

I still have to match the log list with the tracks I would like to have. For that either I would need to have the track numbers in a format which will not change (unlike maybe the file names) or if the order of the tracks in the log is always sorted (first track first, second track second, ...) this would also be sufficient.
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: [SOLVED] Demux Support & CLI

Post by admin »

Zathor wrote:
Wed Mar 28, 2018 8:10 am
Ah, I only have tested yet with files containing only audio and only with -a. :oops:
For MeGUI it is sufficient if only audio files are added. Then of course the track type would not be needed.
But maybe others would want to have all extracted files and their types added there? No clue.
OK, I'll leave it as just audio for now.
I still have to match the log list with the tracks I would like to have.
How do you know the tracks you would like to have? The better I understand your needs the better I can meet them.

In my simplistic brain, I would just add the listed files to a listbox and let the user select. That way there is no need to know or care about "track numbers".
DAE avatar
Zathor
Posts: 94
Joined: Sun Nov 28, 2010 5:06 am

Re: [SOLVED] Demux Support & CLI

Post by Zathor »

admin wrote:
Wed Mar 28, 2018 9:10 am
How do you know the tracks you would like to have? The better I understand your needs the better I can meet them.

In my simplistic brain, I would just add the listed files to a listbox and let the user select. That way there is no need to know or care about "track numbers".
Correct, based on the mediainfo of a file a list box gets filled with the audio tracks. Those can be selected by the user.
This selection has to be matched later-on with the demuxed files DGDecNV/IM provides.
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: [SOLVED] Demux Support & CLI

Post by admin »

Ah, now I get why you need this "track number". I keep putting it in quotes because it is not a formal thing, e.g., transport streams have PIDs and no formal track numbers. Yes, we can arbitrarily treat them as track numbers but I'd have to be sure MediaInfo uses those same numbers. I'll experiment to see how they relate.
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: [SOLVED] Demux Support & CLI

Post by admin »

I have a test version for you:

http://rationalqm.us/misc/Zathor.rar

The "track number" is now given at the beginning of the line. The numbers are decimal and the entries are sorted numerically by "track number". E.g., for MKV:

2: D:\tmp\Subtitle Test\PGS\Rambo.First.Blood_34tracks_track2_ger_DELAY 2ms.dts
3: D:\tmp\Subtitle Test\PGS\Rambo.First.Blood_34tracks_track3_eng_DELAY 2ms.dts
4: D:\tmp\Subtitle Test\PGS\Rambo.First.Blood_34tracks_track4_fre_DELAY 2ms.dts
5: D:\tmp\Subtitle Test\PGS\Rambo.First.Blood_34tracks_track5_spa_DELAY 2ms.dts
6: D:\tmp\Subtitle Test\PGS\Rambo.First.Blood_34tracks_track6_ita_DELAY 2ms.dts
7: D:\tmp\Subtitle Test\PGS\Rambo.First.Blood_34tracks_track7_rus_DELAY 2ms.dts

E.g., for MPLS:

4352: H:\GRAVE OF THE FIREFLIES\BDMV\STREAM\00004 PID 1100 L+R 48 1536 eng DELAY 0ms.dts
4353: H:\GRAVE OF THE FIREFLIES\BDMV\STREAM\00004 PID 1101 L+R 48 1536 jpn DELAY 0ms.dts
4354: H:\GRAVE OF THE FIREFLIES\BDMV\STREAM\00004 PID 1102 L+R 48 1536 eng DELAY 0ms.dts

Please let me know if this will do the trick for you and I will slipstream it.
DAE avatar
Zathor
Posts: 94
Joined: Sun Nov 28, 2010 5:06 am

Re: [SOLVED] Demux Support & CLI

Post by Zathor »

Thank you very much! Sadly I cannot test this anymore today but based on your message this seems to be the solution :)

Only small question:

Code: Select all

4352: H:\GRAVE OF THE FIREFLIES\BDMV\STREAM\00004 PID 1100 L+R 48 1536 eng DELAY 0ms.dts
Why is it 4352 and not 1100? And yes, I know that 1100 Hex is 4352 Dec 8-)
So the "track number" is always written in Dec? No need to have it changed I only want to understand it.
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: [SOLVED] Demux Support & CLI

Post by admin »

I can write it as hex if you prefer. The printed number base is completely arbitrary.
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: [SOLVED] Demux Support & CLI

Post by admin »

I looked at MediaInfo. It shows decimal with hex in parentheses. I'll stick with decimal unless you have a good reason not to.
DAE avatar
Zathor
Posts: 94
Joined: Sun Nov 28, 2010 5:06 am

Re: [SOLVED] Demux Support & CLI

Post by Zathor »

Decimal is fine. I only wanted to know if it is always decimal so that I can convert if needed.
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: [SOLVED] Demux Support & CLI

Post by admin »

Yes, it will always be decimal.
DAE avatar
Zathor
Posts: 94
Joined: Sun Nov 28, 2010 5:06 am

Re: [SOLVED] Demux Support & CLI

Post by Zathor »

Some observations while testing around with your "zathor"/138 build ;)
Btw all tests have been successful, I will release the new version soon. :hat:

- if I try to open a AVI file nothing happens (yes, this file type cannot be opened but when I open other file types I get something like "could not find a supported video track (need AVC/MPEG2/VC1/HEVC)". MediaInfo of that (old) file:

Code: Select all

General
Complete name                            : D:\MeGUI\_SAMPLE_FILES\test.avi
Format                                   : AVI
Format/Info                              : Audio Video Interleave
File size                                : 700 MiB
Duration                                 : 1 h 45 min
Overall bit rate mode                    : Variable
Overall bit rate                         : 928 kb/s
Writing application                      : VirtualDubMod 1.5.10.2 (build 2540/release)
Writing library                          : VirtualDubMod build 2540/release

Video
ID                                       : 0
Format                                   : MPEG-4 Visual
Format profile                           : Advanced Simple@L5
Format settings                          : BVOP2
Format settings, BVOP                    : 2
Format settings, QPel                    : No
Format settings, GMC                     : No warppoints
Format settings, Matrix                  : Default (H.263)
Codec ID                                 : XVID
Codec ID/Hint                            : XviD
Duration                                 : 1 h 45 min
Bit rate                                 : 793 kb/s
Width                                    : 608 pixels
Height                                   : 304 pixels
Display aspect ratio                     : 2.000
Frame rate                               : 25.000 FPS
Color space                              : YUV
Chroma subsampling                       : 4:2:0
Bit depth                                : 8 bits
Scan type                                : Progressive
Compression mode                         : Lossy
Bits/(Pixel*Frame)                       : 0.172
Stream size                              : 598 MiB (85%)
Writing library                          : XviD 1.1.2 (UTC 2006-11-01)

Audio
ID                                       : 1
Format                                   : MPEG Audio
Format version                           : Version 1
Format profile                           : Layer 3
Format settings                          : Joint stereo / MS Stereo
Codec ID                                 : 55
Codec ID/Hint                            : MP3
Duration                                 : 1 h 45 min
Bit rate mode                            : Variable
Bit rate                                 : 122 kb/s
Nominal bit rate                         : 128 kb/s
Channel(s)                               : 2 channels
Sampling rate                            : 48.0 kHz
Frame rate                               : 41.667 FPS (1152 SPF)
Compression mode                         : Lossy
Stream size                              : 91.8 MiB (13%)
Alignment                                : Aligned on interleaves
Interleave, duration                     : 24  ms (0.60 video frame)
Interleave, preload duration             : 499  ms
Writing library                          : LAME3.90.
Encoding settings                        : -m j -V 4 -q 2 -lowpass 17.6 --abr 128
- in the file open dialogue the HEVC formats are missing but that may be because my GPU does not support them.

- is there a way how to detect if the GPU is able to decode HEVC? If possible I would love to have a special CLI switch based on which there will be a response which I can then use in MeGUI. Reason is that I would like to enable HEVC if the GPU supports it. Even better would be to also detect if a supported GPU is installed at all.
So something like "dgindexnv.exe -gpu" returns 1 (process exit code) if the GPU is not supported at all, 2 if is supports all except HEVC, 3 if it supports everything.
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: [SOLVED] Demux Support & CLI

Post by admin »

Zathor wrote:
Fri Mar 30, 2018 8:43 am
Btw all tests have been successful, I will release the new version soon.
Cool, thanks.
- if I try to open a AVI file nothing happens (yes, this file type cannot be opened but when I open other file types I get something like "could not find a supported video track (need AVC/MPEG2/VC1/HEVC)".
The difference is that for the other files the container type is supported, while AVI is not. I don't think it's worth doing anything.
- in the file open dialogue the HEVC formats are missing but that may be because my GPU does not support them.
No, they are just missing. Will add them.
- is there a way how to detect if the GPU is able to decode HEVC? If possible I would love to have a special CLI switch based on which there will be a response which I can then use in MeGUI. Reason is that I would like to enable HEVC if the GPU supports it. Even better would be to also detect if a supported GPU is installed at all.
So something like "dgindexnv.exe -gpu" returns 1 (process exit code) if the GPU is not supported at all, 2 if is supports all except HEVC, 3 if it supports everything.
OK, will see what I can do. No guarantees because the checking for HEVC support is not easy without opening a file and trying to create the decoder.
DAE avatar
Zathor
Posts: 94
Joined: Sun Nov 28, 2010 5:06 am

Re: [SOLVED] Demux Support & CLI

Post by Zathor »

admin wrote:
Fri Mar 30, 2018 9:09 am
OK, will see what I can do. No guarantees because the checking for HEVC support is not easy without opening a file and trying to create the decoder.
Do not spend too much time into it. It os not worth too much effort. In worst case I can add an option to MeGUI where a user can enable the HEVC support.

Sadly I found during my final implementation test one remaining change I would like to request.

With this command line:
""D:\MeGUI\MeGUI_dgindexnv\bin\x86\Debug\tools\dgindexnv\dgindexnv.exe" -i "D:\MeGUI\00072.m2ts" -o "D:\MeGUI\f4aekuby.jmz\00073.dgi" -h -a
This log is created:
D:\MeGUI\00072.log
While I would have expected this:
D:\MeGUI\f4aekuby.jmz\00073.log

Could you please change it that it is written in the project / dgi file path with dgi / project name? EDIT: Or in other words - use -o instead of -i to define the log path & name.
Especially the path is important as e.g. with Blu-rays or other readonly media it will be impossible to write to the source file folder.

Thank you very much again and I am sorry for all these requests :-(
User avatar
admin
Posts: 4551
Joined: Thu Sep 09, 2010 3:08 pm

Re: [SOLVED] Demux Support & CLI

Post by admin »

OK, makes a lot of sense. I'll slip it when I get back from swimming. Check back in about 4-5 hours.
DAE avatar
Zathor
Posts: 94
Joined: Sun Nov 28, 2010 5:06 am

Re: [SOLVED] Demux Support & CLI

Post by Zathor »

Thanks, but please take your time. I will already be sleeping when you are back and tomorrow likely I do not have any time so before Monday it will be hard for me to do the final check.
Post Reply