[RESOLVED] CLIP + cropping

Support forum for DGDecNV
Post Reply
Zathor
Distinguished Member
Distinguished Member
Posts: 88
Joined: Sun Nov 28, 2010 6:06 am

[RESOLVED] CLIP + cropping

Post by Zathor » Sun Dec 02, 2018 1:54 pm

Hello Don,

Based on my current work with DGSource() and cropping and also based on that post (and following) https://forum.???.org/showpost.php?p= ... count=6638 I noticed this issue here, which I cannot explain myself:

Source size (MKV/AVC): 638x398
CLIP 0 2 0 2
(Btw why is the order of the values in CLIP and the default DGSource() crop values different?)

DGSource(dgifile): 638x398 (as expected)
DGSource(dgifile, crop_t=0, crop_b=2, crop_l=0, crop_r=2): error - All crops must be at least mod 4! (here I would have expected the same result as above as this is the cropping based on the CLIP values)
DGSource(dgifile, crop_t=0, crop_b=4, crop_l=0, crop_r=4): 636x396

Why is DGSource() without crop values able to crop something what crop cannot do?

EDIT: Could you maybe add a check that if the crop values match the CLIP values, that it is shown as without any crop values specified?
Or even better, enable MOD2 in crop as it does work in CLIP (e.g. I tested the file above with CLIP 0 6 0 0 and CLIP 2 6 6 0).

Also it would be great if values of 0 would overwrite the CLIP values.

Thanks in advance for any thoughts,
Zathor

User avatar
admin
Site Admin
Posts: 4382
Joined: Thu Sep 09, 2010 3:08 pm

Re: CLIP + cropping

Post by admin » Sun Dec 02, 2018 3:54 pm

I'll look into it all, Zathor. Give me some days. Thank you for the observations and suggestions.

User avatar
admin
Site Admin
Posts: 4382
Joined: Thu Sep 09, 2010 3:08 pm

Re: CLIP + cropping

Post by admin » Sun Dec 02, 2018 7:19 pm

Can you link me to your source file please, Zathor?

Zathor
Distinguished Member
Distinguished Member
Posts: 88
Joined: Sun Nov 28, 2010 6:06 am

Re: CLIP + cropping

Post by Zathor » Mon Dec 03, 2018 2:50 am

Sure, my sample file is:
http://www.mediafire.com/file/x1226kyz6 ... e.mkv/file

Take your time :)

User avatar
admin
Site Admin
Posts: 4382
Joined: Thu Sep 09, 2010 3:08 pm

Re: CLIP + cropping

Post by admin » Mon Dec 03, 2018 7:44 am

Thanks for that. A little heads-up for you: probably the whole CLIP mechanism will be removed and the cropping dialog will become a cropping calculator, that just gives you values you can subsequently use in DGSource() cropping or in the Avisynth cropping. I will check but IIRC the mod 4 limitation on DGSource() cropping is an NVDec limitation. Formally, interlaced YV12 cannot be cropped mod 2, so I suppose that is the reason for it.

Your further thoughts will be appreciated as the main thing is to make things work smoothly in MeGUI.

User avatar
admin
Site Admin
Posts: 4382
Joined: Thu Sep 09, 2010 3:08 pm

Re: CLIP + cropping

Post by admin » Mon Dec 03, 2018 8:33 am

When I index your file I get CLIP 0 4 0 4 but you said CLIP 0 2 0 2. Can you give me a file that produces 0 2 0 2? Thank you.

I need a mod 2 clip to get to the bottom of things and test it with NVDec. I asked the user at the other forum for it but he's being uncooperative so far in giving it to me. You see, he knows better than me and tells me it is "nothing special".

Zathor
Distinguished Member
Distinguished Member
Posts: 88
Joined: Sun Nov 28, 2010 6:06 am

Re: CLIP + cropping

Post by Zathor » Mon Dec 03, 2018 12:42 pm

admin wrote:
Mon Dec 03, 2018 7:44 am
Thanks for that. A little heads-up for you: probably the whole CLIP mechanism will be removed and the cropping dialog will become a cropping calculator, that just gives you values you can subsequently use in DGSource() cropping or in the Avisynth cropping. I will check but IIRC the mod 4 limitation on DGSource() cropping is an NVDec limitation. Formally, interlaced YV12 cannot be cropped mod 2, so I suppose that is the reason for it.
Thanks, sounds great!
If the limitation of mod 4 has to stay, ok, that is then the way to go.
admin wrote:
Mon Dec 03, 2018 8:33 am
When I index your file I get CLIP 0 4 0 4 but you said CLIP 0 2 0 2. Can you give me a file that produces 0 2 0 2? Thank you.
I need a mod 2 clip to get to the bottom of things and test it with NVDec.
Very strange, with that file I do get this dgi file:
https://www.mediafire.com/file/lri4bx73 ... e.dgi/file
which does include CLIP 0 2 0 2
Does it maybe vary based on the engine? I do have a 970 GTX.

User avatar
admin
Site Admin
Posts: 4382
Joined: Thu Sep 09, 2010 3:08 pm

Re: CLIP + cropping

Post by admin » Mon Dec 03, 2018 1:01 pm

Hmm. Can you please give me your DGIndexNV INI file?

Zathor
Distinguished Member
Distinguished Member
Posts: 88
Joined: Sun Nov 28, 2010 6:06 am

Re: CLIP + cropping

Post by Zathor » Mon Dec 03, 2018 1:02 pm

Here it is:

Code: Select all

Version=DGIndexNV 2053.0.0.161
Window_Position=0,0
Info_Window_Position=0,0
Process_Priority=2
Playback_Speed=3
AVS_Template_Folder=
AVS_Template_File=template.avs
AVS_Template_File_Index=0
AVS_Enable_Template=1
AVS_Overwrite=0
Full_Path_In_Files=1
MRUList[0]=D:\MeGUI\file.mkv
MRUList[1]=
MRUList[2]=
MRUList[3]=
Enable_Info_Log=1
Loop_Playback=0
AVC_Extension=264
MPG_Extension=m2v
VC1_Extension=vc1
HEVC_Extension=265
Deinterlace=0
UsePF=0
AlwaysCrop=1
UseD3D=0
Snapped=0
ResponseOnAudioMismatch=1
Enable_Audio_Demux=1
CUDA_Device=255
Decode_Modes=0,0,0,0
Full_Info=1
Bare_Demux=0
Disable_Encrypted_Audio_Warning=0
Fine_Cropping=0
Force_Zoom=0
StrictAVC=0
PGSForcedOnly=0

Zathor
Distinguished Member
Distinguished Member
Posts: 88
Joined: Sun Nov 28, 2010 6:06 am

Re: CLIP + cropping

Post by Zathor » Mon Dec 03, 2018 1:17 pm

And if it helps this was the command line used:
"D:\MeGUI\MeGUI_dgindexnv\bin\x86\Debug\tools\dgindexnv\dgindexnv.exe" -i "D:\MeGUI\file.mkv" -o "D:\MeGUI\file.dgi" -h

Post Reply