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 Usage

Reply
 
Thread Tools Search this Thread Display Modes
Old 4th July 2006, 23:52   #1  |  Link
Trixter
Registered User
 
Join Date: Oct 2003
Posts: 200
MVTools working in some scripts but not others?

I'm really confused at the moment; I'm using MVTools to do some standards conversion and it works in some scripts and I get an error message in others. I discovered this when I was trying to use Scharfis' mvbob as a preprocessor to the standards conversion. I'm using avisynth 2.56 with mvtools version 1.3.0 (the most recent one).

For example, this works perfectly:

Code:
loadplugin("mvtools.dll") # my default plugin path is set properly in the registry)
AVISource("h:\assets\mc2\pal\groovy.avi").ConvertToYUY2(interlaced=true)

function bobit(clip c) 
{
	# Use TDeint to turn 25i into 50p
	c.TDeint(order=1,mode=1,type=0,sharp=false,AP=50,APtype=0)
} 

function MOCOMP_50_to_5994(clip c)
{
	backward_vec = c.MVAnalyse(isb = true, truemotion=true, pel=2, idx=1)
	# we use explicit idx for more fast processing
	forward_vec = c.MVAnalyse(isb = false, truemotion=true, pel=2, idx=1)
	cropped = c.crop(4,4,-4,-4)	# by half of block size 8
	backward_vec2 = cropped.MVAnalyse(isb = true, truemotion=true, pel=2, idx=2)
	forward_vec2 = cropped.MVAnalyse(isb = false, truemotion=true, pel=2, idx=2)
	c.MVFlowFps2(backward_vec,forward_vec,backward_vec2,forward_vec2,num=60000,den=1001,idx=1,idx2=2) # the 60000 / 1001 = 59.9401
}

bobit
BilinearResize(720,480)
MOCOMP_50_to_5994
#ChangeFPS(60000, 1001)	# Convert field rate to NTSC (59.94), by duplicating/dropping fields

AssumeFrameBased
SeparateFields()
SelectEvery(4, 0, 3) # 4,1,2 is for odd field first; 4,0,3 is for even field first
weave
...but this next example results in the error AVISynth open failure: Script Error: MVAnalyse does not have a named argument "truemotion":

Code:
loadplugin("mvtools.dll")
import("d:\Program Files\AviSynth 2.5\plugins\mvbob.avs")
AVISource("h:\assets\mc2\pal\groovy.avi").ConvertToYUY2(interlaced=true)
AssumeTFF

mvbob

function MOCOMP_50_to_5994(clip c)
{
	# Assume progressive PAL 50 fps source. Lets convert to 60.
	backward_vec = c.MVAnalyse(isb = true, truemotion=true, pel=2, idx=1)
	# we use explicit idx for more fast processing
	forward_vec = c.MVAnalyse(isb = false, truemotion=true, pel=2, idx=1)
	cropped = c.crop(4,4,-4,-4)	# by half of block size 8
	backward_vec2 = cropped.MVAnalyse(isb = true, truemotion=true, pel=2, idx=2)
	forward_vec2 = cropped.MVAnalyse(isb = false, truemotion=true, pel=2, idx=2)
	c.MVFlowFps2(backward_vec,forward_vec,backward_vec2,forward_vec2,num=60000,den=1001,idx=1,idx2=2) # the 60000 / 1001 = 59.9401
}

MOCOMP_50_to_5994
Since MVAnalyse quite clearly does have a named argument "truemotion", because it works in the first script, what am I doing wrong? Is the problem with mvbob or is it a malformed script on my part? (I did have to correct a "convertttoyuy2" error in the original mvbob script, maybe there are other errors?)
Trixter is offline   Reply With Quote
Old 5th July 2006, 00:23   #2  |  Link
foxyshadis
ангел смерти
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Lost
Posts: 9,175
Code:
loadplugin("mvtools.dll") # my default plugin path is set properly in the registry)
This might be where the confusion stems from, if you do this, it will load whatever plugin is in the script's folder, not what's in the avisynth folder. But what I'm guessing is it's actually hiding the error, because mvbob.avs includes its own loadplugin("mvtools.dll") which would pull it from "d:\Program Files\AviSynth 2.5\plugins\" instead! Ie, the one in your script's folder is current and the one in your main plugin folder is old. So you can either comment out the load in mvbob, or remove every mvtools.dll you can find and only place the most current in your main plugin folder (and remove the loadplugin calls since it'll be autoloaded).

That's my attempt at psychic debugging, anyway.
__________________
There are four boxes to be used in defense of liberty: soap, ballot, jury, and ammo. Please use in that order. ~ Ed Howdershelt
foxyshadis is offline   Reply With Quote
Old 5th July 2006, 05:14   #3  |  Link
Trixter
Registered User
 
Join Date: Oct 2003
Posts: 200
A good guess, except that the only copy of mvtools.dll on the system is in my plugins directory. But thanks for trying :-)

I'm hoping Scharfis sees this and comments, because it's his mvbob that had the typo in it, which leads me to believe he hasn't used it in a while :-)
Trixter is offline   Reply With Quote
Old 5th July 2006, 08:45   #4  |  Link
Boulder
Pig on the wing
 
Boulder's Avatar
 
Join Date: Mar 2002
Location: Hollola, Finland
Posts: 4,296
You are supposed to extract the MVBob package to its own directory. Then when you import the mvbob.avs in your script, it loads the correct mvtools.dll which is also in the MVBob directory. That's why there is no path in the LoadPlugin line.
__________________
And if the band you're in starts playing different tunes
I'll see you on the dark side of the Moon...
Boulder is offline   Reply With Quote
Old 5th July 2006, 14:46   #5  |  Link
scharfis_brain
brainless
 
scharfis_brain's Avatar
 
Join Date: Mar 2003
Location: Germany
Posts: 3,605
mvbob.avs loads plugins by itsfelf. this means it loads an outdated mvtools.dll. there is NO typo in mvbob.avs.

just load mvtools.dll after importing mvbob.avs.
__________________
Don't forget the 'c'!

Don't PM me for technical support, please.
scharfis_brain is offline   Reply With Quote
Old 5th July 2006, 19:04   #6  |  Link
Trixter
Registered User
 
Join Date: Oct 2003
Posts: 200
Quote:
Originally Posted by scharfis_brain
mvbob.avs loads plugins by itsfelf. this means it loads an outdated mvtools.dll. there is NO typo in mvbob.avs.

just load mvtools.dll after importing mvbob.avs.
So that means that "convertttoyuy2" isn't a typo, it's something provided by one of the .dlls?
Trixter is offline   Reply With Quote
Old 5th July 2006, 19:23   #7  |  Link
Trixter
Registered User
 
Join Date: Oct 2003
Posts: 200
Quote:
Originally Posted by scharfis_brain
there is NO typo in mvbob.avs.
Then what is this:



(if the above attachment didn't work, it's an error message "there is no function named "convertttoyv12", mvbob.avs, line 115") This is straight out of your mvbob.rar file, unedited. Here's the script that produced it:

Code:
import("d:\Program Files\AviSynth 2.5\plugins\mvbob\mvbob.avs")
AVISource("h:\assets\mc2\pal\groovy.avi").ConvertToYUY2(interlaced=true).AssumeTFF
mvbob
mvconv
info
BTW, mvbob works fine now that it's in its own directory, thanks for the tip :-) And it is definitely the best -- and slowest -- bobber I've ever used. For longer projects, I will probably fall back to TDeint(order=1,mode=1,type=0,sharp=false,AP=50,APtype=0) for speed reasons since the quality is only about 2% worse than mvbob with my footage.
Attached Images
 

Last edited by Trixter; 5th July 2006 at 19:28.
Trixter is offline   Reply With Quote
Old 5th July 2006, 19:24   #8  |  Link
Trixter
Registered User
 
Join Date: Oct 2003
Posts: 200
Quote:
Originally Posted by Boulder
You are supposed to extract the MVBob package to its own directory. Then when you import the mvbob.avs in your script, it loads the correct mvtools.dll which is also in the MVBob directory. That's why there is no path in the LoadPlugin line.
Indeed, that fixed one of the issues, thanks very much!
Trixter is offline   Reply With Quote
Old 5th July 2006, 19:50   #9  |  Link
Boulder
Pig on the wing
 
Boulder's Avatar
 
Join Date: Mar 2002
Location: Hollola, Finland
Posts: 4,296
You can (and probably should) replace that mvtools.dll by the most recent one, or load it separately after importing mvbob.avs like scharfi said.
__________________
And if the band you're in starts playing different tunes
I'll see you on the dark side of the Moon...
Boulder is offline   Reply With Quote
Old 5th July 2006, 23:01   #10  |  Link
scharfis_brain
brainless
 
scharfis_brain's Avatar
 
Join Date: Mar 2003
Location: Germany
Posts: 3,605
oh okay. that's a typo, indeed. (I wasn't aware of it)

but I thought you were referring to the truemotion-thing
__________________
Don't forget the 'c'!

Don't PM me for technical support, please.
scharfis_brain is offline   Reply With Quote
Old 7th July 2006, 05:08   #11  |  Link
Trixter
Registered User
 
Join Date: Oct 2003
Posts: 200
Quote:
Originally Posted by scharfis_brain
but I thought you were referring to the truemotion-thing
Originally, I was :-) I put it all into its own directory and all is well.

Your understanding of proper bobbing is impressive; one wonders what Faroudja units use (not motion synthesis, that's for sure).
Trixter is offline   Reply With Quote
Old 7th July 2006, 14:42   #12  |  Link
scharfis_brain
brainless
 
scharfis_brain's Avatar
 
Join Date: Mar 2003
Location: Germany
Posts: 3,605
I guess that faroudja uses a similar thing like securedeint (eedi2 + motionmask) and a 3:2 / 2:2 Pulldown detection for FILM-sequences.
__________________
Don't forget the 'c'!

Don't PM me for technical support, please.
scharfis_brain is offline   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 19:12.


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