<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="http://avisynth.nl/skins/common/feed.css?303"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://avisynth.nl/index.php?action=history&amp;feed=atom&amp;title=MaskTools%2FEdgeMask</id>
		<title>MaskTools/EdgeMask - Revision history</title>
		<link rel="self" type="application/atom+xml" href="http://avisynth.nl/index.php?action=history&amp;feed=atom&amp;title=MaskTools%2FEdgeMask"/>
		<link rel="alternate" type="text/html" href="http://avisynth.nl/index.php?title=MaskTools/EdgeMask&amp;action=history"/>
		<updated>2026-05-14T01:00:17Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.19.24</generator>

	<entry>
		<id>http://avisynth.nl/index.php?title=MaskTools/EdgeMask&amp;diff=163&amp;oldid=prev</id>
		<title>Admin: 1 revision</title>
		<link rel="alternate" type="text/html" href="http://avisynth.nl/index.php?title=MaskTools/EdgeMask&amp;diff=163&amp;oldid=prev"/>
				<updated>2013-05-09T15:01:59Z</updated>
		
		<summary type="html">&lt;p&gt;1 revision&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
			&lt;tr valign='top'&gt;
			&lt;td colspan='1' style=&quot;background-color: white; color:black;&quot;&gt;← Older revision&lt;/td&gt;
			&lt;td colspan='1' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 15:01, 9 May 2013&lt;/td&gt;
			&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>Admin</name></author>	</entry>

	<entry>
		<id>http://avisynth.nl/index.php?title=MaskTools/EdgeMask&amp;diff=162&amp;oldid=prev</id>
		<title>Gzarkadas at 20:03, 6 March 2008</title>
		<link rel="alternate" type="text/html" href="http://avisynth.nl/index.php?title=MaskTools/EdgeMask&amp;diff=162&amp;oldid=prev"/>
				<updated>2008-03-06T20:03:15Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{FilterCat|External_filters|Other_filters|Support_filters}}&lt;br /&gt;
&lt;br /&gt;
{{FuncDef|EdgeMask (clip[, int &amp;quot;thY1&amp;quot;[, int &amp;quot;thY2&amp;quot;[, int &amp;quot;thC1&amp;quot;[, int &amp;quot;thC2&amp;quot;[, string &amp;quot;type&amp;quot;]]]]])}}&lt;br /&gt;
&lt;br /&gt;
'''Plugin''': [[MaskTools]]&lt;br /&gt;
&lt;br /&gt;
This filter creates an edge mask of the picture. The edge-finding algorithm uses a convolution kernel, and the result of the convolution is then thresholded with &amp;lt;tt&amp;gt;thY1&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;thY2&amp;lt;/tt&amp;gt; (luma) and  &amp;lt;tt&amp;gt;thC1&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;thC2&amp;lt;/tt&amp;gt; (chroma). The thresholding happens like that (r is the result of the convolution):&lt;br /&gt;
&lt;br /&gt;
* r &amp;lt;= th1 gives 0.&lt;br /&gt;
* th1 &amp;lt; r &amp;lt;= th2 gives r.&lt;br /&gt;
* th2 &amp;lt; r gives 255.&lt;br /&gt;
&lt;br /&gt;
In order to create a binary mask, you just have to set th1=th2.&lt;br /&gt;
&lt;br /&gt;
The choice of the convolution kernel is done by &amp;lt;tt&amp;gt;type&amp;lt;/tt&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;0&amp;quot; cellspacing=&amp;quot;4&amp;quot; cellpadding=&amp;quot;8&amp;quot;&lt;br /&gt;
!width=35% align=&amp;quot;left&amp;quot; style=&amp;quot;background:#8090B0&amp;quot;| &amp;lt;tt&amp;gt;type&amp;lt;/tt&amp;gt;&lt;br /&gt;
!width=65% align=&amp;quot;left&amp;quot; style=&amp;quot;background:#8090B0&amp;quot;| Kernel&lt;br /&gt;
|-&lt;br /&gt;
|style=&amp;quot;background:lavender&amp;quot;| &amp;quot;roberts&amp;quot;&lt;br /&gt;
|style=&amp;quot;background:lavender&amp;quot;| &lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;4&amp;quot; width=&amp;quot;100px&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|width=50% align=&amp;quot;center&amp;quot;|  2 &lt;br /&gt;
|width=50% align=&amp;quot;center&amp;quot;| -1 &lt;br /&gt;
|- &lt;br /&gt;
|width=50% align=&amp;quot;center&amp;quot;| -1 &lt;br /&gt;
|width=50% align=&amp;quot;center&amp;quot;|  0&lt;br /&gt;
|}&lt;br /&gt;
|-&lt;br /&gt;
|style=&amp;quot;background:lavender&amp;quot;| &amp;quot;sobel&amp;quot; &lt;br /&gt;
|style=&amp;quot;background:lavender&amp;quot;|&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;4&amp;quot; width=&amp;quot;150px&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;|  0 &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1 &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;|  0 &lt;br /&gt;
|- &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1 &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;|  0 &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;|  1&lt;br /&gt;
|-&lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;|  0 &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;|  1 &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;|  0&lt;br /&gt;
|}&lt;br /&gt;
|-&lt;br /&gt;
|style=&amp;quot;background:lavender&amp;quot;| &amp;quot;laplace&amp;quot;&lt;br /&gt;
|style=&amp;quot;background:lavender&amp;quot;|&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;4&amp;quot; width=&amp;quot;150px&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1/8 &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1/8 &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1/8 &lt;br /&gt;
|- &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1/8 &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;|   1  &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1/8&lt;br /&gt;
|-&lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1/8 &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1/8 &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1/8&lt;br /&gt;
|}&lt;br /&gt;
|-&lt;br /&gt;
|style=&amp;quot;background:lavender&amp;quot;| &amp;quot;special&amp;quot;&lt;br /&gt;
|style=&amp;quot;background:lavender&amp;quot;|&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;4&amp;quot; width=&amp;quot;150px&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1/4 &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;|   0  &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1/4 &lt;br /&gt;
|- &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;|   0  &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;|   1  &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;|   0&lt;br /&gt;
|-&lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1/4 &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;|   0  &lt;br /&gt;
|width=33% align=&amp;quot;center&amp;quot;| -1/4&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Finally, there are also two other possible values for &amp;lt;tt&amp;gt;type&amp;lt;/tt&amp;gt; (&amp;quot;cartoon&amp;quot; and &amp;quot;line&amp;quot;), which have behaviors which are not documented here.&lt;br /&gt;
&lt;br /&gt;
Defaults are : &amp;lt;tt&amp;gt;thY1&amp;lt;/tt&amp;gt; = 0, &amp;lt;tt&amp;gt;thY2&amp;lt;/tt&amp;gt; = 20, &amp;lt;tt&amp;gt;thC1&amp;lt;/tt&amp;gt; = 0, &amp;lt;tt&amp;gt;thC2&amp;lt;/tt&amp;gt; = 20 and &amp;lt;tt&amp;gt;type&amp;lt;/tt&amp;gt; = &amp;quot;sobel&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
Back to [[MaskTools]].&lt;/div&gt;</summary>
		<author><name>Gzarkadas</name></author>	</entry>

	</feed>