digitalFAQ.com Forums [Archives]

digitalFAQ.com Forums [Archives] (http://www.digitalfaq.com/archives/)
-   Avisynth Scripting (http://www.digitalfaq.com/archives/avisynth/)
-   -   Avisynth: Latest Script - syntax/format modifications (http://www.digitalfaq.com/archives/avisynth/4282-avisynth-latest-script.html)

Grantman 07-01-2003 06:31 PM

Latest Script - syntax/format modifications
 
In the latest script does the section:

## Defined Variables and Constants ##
#
MaxTreshold = 1.50
nf = 0 # Current frame.
#
####

Have to come BEFORE the "MPEGSource" line?

If we moved that line lower... we could use the script as is and reference it in a primary script.

That is how I am working things now. I have a file named "optimal.avs" which is the current optimal script. I call that file from my project specific script using this line:

Import("optimal.avs")

This way if I have multiple scripts and there is an update to the optimal script I only update one file and all project specific scripts are updated.

FYI... I also generate the project specific scipts in batch using this line:

MPEGSource(%filename)

Then I used the web application on the avisynth.org site to generate several scripts based on a list of filenames I provide. If I have a directory of files named *.d2v I can list them and the app spits out scripts with the correct filename in each and with the same name in the title.

Avisynth is very automated. (I also added "Eval" to the GripCrop line so that I could easily batch update resolution parameters).

Just ideas for more streamlined updates when the script changes.


Grantman

vhelp 07-01-2003 08:10 PM

Hi Grantman..

Actually, I was doing this same thing, and just fine-tuning it.. but I'm still
working on it, cause I found that in working w/ "past" MA script snips that
changed over time, one might work better than the current or prior or
what-have-you. So, I found it better or easier to just REM "#" out those
lines pertaining to MA and only keep one active. if I didn't like it, I would
simply REM that one, and try another (un-REMing) etc. So, until I can
perfect the idea above..

I think that most others here would benefit from that idea though. They
wont be as picky or "debugin" as I am, and it will or should work for them :)

-vhelp

jorel 07-01-2003 08:24 PM

your ideas are better than mine.

i use the date and hour in the name of each script!
:wink:

ozjeff99 07-02-2003 01:38 AM

Quote:

Originally Posted by Grantman
Avisynth is very automated. (I also added "Eval" to the GripCrop line so that I could easily batch update resolution parameters).

Hi Grantman, how does this work. Looks very interesting. Could you explain in more detail.

Thanks
ozjeff99

Grantman 07-03-2003 11:49 AM

Additional Explanation
 
My whole idea is to create a slef-referencing script where any "variable" that I might change depending on the source would be easily changed without having to copy the entire script. That is easy enough to do.

However, I also want to be able to plug in the optimal script with minimum updates and edits. I have been using the following script functions to help generate such a script...

This is directly from the www.avisynth.org site:

Eval(string)
Apply(func-string, arg, ...): Eval("f(x)") is equivalent to f(x) is equivalent to Apply("f", x))

You can use Eval for something like:
settings = "352, 288"
Eval( "BicubicResize(" + settings + ")" )

You can import the text of another script:
Import (filename): evals contents of another AviSynth script.


Grantman

ozjeff99 07-04-2003 02:47 AM

Thanks Grantman....I'll check it out.

ozjeff99

vhelp 07-04-2003 03:07 PM

hi Grantman.. :)

If I confused you, sorry. I ment that I was doing work w/ the IMPORT()
not the other items you listed in your first post after the FYI. K?

Anyways.. I have some ideas I was hoping to get out.

Take it easy.
-vhelp


All times are GMT -5. The time now is 07:52 PM  —  vBulletin © Jelsoft Enterprises Ltd

Site design, images and content © 2002-2024 The Digital FAQ, www.digitalFAQ.com
Forum Software by vBulletin · Copyright © 2024 Jelsoft Enterprises Ltd.