Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > General > DVD2AVI / DGIndex

Reply
 
Thread Tools Search this Thread Display Modes
Old 11th May 2022, 20:46   #1  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
*SOLVED* DGIndexNV __del__ dont work

*SOLVED* , see post #4.

What am I doing wrong with the __del__ template macro ?

I use the __del__ template macro all of the time in DGIndex and works ok, but in DGIndexNV, I have not (I think) had it ever work as desired.

Here is a template [or at least the start of it]

Code:
VideoFileName   ="__vid__"
AudioFileName   ="__aud__"
AudioDelay      =Value("__del__")  # this works fine in DgIndex

# below just testing if works
TEST_DEL  = "__del__"
TEST_CROP = "__crop__"
TEST_H2S  = """__h2s__"""    # EDIT: Fixed, Enclosed in Triple dQuotes, as h2s macro can contain double quotes
Code:
VideoFileName   ="D:\___BLURAY\T\Inch.dgi"
AudioFileName   ="D:\___BLURAY\T\Inch_track2_eng_DELAY 3003ms.dts"
AudioDelay      =Value("__del__")  # dont work in DgIndexNV - should be Value("3.003")

# below just testing if everything works
TEST_DEL  = "__del__"
TEST_CROP = ",ct=24,cb=24,cl=0,cr=0"
TEST_H2S  = """mode="pq",white=2000,black=0,gamma=0.42,r=1.00,g=1.00,b=1.00,tm=1.00,roll=0.70""" # EDIT: Fixed, Enclosed in Triple dQuotes, as h2s macro can contain double quotes
Above, did crop internal to DGIndexNV,
and also did the "Enable HDR to SDR" thingy.

What terrible sin did I commit.

EDIT: I can easily extract delay from the audio file name if necessary.

EDIT:

Quote:
Template Settings

DGIndexNV can automatically generate an Avisynth/Vapoursynth script for serving your project. It requires you to specify a template file, such as the following Avisynth one (operation is analogous for Vapoursynth):

loadplugin("...\DGDecodeNV.dll")
loadplugin("...\Decomb.dll")
dgsource("__vid__")
fielddeinterlace()

This is any normal AVS script, except that the DGI file name is replaced with __vid__ (that's two underscores before "vid" and two after). When DGIndexNV creates the AVS script, it replaces __vid__ with the correct DGI file name.

To select and enable a template, use the Settings/Template Settings button to open a dialog that allows you to set your template file as the active template file. After performing a Save Project operation, DGIndexNV uses this file as a template and inserts the right file name whenever it sees __vid__.

You may also use the __aud__ specifier to generate the audio file name. Note that if you are generating more than one audio file, this specifier will refer to the first audio file that is opened. Therefore, to be sure to get the desired audio file, process just one audio stream.

You may also use the __del__ specifier to generate the delay value for use in DelayAudio(__del__).

You may also use the __crop__ specifier to allow the Cropping Tool to export cropping values to the Avisynth script. Important note: for proper operation, the __crop__ macro must NOT be preceded by a comma in the template file, e.g., DGSource("__vid__"__crop__).

You may also use the __h2s__ specifier to generate parameters for HDR to SDR conversion as defined in the HDR to SDR dialog. This typically for DGHDRtoSDR() invocation.

DGIndexNV creates the script file only if it does not already exist or if the 'Overwrite existing script' box is checked. The script file is created in the same directory as the DGI file.

The Template Serttings dialog box displays the current active template folder and the current active template file.

If the 'Enable template' box is unchecked, the template file will not be created.

After a template directory is specified, the template file drop-down box will list all AVS/VPY files in that directory. You may select one of these listed files to specify that file as your active template file.

The option settings are stored in the INI file and so are retained across DGIndexNV invocations.
EDIT: DGIndexNV latest v242, x64.
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 14th May 2022 at 20:22.
StainlessS is offline   Reply With Quote
Old 11th May 2022, 23:27   #2  |  Link
gonca
Registered User
 
Join Date: Jul 2012
Posts: 1,213
Instead of
Quote:
AudioDelay =Value("__del__")
Try
Quote:
DelayAudio(__del__)
Don't know if it will work or if you need quotes, but it might be worth a try
gonca is offline   Reply With Quote
Old 12th May 2022, 11:46   #3  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
Thank you but, As noted in post #1,
Code:
AudioDelay      =Value("__del__")  # dont work in DgIndexNV - should be Value("3.003")
The quotes around "__del__" together with Value(), make it work (ie set AudioDelay to 0.0) when macro is not inserted (on the odd occasion I think) in DGIndex,
it is a safety measure against script failure (Not sure why it fails insert, maybe dont insert delay in DGIndex when extracting audio to WAV {where any delay is always auto fixed to 0.0 in the WAV}).

DelayAudio(__del__) causes failure as __del__ will not be defined; nor even exist.

Preset __del__ = 0.0 beforehand as another failure prevention solution would where macro IS replaced,
result in 0.0 = 0.0 and script failure "Script Error: Left operand of '=' must be a variable name"

Anyways, Graft PM'ed that is not implemented at present and is in the queue for a coming version of DGIndexNV.

Thanks again.

EDIT: I did actually try with DelayAudio(__del__) but no change, resulted in DelayAudio(__del__) and script failure.
[tried, just in case Dquotes confused DGIndexNV for some reason]
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 12th May 2022 at 12:37.
StainlessS is offline   Reply With Quote
Old 14th May 2022, 20:20   #4  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
Problem solved in DG_IndexNV, v243, see here,
https://forum.doom9.org/showthread.p...64#post1969064

Thanks DG, and kedautinh12 for posting the link [eyes like a hawk that man].
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 14th May 2022 at 20:23.
StainlessS is offline   Reply With Quote
Reply

Tags
dgindexnv

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 07:27.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.