View Full Version : AvsP v2.0.2 (10/27/07)
qwerpoi
29th August 2007, 19:37
(for the old thread, click here (http://forum.doom9.org/showthread.php?p=871134))
AvsP (http://avisynth.org/qwerpoi/) is a tabbed script editor for Avisynth. It has many features common to programming editors, such as syntax highlighting, autocompletion, calltips. It also has an integrated video preview, which when coupled with tabs for each script make video comparisons a snap. What really makes AvsP unique is the ability to create graphical sliders and other elements for any filter's arguments, essentially giving Avisynth a gui without losing any of its powerful features. For example, check out this screenshot:
http://img103.imageshack.us/img103/6533/avspv2qy2.th.png (http://img103.imageshack.us/my.php?image=avspv2qy2.png)
Without adding anything special to the script, AvsP automatically parses the script and creates graphical elements for each specified argument. You can drag any slider around to see the effects of each of Tweak's arguments, hit the button by the filename to choose a new file for AVISource, etc. Through these combinations of features, AvsP provides the means to perfect the output of any script.
AvsP also has a ton of other features going for it, like a crop editor, trim editor, and more recently, tools such as a resize calculator and an encoding gui. There's way too much stuff to go into detail here, you can get more info at the website (http://avisynth.org/qwerpoi/) or the old thread (http://forum.doom9.org/showthread.php?p=871134). I would recommend downloading it and playing around with it yourself to get a feel for what it can really offer, no frameworks necessary, no writing to the registry, just download the zip file (~5 mb), unzip to a folder and you're set.
AvsP Download page (http://www.avisynth.org/qwerpoi/Download.html)
bugfix for v2.0.2 (http://avisynth.org/qwerpoi/AvsP_v2.0.2_bugfix3.zip) (more info here (http://forum.doom9.org/showthread.php?p=1059559#post1059559))
mirror for 2.0.2 (http://www.savefile.com/files/1153115) (savefile.com)
mirror for 2.0.1 (http://www.savefile.com/files/1061266) (savefile.com)
mirror for 2.0.0 (http://www.savefile.com/files/1013767) (savefile.com)
Japanese translation (http://niiyan.s8.xrea.com/blosxom/avisynth/tool/20060920-avsp-ja.htm) (translated by niiyan)
Russian translation (http://avisynth.org.ru/avsp) (translated by Fizick)
German translation (http://technik.movie2digital.de/thread.php?postid=438200#post438200) (translated by Henrikx)
French translation (http://homepages.nildram.co.uk/~cestial/AvsP/) (translated by Alain2)
Spanish translation (http://forum.doom9.org/showthread.php?p=1046290#post1046290) (translated by zemog)
Portuguese translation (http://forum.doom9.org/showthread.php?p=1047583#post1047583) (translated by Veiga)
Italian translation (http://people.ee.ethz.ch/~rporetti/AvsP_Trad/AvsP_translationITA.zip) (translated by khs81)
qwerpoi
29th August 2007, 19:41
Here's what's new in version 2.0.0 (compared to v1.4.0):
* fully automatic user sliders (enabled by default in this release)
* added default presets for each filter (suggested by Zarxrax)
* new "Tools" directory designed for AvsP plugins (suggested by Rahima, Fizick)
* new resize calculator tool (suggested by chipzoller)
* new encoder tool supporting any command line encoders (through presets)
* script tabs now keep track of their own frames
* added new side button to toggle sliders
* added reminder images in the script tabs when video has focus
* added several new configurable text colors
* improved filter documentation filename searching
* added configurable web search for filter docs whenever local docs not found
* changed external player to use original script whenever possible
* changed program to open socket for single instance check only when necessary
* improved rules for displaying calltips
* improved macros menu organization with submenus defined by subdirectories
* improved SetBookmark() macro performance with large lists (suggested by AlanHK)
+ fixed calltip bug with parentheses inside string (thanks niiyan)
+ fixed calltip bug with filters with zero arguments (thanks niiyan)
+ fixed calltip bug with "Frequent calltips" turned off (thanks Alain2)
+ fixed asterisk on title bar in separate video window (thanks krisq)
+ fixed color customization to allow non-white default background (thanks RedDwarf1)
+ fixed open with unicode filename bug (thanks Zarxrax)
The first thing to note is that the website is really out of date, thanks to all these new changes. I'm currently working on updating it, but in the meantime you'll have to pay attention here to understand some of the newer features (although most should be self-explanatory).
The second thing to note is that the options files (*.dat) from older versions of AvsP are not compatible, so don't copy them over to the new version. That means you'll have to reconfigure any program customizations you've made, I apologize for the inconvenience, but it was sort of necessary for me to move forward.
The most noticeable new feature is the automatic user sliders, which were actually introduced in the previous version, but were disabled by default. This feature isn't perfect yet, but it's already functional and pretty close to 100%. As mentioned in the first post, you don't need to do any extra work to get the sliders, they'll get built automatically when you refresh the video. By default all user sliders are folded, simply click on the filter label to unfold the arguments for that filter. You can control a lot of aspects about how user sliders are built and displayed from the "Options -> Program settings..." dialog, under the "User sliders" tab.
The automatic user slider creation depends heavily on AvsP's filter database, which has changed a lot in this version. The filter database is entirely stored in the file filterdb.dat, which is actually just a text file, you can take a look at it if you wish. If you find any errors in the database or want to add new functions, the recommended method is to use the "Options -> AviSynth function definition..." dialog. This dialog has been reworked entirely and hopefully is more straightforward for an average user to edit. Although you could edit the filterdb.dat file directly, I wouldn't recommend it since it will be difficult to accept any updates I make to the database. If you would like to submit edits or additions to the database, you can use the "Export customizations" button in the Avisynth function definition dialog, which will save all your customizations to a text file you can send to me.
Presets work a little differently in v2.0.0. Presets are now activated every time you use Enter to finish an autocompletion (you can change this to Tab or turn it off entirely if you wish). By default, AvsP automatically generates presets for each filter using the information in the database. This preset will automatically enter every one of the filter's arguments, filling in defaults for optional arguments and placing a "?" for every argument without a known default. You can customize individual presets in the "Options -> AviSynth function definition..." dialog.
Documentation paths are no longer customizable per filter. Instead, every time you click on a calltip and the filter's documentation is not found, AvsP will perform a google search using the filter name. You can customize the search to use any url in the "Options -> Program settings..." dialog under the first tab. Note that as always there you can specify which folders on your hard drive to search through for local docs. The search for local documentation files has also been improved. For example, before if you clicked on EEDI2's calltip, AvsP would specifically search for EEDI2.txt, EEDI2.html, or EEDI2.htm. Now the search is less strict and will find files named "EEDI2 - readme.txt", etc.
Another major change is the tools folder. Now AvsP can be extended through tools, which are simply python scripts which are imported by AvsP. In general, tools have a graphical interface, either by using wxPython directly in the script or by using python to communicate with a compiled executable written in a different language. Tools are actually a lot like macros, and can do anything macros can do, but there are some key differences. Tools allow for translation of any messages in the graphical interface. Tools allow for importing of other supporting scripts (for example, the encoding_gui.py tool uses MP3Info.py to determine if an mp3 is cbr or vbr). Tools also have an additional method, avsp.GetWindow(), which returns the running AvsP frame (which is in general necessary to give to a wxPython dialog as a parent). In order to make a new tool, simply make a new python script in the Tools directory, and make sure you have a function named avsp_run() which takes no arguments. The tool will automatically show up in the Tools menu the next time you run AvsP, and the avsp_run() function will be run when you click on the menu item. You can check out the included tools if you need examples. The ToolsMenu.py can optionally be used to define the order of the tools, as well as the menu label and status bar message.
This version comes with three tools, a resize calculator, an encoder gui, and the avs2avi gui, which was converted to a tool. The resize calculator was roughly based on ResCalc.exe, a program suggested to me by chipzoller. The calculator is a bit basic right now, and seeing how I'm not an aspect ratio expert, there may be errors in my calculations, so please let me know if you come across any problems. The encoder gui is a generic interface to any arbitrary command line program or programs. Essentially it's a gui which generates and runs batch script based on the current script and a selected preset. The dialog also has a pretty decent bitrate calculator. Again I can't 100% vouch for my calculations, especially the container overhead computations, which are currently has some estimations (although I should point out I have used the tool successfully several times for my own encodes). What's really nice is that since everything's connected to AvsP, the dialog fills out a lot of info automatically, input/output filenames, framecount, framerate, even audio and subtitle filenames (assumming they have similar names to the input avs script). You'll have to try it out to get a better idea of how it works. Right now the program only comes with a few presets stored in the files x264.presets and xvid.presets, which are just text files with a pretty straightforward format. They're only there for example, in order for the tool to be really useful, I'll need help from anyone who have some command line presets they'd like to see added. You don't need to put them in AvsP's format if you can't figure it out, you can send me the raw command lines if you wish. Anyway, this tool isn't really meant to make AvsP compete with MeGUI or other encoder specific guis, it's really just meant to be a quick way to encode videos that will hopefully be future proof, since it's almost entirely driven by presets.
One new feature for macro lovers is the ability to organize the Macros menu with submenus. Simply make folders in AvsP's macros folder, place any macros in the folders, and they will appear in submenus in the Macros menu. You can even make folders in the folders for recursive submenus (although I haven't tested how deep it can go). You can also now use an empty text file named "---.py" to add a separator to the menu.
For translators, you can update the translation the same way as the last version, just put the older translation.py in the AvsP folder and run AvsP. There are a whopping 129 new messages to translate (!), although only 56 are from the main program. The rest are from the new tools, which you don't really need to translate if you don't plan on using them. All messages for the tools appear at the bottom of the translation.py file.
So. Lot of new stuff, lots of new stuff. In some sense you can consider this a beta release, since there are several areas which may be considered incomplete. As my available time for AvsP development decreases, I would certainly appreciate any contributions, especially since some features like command line encoders and overhead calculations are not my area of expertise. Anyhow, give it a whirl, and let me know if you have any new feature requests or problems.
Terranigma
29th August 2007, 19:53
Wow, that's quite the changelog. I'll give this a go right now, Thanks :D
DarkT
29th August 2007, 20:12
" script tabs now keep track of their own frames"
THANK GOD, the whole "change frame here, it changes everywhere" was getting SOOOOOOO on my nerves... But it was still very comfortable for comparisons of different raws, so I was adding black frames at beginning to make them all the same... GOD...
Now, if only I knew how to disable those damn explanations which pop once you go with mouse over a known filter to the AVSP... GOD - that's as annoying as the frames thingy ;).
Besides that - I LOVE, love love - absolutely LOVE the AlienVerSusPradator tool ;).
lolent
29th August 2007, 23:49
incredible changelog, i'll give it a try as soon as possible.
thanks for your work qwerpoi ;)
~bT~
29th August 2007, 23:55
Massssive changelog! Cheers qwerpoi!
smok3
30th August 2007, 00:03
nice, feature request: but it would be even nicer, if the crop info was actually used for proper resizing; example:
http://blog.somestuff.org/resizecalculator.htm
(also crop will need even numbers for yuv.)
qwerpoi
30th August 2007, 03:10
THANK GOD, the whole "change frame here, it changes everywhere" was getting SOOOOOOO on my nerves... But it was still very comfortable for comparisons of different raws, so I was adding black frames at beginning to make them all the same... GOD...
Whoa, didn't know it was so stressful! I'm glad things are okay in this version.
Now, if only I knew how to disable those damn explanations which pop once you go with mouse over a known filter to the AVSP... GOD - that's as annoying as the frames thingy ;).
If you're referring to the filter calltips, you were always able to disable them from the options menu, but in this version they pop up less by default. Now they appear only when you create the filter, or when you go back and edit the filter's arguments, NOT when you move the cursor within the parentheses. If you want them to appear without editing the script, you can highlight a portion of the text within the filter's parentheses.
Wow, that's quite the changelog. I'll give this a go right now, Thanks :D
incredible changelog, i'll give it a try as soon as possible.
thanks for your work qwerpoi ;)
Massssive changelog! Cheers qwerpoi!
Heh, glad you guys are impressed by the changelog, I hope there won't be any major problems so you'll be as happy with the program itself :)
nice, feature request: but it would be even nicer, if the crop info was actually used for proper resizing; example:
http://blog.somestuff.org/resizecalculator.htm
(also crop will need even numbers for yuv.)
As I've mentioned, I'm no resize/aspect ratio expert, but I believe you can crop out black bars (using AvsP's crop tool if you'd like) prior to activating the resize calculator, it should work fine. Basically the pixel aspect ratio (which is automatically computed from the d2v if present) is independent of the video dimensions, so the reported sizes and errors will still be accurate when cropping prior to running the resize calculator. Again, maybe I'm misunderstanding things, so any experts out there, feel free to correct me.
foxyshadis
30th August 2007, 03:44
Cropping and resizing is such a contentious issue that even the DVD authors don't always get it right, so it's a good thing the PAR is editable. =D
Thank you for continuing to work on this, the additions are pretty helpful. Plus the program forces me to learn a little Python to bend it to my will!
Pookie
30th August 2007, 04:17
Almost a year to the day since your original release. Thanks, man.
AlanHK
30th August 2007, 05:18
Great, looks nice.
And now for the bitching:
Typo: Program settings/Text 1:
"..captital letters" --> should be "... capital letters"
I've found a couple of glitches using the automatically generated sliders.
I have a rather long script for a grotty old video:
AVISource("1-1.avi",false)
ffreeze(755)
ffreeze(954)
# 180 ffreezes...
ffreeze(44347)
RemoveDirt()
Sharpen(0.8)
LanczosResize(672,544,0,0,640,480)
AddBorders(24,16,24,16)
(Where ffreeze is my function to simplify FreezeFrame.)
When I loaded this in AvsP, the only function that displayed an automatic slider was Avisource. I couldn't see any way to stimulate it to show the others. But after closing and reopening AvsP, it did detect the commands at the end of the file and presented folded sliders for them.
(Also, when editing the freezeframe numbers I had to continually refresh the video window, otherwise it was showing the wrong frame. This is more of an Avisynth bug I think, similar problems in VDub. This script is the reason I wanted to import and export hundreds of bookmarks, by the way.)
And in another script I have some Trims:
Trim(0 ,781 ) ++\
Trim(781 +1,6238 ).NoLogoAuto(logo,1)++\
Trim(6238 +1,13109) ++\
Trim(13109 +1, 0 ).NoLogoAuto(logo,1)
The sliders for the Trims are confused by the expressions and seem to just ignore them.
The first Trim's first and last frames are shown correctly, but the second only has: First Frame = 6238.
(It should be 781+1 = 782), and no Last Frame at all. The other Trims are similarly given the wrong frames.
Cropping:
If I use the crop editor and mouse to select an area, but have it an odd number in size, I lose the display completely and get a big red error message "Crop: YUV images can only be cropped by an even number..." There is no way to correct my selection area except editing the script directly, or deleting the crop and starting again. Would be nice if the visual crop editor constrained you to legal crop dimensions.
Tabs:
It's quite subtle how the tabs change to show which is the active one. I'd prefer it if the active tab was very obvious, e.g. a different colour, bold text.
krisq
30th August 2007, 07:58
Thanks qwerpoi for this über update. Looks slick so far :D
G_M_C
30th August 2007, 08:26
http://gathering.tweakers.net/global/smileys/worshippy.gif
Was looking at all the fast en usefull changes in the old thread, but never tried using this tool. But seeing how far it has come now, i wont be able to forego on it now. So many kudo's for you qwerpoi, you seem to have succesfully created something other people have failed to get right.
http://gathering.tweakers.net/global/smileys/worshippy.gif
Can you guys even see this smily :?
Henrikx
30th August 2007, 10:39
Update German language file AvsP 2.0.0
New address for the Download
http://technik.movie2digital.de/thread.php?postid=434677#post434677
@qwerpoi
Great Work !
krisq
30th August 2007, 11:50
So... I've opened avsp , drag&dropped .d2v file into it and it showed 'could not open one of the input files'. Save and re-open of the script solved the problem. I have dgdecode in my plugins dir so I don't need to load it manually. There is no such problem with avisource and directshowsource. My guess is it happens with all external source plugins.
SixdeeBee
30th August 2007, 15:34
Got this error message:
[Thu Aug 30 16:15:00 2007]
Traceback (most recent call last):
File "run.py", line 6, in <module>
File "AvsP.pyo", line 11164, in main
File "wx\_core.pyo", line 7700, in __init__
File "wx\_core.pyo", line 7352, in _BootstrapApp
File "AvsP.pyo", line 11154, in OnInit
File "AvsP.pyo", line 3344, in __init__
File "AvsP.pyo", line 3900, in defineFilterInfo
File "AvsP.pyo", line 4072, in getFilterInfoFromAvisynth
AttributeError: 'NoneType' object has no attribute 'split'
System is an AMD K7 (3200+), WinXP home SP 2.
Old version 1.4 works fine.
On a dual core AMD K8 and WinXP pro SP2 the version 2.0
works fine. Both systems have AviSynth 2.57 installed.
Any idea ???
SDB
jethro
30th August 2007, 19:08
Thank you very much, sir!:thanks:
foxyshadis
30th August 2007, 20:36
SixDeeBee, does it happen if you empty out the external plugin folder? Can you isolate it to one plugin if it does?
That reminds me, it seems to be failing if C-interface plugins are found during the initial parse. When it comes across Yadif, I get:
Error parsing GetSystemEnv plugin parameters: unknown character Y
Error parsing GetSystemEnv plugin parameters: unknown character a
Error parsing GetSystemEnv plugin parameters: unknown character d
Error parsing GetWorkingDir plugin parameters: unknown character
Error parsing GetFileInfo plugin parameters: unknown character
Doesn't seem care about FFMpegSource though, so maybe it's not C-interface at all.
SixdeeBee
31st August 2007, 00:35
Found the error, it was my own fault !:stupid:
Its always the difference between thinking and knowing ...
I thought that it was AviSynth 2.57 which had been installed few weeks ago ... but it was 2.58 !
It seems that there is an incompatibility between 2.58 and AvsP 2.0.
Went back to 2.57 and now it works.:)
Possibly someone else can also test with 2.58 and tell us his/her results ?
SdB
qwerpoi
31st August 2007, 23:39
Sorry for the lack of replies recently, I've been sick as a dog these last few days. I'm planning on releasing a bugfix within the week to address some of the issues brought up.
Thank you for continuing to work on this, the additions are pretty helpful. Plus the program forces me to learn a little Python to bend it to my will!
No problem, and learning a bit of Python is always a good thing!
Almost a year to the day since your original release. Thanks, man.
You noticed too, huh? Really just a coincidence (if I noticed sooner I would have planned it to be exactly a year :)), seems like it's been out longer than that to me.
Typo: Program settings/Text 1:
"..captital letters" --> should be "... capital letters"
I've found a couple of glitches using the automatically generated sliders.
Thanks for the bug reports, I'll look into them, along with your cropping and tab suggestions as well.
http://gathering.tweakers.net/global/smileys/worshippy.gif
Was looking at all the fast en usefull changes in the old thread, but never tried using this tool. But seeing how far it has come now, i wont be able to forego on it now. So many kudo's for you qwerpoi, you seem to have succesfully created something other people have failed to get right.
http://gathering.tweakers.net/global/smileys/worshippy.gif
Can you guys even see this smily :?
Thanks, glad to have another convert (and yes, we can see the smiley.)
Update German language file AvsP 2.0.0
New address for the Download
http://technik.movie2digital.de/thread.php?postid=434677#post434677
@qwerpoi
Great Work !
Your translations are always done in record time! I'll update the links accordingly when I get a chance.
So... I've opened avsp , drag&dropped .d2v file into it and it showed 'could not open one of the input files'. Save and re-open of the script solved the problem. I have dgdecode in my plugins dir so I don't need to load it manually. There is no such problem with avisource and directshowsource. My guess is it happens with all external source plugins.
Okay, thanks for pointing that out, I'll try and see what's going on.
Got this error message:
[Thu Aug 30 16:15:00 2007]
Traceback (most recent call last):
File "run.py", line 6, in <module>
File "AvsP.pyo", line 11164, in main
File "wx\_core.pyo", line 7700, in __init__
File "wx\_core.pyo", line 7352, in _BootstrapApp
File "AvsP.pyo", line 11154, in OnInit
File "AvsP.pyo", line 3344, in __init__
File "AvsP.pyo", line 3900, in defineFilterInfo
File "AvsP.pyo", line 4072, in getFilterInfoFromAvisynth
AttributeError: 'NoneType' object has no attribute 'split'
It seems that there is an incompatibility between 2.58 and AvsP 2.0.
Went back to 2.57 and now it works.:)
Huh, I'll have to install 2.58 and see what's the problem. I definitely don't want AvsP to force people to stick with older versions of Avisynth, in AvsP 2.0.0 it's possible to create a filter database specific to each version of Avisynth which will be helpful in this matter. However, having the wrong version should not result in a crash, so I'll try and figure out how to fix that.
Thank you very much, sir!:thanks:
No problemo, sir!
That reminds me, it seems to be failing if C-interface plugins are found during the initial parse. When it comes across Yadif, I get:
Error parsing GetSystemEnv plugin parameters: unknown character Y
Error parsing GetSystemEnv plugin parameters: unknown character a
Error parsing GetSystemEnv plugin parameters: unknown character d
Error parsing GetWorkingDir plugin parameters: unknown character
Error parsing GetFileInfo plugin parameters: unknown character
Doesn't seem care about FFMpegSource though, so maybe it's not C-interface at all.
Ho, I'll check that out asap, thanks for letting me know.
foxyshadis
1st September 2007, 09:08
I was wondering, would you be amenable to something like this in the macro execution:
try:
# Read the macro text
f = open(macrofilename)
macroLines = f.readlines()
f.close()
# Check for syntax errors (thows SyntaxError exception with line number)
compile(''.join(macroLines+['pass']), macrofilename, 'exec')
# Wrap the macro in a function (allows top-level variables to be treated "globally" within the function)
lineList = ['def AvsP_macro_main():'] + ['\t%s' % line for line in macroLines] + ['AvsP_macro_main()']
macrotxt = ''.join(lineList)
# Execute the macro
self.macroVars['avsp'] = AvsP_functions
exec macrotxt in self.macroVars, {}
except:
import traceback
wx.MessageBox('%s\n\n%s\n%s' % (_('Error in the macro:'), sys.exc_info()[1], traceback.format_exc()), 'ERROR')
(modified lines in bold)
This has proven quite helpful in macro development, since I still seem to be making a hundred little syntax mistakes for everything I write; this shows the correct line # and the full error. (Alternately you could just spit the error out to stdout/err.)
Edit: A closer reading of the docs shows that exc_info already returns a traceback and I didn't need to grab a clean one after all. Oops! :p Edit 2: Haha, didn't actually work, I'll figure it out later.
By the way, on an unrelated note, if anyone ever needs to open a file from a macro, it's a somewhat convoluted procedure, since as far as I know you can't piggyback on avsp's window. I don't know much about python's inheritance, though, so many you can. Here's how I accessed it, names changed to protect the guilty:
class MyClass(wxp.Frame):
def __init__(self, parent=None, id=wx.ID_ANY, title='Insert', pos=wx.DefaultPosition, size=(1, 1), style=wx.DEFAULT_FRAME_STYLE):
wx.Frame.__init__(self, parent, id, pos=pos, size=size, style=style)
myfolder = os.environ['SYSTEMROOT']
dlg = wx.FileDialog(parent=self, message='Archives', defaultDir=myfolder, wildcard='Archives|*.zip;*.rar|Everything|*', style=wx.OPEN)
ID = dlg.ShowModal()
if ID == wx.ID_OK:
f = dlg.GetPath()
blah=MyClass() # must be instantiated
The little 1x1 window shouldn't bother anyone, though you can position it offscreen if needed. If you're user friendly, you can save the path for next time, too. :P
check
1st September 2007, 09:48
(modified lines in bold)Just for future reference, with my firefox 2 at least, the bold is almost identical to the non bold in CODE tags. Could you suffix the lines with a # or something as well? The change was a nice idea though, I have been growling about this too :)
By the way, on an unrelated note, if anyone ever needs to open a file from a macro, it's a somewhat convoluted procedure, since as far as I know you can't piggyback on avsp's window. I don't know much about python's inheritance, though, so many you can.
Actually, you can pass None as the parent, which means you can skip the need to instantiate a window for this. I haven't actually specifically tested opening a save window without a main frame, but it should just work like this:
dialog = wx.FileDialog(parent = None, message = "Choose a Save Location", defaultDir = os.getcwd(), wildcard = 'All Files|*', style=wx.SAVE|wx.OVERWRITE_PROMPT|wx.CHANGE_DIR, pos = wx.DefaultPosition)
if dialog.ShowModal() == wx.ID_OK:
return os.path.join(dialog.GetDirectory(),dialog.GetFilename()))
Also note wx.CHANGE_DIR, which will save the path. My memory tells me it does so by changing the CWD though ;)
foxyshadis
1st September 2007, 10:30
One of my little pet peeves is when different file dialogs re-use each other's folders in wildly different circumstances, so I like keeping each dialog's location stored separately. Thanks for the hint on None. (Still a Python nub, it took about an hour to find the traceback library last week, and a few more to figure out needing and how to create a window for a dialog. Working late at night is probably a bad habit.)
Also, added blue text. :D
check
1st September 2007, 11:21
Awesome wxpython reference: http://www.wxpython.org/docs/api/
Also, mistake with my above code (I won't edit it).
String GetDirectory(self)
Returns the default directory.
String GetFilename(self)
Returns the default filename.
You need dialog.GetPath() (or GetPaths() if it's a multiselection) instead. Then to grab the directory you just need to os.path.dirname(dialog.GetPath())
RedDwarf1
2nd September 2007, 04:48
I keep getting an error when I OK the Configure Shortcuts dialogue. The keys I set are not being implemented. The default video movement settings are not logical to me. I tried setting move forward by 1 second to the Up key but the Up key still moves back 1 second. I have Down set to move back 1 second but it is still moving forward 1 second.
Traceback (most recent call last):
File "AvsP.pyo", line 6039, in OnMenuConfigureShortcuts
File "AvsP.pyo", line 4580, in bindShortcutsToAllWindows
File "wxp.pyo", line 404, in BindShortcutsToWindows
KeyError: 231
krisq
2nd September 2007, 12:49
I keep getting an error when I OK the Configure Shortcuts dialogue. The keys I set are not being implemented. The default video movement settings are not logical to me. I tried setting move forward by 1 second to the Up key but the Up key still moves back 1 second. I have Down set to move back 1 second but it is still moving forward 1 second.
Traceback (most recent call last):
File "AvsP.pyo", line 6039, in OnMenuConfigureShortcuts
File "AvsP.pyo", line 4580, in bindShortcutsToAllWindows
File "wxp.pyo", line 404, in BindShortcutsToWindows
KeyError: 231
I can confirm the error. Changed shortcuts work after restart.
Zarxrax
2nd September 2007, 22:25
When line-by-line update is enabled, can you have it not automatically move the cursor to a problematic line?
Say you add a filter to your script, and avisynth throws an error saying that the video is in the wrong colorspace. You press up to go to the previous line so you can add a colorspace conversion, but when you press up, avsp will update again, and pull your cursor back down. This can lead to you very easily overwriting lines in your script by accident.
Harukalover
3rd September 2007, 00:46
Been having a lot of trouble using avsp. Multitudes of errors have appeared during my usage of it which almost all end in crashes.
Examples from the error log:
Exception exceptions.WindowsError: 'exception: access violation reading 0x80D47ED5' in <bound method PIScriptEnvironment.__del__ of <avisynth.PIScriptEnvironment instance at 0x01A1A878>>
WindowsError: exception: access violation reading 0x00086100
Traceback (most recent call last):
File "AvsP.pyo", line 7012, in OnPaintVideoWindow
File "AvsP.pyo", line 9314, in PaintAVIFrame
File "pyavs.pyo", line 322, in DrawFrame
File "pyavs.pyo", line 301, in _GetFrame
File "avisynth.pyo", line 277, in GetFrame
WindowsError: exception: access violation reading 0x00086100
Any ideas what's causing these errors from those logs? Would an install of wxPython cause these issues? (I need it for a separate program to work)
bidmead
3rd September 2007, 08:03
Excellent work -- I love this thing.
I have some queries:
The encoder tool seems to allow you to set up any .exe as the encoder. It seems to exclude using, eg, a .bat file in this capacity.
I don't understand the "automatic user sliders". The accumulation of functions folded on the right hand side of the viewer open to show editable values but I can't see any sliders here.
These folded functions are miscreated for moderately complex script lines like, eg:
Dissolve(Trim(movie,0,2078), Trim(movie,3346,0))
I voice these niggles with some reluctance, because I'm probably just exposing my own ignorance. But hopefully there's an outside chance that they may be useful.
--
Chris
AlanHK
3rd September 2007, 10:02
I don't understand the "automatic user sliders". The accumulation of functions folded on the right hand side of the viewer open to show editable values but I can't see any sliders here.
You do get automatic sliders for functions like "sharpen".
I'd like a way to hide, not just "fold", auto sliders I don't want to play with. A right-click option perhaps.
salehin
3rd September 2007, 16:37
Thanks a lot qwerpoi for this nice little tool which is saving me lot of time. I also like the way you've kindly mentioned contributors' names in the log.
I may be wrong in what follows- when I switch between tabs, AvsP takes me to the exact frame. But it doesn't seem to work in the 1st tab. 1st tab stays on the last frame that it had (regardless of what was in other tabs beforehand)
Avs script
DGDecode_mpeg2source("K:\CALCUTTA\VIDEO_TS\IBRD.d2v")
tfm(order=1).tdecimate()
crop( 30, 14, -30, -18)
#Spline36Resize(656,448) # Spline36 (Neutral)
dull = last.Spline36Resize(656,448)
sharp = dull.LimitedSharpenFaster(dest_x=656,dest_y=448,Strength=85)
Soothe(sharp,dull,40)
FYI, according to DGIndex 1.5.0.0,
FR: 29.97 fps
Type: Film (99%),
Field order: top & bottom (both, varies)
Frame type: progressive and interlaced (both, varies)
Bitrate (goes upto): 8-9 mbps
foxyshadis
3rd September 2007, 21:27
I don't understand the "automatic user sliders". The accumulation of functions folded on the right hand side of the viewer open to show editable values but I can't see any sliders here.
Sliders are only for numeric values.
A bug I found a long time ago but forgot to mention: For some reason, using the scroll wheel on the preview video will make it hang for a while. (And once locked up completely.)
kipico
4th September 2007, 00:06
I'm thoroughly impressed by the versatility of this application! Throw in an Auto Crop function and audio encode/muxing and this'll convert me from GK :D
Veiga
4th September 2007, 05:12
qwerpoi
Congratulation one time more for your nice tool.
little contribution for who appreciate portugues_Br translation
kypec
4th September 2007, 12:28
Thanks for your great effort on this tool :)
Just a tiny comment: please replace the JPG screenshots in help\images with PNG. It is much better suited for that type of graphics...
check
4th September 2007, 14:32
the output box can output jpb, png or bmp. The format is chosen based on the extension used.
Leak
4th September 2007, 16:09
the output box can output jpb, png or bmp. The format is chosen based on the extension used.
Ummm... I think he might have been talking about the AvsP documentation and replacing the JPG screenshots of the interface therein with PNG ones...
np: Dr. Walker & M.Flux - Cover M-I-5 (Köln Kompakt 1)
check
5th September 2007, 08:47
Ummm... I think he might have been talking about the AvsP documentation and replacing the JPG screenshots of the interface therein with PNG ones...
np: Dr. Walker & M.Flux - Cover M-I-5 (Köln Kompakt 1)
oops, where are my glasses 8)
kypec
5th September 2007, 09:25
Ummm... I think he might have been talking about the AvsP documentation and replacing the JPG screenshots of the interface therein with PNG ones...
Yes, that's exactly what I had in mind :p
Serbianboss
6th September 2007, 13:15
Just two suggestion,
It would be good if we have button "close tabs". Because if we have several tabs open and want to close avsp it aks for every tab to close. Its ok, but it would be easer if we press just once to close all tabs.
Also it would be good if you update flash tutorial on site with new features of avsp.
thanks
foxyshadis
6th September 2007, 14:20
Agreed that something like "New Session" would be useful. In the meantime, you can use a macro like this:
while(avsp.GetTabCount() > 1):
avsp.CloseTab(boolPrompt=False)
avsp.NewTab()
avsp.CloseTab(index=0,boolPrompt=False)
(Doesn't ask or save anything! Save your session first. Extending it to ask something like "save all, save none, ask" would be pretty trivial though.)
bidmead
6th September 2007, 14:26
Sliders are only for numeric values.
Yup. So I was expecting there to be sliders for, eg:
Trim(0,4578) ++ Trim(5903,0)
--
Chris
foxyshadis
6th September 2007, 14:38
Yup. So I was expecting there to be sliders for, eg:
Trim(0,4578) ++ Trim(5903,0)
--
Chris
Turns out I was wrong, sorry, didn't look hard enough. You have to explicitly define slider ranges in the function definition (trim is listed under built-ins). Trim is kind of a special case, it's something that'd need to be reset internally on every refresh to be most useful, possibly each one read as it own clip's properties, but that isn't possible now.
qwerpoi
6th September 2007, 17:38
I haven't had much time for AvsP recently, the bugfix update is still planned to be released over the weekend or early next week. Thanks to everyone who have been answering questions, it's a big help.
I was wondering, would you be amenable to something like this in the macro execution:
This has proven quite helpful in macro development, since I still seem to be making a hundred little syntax mistakes for everything I write; this shows the correct line # and the full error.
I'll take a look at it, it should be doable.
By the way, on an unrelated note, if anyone ever needs to open a file from a macro, it's a somewhat convoluted procedure, since as far as I know you can't piggyback on avsp's window.
You should be able to use the macro command avsp.GetFilename() for this purpose, which will simply return the filename (or an empty string if the user presses cancel). Although this is undocumented (sorry about that), you can specify the file filter as well, which follows standard syntax. So the code to get the filename of an archive file would be one line:
filename = avsp.GetFilename(title='Get an archive file', filefilter='Archives|*.zip;*.rar|Everything|*')
I *think* that will be able to do everything that you need.
I keep getting an error when I OK the Configure Shortcuts dialogue. The keys I set are not being implemented.
Thanks for letting me know, I'll try and have it fixed for the next release.
When line-by-line update is enabled, can you have it not automatically move the cursor to a problematic line?
Say you add a filter to your script, and avisynth throws an error saying that the video is in the wrong colorspace. You press up to go to the previous line so you can add a colorspace conversion, but when you press up, avsp will update again, and pull your cursor back down. This can lead to you very easily overwriting lines in your script by accident.
I haven't used line-by-line updating in a while, so it never occured to me - I'll try to simply automatically disable problematic line highlighting when line-by-line updating is checked.
Been having a lot of trouble using avsp. Multitudes of errors have appeared during my usage of it which almost all end in crashes.
Any ideas what's causing these errors from those logs? Would an install of wxPython cause these issues? (I need it for a separate program to work)
I don't think having wxPython installed can cause such issues (I have it installed as well). The errors you are reporting are crashes in avisynth, which possibly means there's a problem with your specific avisynth scripts. Try running the same scripts in virtual dub, or even an older version of AvsP, it may turn out you have an unstable plugin or avsi script in your plugins directory. Or it may turn out that there's a problem in AvsP 2.0.0, so in either case, post an example problematic script and I'll take a look.
The encoder tool seems to allow you to set up any .exe as the encoder. It seems to exclude using, eg, a .bat file in this capacity.
That's true, I guess it made sense to me that way. If you wanted to use a .bat file instead of an .exe, couldn't you make a preset using cmd.exe, where the first argument is the batch file? Or is it not possible this way to send further args to the batch file? (Sorry, command lines and dos batch scripts are not my area of expertise...)
I don't understand the "automatic user sliders". The accumulation of functions folded on the right hand side of the viewer open to show editable values but I can't see any sliders here.
As foxyshadis pointed out, all specified arguments in the script show up in the slider window, but if AvsP doesn't have the info to build a slider, it will show the simple text box in its place. You can tell if AvsP has the info or not by looking at the calltip. And again as foxyshadis mentioned, it would be possible to make sliders for Trim, but the min and max values for the sliders are quite complicated, since they depend on the clip's framecount and each other. Eventually AvsP may support such complexities, but for now, they'll show up as text boxes, you can edit the values in the box and hit enter to refresh.
These folded functions are miscreated for moderately complex script lines like, eg:
Dissolve(Trim(movie,0,2078), Trim(movie,3346,0))
Yes, you're right, I should have mentioned this earlier - the automatic sliders currently choke on filters with repeating arguments. If you look at the calltip for Dissolve:
Dissolve(clip a, clip b [, ...], int overlap, float "fps")
The [, ...] indicates that you can keep on adding more clips, clip c, clip d, etc. This makes it very difficult to build sliders properly. Difficult, but not impossible, it's something I'm working on for the near future.
I'd like a way to hide, not just "fold", auto sliders I don't want to play with. A right-click option perhaps.
I think you can accomplish what you want by simply excluding certain filters from ever having automatic sliders. In the "Options -> Program settings..." dialog box, under the "User sliders" tab, you can simply enter the names of any filters you never want user sliders for in the "Filter exclusion list" at the bottom (separate by spaces). Alternatively, you can uncheck various type checkboxes, so if you uncheck everything except for "type int/float", then when the automatic sliders are created, only filters with numerical slider arguments are created.
Thanks a lot qwerpoi for this nice little tool which is saving me lot of time. I also like the way you've kindly mentioned contributors' names in the log.
I may be wrong in what follows- when I switch between tabs, AvsP takes me to the exact frame. But it doesn't seem to work in the 1st tab. 1st tab stays on the last frame that it had (regardless of what was in other tabs beforehand)
The frame is forced to be the same as the previous tab when the two videos have similar properties (width, height, framecount), which is probably what's going on here. This is crucial for being able to compare filter differences between two videos in two tabs, but it can on rare occasions get in the way.
A bug I found a long time ago but forgot to mention: For some reason, using the scroll wheel on the preview video will make it hang for a while. (And once locked up completely.)
The reason this occurs is the scroll wheel is used to cycle between tabs when the video preview has focus. Specifically, AvsP searches for the next tab with similar video properties (width, height, framecount). An unfortunate side effect is that if you have many tabs open which have never been previewed, AvsP will refresh the video on each tab behind your back in order to determine its video properties. I think I should make it an option to disable scroll wheel through tabs, since keyboard shortcuts should provide a faster alternative.
I'm thoroughly impressed by the versatility of this application! Throw in an Auto Crop function and audio encode/muxing and this'll convert me from GK :D
There's nothing stopping you or someone else from creating an encoding preset that does audio encoding and muxing, since plenty of command line tools exist for the job (mp4box, besweet, mencoder, etc). I may try and put together a few examples for a future release (although it's not really my area of expertise). As for an auto-crop, that's actually an interesting idea, I'll give it some thought.
qwerpoi
Congratulation one time more for your nice tool.
little contribution for who appreciate portugues_Br translation
Thanks a lot for the translation update, I'll update the links as soon as I can.
Thanks for your great effort on this tool :)
Just a tiny comment: please replace the JPG screenshots in help\images with PNG. It is much better suited for that type of graphics...
Hah, originally I made them jpgs to conserve bandwith, since the help files are distributed with each version, and my stuff is being graciously hosted on the avisynth webspace. Anyway, I'm going to have to redo every screenshot for AvsP 2.0.0, so I'll likely use pngs as you suggest, and not include the web pages with each release.
It would be good if we have button "close tabs". Because if we have several tabs open and want to close avsp it aks for every tab to close. Its ok, but it would be easer if we press just once to close all tabs.
Also it would be good if you update flash tutorial on site with new features of avsp.
Good idea on the close tabs, I'll add it to the File menu, and it will prompt to save the session before closing. As for updating the flash tutorial, you're absolutely right, I was planning on doing a whole screencast sort of thing, although ultimately it's going to take quite a bit of time to update the whole website properly.
Harukalover
6th September 2007, 21:27
I don't think having wxPython installed can cause such issues (I have it installed as well). The errors you are reporting are crashes in avisynth, which possibly means there's a problem with your specific avisynth scripts. Try running the same scripts in virtual dub, or even an older version of AvsP, it may turn out you have an unstable plugin or avsi script in your plugins directory. Or it may turn out that there's a problem in AvsP 2.0.0, so in either case, post an example problematic script and I'll take a look.
Aye, at the time I didn't have a full pattern of why it was happening but it seems it was the obvious. It currently only seems to happen with rather long scripts. (this particular one being 417 lines long). Also the script seems to cause Vdub to crash if reopened more than 2 times. So probably just some issued filter being used. If you do want the script for checking, I'll PM you it since it's kind of long and I don't think this site allows spoiler tags.
Also quick question. Is there anyway to make AvsP act like it used to where it didn't keep track of what frame each tab is on by itself? It's a pain for when comparing two different resolution videos but the exact same video in frame count. (the other is just resized)
zemog
8th September 2007, 09:11
Thanks qwerpoi for your excellent work on this valuable update
AlanHK
8th September 2007, 10:53
Originally Posted by AlanHK:
I'd like a way to hide, not just "fold", auto sliders I don't want to play with. A right-click option perhaps.
I think you can accomplish what you want by simply excluding certain filters from ever having automatic sliders.
I can do that, but in one script I may want to twiddle a particular function, in another not. Or after I've worked out a setting, I want to hide it and concentrate on another.
rfmmars
10th September 2007, 17:18
On all of my workstations using version 2.0, the Slider-Togle panel on the right does not display, your see part of the desktop instead. This is a very long script. clicking to a short script with panel and back again, fixes the problem. This was not a problem with the older version.
http://img68.imageshack.us/img68/5545/avspopenus3.th.jpg (http://img68.imageshack.us/my.php?image=avspopenus3.jpg)
[COLOR="RoyalBlue"]#AVISource("e:\1.vdr.avi")
ImageSource("Alaska.jpg")
LoadPlugin("e:\AVS\Plugins\AGC.dll")
LoadPlugin("e:\AVS\plugins\removegrain.dll")
LoadPlugin("e:\AVS\Plugins\mt_masktools.dll")
LoadPlugin("e:\AVS\Plugins\warpsharp.dll")
Loadplugin("e:\avs\plugins\gradfun2db.dll")
loadplugin("e:\avs\plugins\DeGrainMedian.dll")
loadplugin("e:\avs\plugins\Smoothdeinterlacer.dll")
LoadPlugin("e:\avs\plugins\Convolution3d.dll")
LoadPlugin("e:\avs\plugins\FFT3DFilter.dll")
LoadPlugin("e:\avs\plugins\VagueDenoiser.dll")
LoadPlugin("e:\avs\plugins\depan.dll")
LoadPlugin("e:\avs\plugins\depanEstimate.dll")
LoadPlugin("E:\AVS\Plugins\repair.dll")
LoadPlugin("E:\AVS\Plugins\masktools.dll")
LoadPlugin("e:\avs\plugins\mvtools.dll")
LoadPlugin("e:\avs\plugins\autolevels.dll")
import("E:\avs\seesaw6.avs")
SetMemoryMax(512)
ConverttoYv12()
Autolevels(filterRadius=8,sceneChgThresh=10)
#Autolevels(filterRadius=8, sceneChgThresh=10,
ConverttoYUY2()
ConvertToYV12()
HDRAGC(avg_lum=1391,mode=2,passes=1,shift_u=-35, shift_v=0,protect=2,coef_gain=0.05,max_gain=4.61,corrector=0.9,reducer=2.0,avg_window=30,black_clip=0.8,max_sat=2.37,min_sat=0.17,coef_sat=1.0)
Tweak(0.4,1.2)
#
#SeeSaw( NRlimit=4, NRlimit2=5, Sstr=1.5, Slimit=9, Spower=9, Szp=16, sootheT=80, bias=40)
return last
EDIT: Deleted AVSp Comment lines plus I found that script sizes doesn't plat a part in this problem
Richard
bidmead
10th September 2007, 20:09
Sorry, but I don't see the point of posting a huge long script, most of which is commented out, and with a large number of blank lines. And in fact there doesn't seem much point in submitting a script like this at all, as it's only going to throw up an error message without the source file(s).
And as far as I can see, Tweak is the only function there that can be expected to autocreate a slider, unless you've explicitly set up autosliders for the external functions.
What happens when you hit Alt-F5?
--
Chris
rfmmars
10th September 2007, 23:05
Sorry, but I don't see the point of posting a huge long script, most of which is commented out, and with a large number of blank lines. And in fact there doesn't seem much point in submitting a script like this at all, as it's only going to throw up an error message without the source file(s).
And as far as I can see, Tweak is the only function there that can be expected to autocreate a slider, unless you've explicitly set up autosliders for the external functions.
What happens when you hit Alt-F5?
--
Chris
Well I thought it was a long script problem, but it doesn't matter if its a long or short script. If i hit Alt F5, i get a full preview window, it I hit it again, then everything is OK.
I posted the script as it was saved by AVSp, it puts the commented lines in, not me . Just trying to give the author as much information as possible.
So yes hitting "Alt F5 twice fixes it but I should not have to do it, not needed before
Richard
vBulletin® v3.8.11, Copyright ©2000-2025, vBulletin Solutions Inc.