View Full Version : AvisynthWrapper usage for newbies
kenpachi
18th April 2012, 00:44
I am studying meGUI source to understand how AvisynthWrapper works but it is more or less magic to me as I've just started.
1) Let's have sample.avs:
#Loadplugin("C:\Program Files\VideoAudio\AviSynth 2.5\plugins\avss.dll")
#BlankClip(length=200)
DSS2("E:\sample.avi")
#AviSource("E:\sample.avi")
When attempting to open it in my project:
AviSynthClip clip = null;
AviSynthScriptEnvironment env = new AviSynthScriptEnvironment();
clip = env.OpenScriptFile("sample.avs", AviSynthColorspace.RGB24);
dimzon_avs_init_2 doesn't success and throws "Can't open E:\sample.avi: 80040217". Uncommenting "LoadPlugin" doesn't help. AviSource or internal sources work as far. What might be the reason haaliDS doesn't work?
IanB
18th April 2012, 11:42
0x80040217 is VFW_E_CANNOT_CONNECT
From VFWMSGS.H//
// MessageId: VFW_E_CANNOT_CONNECT
//
// MessageText:
//
// No combination of intermediate filters could be found to make the connection.%0
//
#define VFW_E_CANNOT_CONNECT ((HRESULT)0x80040217L)
You possibly do not have the required direct show codec for E:\sample.avi.
Seeing you are porting MeGui code have you actually tried running your script in MeGui, this will confirm/eliminate problems with your understanding of AvisynthWrapper usage. But I think your code is working correctly including error reporting and handling.
As always fall back to good old reliable VirtualDub when you have script or plugin problems it eliminates all the extraneous dross from the problem.
Also I think AvisynthWrapper has some original roots here AvsFilterNet - writing avisynth filter in .NET (http://forum.doom9.org/showthread.php?t=144663)
tebasuna51
18th April 2012, 14:46
Here (http://www.codeplex.com/AvisynthWrapper) you have the AvisynthWrapper used in BeHappy.
The first release by Dimzon, Jan 24 2008, was the initial version used in MeGUI.
kenpachi
18th April 2012, 22:55
have you actually tried running your script in MeGui, this will confirm/eliminate problems with your understanding of AvisynthWrapper usage.
meGUI opens the script. It's more a question to meGUI Developers, then - what am I doing wrong? I usually test scripts with AvsEdit or using MediaFoundation (EVR). HaaliDS works fine in my scripts.
Here (http://www.codeplex.com/AvisynthWrapper) you have the AvisynthWrapper used in BeHappy.
The first release by Dimzon, Jan 24 2008, was the initial version used in MeGUI.
I'm using the 2010-04-10 build found in meGUI source. I've also tried the 2008-02-03 build. Both builds have dimzon_avs_init_2 function (Dependency Walker info) and neither of them successes with DSS2() in a script.
kenpachi
29th May 2012, 21:21
I had put the problem away but accidentally managed to find out the reason some time ago. I advice all using VS2010 to run your builds without debugger when testing AviSynth. The debug mode causes AviSynth server to act weird, e.g. it doesn't want to work with DSS2() or Trim(). No "debug mode" fixes the problem.
vBulletin® v3.8.11, Copyright ©2000-2025, vBulletin Solutions Inc.