GrainFactory3

From Avisynth wiki
(Difference between revisions)
Jump to: navigation, search
m (Changelog: link)
 
(6 intermediate revisions by one user not shown)
Line 1: Line 1:
{{FilterCat|External_filters|Adjustment_filters|Effects}}
+
{{FilterCat4|External_filters|Scripts|Adjustment_filters|Effects}}
{{Filter
+
{{Filter3
 
|Didée
 
|Didée
 
|3
 
|3
Line 6: Line 6:
 
|Effects
 
|Effects
 
|
 
|
* YV12
+
|6=[http://forum.doom9.org/showthread.php?t=141303 Doom9 Thread]}}
|}}
+
 
<br>
 
<br>
 
== Description ==
 
== Description ==
:Noise generator that tries to simulate the behavior of silver grain on film..
+
Noise generator that tries to simulate the behavior of silver grain on film.<br/>
 +
<br>
 +
== Requirements==
 +
* AviSynth 2.5.8 or later
 +
* Supported color formats: [[YV12]]
 +
* [[FAQ_different_types_content#How_do_I_recognize_progressive.2C_interlaced.2C_telecined.2C_hybrid_and_blended_content.3F|Progressive]] input only
 +
<br>
 +
==== Required Plugins ====
 +
* [[AddGrainC]]
 +
*[[MaskTools2]] 2.0a48+
 
<br>
 
<br>
== Requirements: ==
 
:- AviSynth 2.5.8 or later
 
:- Supported color formats: [[YV12]]
 
:- [[FAQ_different_types_content#How_do_I_recognize_progressive.2C_interlaced.2C_telecined.2C_hybrid_and_blended_content.3F|Progressive]] input only
 
  
==== Required Filters: ====
+
== [[Script variables|Syntax and Parameters]] ==
:* AddGrainC
+
:{{Template:FuncDef|GrainFactory3 (''clip'' clp, ''int'' "g1str", ''int'' "g2str", ''int'' "g3str", ''int'' "g1shrp", ''int'' "g2shrp", ''int'' "g3shrp", ''float'' "g1size", ''float'' "g2size", ''float'' "g3size", ''int'' "g1tex", ''int'' "g2tex", ''int'' "g3tex", ''int'' "temp_avg", ''int'' "ontop_grain", ''int'' "th1", ''int'' "th2", ''int'' "th3", ''int'' "th4")}}
:*[[MaskTools2]] 2.0a48+
+
 
<br>
 
<br>
 +
::'''Input:'''
  
== Syntax and Parameters ==
+
:::{{Par2|clp|clip| }}
:{{Template:FuncDef|GrainFactory3 (clip clp, int "g1str", int "g2str", int "g3str", int "g1shrp", int "g2shrp", int "g3shrp", float "g1size", float "g2size", float "g3size", int "g1tex", int "g2tex", int "g3tex", int "temp_avg", int "ontop_grain", int "th1", int "th2", int "th3", int "th4")}}
+
::::Input clip.
 
<br>
 
<br>
 
::'''Strength of grain:'''
 
::'''Strength of grain:'''
  
:::{{Par|g1str|int|13}}
+
:::{{Par2|g1str|int|13}}
 
::::Strength of grain / for dark areas.
 
::::Strength of grain / for dark areas.
 
:::::Range: 0 - ???
 
:::::Range: 0 - ???
  
:::{{Par|g2str|int|15}}
+
:::{{Par2|g2str|int|15}}
 
::::Strength of grain / for midtone areas.
 
::::Strength of grain / for midtone areas.
 
:::::Range: 0 - ???
 
:::::Range: 0 - ???
  
:::{{Par|g3str|int|25}}
+
:::{{Par2|g3str|int|25}}
 
::::Strength of grain / for bright areas.
 
::::Strength of grain / for bright areas.
 
:::::Range: 0 - ???
 
:::::Range: 0 - ???
Line 41: Line 45:
 
::'''Sharpness of grain:'''
 
::'''Sharpness of grain:'''
  
:::{{Par|g1shrp|int|60}}
+
:::{{Par2|g1shrp|int|60}}
 
::::Sharpness of grain / for dark areas (NO EFFECT when g1size=1.0 !!)
 
::::Sharpness of grain / for dark areas (NO EFFECT when g1size=1.0 !!)
 
:::::Range: 0 - 100
 
:::::Range: 0 - 100
  
:::{{Par|g2shrp|int|66}}
+
:::{{Par2|g2shrp|int|66}}
 
::::Sharpness of grain / for midtone areas (NO EFFECT when g2size=1.0 !!)
 
::::Sharpness of grain / for midtone areas (NO EFFECT when g2size=1.0 !!)
 
:::::Range: 0 - 100
 
:::::Range: 0 - 100
  
:::{{Par|g3shrp|int|80}}
+
:::{{Par2|g3shrp|int|80}}
 
::::Sharpness of grain / for bright areas (NO EFFECT when g3size=1.0 !!)
 
::::Sharpness of grain / for bright areas (NO EFFECT when g3size=1.0 !!)
 
:::::Range: 0 - 100
 
:::::Range: 0 - 100
Line 55: Line 59:
 
::'''Size of grain:'''
 
::'''Size of grain:'''
  
:::{{Par|g1size|float|1.50}}
+
:::{{Par2|g1size|float|1.50}}
 
::::Size of grain / for dark areas.
 
::::Size of grain / for dark areas.
 
:::::Range: 0.5 - 4.0
 
:::::Range: 0.5 - 4.0
  
:::{{Par|g2size|float|1.20}}
+
:::{{Par2|g2size|float|1.20}}
 
::::Size of grain / for mid-tone areas.
 
::::Size of grain / for mid-tone areas.
 
:::::Range: 0.5 - 4.0
 
:::::Range: 0.5 - 4.0
  
:::{{Par|g3size|float|0.90}}
+
:::{{Par2|g3size|float|0.90}}
 
::::Size of grain / for bright areas
 
::::Size of grain / for bright areas
 
:::::Range: 0.5 - 4.0
 
:::::Range: 0.5 - 4.0
Line 69: Line 73:
 
::'''Texture:'''
 
::'''Texture:'''
  
:::{{Par|g1tex|int|0}}
+
:::{{Par2|g1tex|int|0}}
 
::::Strength of "material texture" appearance.
 
::::Strength of "material texture" appearance.
 
:::::Range: 0 - 100
 
:::::Range: 0 - 100
  
:::{{Par|g2tex|int|0}}
+
:::{{Par2|g2tex|int|0}}
 
::::(In fact: 'bump' effect)
 
::::(In fact: 'bump' effect)
 
:::::Range: 0 - 100
 
:::::Range: 0 - 100
  
:::{{Par|g3tex|int|0}}
+
:::{{Par2|g3tex|int|0}}
 
::::For dark / midtone / bright grain.
 
::::For dark / midtone / bright grain.
 
:::::Range: 0 - 100
 
:::::Range: 0 - 100
 
<br>
 
<br>
 
::'''Temporal averaging:'''
 
::'''Temporal averaging:'''
:::{{Par|temp_avg|int|0}}
+
 
 +
:::{{Par2|temp_avg|int|0}}
 
::::Percentage of noise's temporal averaging.
 
::::Percentage of noise's temporal averaging.
 
:::::Range: 0 - 100
 
:::::Range: 0 - 100
Line 88: Line 93:
 
::'''Mixing zone:'''
 
::'''Mixing zone:'''
  
:::{{Par|th1|int|24}}
+
:::{{Par2|th1|int|24}}
 
::::Start of dark->midtone  mixing zone.
 
::::Start of dark->midtone  mixing zone.
  
:::{{Par|th2|int|56}}
+
:::{{Par2|th2|int|56}}
 
::::End  of  dark->midtone  mixing zone.
 
::::End  of  dark->midtone  mixing zone.
  
:::{{Par|th3|int|128}}
+
:::{{Par2|th3|int|128}}
 
::::Start of midtone->bright  mixing zone.
 
::::Start of midtone->bright  mixing zone.
  
:::{{Par|th4|int|160}}
+
:::{{Par2|th4|int|160}}
 
::::End  of  midtone->bright  mixing zone
 
::::End  of  midtone->bright  mixing zone
 
<br>
 
<br>
 
::'''On top grain:'''
 
::'''On top grain:'''
  
:::{{Par|ontop_grain|int|0}}
+
:::{{Par2|ontop_grain|int|0}}
 
::::additional grain to put on top of previously generated grain.
 
::::additional grain to put on top of previously generated grain.
 
:::::Range:0 - ???
 
:::::Range:0 - ???
 
<br>
 
<br>
== Examples ==
 
  
 +
== Examples ==
 
  [[AviSource]]("Blah.avi")
 
  [[AviSource]]("Blah.avi")
 
  Grainfactory3(5,7,10)
 
  Grainfactory3(5,7,10)
 
+
<br>
 
== Changelog ==
 
== Changelog ==
   Changes [http://forum.doom9.org/showthread.php?p=1190302#post1190302 2008-10-03:]
+
   Changes [http://forum.doom9.org/showpost.php?p=1191292&postcount=30 2008-10-03:]
 
     - GrainFactory3
 
     - GrainFactory3
 
       - Shorten parameters' names
 
       - Shorten parameters' names
 
       - Add "mixing zone" parameters
 
       - Add "mixing zone" parameters
 
       - Restructure parameters. Better control for dark, midtone, and bright areas.<br>
 
       - Restructure parameters. Better control for dark, midtone, and bright areas.<br>
   Changes [http://forum.doom9.org/showthread.php?p=1190302#post1190302 2008-10-01:]
+
   Changes [http://forum.doom9.org/showpost.php?p=1190302&postcount=13 2008-10-01:]
 
     - GrainFactory_MT1/MT2
 
     - GrainFactory_MT1/MT2
 
       - Interdependent version for [[MaskTools]] or [[MaskTools2]]
 
       - Interdependent version for [[MaskTools]] or [[MaskTools2]]
       - For all changes see [http://forum.doom9.org/showthread.php?p=1190302#post1190302 here]<br>
+
       - For all changes see [http://forum.doom9.org/showpost.php?p=1190302&postcount=13 here]<br>
   Changes [http://forum.doom9.org/showthread.php?p=841483#post841483 circa 2005:]
+
   Changes [http://forum.doom9.org/showpost.php?p=841483&postcount=6 circa 2005:]
 
     - GrainFactory
 
     - GrainFactory
      - Initial release
+
    - Initial release as [http://web.archive.org/web/20071021184709/http://www.neuron2.net/board/viewtopic.php?p=5622 a small "noise factory"]
  
== Links ==
+
==External Links ==
 
*[http://forum.doom9.org/showthread.php?t=141303 Doom9 Forum] - GrainFactory discussion.
 
*[http://forum.doom9.org/showthread.php?t=141303 Doom9 Forum] - GrainFactory discussion.
<br>
 
 
<br>
 
<br>
 
<br>
 
<br>
 
-----------------------------------------------
 
-----------------------------------------------
 
'''Back to [[External_filters#Effects|External Filters]] &larr;'''
 
'''Back to [[External_filters#Effects|External Filters]] &larr;'''

Latest revision as of 20:47, 18 January 2015

Abstract
Author Didée
Version 3
Download GrainFactory3.avsi
Category Effects
License
Discussion Doom9 Thread


Contents

[edit] Description

Noise generator that tries to simulate the behavior of silver grain on film.

[edit] Requirements

  • AviSynth 2.5.8 or later
  • Supported color formats: YV12
  • Progressive input only


[edit] Required Plugins


[edit] Syntax and Parameters

GrainFactory3 (clip clp, int "g1str", int "g2str", int "g3str", int "g1shrp", int "g2shrp", int "g3shrp", float "g1size", float "g2size", float "g3size", int "g1tex", int "g2tex", int "g3tex", int "temp_avg", int "ontop_grain", int "th1", int "th2", int "th3", int "th4")


Input:
clip  clp =
Input clip.


Strength of grain:
int  g1str = 13
Strength of grain / for dark areas.
Range: 0 - ???
int  g2str = 15
Strength of grain / for midtone areas.
Range: 0 - ???
int  g3str = 25
Strength of grain / for bright areas.
Range: 0 - ???


Sharpness of grain:
int  g1shrp = 60
Sharpness of grain / for dark areas (NO EFFECT when g1size=1.0 !!)
Range: 0 - 100
int  g2shrp = 66
Sharpness of grain / for midtone areas (NO EFFECT when g2size=1.0 !!)
Range: 0 - 100
int  g3shrp = 80
Sharpness of grain / for bright areas (NO EFFECT when g3size=1.0 !!)
Range: 0 - 100


Size of grain:
float  g1size = 1.50
Size of grain / for dark areas.
Range: 0.5 - 4.0
float  g2size = 1.20
Size of grain / for mid-tone areas.
Range: 0.5 - 4.0
float  g3size = 0.90
Size of grain / for bright areas
Range: 0.5 - 4.0


Texture:
int  g1tex = 0
Strength of "material texture" appearance.
Range: 0 - 100
int  g2tex = 0
(In fact: 'bump' effect)
Range: 0 - 100
int  g3tex = 0
For dark / midtone / bright grain.
Range: 0 - 100


Temporal averaging:
int  temp_avg = 0
Percentage of noise's temporal averaging.
Range: 0 - 100


Mixing zone:
int  th1 = 24
Start of dark->midtone mixing zone.
int  th2 = 56
End of dark->midtone mixing zone.
int  th3 = 128
Start of midtone->bright mixing zone.
int  th4 = 160
End of midtone->bright mixing zone


On top grain:
int  ontop_grain = 0
additional grain to put on top of previously generated grain.
Range:0 - ???


[edit] Examples

AviSource("Blah.avi")
Grainfactory3(5,7,10)


[edit] Changelog

 Changes 2008-10-03:
   - GrainFactory3
     - Shorten parameters' names
     - Add "mixing zone" parameters
     - Restructure parameters. Better control for dark, midtone, and bright areas.
Changes 2008-10-01: - GrainFactory_MT1/MT2 - Interdependent version for MaskTools or MaskTools2 - For all changes see here
Changes circa 2005: - GrainFactory - Initial release as a small "noise factory"

[edit] External Links




Back to External Filters

Personal tools