Convolution3D

Sommario

author: Vlad59
versions: - 1.01 (YUY2 version)
                - beta 4 (YV12 version with temporal influence disabled)
download: http://www.avisynth.org/warpenterprises/
category: Spatio-Temporal Smoothers
requirements: 

Descrizione

Convolution3D è un filtro avisynth che applica una convoluzione 3Da tutti i pixels di un frame.

1 - Come si usa

Convolution3d (matrix=0, ythresh=3, cthresh=4, t_ythresh=3, t_cthresh=4, influence=3, debug=0)

Scelta della Matrice :
0 : matrice originale:
1 2 1   2 4 2   1 2 1
2 4 1   4 8 4   2 4 1
1 2 1   2 4 2   1 2 1
Questa matrice è utile per movie normali (non anime) perché conserva più dettagli
1 : idea di bb di una matrice di 1(grande idea)
1 1 1   1 1 1   1 1 1
1 1 1   1 1 1   1 1 1
1 1 1   1 1 1   1 1 1
Questa matrice è assai utile con le anime o con sorgenti di cattiva qualità poiché blurra leggermente di più ( rimuovendo in tal modo più rumore)

Influenza Temporale :
E' usata principalmente per velocizzare leggermente il filtro e per evitare di usare informazioni temporali quando non necessarie (scene change, fade, ...)
Per prima cosa viene stabilito un limite = Temporal Luma Threshold * Temporal influence
Per ogni 2 pixel elaborati (a causa di MMX, 2 pixel alla volta), si testa questo:
if
(Abs (Y0 - Y0[Previous frame]) +
Abs (Y0 - Y0[Next frame]) +
Abs (Y1 - Y1[Previous frame]) +
Abs (Y1 - Y1[Next frame])) > limit
then
do Spacial work (only 3*3 matrix)
Else
do Spacial and Temporal work (3*3*3 matrix)
Più bassa è la Temporal -> più veloce sarà il filtro, ma la compressibilità sarà minore
Al contrario se più alta -> più lento risulterà il filtro, ma con compressibilit maggiore
Se la temporal influence è impostata a -1 viene attivato solo il filtraggio spaziale (alta velocità).
This parameter is a float.

2 - Esempio di Parametri

Per rendere le cose più facili sono stati approntati i seguenti presets :
Convolution3d (preset="movieHQ") // Movie Hi Quality (buon DVD source)
è un alias di Convolution3D (0, 3, 4, 3, 4, 2.8, 0)
Convolution3d (preset="movieLQ") // Movie Low Quality (noisy DVD source)
è un alias di Convolution3D (0, 6, 10, 6, 8, 2.8, 0)
Convolution3d (preset="animeHQ") // Anime Hi Quality (good DVD source)
è un alias di Convolution3D (0, 6, 12, 6, 8, 2.8, 0)
Convolution3d (preset="animeLQ") // Anime Low Quality (noisy DVD source)
è un alias di Convolution3D (1, 8, 16, 8, 8, 2.8, 0)
Convolution3d (preset="animeBQ") // Anime Bad Quality (???)
è un alias di Convolution3D (1, 12, 22, 8, 8, 2.8, 0)
Convolution3d (preset="vhsBQ") // VHS capture Bad Quality (???)
è un alias di Convolution3D (0, 32, 128, 16, 64, 10, 0)

Ho testato Convolution3d con cattive catture TV nel qual caso si deve aumentare specialmente le
chroma tresholds (causando però un pò di ghosting ma la qualità generale sembra essere migliore).
Personalmente uso questi parametri :

Convolution3D (0, 32, 128, 32, 128, 10, 0)

Le thresholds di Convolution3d si prendono cura dei contorni e dei cambi di scena. Potete aumentare quella spaziale (specialmente la chroma threshold) ma fermatevi non appena vedete qualche blurring attorno i bordi (se volete qualità). Con i settings proposti non dovreste avere questo problema.
Per evitare il ghosting il valore Temporal lo si dovrebbe lasciare al di sotto di 10.
Fate particolare attenzione al threshold con la matrice 1, poché con questa il frame corrente pesa meno per cui è più facile avere ghosting.

Ulteriori informazioni sul suo funzionamento in : http://forum.doom9.org/showthread.php?s=&threadid=29829

3 - Attuali limitazioni o problemi conosciuti

4 - Credits

Thanks to
bb for the original idea and a lot of tests
iago, Koepi and TheReal for real full length movie (or capture) tests
Tom Barry, Dividee and Sh0dan for their usefull technicals informations or ideas
Ctrl-Alt-Suppr for a french tutorial
Defiler for hosting Convolution3d
all Convolution3D users

Vlad59 (babas.lucas@laposte.net)

5 - License

Copyright (c) 2002 Sébastien LUCAS. All rights reserved.
babas.lucas@laposte.net

This file is subject to the terms of the GNU General Public License as published by the Free Software Foundation. A copy of this license is included with this software distribution in the file COPYING. If you do not have a copy, you may obtain a copy by writing to the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.

This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details

$Date: 2004/10/19 21:09:19 $