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 > Capturing and Editing Video > Avisynth Development

Reply
 
Thread Tools Search this Thread Display Modes
Old 31st March 2016, 17:57   #1  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 980
MVTools-pfmod

Get latest version from here:
MvTools2 with depans, release pages

Historical part here:
----

I'd like to announce my first published plugin mod.

mvtools-pfmod 2.7.0.1

- based on mvtools 2.6.0.5
- Sorry, no new colorspaces, just v2.6 API
- access violation fixes
- Intel C++ 16 build with Visual Studio 2015
- 32 and 64 bit versions
- works like a charm with latest AVS+ r1828-MT (though I didn't have problems with 2.6.0.5)

Background (chain reaction):
- Once I tried to use DepanStabilize on vapoursynth. The reason was that vapoursynth offers 16 bit color depth natively, and I have modified DepanStabilize for using stacked input.
- One day I changed my vapoursynth to 64bit only.
- I realized that DepanStabilize is 32bit only, so I compiled it to 64 bit.
- But VapourSynth did not allow to use old 2.5 AVS API for x64. So I modified DepanStabilize for v2.6 API.
- At that time I had no confidence porting DepanEstimate to x64 (input for DepanStabilize), tried to use MDepan from the native vapoursynth mvtools. But this function was not ported yet.
- Had to go back to use the 64 bit 2.6.0.5 mvtools on VapourSynth, but it was v2.5 API => ported it
- mvtools MDepan did not work, I had freezes. Learned debugging dlls in visual studio. Caught a famous 0xc0000005 in it and happily fixed it. And myrsloik was kind enough to integrate a hack into vs's avscompat module just because of 64-bit avs mdepan.
- Meanwhile my DepanStabilize-mod got YV24 support, and with stacked high bit depth logic, and I was able to stabilize my 10 bit Prores 444 test files! I reached my goal: my 8mm film restoration project is not starting anymore with dropping to 8bit YV12 right in the very first step.
- The mvtools project stalled - I was busy with fixing avs+ mt slowdown - until recently stax76 had problems under Win10 and the existing x64 mvtools2. After some busy nights another access violation was fixed in the x64 part.
- Thus I had a working mvtools2 version, and didn't want to keep it in secret.
- Finally along with my avs+ branch I had to learn how to create git repos, branch, push, as all these git things are new to me.

So please use this mod with fun.

Last edited by pinterf; 29th June 2017 at 13:50. Reason: New build 2.7.21.22, changelog removed from here
pinterf is online now   Reply With Quote
Old 31st March 2016, 23:26   #2  |  Link
Fizick
AviSynth plugger
 
Fizick's Avatar
 
Join Date: Nov 2003
Location: Russia
Posts: 2,183
Hi, pinterf!

From your readme.md:
Quote:
Current build as of March 31, 2016:
2.7.0.1 (skipped 2.6.x.x to leave numbering space to the previous authors)
It is a bug
I have small update to original MVTools . And versioning is confusing now. 2.6.x.x is not appropriate for me (it is without Firesledge's additions). May be will use 2.5.11.10,...

P.S. I also have bad 8mm films for restoration.
__________________
My Avisynth plugins are now at http://avisynth.org.ru and mirror at http://avisynth.nl/users/fizick
I usually do not provide a technical support in private messages.
Fizick is offline   Reply With Quote
Old 1st April 2016, 22:17   #3  |  Link
Motenai Yoda
Registered User
 
Motenai Yoda's Avatar
 
Join Date: Jan 2010
Posts: 686
as I remember with overlap = blksize/4 the last rows or coloumns are unfiltered , at least, by mdegrainX
are you planning to fix this?

ps I have 2.6.0.5 version
__________________
powered by Google Translator

Last edited by Motenai Yoda; 1st April 2016 at 22:20.
Motenai Yoda is offline   Reply With Quote
Old 1st April 2016, 23:11   #4  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 980
Quote:
Originally Posted by Fizick View Post
I have small update to original MVTools . And versioning is confusing now. 2.6.x.x is not appropriate for me (it is without Firesledge's additions). May be will use 2.5.11.10,...

P.S. I also have bad 8mm films for restoration.
Restoration project never ends, mine is not even started, always waiting to the best workflow, testing new scripts, re-scan some originals in every two years hoping for the better, ehh, too much time.
But you are back here. Good.

Anyway, that's what I don't like, billions of versions doing almost the same, one fixing this, other's version fixes that, my version fixed some other things. And now it seems that I missed some other (quality) fixes, as Motenai Yoda noticed?
pinterf is online now   Reply With Quote
Old 2nd April 2016, 13:45   #5  |  Link
Overdrive80
Anime addict
 
Overdrive80's Avatar
 
Join Date: Feb 2009
Location: Spain
Posts: 621
Quote:
Originally Posted by Motenai Yoda View Post
as I remember with overlap = blksize/4 the last rows or coloumns are unfiltered , at least, by mdegrainX
are you planning to fix this?

ps I have 2.6.0.5 version
For this, didnt it use int "hpad", int "vpad" of Msuper? I dont remember very fine.
__________________
Intel i7-6700K + Noctua NH-D15 + Z170A XPower G. Titanium + Kingston HyperX Savage DDR4 2x8GB + Nvidia GTX750 2GB DDR5 + SSD Vertex 4 256 GB + Antec EDG750 80 Plus Gold Mod + Corsair 780T Graphite
Overdrive80 is offline   Reply With Quote
Old 2nd April 2016, 16:24   #6  |  Link
Motenai Yoda
Registered User
 
Motenai Yoda's Avatar
 
Join Date: Jan 2010
Posts: 686
Quote:
Originally Posted by Overdrive80 View Post
For this, didnt it use int "hpad", int "vpad" of Msuper? I dont remember very fine.
I didn't investigate too much, as I tried with 16/4 or 32/8 it needs mod64 res...
but I see the same even with overlap=blksize/2, just difference in how many rows or coloumns are unfiltered.

Maybe it's some rounding stuff
__________________
powered by Google Translator

Last edited by Motenai Yoda; 2nd April 2016 at 17:13.
Motenai Yoda is offline   Reply With Quote
Old 29th April 2016, 13:53   #7  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 980
New mvtools2 version on the horizon.
Update: merged with Fizick's 2.5.11.22 version.
More info in the first post.

Download mvtools2 2.7.0.22 for 32 and 64 bit
pinterf is online now   Reply With Quote
Old 30th April 2016, 07:38   #8  |  Link
jpsdr
Registered User
 
Join Date: Oct 2002
Location: France
Posts: 1,621
Out of curiosity i take a qucik look at the asm code, and i've noticed a possible issue in this :
Code:
%macro RB2CubicHorizontalInplaceLine_SSE_macro 3 ; weight1, weight2, shift
[endprolog]
                xchg rdx, rcx		; pSrc, nWidthMMX
;                mov rdx, pSrc
;                mov rcx, nWidthMMX
            ; prepare constants
                pcmpeqw mm7, mm7 ; = FFFFFFFFFFFFFFFF
                pxor mm6, mm6 ; =0
                psubw mm6, mm7 ; =1
                psllw mm6, %3-1; 4 ; *16 = 16

                pxor mm7, mm7 ; =0

                pcmpeqw mm5, mm5 ; = FFFFFFFFFFFFFFFF
                psrlw mm5, 8 ; /256 = 00FF00FF00FF00FF
                mov eax, %1; 05
                movd mm4, eax
                pshufw mm4, mm4, 0

                mov eax, %2; 10
                movd mm3, eax
                pshufw mm3, mm3, 0


                mov eax, 1 ; very first (left) is skipped

            .loopw:
                cmp eax, ecx
                jge .finish

                movq mm0, [rdx+rax*2-2]
In your code, you allways use only eax, never fully clear rax, put 1 in eax and not rax, and suddenly use rax. Is it safe ? Can't something be left in the up 32 part when you suddenly use rax ? Personnaly, i should have put "mov rax,1" instead.
Didn't look all the code, so don't know if there is "issues" like this elsewhere.
jpsdr is offline   Reply With Quote
Old 30th April 2016, 07:53   #9  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 980
Possibly not if the prolog really dont nullify it. Already fixed one or two such cases where I had to deal with the code but haven't checked all asm codes.
pinterf is online now   Reply With Quote
Old 11th May 2016, 23:46   #10  |  Link
bcn_246
Registered User
 
bcn_246's Avatar
 
Join Date: Nov 2005
Location: UK
Posts: 146
Quote:
Originally Posted by pinterf View Post
After Fizick updated mvtools to 2.5.11.22 and fixed some issues (e.g. green artifacts in MFlowInter), I made a new merge with 2.6.0.5 that still works in both 32 and 64 bit.

Download mvtools2 2.7.0.22 for 32 and 64 bit (20160429)

After it survived a full night QTGMC("Slow") 100-thread stress test under Avisynth+ 64bit (r1849), I decided to publish it.
Please give it a try.

----
I'd like to announce my first published plugin mod.

mvtools-pfmod 2.7.0.1

- based on mvtools 2.6.0.5
- Sorry, no new colorspaces, just v2.6 API
- access violation fixes
- Intel C++ 16 build with Visual Studio 2015
- 32 and 64 bit versions
- works like a charm with latest AVS+ r1828-MT (though I didn't have problems with 2.6.0.5)

Background (chain reaction):
- Once I tried to use DepanStabilize on vapoursynth. The reason was that vapoursynth offers 16 bit color depth natively, and I have modified DepanStabilize for using stacked input.
- One day I changed my vapoursynth to 64bit only.
- I realized that DepanStabilize is 32bit only, so I compiled it to 64 bit.
- But VapourSynth did not allow to use old 2.5 AVS API for x64. So I modified DepanStabilize for v2.6 API.
- At that time I had no confidence porting DepanEstimate to x64 (input for DepanStabilize), tried to use MDepan from the native vapoursynth mvtools. But this function was not ported yet.
- Had to go back to use the 64 bit 2.6.0.5 mvtools on VapourSynth, but it was v2.5 API => ported it
- mvtools MDepan did not work, I had freezes. Learned debugging dlls in visual studio. Caught a famous 0xc0000005 in it and happily fixed it. And myrsloik was kind enough to integrate a hack into vs's avscompat module just because of 64-bit avs mdepan.
- Meanwhile my DepanStabilize-mod got YV24 support, and with stacked high bit depth logic, and I was able to stabilize my 10 bit Prores 444 test files! I reached my goal: my 8mm film restoration project is not starting anymore with dropping to 8bit YV12 right in the very first step.
- The mvtools project stalled - I was busy with fixing avs+ mt slowdown - until recently stax76 had problems under Win10 and the existing x64 mvtools2. After some busy nights another access violation was fixed in the x64 part.
- Thus I had a working mvtools2 version, and didn't want to keep it in secret.
- Finally along with my avs+ branch I had to learn how to create git repos, branch, push, as all these git things are new to me.

So please use this mod with fun.
Thanks, can also confirm this works with the Dither package.
bcn_246 is offline   Reply With Quote
Old 12th May 2016, 16:36   #11  |  Link
GMJCZP
Registered User
 
GMJCZP's Avatar
 
Join Date: Apr 2010
Location: I have a statue in Hakodate, Japan
Posts: 512
Thanks for the contribution, but not working in WXP SP3. Again, VS2015 is the guilty.
__________________
By law and justice!

Flea Market
GMJCZP is offline   Reply With Quote
Old 14th May 2016, 07:22   #12  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 980
First post links to the package containing an additional XP-win32 build.

Due to problems of Intel compiler with xp toolsets, XP builds temporarily need VS2015, so I cannot provide x64 build for XP now.
pinterf is online now   Reply With Quote
Old 14th May 2016, 14:34   #13  |  Link
GMJCZP
Registered User
 
GMJCZP's Avatar
 
Join Date: Apr 2010
Location: I have a statue in Hakodate, Japan
Posts: 512
It works, thanks!
Without AvsMeter, I noted that this build is more slow that Fizick and cretindesalpes versions. It's weird.
__________________
By law and justice!

Flea Market
GMJCZP is offline   Reply With Quote
Old 14th May 2016, 15:40   #14  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 980
Yes, weird. What is your processor?
I compiled the XP version with the simplest /arch:SSE.
And I suppose the built-in asms are working the same way.

I checked the x86 versions with avsmeter on my standard qtgmc(fast) script.
2.6.0.5 (cretindesalpes): 101 fps
2.7.0.22: 104-105 fps (practically head by head the non-XP: Intel 2017beta, and XP:VS2015 builds)
Fizick's one did not run as Mdegrain1 does not have a named argument "lsb".
pinterf is online now   Reply With Quote
Old 14th May 2016, 15:54   #15  |  Link
GMJCZP
Registered User
 
GMJCZP's Avatar
 
Join Date: Apr 2010
Location: I have a statue in Hakodate, Japan
Posts: 512
I have C2D E4400 and I use AVisynth sET MT. For accident the tests have been with MT mode deactivated.
__________________
By law and justice!

Flea Market
GMJCZP is offline   Reply With Quote
Old 17th May 2016, 14:34   #16  |  Link
BakaProxy
Registered User
 
Join Date: Jan 2015
Posts: 47
Idk if this has already been asked and/or answered but is it possible to use mvtools in mt? Uhh more like whenever I use mdegrain (and the vectors that come allong) cpu utilization is rather low, some scenarios even only 20%. I've tried every mt mode with mvtools but it either completely freezes the encode or it doesn't change anything performance wise. Prefetch amounts don't change anything as well, it just takes longer to start with large amounts.

Verstuurd vanaf mijn SM-A500FU met Tapatalk
BakaProxy is offline   Reply With Quote
Old 17th May 2016, 15:03   #17  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 980
I don't know if it helps, but you could try avstp. In the original 2.6.0.5 it worked and hopefully I did not ruin it.
pinterf is online now   Reply With Quote
Old 23rd May 2016, 06:22   #18  |  Link
bilditup1
Registered User
 
bilditup1's Avatar
 
Join Date: Feb 2004
Location: NYC
Posts: 122
Quote:
Originally Posted by pinterf View Post
I don't know if it helps, but you could try avstp. In the original 2.6.0.5 it worked and hopefully I did not ruin it.
I have successfully used your build with avstp 1.0.3 and AviSynth 2.6.1 alpha. This appears to provide a speed bump of 25% (6fps --> 7.44fps) when used with a 4770K@4.5Ghz on an MPEG2 1080i30 source run through QTGMC with Fast preset and divisor = 2 followed by a Spline36Resize to SD (640x360). Not sure whether this is good or bad performance for QTGMC with your MvTools and avstp. Usage does not get higher than 33%...but at least it's stable and unfinicky, unlike AVS MT.

Last edited by bilditup1; 23rd May 2016 at 06:23. Reason: spelling
bilditup1 is offline   Reply With Quote
Old 16th June 2016, 10:05   #19  |  Link
Groucho2004
 
Groucho2004's Avatar
 
Join Date: Mar 2006
Posts: 3,783
@pinterf
mvtools2 and some other of Fizick's plugins insists on (delay-) loading "fftw3.dll". The FFTW distributables however are named "libfftw3f-3.dll". In order to avoid renaming and user confusion I suggest adding the code in blue:
Code:
hinstLib = LoadLibrary("fftw3.dll"); // delayed loading
if (hinstLib == NULL)
 hinstLib = LoadLibrary("libfftw3f-3.dll");
Groucho2004 is offline   Reply With Quote
Old 16th June 2016, 13:14   #20  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 980
Thank you, done.
I've already done it in DepanEstimate (work still in progress)
pinterf is online now   Reply With Quote
Reply

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 13:05.


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