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
Register FAQ Calendar Today's Posts Search

Reply
 
Thread Tools Search this Thread Display Modes
Old 16th November 2004, 06:33   #1  |  Link
pogo stick
I have sawdust in my head
 
pogo stick's Avatar
 
Join Date: Aug 2003
Location: Russia
Posts: 305
ffavisynth - ffdshow preprocessing filter for avisynth

New versions of ffdshow include this filter (as well as filters for VirtualDub and DScaler).
Here is what ffdshow's help says about it:
Quote:
ffavisynth

ffavisynth - Avisynth filter to directly use ffdshow image processing filters from Avisynth scripts

Syntax

ffdshow(string "preset", string "options")

preset - existing ffdshow preset to be used
options - array of "name=value" pairs separated by commas

Both parameters are optional. If preset is not specified, a new preset called ffavisynth is created temporarly. Options override preset settings. List of allowed options names and values is to be written, for now look at registry key HKEY_CURRENT_USER\Software\GNU\ffdshow\default to get the idea.

Limitation

Input and output colorspaces are equal. Even if ffdshow image processing filter chain would produce image with different colorspace, it will be converted to match that on input.
And here is more explanations by Milan:
Quote:
Try to append this:

ffdshow(options="isLevels=1,levelsMode=0,levelsGamma=1500")

to your script. If it would work, the effect should be very visible.

Another for is:

ffdshow(preset="alread_existing_preset_name")

and you can combine both

ffdshow(preset="alread_existing_preset_name",options="isLevels=1,levelsMode=0,levelsGamma=1500")

which will load preset, modify given values and process video.
I tried some options and it seems to work as it should.
pogo stick is offline   Reply With Quote
Old 16th November 2004, 08:57   #2  |  Link
sh0dan
Retired AviSynth Dev ;)
 
sh0dan's Avatar
 
Join Date: Nov 2001
Location: Dark Side of the Moon
Posts: 3,480
Rock! Really cool feature! Being able to use AviSynth in ffdshow is great, but this is awesome!
__________________
Regards, sh0dan // VoxPod
sh0dan is offline   Reply With Quote
Old 17th November 2004, 06:30   #3  |  Link
Zarxrax
Registered User
 
Join Date: Dec 2001
Posts: 1,219
WOW! Just the other day I was wishing for something that does exactly this!
Zarxrax is offline   Reply With Quote
Old 5th December 2004, 02:16   #4  |  Link
Video Dude
Senior Member
 
Join Date: Apr 2004
Posts: 1,054
This filter works great.

Last edited by Video Dude; 13th April 2005 at 20:45.
Video Dude is offline   Reply With Quote
Old 21st December 2004, 01:12   #5  |  Link
Valky
Registered User
 
Valky's Avatar
 
Join Date: Feb 2002
Location: Finland
Posts: 275
I wasn't lucky enough to get this to work. I wonder what I did wrong.

In ffdshow I adjusted my settings so that video looked good. Then I saved my preset to 'e:\avs-testit\' as 'newone'.

Then I tried this script:

AviSource("E:\AVS-TESTIT\testi.avi")
ffdshow(preset="e:\avs-testit\newone")


And it didn't work? It doesn't give me any errors in VD, but I just know that the postprocessing, level adjustment or reize isn't there but video loads fine.

My ffdshow is version from beginning of november. Are there something I didn't understand (well that's obvious...) ?



edit: fortunately VD-plugin works great and I can do the same things there!

Last edited by Valky; 21st December 2004 at 01:23.
Valky is offline   Reply With Quote
Old 22nd December 2004, 01:03   #6  |  Link
marcellus
Registered User
 
Join Date: Mar 2004
Posts: 95
Quote:
Originally posted by Valky
I wasn't lucky enough to get this to work. I wonder what I did wrong.

In ffdshow I adjusted my settings so that video looked good. Then I saved my preset to 'e:\avs-testit\' as 'newone'.

Then I tried this script:

AviSource("E:\AVS-TESTIT\testi.avi")
ffdshow(preset="e:\avs-testit\newone")


And it didn't work? It doesn't give me any errors in VD, but I just know that the postprocessing, level adjustment or reize isn't there but video loads fine.

My ffdshow is version from beginning of november. Are there something I didn't understand (well that's obvious...) ?



edit: fortunately VD-plugin works great and I can do the same things there!
AFAIK the presets in ffdshow are saved only in registry, I don't know how you managed to save a preset on disk (or you just typed a path as a preset name?). Next time try to save the preset to a name like "my_preset" and call it from avisynth with that name, without any path. I did so some time ago and it worked.
marcellus is offline   Reply With Quote
Old 22nd December 2004, 01:59   #7  |  Link
Valky
Registered User
 
Valky's Avatar
 
Join Date: Feb 2002
Location: Finland
Posts: 275
Quote:
Originally posted by marcellus
AFAIK the presets in ffdshow are saved only in registry, I don't know how you managed to save a preset on disk (or you just typed a path as a preset name?). Next time try to save the preset to a name like "my_preset" and call it from avisynth with that name, without any path. I did so some time ago and it worked.
In ffdshow you can find 'image settings' in menu where and there you can choose option 'save to file'. You can also load your presets here.

So I saved my preset as 'newone' on that particular folder in my script and I have in that folder 7k file named 'newone.preset'. I tried to open this file in avisynth also with extension, but no luck (no error either and video opens in vd, but without any filtering...).

Also if I open this preset-file in notepad, I can see that there are just those options enabled that I had enabled in ffdshow just before I saved that file, so I dont know why this didn't work
Valky is offline   Reply With Quote
Old 22nd December 2004, 07:59   #8  |  Link
Leak
ffdshow/AviSynth wrangler
 
Leak's Avatar
 
Join Date: Feb 2003
Location: Austria
Posts: 2,441
Quote:
Originally posted by Valky
In ffdshow you can find 'image settings' in menu where and there you can choose option 'save to file'. You can also load your presets here.

So I saved my preset as 'newone' on that particular folder in my script and I have in that folder 7k file named 'newone.preset'. I tried to open this file in avisynth also with extension, but no luck (no error either and video opens in vd, but without any filtering...).
Are you sure that the ffdshow-AviSynth-plugin wants a file name here?

Have you tried just creating a preset in the ffdshow config dialog (which gets stored in the registry AFAIK) and using just it's name instead of a filename?
Leak is offline   Reply With Quote
Old 22nd December 2004, 12:59   #9  |  Link
Valky
Registered User
 
Valky's Avatar
 
Join Date: Feb 2002
Location: Finland
Posts: 275
Quote:
Originally posted by Leak
Are you sure that the ffdshow-AviSynth-plugin wants a file name here?

Have you tried just creating a preset in the ffdshow config dialog (which gets stored in the registry AFAIK) and using just it's name instead of a filename?
I have also tried script:

Code:
loadplugin("C:\Program Files\AviSynth 2.5\plugins\ffavisynth.dll")
AviSource("E:\AVS-TESTIT\testi.avi")

ffdshow()
And it doesn't work (well video opens fine, but settings aren't there)
Is it broken in this version from Nov 1 ?
Valky is offline   Reply With Quote
Old 22nd December 2004, 13:42   #10  |  Link
Leak
ffdshow/AviSynth wrangler
 
Leak's Avatar
 
Join Date: Feb 2003
Location: Austria
Posts: 2,441
Quote:
Originally posted by Valky
I have also tried script:

Code:
loadplugin("C:\Program Files\AviSynth 2.5\plugins\ffavisynth.dll")
AviSource("E:\AVS-TESTIT\testi.avi")

ffdshow()
And it doesn't work (well video opens fine, but settings aren't there)
Is it broken in this version from Nov 1 ?
I'd say this doesn't work because, as it's stated in the first post in this thread, if you don't specify anything it'll use a preset named "ffavisynth". If you want to use the current ffdshow settings, you'll probably have to use

ffdshow("default")

or you can just create a new preset by hitting the new button, rename it by clicking twice on "default 1" or what the new one is named and change it's settings to your liking, then using

ffdshow("<name of your new preset>")

and it should work. No files on disk involved - everything gets stored in the registry.

Also, the newest ffdshow build can be found here:

http://celticdruid.no-ip.com/xvid/ffdshow/
Leak is offline   Reply With Quote
Old 22nd December 2004, 14:08   #11  |  Link
Valky
Registered User
 
Valky's Avatar
 
Join Date: Feb 2002
Location: Finland
Posts: 275
Quote:
Originally posted by Leak
[B]I'd say this doesn't work because, as it's stated in the first post in this thread, if you don't specify anything it'll use a preset named "ffavisynth". If you want to use the current ffdshow settings, you'll probably have to use

ffdshow("default")
Ah, finally!
The trick was to use parameter "default" so thank you very much
Valky is offline   Reply With Quote
Old 22nd December 2004, 15:03   #12  |  Link
marcellus
Registered User
 
Join Date: Mar 2004
Posts: 95
Quote:
Originally posted by Valky
In ffdshow you can find 'image settings' in menu where and there you can choose option 'save to file'. You can also load your presets here.
Ahh, yes, my mistake, sorry, I was confused ( I was thinking about the encoder's presets, not image processing presets).

Anyway, it seems that ffavisynth cannot call presets that are not already in registry, so for now forget about presets saved on disk.
Quote:
Originally posted by Valky
The trick was to use parameter "default" so thank you very much
Yes, this does the trick as long you don't modify it (which is very easy to do when you play a file and fiddle with settings). If you like your settings and you want to keep'em for future use create a new preset as Leak told you and give it a name like "denoise" (or something) and call it with
ffdshow("denoise")
It will work, I assure you, and besides you can make as many presets as you need for various movie sources you have and save time that way. This is what a preset is meant for.
marcellus is offline   Reply With Quote
Reply


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 00:05.


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