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. |
![]() |
#1 | Link | |
typo lover
Join Date: May 2009
Posts: 595
|
GenericFilters [Now part of VS core]
GenericFilters-0.7.0.zip
https://github.com/chikuzen/GenericFilters GenericFilters is a set of common image-processing filters. I think that the necessity of using masktools2 of avisynth will decrease considerably if this plugin and std.functions are used together. Quote:
20130812 update to 0.7.0
__________________
my repositories Last edited by Chikuzen; 21st August 2013 at 03:22. |
|
![]() |
![]() |
![]() |
#2 | Link |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,503
|
It is my duty to shamelessly bump this post since it renders masktools almost completely obsolete. We're now one big step closer to getting completely native vapoursynth scripts for useful things.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
![]() |
![]() |
![]() |
#5 | Link | |
soy sauce buyer
Join Date: Mar 2010
Location: United Kingdom
Posts: 164
|
Quote:
|
|
![]() |
![]() |
![]() |
#6 | Link |
typo lover
Join Date: May 2009
Posts: 595
|
hmm...
generic.Convolution always saturate the output on 8bit format. mt_edge("1 2 1 0 0 0 -1 -2 -1 1", 0, 255) is same as mt_convolution("1 2 1", "1 0 -1", saturate=false) currently, I'm working on imprementing Sobel and Prewitt proper function by the request from Myrsloik. Since I'm not familiar with SIMD, I may require time for beginning it.
__________________
my repositories Last edited by Chikuzen; 6th January 2013 at 13:12. |
![]() |
![]() |
![]() |
#7 | Link |
typo lover
Join Date: May 2009
Posts: 595
|
Updated to 0.2.0
* Add new function 'Sobel'. * Add new function 'Prewitt'. * Convolution/HV: add new option 'saturate'. * Minimum/Maximum: add new option 'coordinates' * various bug fix.
__________________
my repositories |
![]() |
![]() |
![]() |
#8 | Link |
Registered User
Join Date: Sep 2004
Location: Near LA, California, USA
Posts: 1,545
|
The coordinates option and saturate option fix the issues HolyWu described. Thank You.
__________________
Pirate: Now how would you like to die? Would you like to have your head chopped off or be burned at the stake? Curly: Burned at the stake! Moe: Why? Curly: A hot steak is always better than a cold chop. |
![]() |
![]() |
![]() |
#9 | Link | |||
typo lover
Join Date: May 2009
Posts: 595
|
Quote:
Quote:
Quote:
and, Prewitt that I wrote is 'Prewitt compass edge detection' which requires 8 kernels.
__________________
my repositories Last edited by Chikuzen; 5th January 2013 at 11:50. |
|||
![]() |
![]() |
![]() |
#10 | Link | |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,503
|
Quote:
Sobel is indeed defined as 1 2 1, 0 0 0, - 1 -2 - 1 and then the horizontal and vertical filters are usually summed up as sqrt(sh^2+sv^2) or abs(sh) + abs(sv) for speed. There are also variants where the filter is rotated when looking for diagonal edges but I've never seen it used. Now on to prewitt. Apparently the prewitt guy was busy and suggested several similar things. But the one you want is described here: http://en.wikipedia.org/wiki/Prewitt_operator and should be just about identical to sobel except that it's 1 1 1. I really can't find any mention of masktool's so called sobel filter. I can however tell you this, it really is implemented like a single 0 1 0, 1 0 -1, 0 -1 0 convolution and I think it looks like a horrible idea. It's easy to see that edges get a VEEEEEERY different weight depending on directionality. Just imagine a diagonal gradient in the \ and / directions and see the difference in result.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
|
![]() |
![]() |
![]() |
#11 | Link |
typo lover
Join Date: May 2009
Posts: 595
|
I found some typo and wrong understanding on Sobel and Prewitt.
updated to 0.2.1 * Sobel/Prewitt: fix invalid logic * Sobel/Prewitt: Change default values of 'min' and 'max'
__________________
my repositories |
![]() |
![]() |
![]() |
#13 | Link |
Registered User
Join Date: Sep 2004
Location: Near LA, California, USA
Posts: 1,545
|
^Not yet.
The current Vapoursynth QTGMC script is here. http://forum.doom9.org/showthread.php?t=166582
__________________
Pirate: Now how would you like to die? Would you like to have your head chopped off or be burned at the stake? Curly: Burned at the stake! Moe: Why? Curly: A hot steak is always better than a cold chop. |
![]() |
![]() |
![]() |
#14 | Link |
typo lover
Join Date: May 2009
Posts: 595
|
updated to 0.2.2
* Sobel, Prewitt: add new option 'rshift' * Sobel, Prewitt: fix 9/10/16bit format processing
__________________
my repositories |
![]() |
![]() |
![]() |
#16 | Link |
typo lover
Join Date: May 2009
Posts: 595
|
__________________
my repositories |
![]() |
![]() |
![]() |
#17 | Link |
typo lover
Join Date: May 2009
Posts: 595
|
updated to 0.3.0
* add new function 'Blur'
__________________
my repositories |
![]() |
![]() |
![]() |
#20 | Link |
typo lover
Join Date: May 2009
Posts: 595
|
(Probably,) fixed.
genericfilters_0.4.1.dll
__________________
my repositories |
![]() |
![]() |
![]() |
Thread Tools | Search this Thread |
Display Modes | |
|
|