VideoHelp Forum




+ Reply to Thread
Page 1 of 2
1 2 LastLast
Results 1 to 30 of 53
  1. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    Hi,

    I am trying to open the sript in VirtualDub:

    MPEG2Source("C:\Documents and Settings\Owner\Desktop\Ladykillers-Test.avi")
    function LimitedSharpenFaster(ss_x=1.25,ss_y=1.25,Smode=4,s trength=600,soft=30)
    Soothe(sharp,dull,25){}

    and receive error message:

    Avisynth open failure
    Script error: expected a , or )
    (C:\Path\To\filename.avs, line 2, column 35)

    What's wrong in the script?

    Thank you!
    Quote Quote  
  2. Member
    Join Date
    May 2001
    Location
    United States
    Search Comp PM
    Originally Posted by vertical
    Hi,

    I am trying to open the sript in VirtualDub:

    MPEG2Source("C:\Documents and Settings\Owner\Desktop\Ladykillers-Test.avi")
    function LimitedSharpenFaster(ss_x=1.25,ss_y=1.25,Smode=4,s trength=600,soft=30)
    Soothe(sharp,dull,25){}

    and receive error message:

    Avisynth open failure
    Script error: expected a , or )
    (C:\Path\To\filename.avs, line 2, column 35)

    What's wrong in the script?

    Thank you!
    I believe that your syntax for your function statement is incorrect. It looks like the function is trying to call a video clip named "ss_x", then parsing a "=" and throwing an exception.

    Is LimitedSharpenFaster really a function, or is it a plugin?
    ICBM target coordinates:
    26° 14' 10.16"N -- 80° 16' 0.91"W
    Quote Quote  
  3. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    Thank you!

    I am not sure but I believe you gave a clue. What if it is like this?

    MPEG2Source("C:\Documents and Settings\Owner\Desktop\Ladykillers-Test.avi")
    LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\DGDecode.dll")
    LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\MaskTools.dll")
    LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\MT_MaskTools.dll")
    LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\RemoveGrain.dll")
    dull=last
    Sharp=LimitedSharpenFaster(ss_x=1.25,ss_y=1.25,Smo de=4,strength=150,soft=30)
    Soothe(sharp,dull,25)

    Thanks!

    I tried this one and it looks like it is OK but it requires d2v file instead of avi. Probably I can use DMPGDindex to create d2v from avi though not sure whether it's possible.
    Quote Quote  
  4. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    It looks like there is a mistake.

    It should be DirectShowSource for avi instead MPEG2Source, right?

    But now it gives another error message...
    Quote Quote  
  5. Always Watching guns1inger's Avatar
    Join Date
    Apr 2004
    Location
    Miskatonic U
    Search Comp PM
    Load your plugins before you load the movie. DGDecode needs to be loaded before MPEG2Source is called, if the file is an mpeg. Also, you need to create the d2v files and load that instead.

    If it is an avi, then either DirectShowSource or AVISource should be used instead of mpeg2source. Also, if it is an avi, you probably don't need to load DGDecode.dll

    It is good practice to load all the plugins etc first, before doing anything else int he script.
    Read my blog here.
    Quote Quote  
  6. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    guns1inger, thank you.

    What does it mean "to load the plugins"?

    I have put all Plugins in to Avisynth plugins directory. Should not they be called by the script?
    Quote Quote  
  7. It means put all the LoadPlugin lines (the ones with the DLLs) before the Source line. It'll make a big difference if you're using MPEG2Source, as it can't be used until you load the plugin for DGDecode.dll. It's standard practice. If your source is an AVI, use AVISource (or DirectShowSource if that doesn't work), and you don't need to load the DGDecode.dll at all.

    And stop doing this:

    function LimitedSharpenFaster.....

    How many times do I have to tell you it's:

    LimitedSharpenFaster.....
    Quote Quote  
  8. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    Should it be this way?

    LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\MaskTools.dll")
    LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\MT_MaskTools.dll")
    LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\RemoveGrain.dll")
    DirectShowSource("C:\Documents and Settings\Owner\Desktop\Ladykillers-Test.avi")
    dull=last
    LimitedSharpenFaster(ss_x=1.25,ss_y=1.25,Smode=4,s trength=150,soft=30)
    Soothe(sharp,dull,25)

    "How many times do I have to tell you it's..." - Sorry about this. But I do not remeber you telling me about it -)
    Quote Quote  
  9. Hi-

    But I do not remeber you telling me about it -)
    I don't even understand why what you had works for you. Always test by opening in VDubMod before sending to your encoder. This should be enough:

    LoadPlugin("C:\Path\To\DGDecode.dll")
    MPEG2Source("F:\Documents\Temp\moviename.d2v")
    LimitedSharpenFaster()
    I meant that you had this:

    MPEG2Source("F:\Documents\Temp\moviename.d2v")
    function LimitedSharpenFaster(){}
    Yes, if you have the Soothe.avsi in the AviSynth Plugins folder, along with LimitedSharpenFaster.avsi, that script should work.
    Quote Quote  
  10. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    manono, thank you.

    Yes, I do remeber this but I did not even know about the thing. I mean "to load plugins" and did not realize the order of lines is of importance but now I know.

    I do not have Southe avsi. Will it be a big deal if I remove the last (Southe) line? Or I can create the avsi I you could please afvise what should stick in it.

    Thanks.
    Quote Quote  
  11. Always Watching guns1inger's Avatar
    Join Date
    Apr 2004
    Location
    Miskatonic U
    Search Comp PM
    The code for the soothe function was either on the limitedsharpenfaster function page, or linked to from it.
    Read my blog here.
    Quote Quote  
  12. I'll link to the Soothe thread where you can find the Soothe function, for the 3rd time now:

    http://forum.doom9.org/showthread.php?t=99679&highlight=Soothe
    Quote Quote  
  13. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    Thank you very much!
    Quote Quote  
  14. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    Sorry to bug you with the same issue.

    I created Sothe.avsi and put into Avisynth plugin folder but I get error message:

    Script error: syntax error.
    (C:\Path\To\line7, column 22)

    I tried with {} at the very end and without it but get error messages. Thanks!
    Quote Quote  
  15. Oh, sorry, but I forgot something. The script you posted wasn't quite right. You do it like this:

    Dull=Last
    Sharp=LimitedSharpenFaster(ss_x=1.25,ss_y=1.25,Smo de=4,strength=150,soft=30)
    Soothe(Sharp,Dull,25)

    Soothe needs the unsharpened video (Dull) and the sharpened video (Sharp) in order to do its thing. The way you had it before won't work.

    And that Soothe setting actually removes most of the sharpening (read the thread to which I linked). I work with mostly old films which are kiind of shakey to begin with. I don't want LSF to make them any shakier, so my Soothe setting is kind of strong. If you have a nice clean new video, then you may not need Soothe at all, and the Soft setting should be plenty. About all you can do is test. I noticed in a previous script you had the strength set for 600. I'm not saying that's bad, but if you start to get artifacts in the form of jaggies/aliasing/shimmer, either increase the Soft setting, back off the Strength setting or both. Or put on Soothe.

    Edit: you posted before I got in my clarification. If what I said to do doesn't get it going, please post your full script.
    Quote Quote  
  16. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    manono, thank you.

    It looks I am missng something. I still get error message. Here is the full script:


    LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\MaskTools.dll")
    LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\MT_MaskTools.dll")
    LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\RemoveGrain.dll")
    DirectShowSource("C:\Documents and Settings\Owner\Desktop\Ladykillers-Test.avi")
    Dull=Last
    Sharp=LimitedSharpenFaster(ss_x=1.25,ss_y=1.25,Smo de=4,strength=150,soft=30)
    Soothe(Sharp,Dull,25){}

    How can I disable Soothe in case I deal with a new good quality movie? Just to change 25 to 0?

    As for Strength=600 I set it this way just to try.
    Quote Quote  
  17. First, remove that {} after Soothe. Now try.

    If that doesn't make it work, although I don't seem to need it, the script in the thread says to do it this way:

    Dull=Last
    Sharp=Dull.LimitedSharpenFaster(ss_x=1.25,ss_y=1.2 5,Smode=4,strength=150,soft=30)
    Soothe(Sharp,Dull,25)

    And if that doesn't make it work, then drop Soothe. To use LSF without Soothe, then:

    LimitedSharpenFaster(ss_x=1.25,ss_y=1.25,Smode=4,s trength=150,soft=30)

    Leaving off the Dull and Soothe lines. If that doesn't make it work, then a name or path must be screwed up. The error message should tell you the offending line.

    Edit: There's always the chance you have a colorspace issue. Pay attention to the error message, if there is one. DVDs are always YV12. AVIs can be any old thing, I think. Not really sure, as I work mostly with DVD, unless I'm using an uncompressed Lagarith AVI.
    Quote Quote  
  18. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    I tried all variants but it does not work.

    Depending on the variant, different error messages. If full script with Soothe: there is no function called "SimpleAverage" (Xe...line 77)
    C:.........line 6

    Color was never mentioned in error messages.

    Could be that I screwed the Soothe.avsi and this causes it?
    Quote Quote  
  19. Always Watching guns1inger's Avatar
    Join Date
    Apr 2004
    Location
    Miskatonic U
    Search Comp PM
    Does it work without Soothe ? i.e does LimitedSharpenFaster work on it's own in this script ?
    Read my blog here.
    Quote Quote  
  20. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    No, it does not if I remove
    Dull=Last
    Soothe(Sharp,Dull,25)

    or with it.
    Quote Quote  
  21. Always Watching guns1inger's Avatar
    Join Date
    Apr 2004
    Location
    Miskatonic U
    Search Comp PM
    That points to LSF as being the likely cause.

    avisynth.org has been unavailable to me all day, so I can't check the function code posted there.

    What is the full error message that this represents ?

    there is no function called "SimpleAverage" (Xe...line 77)
    Read my blog here.
    Quote Quote  
  22. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    Thanks.

    The full error message is

    script error: there is no function called "SimpleAverage" (Xe...line 77)
    C:\Path\To\line 6

    But LFS works with builtin Sharpen. Doesn't it mean it is fine?
    Quote Quote  
  23. Always Watching guns1inger's Avatar
    Join Date
    Apr 2004
    Location
    Miskatonic U
    Search Comp PM
    Line 6 of your main script is the call to LSF. What is line 77 of LSF ?
    Read my blog here.
    Quote Quote  
  24. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    Here it is in full as the last version advised by manono:

    LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\MaskTools.dll")
    LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\MT_MaskTools.dll")
    LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\RemoveGrain.dll")
    DirectShowSource("C:\Documents and Settings\Owner\Desktop\Ladykillers-Test.avi")
    Dull=Last
    Sharp=Dull.LimitedSharpenFaster(ss_x=1.25,ss_y=1.2 5,Smode=4,strength=150,soft=30)
    Soothe(Sharp,Dull,25)

    Or you probably mean line 77 in LSF.avsi, don't you?
    Quote Quote  
  25. Always Watching guns1inger's Avatar
    Join Date
    Apr 2004
    Location
    Miskatonic U
    Search Comp PM
    Or you probably mean line 77 in LSF.avsi, don't you?
    Yep.
    Read my blog here.
    Quote Quote  
  26. Does :

    LimitedSharpenFaster()

    by itself work?

    And did you make sure to get the right version of MaskTools? There's a bunch of them.

    Here's a thread that lists what you need and where they can be found. Make sure you have the right ones:

    http://forum.doom9.org/showthread.php?t=115727

    Edit: I was looking for the same thing, guns1inger.

    Also, what version of AviSynth are you using? Make a Version.avs and inside put only this line:

    version()
    Quote Quote  
  27. Always Watching guns1inger's Avatar
    Join Date
    Apr 2004
    Location
    Miskatonic U
    Search Comp PM
    This is probably worth a read

    http://forum.doom9.org/showthread.php?t=115727
    Read my blog here.
    Quote Quote  
  28. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    I've got the following:

    MT_Masktools 2.0.30.0
    Masktools 1.5.1.0

    manono, you are dealing with a newbie. I do not understand what "Does LimitedSharpenFaster() by itself work?" means. How should it work by itself?

    Really sorry.
    Quote Quote  
  29. It has to be MaskTools 1.5.8.

    I meant, if you put:

    LimitedSharpen()

    in the script, without all that other stuff inside the parenthesis, does it work?

    Probably not, if you have the wrong version of MaskTools. It also has to be the correct version of RemoveGrain. Get them both from that last link guns1inger and I gave.
    Quote Quote  
  30. Member
    Join Date
    Jun 2006
    Location
    Canada
    Search Comp PM
    I will replace the masktools right now and will try again.

    No, when I removed everything (Soothe, etc) as you advised it did not work.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!