<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://www.avisynth.nl/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Fizick</id>
	<title>Avisynth wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="http://www.avisynth.nl/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Fizick"/>
	<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php/Special:Contributions/Fizick"/>
	<updated>2026-08-24T16:05:23Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.46.0</generator>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=%D0%94%D0%BE%D0%B1%D1%80%D0%BE_%D0%BF%D0%BE%D0%B6%D0%B0%D0%BB%D0%BE%D0%B2%D0%B0%D1%82%D1%8C&amp;diff=2066</id>
		<title>Добро пожаловать</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=%D0%94%D0%BE%D0%B1%D1%80%D0%BE_%D0%BF%D0%BE%D0%B6%D0%B0%D0%BB%D0%BE%D0%B2%D0%B0%D1%82%D1%8C&amp;diff=2066"/>
		<updated>2011-11-22T15:19:48Z</updated>

		<summary type="html">&lt;p&gt;Fizick: updated links&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;p style=&amp;quot;clear:both; margin-top:-3px; margin-bottom: 1em; font-variant: small-caps; text-align: center; font-size: 105%;&amp;quot;&amp;gt;&amp;lt;!-- These should be fundamental categories --&amp;gt; &lt;br /&gt;
[http://sourceforge.net/project/showfiles.php?group_id=57023 Загрузить] | [[AviSynth FAQ]] | [[Internal filters|Внутренние фильтры]] | [[External filters|Внешние фильтры]] | [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=33 Doom9 форум] | [http://sourceforge.net/projects/avisynth2/ Страница проекта] | [[Feedback|Обратная связь]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Внимание: данная страница и сайт в целом переведены на русский язык далеко не полностью (то есть вообще не переведены). Имеющаяся команда переводчиков сосредоточила имеющиеся силы на переводе офф-лайновой документации, распространяющейся с дистрибутивом AviSynth (смотри сайт [http://avisynth.org.ru www.avisynth.org.ru]).&lt;br /&gt;
&lt;br /&gt;
Однако вы можете переводить и дополнять статьи Wiki данного сайта самостоятельно (используя переведенные части офф-лайновой документации для единства стиля и терминов), добавляя к английским именам страниц окончание /ru (или создать страницы с русским именем - можно и то и другое с перенаправлением).&lt;br /&gt;
&lt;br /&gt;
== Что такое AviSynth? ==&lt;br /&gt;
&lt;br /&gt;
AviSynth - это мощное средство для пост-обработки видео. Он предоставляет методы для редактирования и обработки видео файлов. AviSynth работает как [[фрэймсервер]], обеспечивая мгновенное редактирование без необходимости временных файлов.&lt;br /&gt;
&lt;br /&gt;
AviSynth сам по себе не имеет графического интерфейса пользователя (GUI), но вместо этого зависит от системы скриптов (сценариев, команд), которая позволяет продвинутое нелинейное редактирование. В то время как на первый взгляд это может показаться утомительным и не-интуитивным, это является замечательно мощным и очень хорошим способом управлять проектами точным, согласованным и воспроизводимым образом. Поскольку текстовые скрипты являются вполне читаемыми (по-английски), проекты естественным образом само-документируются. Язык скриптов прост, но мощен, и из базовых операций могут быть построены весьма сложные фильтры, для разработки богатой палитры полезных и уникальных эффектов.&lt;br /&gt;
&lt;br /&gt;
Заинтересовались? На этом сайте вы можете узнать [[more about AviSynth|больше об AviSynth]], изучить официальное [[Internal filters|руководство по AviSynth]], и просмотреть [[AviSynth FAQ|часто задаваемые вопросы и ответы]]. Или вы можете перейти прямо на [http://sourceforge.net/project/showfiles.php?group_id=57023 страницу загрузки] на [[SourceForge]]. AviSynth - свободно распространяемая программа с открытым кодом.&lt;br /&gt;
&lt;br /&gt;
== Использование ==&lt;br /&gt;
=== Что нового в AviSynth - Начните с малого! ===&lt;br /&gt;
&lt;br /&gt;
* [[first script|Ваш первый скрипт]] - Руководство для начинающих.&lt;br /&gt;
* [[Getting started|С чего начать]] - Краткая инструкция об использовании AviSynth.&lt;br /&gt;
* [[Filter introduction|Обзор фильтров]] - Краткий обзор наиболее часто используемых фильтров AviSynth.&lt;br /&gt;
* [[Script examples|Примеры скриптов]] - Несколько примеров, используемых во всем Мире.&lt;br /&gt;
* Несколько руководств, разъясняющих использование AviSynth:&lt;br /&gt;
** [http://www.doom9.org/capture/postprocessing_avisynth.html Руководство захвата аналогового сигнала]. The AviSynth part of the capture guide is about what filters can be used to enhance the quality of the capture. It discusses things like deinterlacing, denoising, cropping and resizing and color adjustment. Which makes it really useful to learn about some of the capabilities of AviSynth in a schematic way.&lt;br /&gt;
** [http://www.animemusicvideos.org/guides/avtech/avisyntha.html Введение в AviSynth от AnimeMusicVideos.org]. Простая инструкция, описывающая деинтерлизинг, изменение размера и некоторые другие базовые действия.&lt;br /&gt;
** [http://www.animemusicvideos.org/guides/avtech/avspostqual.html Введение в фильтры AviSynth от AnimeMusicVideos.org]. Простая инструкция, описывающая фильтры сглаживания, удаления муара, повышения резкости, управления цветом и некоторых других.&lt;br /&gt;
* [[Troubleshooting|Обнаружение проблем]] в Ваших скриптах и конфигурации.&lt;br /&gt;
&lt;br /&gt;
=== Фильтры, внешние плагины, скриптовые функции и утилиты ===&lt;br /&gt;
&lt;br /&gt;
* [[Internal filters|Внутренние фильтры]] - Официальный список включенных в AviSynth фильтров с описанием, сгруппированный по категориям.&lt;br /&gt;
* [[External filters|Внешние фильтры]] - Документация некоторых скриптовых функций и плагинов для AviSynth версии 2.5x.&lt;br /&gt;
** [[External plugins old|Внешние плагины (устар.)]] - Документация по плагинам AviSynth версий v1.0x/v2.0x (устаревшие плагины, однако некоторые из них по прежнему могут быть использованы).&lt;br /&gt;
* [http://www.avisynth.org/warpenterprises/ Коллекция плагинов AviSynth] собранная WarpEnterprises.&lt;br /&gt;
* [[Shared functions|Общие функции]] - Полезные скриптовые функции.&lt;br /&gt;
* [[Utilities]] - Список GUIs, командных, групповых и других AviSynth-утилит.&lt;br /&gt;
&lt;br /&gt;
=== Синтаксис AviSynth-скрипта ===&lt;br /&gt;
&lt;br /&gt;
* [[AviSynth Syntax|Синтаксис]] - Официальная документация.&lt;br /&gt;
** [[Grammar|Грамматика]] - Грамматика скриптового языка AviSynth. Введение в скриптовый язык AviSynth.&lt;br /&gt;
** [[Script variables|Переменные]] - Как объявлять и использовать их в скриптах.&lt;br /&gt;
** [[Operators|Операторы]] - Допустимые операторы и их приоритет.&lt;br /&gt;
** [[Clip properties|Свойства клипа]] - Функции, возвращающие свойства клипа.&lt;br /&gt;
** [[Control structures|Структуры управления]] - Языковые конструкции управления потоком.&lt;br /&gt;
** [[Internal functions|Встроенные функции]] - Ready-made non-clip функции для использования в скриптах.&lt;br /&gt;
** [[User defined script functions|Определяемые пользователем скриптовые функции]] - Как их объявлять и использовать.&lt;br /&gt;
** [[Plugins|Плагины]] - Как подключать плагины AviSynth, VirtualDub, VFAPI и C-плагины, их автозагрузка и именные предпочтения.&lt;br /&gt;
** [[Runtime environment|Runtime-окружение]] - Скриптовое описание для использования отдельных кадров клипа.&lt;br /&gt;
* [[Scripting reference|Руководство по скриптам]] - Выход за пределы базовых приемов написания скриптов.&lt;br /&gt;
** [[The full AviSynth grammar|Полное руководство по грамматике]] - Полное руководство по использованию AviSynth.&lt;br /&gt;
** [[The script execution model|Модель выполнения скриптов]] - The steps behind the scenes from the script to the final video clip output. The filter graph. Scope and lifetime of variables. Evaluation of runtime scripts.&lt;br /&gt;
** [[User functions|Функции пользователя]] - Как эффективно создавать пользовательские скриптовые функции; как избегать общих ошибок; способы организации ваших функций в коллекции, создание библиотек функций и многое другое.&lt;br /&gt;
** [[Block statements|Блоковые конструкции]] - Технические идиомы для создания блоков AviSynth-скриптов.&lt;br /&gt;
** [[Arrays|Массивы]] - Использование массивов (и соответствующих операторов) для управления наборами данных в один шаг.&lt;br /&gt;
** [[Scripting at runtime|Выполнение скриптов]] - Как раскрыть все возможности runtime фильтров и создавать комплексные скрипты, которые реализуют интересные (и эффективные по быстродействию) эффекты и операции.&lt;br /&gt;
&lt;br /&gt;
=== FAQ, Руководства и дополнительные материалы ===&lt;br /&gt;
&lt;br /&gt;
* [[AviSynth FAQ]] - Ответы на часто задаваемые вопросы.&lt;br /&gt;
* [[Aspect ratios|Пропорции клипов]] - Введение в соотношение сторон клипов (DAR, PAR, SAR), как правильно измененять размер исходных клипов.&lt;br /&gt;
* [[Guides|Руководства]] - Советы по конкретным типам конвертирования и общие задачи.&lt;br /&gt;
* [[Advanced topics|Дополнительные советы]] - Рассказывают о таких вещах как ошибка Chroma Upsampling, преобразование цветов, гибридное видео, компенсация движения и т.д.&lt;br /&gt;
&lt;br /&gt;
== Разработка ==&lt;br /&gt;
&lt;br /&gt;
* Хотите [[get involved|принять участие]]?&lt;br /&gt;
* Официальный [http://sourceforge.net/projects/avisynth2/ SourceForge] проект.&lt;br /&gt;
* О том, [[compile AviSynth|как откомпилировать AviSynth]] и плагины.&lt;br /&gt;
* [[Filter SDK]] - Советы по программированию AviSynth-плагинов.&lt;br /&gt;
* [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=69 Форум разработчиков].&lt;br /&gt;
* Список [[changelist|последних изменений]].&lt;br /&gt;
* О разработке платформонезависимой [[AviSynth v3]].&lt;br /&gt;
&lt;br /&gt;
== Wiki ==&lt;br /&gt;
&lt;br /&gt;
Добро пожаловать на MediaWiki. Не стесняйтесь в наполнении данного сайта! Нам нужна Ваша помощь в наполнении данного Wiki-сайта. Ознакомьтесь с [http://meta.wikimedia.org/wiki/Помощь:Содержание руководством пользователя] по редактированию данного сайта.&lt;br /&gt;
&lt;br /&gt;
== Авторские права на документацию ==&lt;br /&gt;
&lt;br /&gt;
Права на документацию AviSynth (c) 2002-2007 принадлежат группе разработчиков AviSynth и других людей, сделавших вклад.&lt;br /&gt;
&lt;br /&gt;
С 5 августа 2007 года информация на данном сайте публикуется под лицензией [http://creativecommons.org/licenses/by-sa/3.0/deed.ru CreativeCommons Attribution-ShareAlike 3.0 License] (сокращенно &amp;quot;CC BY-SA 3.0&amp;quot;, см. [http://creativecommons.org/licenses/by-sa/3.0/legalcode полные правила лицензирования]). Неофициальный перевод на русский: http://ru.wikisource.org/wiki/Creative_Commons_Attribution-ShareAlike_3.0_Unported .&lt;br /&gt;
&lt;br /&gt;
Дополнительная информация о правах доступна [[Avisynth:Copyrights|здесь]].&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=%D0%94%D0%BE%D0%B1%D1%80%D0%BE_%D0%BF%D0%BE%D0%B6%D0%B0%D0%BB%D0%BE%D0%B2%D0%B0%D1%82%D1%8C&amp;diff=2065</id>
		<title>Добро пожаловать</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=%D0%94%D0%BE%D0%B1%D1%80%D0%BE_%D0%BF%D0%BE%D0%B6%D0%B0%D0%BB%D0%BE%D0%B2%D0%B0%D1%82%D1%8C&amp;diff=2065"/>
		<updated>2011-11-22T14:48:30Z</updated>

		<summary type="html">&lt;p&gt;Fizick: removed spam-like link&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;p style=&amp;quot;clear:both; margin-top:-3px; margin-bottom: 1em; font-variant: small-caps; text-align: center; font-size: 105%;&amp;quot;&amp;gt;&amp;lt;!-- These should be fundamental categories --&amp;gt; &lt;br /&gt;
[http://sourceforge.net/project/showfiles.php?group_id=57023 Загрузить] | [[AviSynth FAQ]] | [[Internal filters|Внутренние фильтры]] | [[External filters|Внешние фильтры]] | [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=33 Doom9 форум] | [http://sourceforge.net/projects/avisynth2/ Страница проекта] | [[Feedback|Обратная связь]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Внимание: данная страница и сайт в целом переведены на русский язык далеко не полностью (то есть вообще не переведены). Имеющаяся команда переводчиков сосредоточила имеющиеся силы на переводе офф-лайновой документации, распространяющейся с дистрибутивом AviSynth (смотри сайт [http://avisynth.org.ru www.avisynth.org.ru]).&lt;br /&gt;
&lt;br /&gt;
Однако вы можете переводить и дополнять статьи Wiki данного сайта самостоятельно (используя переведенные части офф-лайновой документации для единства стиля и терминов), добавляя к английским именам страниц окончание /ru (или создать страницы с русским именем - можно и то и другое с перенаправлением).&lt;br /&gt;
&lt;br /&gt;
== Что такое AviSynth? ==&lt;br /&gt;
&lt;br /&gt;
AviSynth - это мощное средство для пост-обработки видео. Он предоставляет методы для редактирования и обработки видео файлов. AviSynth работает как [[фрэймсервер]], обеспечивая мгновенное редактирование без необходимости временных файлов.&lt;br /&gt;
&lt;br /&gt;
AviSynth сам по себе не имеет графического интерфейса пользователя (GUI), но вместо этого зависит от системы скриптов (сценариев, команд), которая позволяет продвинутое нелинейное редактирование. В то время как на первый взгляд это может показаться утомительным и не-интуитивным, это является замечательно мощным и очень хорошим способом управлять проектами точным, согласованным и воспроизводимым образом. Поскольку текстовые скрипты являются вполне читаемыми (по-английски), проекты естественным образом само-документируются. Язык скриптов прост, но мощен, и из базовых операций могут быть построены весьма сложные фильтры, для разработки богатой палитры полезных и уникальных эффектов.&lt;br /&gt;
&lt;br /&gt;
Заинтересовались? На этом сайте вы можете узнать [[more about AviSynth|больше об AviSynth]], изучить официальное [[Internal filters|руководство по AviSynth]], и просмотреть [[AviSynth FAQ|часто задаваемые вопросы и ответы]]. Или вы можете перейти прямо на [http://sourceforge.net/project/showfiles.php?group_id=57023 страницу загрузки] на [[SourceForge]]. AviSynth - свободно распространяемая программа с открытым кодом.&lt;br /&gt;
&lt;br /&gt;
== Использование ==&lt;br /&gt;
=== Что нового в AviSynth - Начните с малого! ===&lt;br /&gt;
&lt;br /&gt;
* [[first script|Ваш первый скрипт]] - Руководство для начинающих.&lt;br /&gt;
* [[Getting started|С чего начать]] - Краткая инструкция об использовании AviSynth.&lt;br /&gt;
* [[Filter introduction|Обзор фильтров]] - Краткий обзор наиболее часто используемых фильтров AviSynth.&lt;br /&gt;
* [[Script examples|Примеры скриптов]] - Несколько примеров, используемых во всем Мире.&lt;br /&gt;
* Несколько руководств, разъясняющих использование AviSynth:&lt;br /&gt;
** [http://www.doom9.org/capture/postprocessing_avisynth.html Руководство захвата аналогового сигнала]. The AviSynth part of the capture guide is about what filters can be used to enhance the quality of the capture. It discusses things like deinterlacing, denoising, cropping and resizing and color adjustment. Which makes it really useful to learn about some of the capabilities of AviSynth in a schematic way.&lt;br /&gt;
** [http://www.animemusicvideos.org/guides/avtech/avisyntha.html Введение в AviSynth от AnimeMusicVideos.org]. Простая инструкция, описывающая деинтерлизинг, изменение размера и некоторые другие базовые действия.&lt;br /&gt;
** [http://www.animemusicvideos.org/guides/avtech/avspostqual.html Введение в фильтры AviSynth от AnimeMusicVideos.org]. Простая инструкция, описывающая фильтры сглаживания, удаления муара, повышения резкости, управления цветом и некоторых других.&lt;br /&gt;
* [[Troubleshooting|Обнаружение проблем]] в Ваших скриптах и конфигурации.&lt;br /&gt;
&lt;br /&gt;
=== Фильтры, внешние плагины, скриптовые функции и утилиты ===&lt;br /&gt;
&lt;br /&gt;
* [[Internal filters|Внутренние фильтры]] - Официальный список включенных в AviSynth фильтров с описанием, сгруппированный по категориям.&lt;br /&gt;
* [[External filters|Внешние фильтры]] - Документация некоторых скриптовых функций и плагинов для AviSynth версии 2.5x.&lt;br /&gt;
** [[External plugins old|Внешние плагины (устар.)]] - Документация по плагинам AviSynth версий v1.0x/v2.0x (устаревшие плагины, однако некоторые из них по прежнему могут быть использованы).&lt;br /&gt;
* [http://www.avisynth.org/warpenterprises/ Коллекция плагинов AviSynth] собранная WarpEnterprises.&lt;br /&gt;
* [[Shared functions|Общие функции]] - Полезные скриптовые функции.&lt;br /&gt;
* [[Utilities]] - Список GUIs, командных, групповых и других AviSynth-утилит.&lt;br /&gt;
&lt;br /&gt;
=== Синтаксис AviSynth-скрипта ===&lt;br /&gt;
&lt;br /&gt;
* [[AviSynth Syntax|Синтаксис]] - Официальная документация.&lt;br /&gt;
** [[Grammar|Грамматика]] - Грамматика скриптового языка AviSynth. Введение в скриптовый язык AviSynth.&lt;br /&gt;
** [[Script variables|Переменные]] - Как объявлять и использовать их в скриптах.&lt;br /&gt;
** [[Operators|Операторы]] - Допустимые операторы и их приоритет.&lt;br /&gt;
** [[Clip properties|Свойства клипа]] - Функции, возвращающие свойства клипа.&lt;br /&gt;
** [[Control structures|Структуры управления]] - Языковые конструкции управления потоком.&lt;br /&gt;
** [[Internal functions|Встроенные функции]] - Ready-made non-clip функции для использования в скриптах.&lt;br /&gt;
** [[User defined script functions|Определяемые пользователем скриптовые функции]] - Как их объявлять и использовать.&lt;br /&gt;
** [[Plugins|Плагины]] - Как подключать плагины AviSynth, VirtualDub, VFAPI и C-плагины, их автозагрузка и именные предпочтения.&lt;br /&gt;
** [[Runtime environment|Runtime-окружение]] - Скриптовое описание для использования отдельных кадров клипа.&lt;br /&gt;
* [[Scripting reference|Руководство по скриптам]] - Выход за пределы базовых приемов написания скриптов.&lt;br /&gt;
** [[The full AviSynth grammar|Полное руководство по грамматике]] - Полное руководство по использованию AviSynth.&lt;br /&gt;
** [[The script execution model|Модель выполнения скриптов]] - The steps behind the scenes from the script to the final video clip output. The filter graph. Scope and lifetime of variables. Evaluation of runtime scripts.&lt;br /&gt;
** [[User functions|Функции пользователя]] - Как эффективно создавать пользовательские скриптовые функции; как избегать общих ошибок; способы организации ваших функций в коллекции, создание библиотек функций и многое другое.&lt;br /&gt;
** [[Block statements|Блоковые конструкции]] - Технические идиомы для создания блоков AviSynth-скриптов.&lt;br /&gt;
** [[Arrays|Массивы]] - Использование массивов (и соответствующих операторов) для управления наборами данных в один шаг.&lt;br /&gt;
** [[Scripting at runtime|Выполнение скриптов]] - Как раскрыть все возможности runtime фильтров и создавать комплексные скрипты, которые реализуют интересные (и эффективные по быстродействию) эффекты и операции.&lt;br /&gt;
&lt;br /&gt;
=== FAQ, Руководства и дополнительные материалы ===&lt;br /&gt;
&lt;br /&gt;
* [[AviSynth FAQ]] - Ответы на часто задаваемые вопросы.&lt;br /&gt;
* [[Aspect ratios|Пропорции клипов]] - Введение в соотношение сторон клипов (DAR, PAR, SAR), как правильно измененять размер исходных клипов.&lt;br /&gt;
* [[Guides|Руководства]] - Советы по конкретным типам конвертирования и общие задачи.&lt;br /&gt;
* [[Advanced topics|Дополнительные советы]] - Рассказывают о таких вещах как ошибка Chroma Upsampling, преобразование цветов, гибридное видео, компенсация движения и т.д.&lt;br /&gt;
&lt;br /&gt;
== Разработка ==&lt;br /&gt;
&lt;br /&gt;
* Хотите [[get involved|принять участие]]?&lt;br /&gt;
* Официальный [http://sourceforge.net/projects/avisynth2/ SourceForge] проект.&lt;br /&gt;
* О том, [[compile AviSynth|как откомпилировать AviSynth]] и плагины.&lt;br /&gt;
* [[Filter SDK]] - Советы по программированию AviSynth-плагинов.&lt;br /&gt;
* [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=69 Форум разработчиков].&lt;br /&gt;
* Список [[changelist|последних изменений]].&lt;br /&gt;
* О разработке платформонезависимой [[AviSynth v3]].&lt;br /&gt;
&lt;br /&gt;
== Wiki ==&lt;br /&gt;
&lt;br /&gt;
Добро пожаловать на MediaWiki. Не стесняйтесь в наполнении данного сайта! Нам нужна Ваша помощь в наполнении данного Wiki-сайта. Ознакомьтесь с [http://meta.wikimedia.org/wiki/Помощь:Содержание руководством пользователя] по редактированию данного сайта.&lt;br /&gt;
&lt;br /&gt;
== Авторские права на документацию ==&lt;br /&gt;
&lt;br /&gt;
Права на документацию AviSynth (c) 2002-2007 принадлежат группе разработчиков AviSynth и других людей, сделавших вклад.&lt;br /&gt;
&lt;br /&gt;
С 5 августа 2007 года информация на данном сайте публикуется под лицензией [http://creativecommons.org/licenses/by-sa/3.0/ CreativeCommons Attribution-ShareAlike 3.0 License] (сокращенно &amp;quot;CC BY-SA 3.0&amp;quot;, см. [http://creativecommons.org/licenses/by-sa/3.0/legalcode полные правила лицензирования]). Перевод на русский: http://wiki.ccrussia.org/index.php?title=Attribution-ShareAlike_3.0_Unported_Commons_Deed . Дополнительная информация о правах доступна [[Avisynth:Copyrights|здесь]].&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Template:Author/Fizick&amp;diff=60</id>
		<title>Template:Author/Fizick</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Template:Author/Fizick&amp;diff=60"/>
		<updated>2009-02-10T16:23:11Z</updated>

		<summary type="html">&lt;p&gt;Fizick: nick is more famous name :)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[http://avisynth.org.ru/ Fizick (Alexander Balakhnin)]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=ReduceBy2&amp;diff=384</id>
		<title>ReduceBy2</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=ReduceBy2&amp;diff=384"/>
		<updated>2008-12-24T19:26:52Z</updated>

		<summary type="html">&lt;p&gt;Fizick: performance related compromise&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Func3Def|HorizontalReduceBy2(clip &#039;&#039;clip&#039;&#039;)|VerticalReduceBy2(clip &#039;&#039;clip&#039;&#039;)|ReduceBy2(clip &#039;&#039;clip&#039;&#039;)}}&lt;br /&gt;
&lt;br /&gt;
HorizontalReduceBy2 reduces the horizontal size of each frame by half, and VerticalReduceBy2 reduces the vertical size by half. Chain them together (in either order) to reduce the whole image by half. You can also use the shorthand ReduceBy2, which is the same as HorizontalReduceBy2.VerticalReduceBy2. &lt;br /&gt;
&lt;br /&gt;
The filter kernel used is (1/4,1/2,1/4), which is the same as in VirtualDub&#039;s &amp;quot;2:1 reduction (high quality)&amp;quot; filter. This avoids the aliasing problems that occur with a (1/2,1/2) kernel. VirtualDub&#039;s &amp;quot;resize&amp;quot; filter uses a third, fancier kernel for 2:1 reduction, but I experimented with it and found that it actually produced slightly worse-looking MPEG files--presumably because it sharpens edges slightly, and most codecs don&#039;t like sharp edges. &lt;br /&gt;
&lt;br /&gt;
If your source video is interlaced, the VerticalReduceBy2 filter will deinterlace it (by field blending) as a side-effect. If you plan to produce output video in a size like320x240, I recommend that you capture at full interlaced vertical resolution (320x480) and use VerticalReduceBy2. You will get much better-looking output. My Huffyuv utility will compress captured video about 2:1, losslessly, so you can capture 320x480 in about the same space as it used to take to capture 320x240. (If your disk has the capacity and throughput to support it, you can even capture at 640x480 and use both HorizontalReduceBy2 and VerticalReduceBy2. But this won&#039;t improve the quality as much, and if you have to go to MotionJPEG to achieve 640x480, you&#039;re probably better off with Huffyuv at 320x480.) &lt;br /&gt;
&lt;br /&gt;
Note that, it&#039;s a quick and dirty filter (performance related compromise). Unlike the standard [[resize]] filters, the ReduceBy2 filters do not preserve the position of the image center. It shifts color planes by half of pixel. In fact, ReduceBy2() is equivalent to:&lt;br /&gt;
&lt;br /&gt;
BilinearResize(Width()/2, Height()/2, 0.5, -0.5) for RGB, &lt;br /&gt;
&lt;br /&gt;
MergeChroma(BilinearResize(Width/2,Height/2,0.5,0.5),BilinearResize(Width/2,Height/2,1.0,1.0)) for YV12,&lt;br /&gt;
&lt;br /&gt;
MergeChroma(BilinearResize(Width/2,Height/2,0.5,0.5),BilinearResize(Width/2,Height/2,1.0,0.5)) for YUY2.&lt;br /&gt;
[[Category:Internal filters]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=%D0%94%D0%BE%D0%B1%D1%80%D0%BE_%D0%BF%D0%BE%D0%B6%D0%B0%D0%BB%D0%BE%D0%B2%D0%B0%D1%82%D1%8C&amp;diff=2057</id>
		<title>Добро пожаловать</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=%D0%94%D0%BE%D0%B1%D1%80%D0%BE_%D0%BF%D0%BE%D0%B6%D0%B0%D0%BB%D0%BE%D0%B2%D0%B0%D1%82%D1%8C&amp;diff=2057"/>
		<updated>2008-11-04T19:02:29Z</updated>

		<summary type="html">&lt;p&gt;Fizick: эта ссылка есть выше&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;p style=&amp;quot;clear:both; margin-top:-3px; margin-bottom: 1em; font-variant: small-caps; text-align: center; font-size: 105%;&amp;quot;&amp;gt;&amp;lt;!-- These should be fundamental categories --&amp;gt; &lt;br /&gt;
[http://sourceforge.net/project/showfiles.php?group_id=57023 Загрузить] | [[AviSynth FAQ]] | [[Internal filters|Внутренние фильтры]] | [[External filters|Внешние фильтры]] | [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=33 Doom9 формум] | [http://sourceforge.net/projects/avisynth2/ Страница проекта] | [[Feedback|Обратная связь]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Внимание: данная страница и сайт в целом переведены на русский язык далеко не полностью (то есть вообще не переведены). Имеющаяся команда переводчиков сосредоточила имеющиеся силы на переводе офф-лайновой документации, распространяющейся с дистрибутивом AviSynth (смотри сайт [http://avisynth.org.ru www.avisynth.org.ru]).&lt;br /&gt;
&lt;br /&gt;
Однако вы можете переводить и дополнять статьи Wiki данного сайта самостоятельно (используя переведенные части офф-лайновой документации для единства стиля и терминов), добавляя к английским именам страниц окончание /ru (или создать страницы с русским именем - можно и то и другое с перенаправлением).&lt;br /&gt;
&lt;br /&gt;
== Что такое AviSynth? ==&lt;br /&gt;
&lt;br /&gt;
AviSynth - это мощное средство для пост-обработки видео. Он предоставляет методы для редактирования и обработки видео файлов. AviSynth работает как [[фрэймсервер]], обеспечивая мгновенное редактирования без необходимости временных файлов.&lt;br /&gt;
&lt;br /&gt;
AviSynth сам по себе не имеет графического интерфейса пользователя (GUI), но вместо этого зависит от системы скриптов (сценариев, команд), которая позволяет продвинутое нелинейное редактирование. В то время как на первый взгляд это может показаться утомительным и не-интуитивным, это является замечательно мощным и очень хорошим способом управлять проектами точным, согласованным и воспроизводимым образом. Поскольку текстовые скрипты являются вполне читаемыми (по-английски), проекты естественным образом само-документируются. Язык скриптов прост, но мощен, и из базовых операций могут быть построены весьма сложные фильтры, для разработки богатой палитры полезных и уникальных эффектов.&lt;br /&gt;
&lt;br /&gt;
Заинтересовались? На этом сайте, вы можете читать [[more about AviSynth|больше об AviSynth]], исследовать официальное [[Internal filters|руководство по AviSynth]], и просмотреть [[AviSynth FAQ|частые вопросы и ответы]]. Или вы можете перейти прямо на [http://sourceforge.net/project/showfiles.php?group_id=57023 страницу загрузки] на [[SourceForge]]. AviSynth - свободно распространяемая программа с открытым кодом.&lt;br /&gt;
&lt;br /&gt;
== Использование ==&lt;br /&gt;
=== Что нового в AviSynth - Начните с малого! ===&lt;br /&gt;
&lt;br /&gt;
* [[first script|Ваш первый скрипт]] - Руководство для начинающих.&lt;br /&gt;
* [[Getting started|С чего начать]] - Краткая инструкция об использовании AviSynth.&lt;br /&gt;
* [[Filter introduction|Обзор фильтров]] - Краткий обзор наиболее часто используемых фильтров AviSynth.&lt;br /&gt;
* [[Script examples|Примеры скриптов]] - Несколько примеров, используемых во всем Мире.&lt;br /&gt;
* Несколько руководств, разъясняющих использование AviSynth:&lt;br /&gt;
** [http://www.doom9.org/capture/postprocessing_avisynth.html Руководство захвата аналогового сигнала]. The AviSynth part of the capture guide is about what filters can be used to enhance the quality of the capture. It discusses things like deinterlacing, denoising, cropping and resizing and color adjustment. Which makes it really useful to learn about some of the capabilities of AviSynth in a schematic way.&lt;br /&gt;
** [http://www.animemusicvideos.org/guides/avtech/avisyntha.html Введение в AviSynth от AnimeMusicVideos.org]. Простая инструкция, описывающая деинтерлизинг, изменение размера и некоторые другие базовые действия.&lt;br /&gt;
** [http://www.animemusicvideos.org/guides/avtech/avspostqual.html Введение в фильтры AviSynth от AnimeMusicVideos.org]. Простая инструкция, описывающая фильтры сглаживания, удаления муара, повышения резкости, управления цветом и некоторых других.&lt;br /&gt;
* [[Troubleshooting|Обнаружение проблем]] в Ваших скриптах и конфигурации.&lt;br /&gt;
&lt;br /&gt;
=== Фильтры, внешние плагины, скриптовые функции и утилиты ===&lt;br /&gt;
&lt;br /&gt;
* [[Internal filters|Внутренние фильтры]] - Официальный список включенных в AviSynth фильтров с описанием, сгруппированный по категориям.&lt;br /&gt;
* [[External filters|Внешние фильтры]] - Документация некоторых скриптовых функций и плагинов для AviSynth версии 2.5x.&lt;br /&gt;
** [[External plugins old|Внешние плагины (устар.)]] - Документация по плагинам AviSynth версий v1.0x/v2.0x (устаревшие плагины, однако некоторые из них по прежнему могут быть использованы).&lt;br /&gt;
* [http://www.avisynth.org/warpenterprises/ Коллекция плагинов AviSynth] собранная WarpEnterprises.&lt;br /&gt;
* [[Shared functions|Общие фукнции]] - Полезные скриптовые функции.&lt;br /&gt;
* [[Utilities]] - Список GUIs, командных, групповых и других AviSynth-утилит.&lt;br /&gt;
&lt;br /&gt;
=== Синтаксис AviSynth-скрипта ===&lt;br /&gt;
&lt;br /&gt;
* [[AviSynth Syntax|Синтаксис]] - Официальная документация.&lt;br /&gt;
** [[Grammar|Грамматика]] - Грамматика скриптового языка AviSynth. Введение в скриптовый язык AviSynth.&lt;br /&gt;
** [[Script variables|Переменные]] - Как объявлять и использовать их в скриптах.&lt;br /&gt;
** [[Operators|Операторы]] - Допустимые операторы и их приоритет.&lt;br /&gt;
** [[Clip properties|Свойства клипа]] - Функции, возвращающие свойства клипа.&lt;br /&gt;
** [[Control structures|Структуры управления]] - Языковые конструкции управления потоком.&lt;br /&gt;
** [[Internal functions|Встроенные функции]] - Ready-made non-clip функции для использования в скриптах.&lt;br /&gt;
** [[User defined script functions|Определяемые пользователем скриптовые функции]] - Как их объявлять и использовать.&lt;br /&gt;
** [[Plugins|Плагины]] - Как подключать плагины AviSynth, VirtualDub, VFAPI и C-плагины, их автозагрузка и именные предпочтения.&lt;br /&gt;
** [[Runtime environment|Runtime-окружение]] - Скриптовое описание для использования отдельных кадров клипа.&lt;br /&gt;
* [[Scripting reference|Руководство по скриптам]] - Выход за пределы базовых приемов написания скриптов.&lt;br /&gt;
** [[The full AviSynth grammar|Полное руководство по грамматике]] - Полное руководство по использованию AviSynth.&lt;br /&gt;
** [[The script execution model|Модель выполнения скриптов]] - The steps behind the scenes from the script to the final video clip output. The filter graph. Scope and lifetime of variables. Evaluation of runtime scripts.&lt;br /&gt;
** [[User functions|Функции пользователя]] - Как эффективно создавать пользовательские скриптовые функции; как избегать общих ошибок; способы организации ваших функций в коллекции, создание библиотек функций и многое другое.&lt;br /&gt;
** [[Block statements|Блоковые конструкции]] - Технические идиомы для создания блоков AviSynth-скриптов.&lt;br /&gt;
** [[Arrays|Массивы]] - Использование массивов (и соответствующих операторов) для управления наборами данных в один шаг.&lt;br /&gt;
** [[Scripting at runtime|Выполнение скриптов]] - Как раскрыть все возможности runtime фильтров и создавать комплексные скрипты, которые реализуют интересные (и эффективные по быстродействию) эффекты и операции.&lt;br /&gt;
&lt;br /&gt;
=== FAQ, Руководства и дополнительные материалы ===&lt;br /&gt;
&lt;br /&gt;
* [[AviSynth FAQ]] - Ответы на часто задаваемые вопросы.&lt;br /&gt;
* [[Aspect ratios|Пропорции клипов]] - Введение в соотношение сторон клипов (DAR, PAR, SAR), как правильно измененять размер исходных клипов.&lt;br /&gt;
* [[Guides|Руководства]] - Советы по конкретным типам конвертирования и общие задачи.&lt;br /&gt;
* [[Advanced topics|Дополнительные советы]] - Рассказывают о таких вещах как ошибка Chroma Upsampling, преобразование цветов, гибридное видео, компенсация движения и т.д.&lt;br /&gt;
&lt;br /&gt;
== Разработка ==&lt;br /&gt;
&lt;br /&gt;
* Хотите [[get involved|принять участие]]?&lt;br /&gt;
* Официальный [http://www.avisynth.org/SourceForge SourceForge] проект.&lt;br /&gt;
* О том, [[compile AviSynth|как откомпилировать AviSynth]] и плагины.&lt;br /&gt;
* [[Filter SDK]] - Советы по программированию AviSynth-плагинов.&lt;br /&gt;
* [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=69 Форум разработчиков].&lt;br /&gt;
* Список [[changelist|последних изменений]].&lt;br /&gt;
* О разработке платформонезависимой [[AviSynth v3]].&lt;br /&gt;
&lt;br /&gt;
== Wiki ==&lt;br /&gt;
&lt;br /&gt;
Добро пожаловать на MediaWiki. Не стесняйтесь в наполнении данного сайта! Нам нужна Ваша помощь в наполнении данного Wiki-сайта. Ознакомьтесь с [http://meta.wikimedia.org/wiki/Помощь:Содержание руководством пользователя] по редактированию данного сайта.&lt;br /&gt;
&lt;br /&gt;
== Авторские прова на документацию ==&lt;br /&gt;
&lt;br /&gt;
Права на документацию AviSynth (c) 2002-2007 принадлежат группе разработчиков AviSynth и других людей, сделавших вклад.&lt;br /&gt;
&lt;br /&gt;
С 5 августа 2007 года информация на данном сайте публикуется под лицензией [http://creativecommons.org/licenses/by-sa/3.0/ CreativeCommons Attribution-ShareAlike 3.0 License] (сокращенно &amp;quot;CC BY-SA 3.0&amp;quot;, см. [http://creativecommons.org/licenses/by-sa/3.0/legalcode полные правила лицензирования]). Перевод на русский: http://wiki.ccrussia.org/index.php?title=Attribution-ShareAlike_3.0_Unported_Commons_Deed . Дополнительная информация о правах доступна [[Avisynth:Copyrights|здесь]].&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=%D0%94%D0%BE%D0%B1%D1%80%D0%BE_%D0%BF%D0%BE%D0%B6%D0%B0%D0%BB%D0%BE%D0%B2%D0%B0%D1%82%D1%8C&amp;diff=2056</id>
		<title>Добро пожаловать</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=%D0%94%D0%BE%D0%B1%D1%80%D0%BE_%D0%BF%D0%BE%D0%B6%D0%B0%D0%BB%D0%BE%D0%B2%D0%B0%D1%82%D1%8C&amp;diff=2056"/>
		<updated>2008-11-04T19:00:39Z</updated>

		<summary type="html">&lt;p&gt;Fizick: russian link&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;p style=&amp;quot;clear:both; margin-top:-3px; margin-bottom: 1em; font-variant: small-caps; text-align: center; font-size: 105%;&amp;quot;&amp;gt;&amp;lt;!-- These should be fundamental categories --&amp;gt; &lt;br /&gt;
[http://sourceforge.net/project/showfiles.php?group_id=57023 Загрузить] | [[AviSynth FAQ]] | [[Internal filters|Внутренние фильтры]] | [[External filters|Внешние фильтры]] | [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=33 Doom9 формум] | [http://sourceforge.net/projects/avisynth2/ Страница проекта] | [[Feedback|Обратная связь]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Внимание: данная страница и сайт в целом переведены на русский язык далеко не полностью (то есть вообще не переведены). Имеющаяся команда переводчиков сосредоточила имеющиеся силы на переводе офф-лайновой документации, распространяющейся с дистрибутивом AviSynth (смотри сайт [http://avisynth.org.ru www.avisynth.org.ru]).&lt;br /&gt;
&lt;br /&gt;
Однако вы можете переводить и дополнять статьи Wiki данного сайта самостоятельно (используя переведенные части офф-лайновой документации для единства стиля и терминов), добавляя к английским именам страниц окончание /ru (или создать страницы с русским именем - можно и то и другое с перенаправлением).&lt;br /&gt;
&lt;br /&gt;
== Что такое AviSynth? ==&lt;br /&gt;
&lt;br /&gt;
AviSynth - это мощное средство для пост-обработки видео. Он предоставляет методы для редактирования и обработки видео файлов. AviSynth работает как [[фрэймсервер]], обеспечивая мгновенное редактирования без необходимости временных файлов.&lt;br /&gt;
&lt;br /&gt;
AviSynth сам по себе не имеет графического интерфейса пользователя (GUI), но вместо этого зависит от системы скриптов (сценариев, команд), которая позволяет продвинутое нелинейное редактирование. В то время как на первый взгляд это может показаться утомительным и не-интуитивным, это является замечательно мощным и очень хорошим способом управлять проектами точным, согласованным и воспроизводимым образом. Поскольку текстовые скрипты являются вполне читаемыми (по-английски), проекты естественным образом само-документируются. Язык скриптов прост, но мощен, и из базовых операций могут быть построены весьма сложные фильтры, для разработки богатой палитры полезных и уникальных эффектов.&lt;br /&gt;
&lt;br /&gt;
Заинтересовались? На этом сайте, вы можете читать [[more about AviSynth|больше об AviSynth]], исследовать официальное [[Internal filters|руководство по AviSynth]], и просмотреть [[AviSynth FAQ|частые вопросы и ответы]]. Или вы можете перейти прямо на [http://sourceforge.net/project/showfiles.php?group_id=57023 страницу загрузки] на [[SourceForge]]. AviSynth - свободно распространяемая программа с открытым кодом.&lt;br /&gt;
&lt;br /&gt;
== Использование ==&lt;br /&gt;
=== Что нового в AviSynth - Начните с малого! ===&lt;br /&gt;
&lt;br /&gt;
* [[first script|Ваш первый скрипт]] - Руководство для начинающих.&lt;br /&gt;
* [[Getting started|С чего начать]] - Краткая инструкция об использовании AviSynth.&lt;br /&gt;
* [[Filter introduction|Обзор фильтров]] - Краткий обзор наиболее часто используемых фильтров AviSynth.&lt;br /&gt;
* [[Script examples|Примеры скриптов]] - Несколько примеров, используемых во всем Мире.&lt;br /&gt;
* Несколько руководств, разъясняющих использование AviSynth:&lt;br /&gt;
** [http://www.doom9.org/capture/postprocessing_avisynth.html Руководство захвата аналогового сигнала]. The AviSynth part of the capture guide is about what filters can be used to enhance the quality of the capture. It discusses things like deinterlacing, denoising, cropping and resizing and color adjustment. Which makes it really useful to learn about some of the capabilities of AviSynth in a schematic way.&lt;br /&gt;
** [http://www.animemusicvideos.org/guides/avtech/avisyntha.html Введение в AviSynth от AnimeMusicVideos.org]. Простая инструкция, описывающая деинтерлизинг, изменение размера и некоторые другие базовые действия.&lt;br /&gt;
** [http://www.animemusicvideos.org/guides/avtech/avspostqual.html Введение в фильтры AviSynth от AnimeMusicVideos.org]. Простая инструкция, описывающая фильтры сглаживания, удаления муара, повышения резкости, управления цветом и некоторых других.&lt;br /&gt;
* [[Troubleshooting|Обнаружение проблем]] в Ваших скриптах и конфигурации.&lt;br /&gt;
&lt;br /&gt;
=== Фильтры, внешние плагины, скриптовые функции и утилиты ===&lt;br /&gt;
&lt;br /&gt;
* [[Internal filters|Внутренние фильтры]] - Официальный список включенных в AviSynth фильтров с описанием, сгруппированный по категориям.&lt;br /&gt;
* [[External filters|Внешние фильтры]] - Документация некоторых скриптовых функций и плагинов для AviSynth версии 2.5x.&lt;br /&gt;
** [[External plugins old|Внешние плагины (устар.)]] - Документация по плагинам AviSynth версий v1.0x/v2.0x (устаревшие плагины, однако некоторые из них по прежнему могут быть использованы).&lt;br /&gt;
* [http://www.avisynth.org/warpenterprises/ Коллекция плагинов AviSynth] собранная WarpEnterprises.&lt;br /&gt;
* [[Shared functions|Общие фукнции]] - Полезные скриптовые функции.&lt;br /&gt;
* [[Utilities]] - Список GUIs, командных, групповых и других AviSynth-утилит.&lt;br /&gt;
&lt;br /&gt;
=== Синтаксис AviSynth-скрипта ===&lt;br /&gt;
&lt;br /&gt;
* [[AviSynth Syntax|Синтаксис]] - Официальная документация.&lt;br /&gt;
** [[Grammar|Грамматика]] - Грамматика скриптового языка AviSynth. Введение в скриптовый язык AviSynth.&lt;br /&gt;
** [[Script variables|Переменные]] - Как объявлять и использовать их в скриптах.&lt;br /&gt;
** [[Operators|Операторы]] - Допустимые операторы и их приоритет.&lt;br /&gt;
** [[Clip properties|Свойства клипа]] - Функции, возвращающие свойства клипа.&lt;br /&gt;
** [[Control structures|Структуры управления]] - Языковые конструкции управления потоком.&lt;br /&gt;
** [[Internal functions|Встроенные функции]] - Ready-made non-clip функции для использования в скриптах.&lt;br /&gt;
** [[User defined script functions|Определяемые пользователем скриптовые функции]] - Как их объявлять и использовать.&lt;br /&gt;
** [[Plugins|Плагины]] - Как подключать плагины AviSynth, VirtualDub, VFAPI и C-плагины, их автозагрузка и именные предпочтения.&lt;br /&gt;
** [[Runtime environment|Runtime-окружение]] - Скриптовое описание для использования отдельных кадров клипа.&lt;br /&gt;
* [[Scripting reference|Руководство по скриптам]] - Выход за пределы базовых приемов написания скриптов.&lt;br /&gt;
** [[The full AviSynth grammar|Полное руководство по грамматике]] - Полное руководство по использованию AviSynth.&lt;br /&gt;
** [[The script execution model|Модель выполнения скриптов]] - The steps behind the scenes from the script to the final video clip output. The filter graph. Scope and lifetime of variables. Evaluation of runtime scripts.&lt;br /&gt;
** [[User functions|Функции пользователя]] - Как эффективно создавать пользовательские скриптовые функции; как избегать общих ошибок; способы организации ваших функций в коллекции, создание библиотек функций и многое другое.&lt;br /&gt;
** [[Block statements|Блоковые конструкции]] - Технические идиомы для создания блоков AviSynth-скриптов.&lt;br /&gt;
** [[Arrays|Массивы]] - Использование массивов (и соответствующих операторов) для управления наборами данных в один шаг.&lt;br /&gt;
** [[Scripting at runtime|Выполнение скриптов]] - Как раскрыть все возможности runtime фильтров и создавать комплексные скрипты, которые реализуют интересные (и эффективные по быстродействию) эффекты и операции.&lt;br /&gt;
&lt;br /&gt;
=== FAQ, Руководства и дополнительные материалы ===&lt;br /&gt;
&lt;br /&gt;
* [[AviSynth FAQ]] - Ответы на часто задаваемые вопросы.&lt;br /&gt;
* [[Aspect ratios|Пропорции клипов]] - Введение в соотношение сторон клипов (DAR, PAR, SAR), как правильно измененять размер исходных клипов.&lt;br /&gt;
* [[Guides|Руководства]] - Советы по конкретным типам конвертирования и общие задачи.&lt;br /&gt;
* [[Advanced topics|Дополнительные советы]] - Рассказывают о таких вещах как ошибка Chroma Upsampling, преобразование цветов, гибридное видео, компенсация движения и т.д.&lt;br /&gt;
&lt;br /&gt;
== Разработка ==&lt;br /&gt;
&lt;br /&gt;
* Хотите [[get involved|принять участие]]?&lt;br /&gt;
* Официальный [http://www.avisynth.org/SourceForge SourceForge] проект.&lt;br /&gt;
* О том, [[compile AviSynth|как откомпилировать AviSynth]] и плагины.&lt;br /&gt;
* [[Filter SDK]] - Советы по программированию AviSynth-плагинов.&lt;br /&gt;
* [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=69 Форум разработчиков].&lt;br /&gt;
* Список [[changelist|последних изменений]].&lt;br /&gt;
* О разработке платформонезависимой [[AviSynth v3]].&lt;br /&gt;
&lt;br /&gt;
== Wiki ==&lt;br /&gt;
&lt;br /&gt;
Добро пожаловать на MediaWiki. Не стесняйтесь в наполнении данного сайта! Нам нужна Ваша помощь в наполнении данного Wiki-сайта. Ознакомьтесь с [http://meta.wikimedia.org/wiki/Помощь:Содержание руководством пользователя] по редактированию данного сайта.&lt;br /&gt;
&lt;br /&gt;
== Авторские прова на документацию ==&lt;br /&gt;
&lt;br /&gt;
Права на документацию AviSynth (c) 2002-2007 принадлежат группе разработчиков AviSynth и других людей, сделавших вклад.&lt;br /&gt;
&lt;br /&gt;
С 5 августа 2007 года информация на данном сайте публикуется под лицензией [http://creativecommons.org/licenses/by-sa/3.0/ CreativeCommons Attribution-ShareAlike 3.0 License] (сокращенно &amp;quot;CC BY-SA 3.0&amp;quot;, см. [http://creativecommons.org/licenses/by-sa/3.0/legalcode полные правила лицензирования]). Перевод на русский: http://wiki.ccrussia.org/index.php?title=Attribution-ShareAlike_3.0_Unported_Commons_Deed . Дополнительная информация о правах доступна [[Avisynth:Copyrights|здесь]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
См. так же: [http://www.avisynth.org/warpenterprises/ Большая коллекция плагинов]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=%D0%94%D0%BE%D0%B1%D1%80%D0%BE_%D0%BF%D0%BE%D0%B6%D0%B0%D0%BB%D0%BE%D0%B2%D0%B0%D1%82%D1%8C&amp;diff=2045</id>
		<title>Добро пожаловать</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=%D0%94%D0%BE%D0%B1%D1%80%D0%BE_%D0%BF%D0%BE%D0%B6%D0%B0%D0%BB%D0%BE%D0%B2%D0%B0%D1%82%D1%8C&amp;diff=2045"/>
		<updated>2008-09-22T15:37:53Z</updated>

		<summary type="html">&lt;p&gt;Fizick: you may use offline doc&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;p style=&amp;quot;clear:both; margin-top:-3px; margin-bottom: 1em; font-variant: small-caps; text-align: center; font-size: 105%;&amp;quot;&amp;gt;&amp;lt;!-- These should be fundamental categories --&amp;gt; &lt;br /&gt;
[http://sourceforge.net/project/showfiles.php?group_id=57023 Download] | [[AviSynth FAQ]] | [[Internal filters]] | [[External filters]] - [http://www.avisynth.org/warpenterprises/ download] | [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=33 Doom9 forum] | [http://sourceforge.net/projects/avisynth2/ Project page] | [[Feedback]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Внимание: данная страница и сайт в целом переведены на русский язык далеко не полностью (то есть вообще не переведены). Имеющаяся команда переводчиков сосредоточила имеющиеся силы на переводе офф-лайновой документации, распространяющейся с дистрибутивом AviSynth (смотри сайт [http://avisynth.org.ru www.avisynth.org.ru]).&lt;br /&gt;
&lt;br /&gt;
Однако вы можете переводить и дополнять статьи Wiki данного сайта самостоятельно (используя переведенные части офф-лайновой документации для единства стиля и терминов), добавляя к английским именам страниц окончание /ru (или создать страницы с русским именем - можно и то и другое с перенаправлением).&lt;br /&gt;
&lt;br /&gt;
== Что такое AviSynth? ==&lt;br /&gt;
&lt;br /&gt;
AviSynth - это мощное средство для пост-обработки видео. Он предоставляет методы для редактирования и обработки видео файлов. AviSynth работает как [[frameserver|фреймсервер]], обеспечивая мгновенное редактирования без необходимости временных файлов.&lt;br /&gt;
&lt;br /&gt;
AviSynth сам по себе не имеет графического интерфейса пользователя (GUI), но вместо этого зависит от системы скриптов (сценариев, команд), которая позволяет продвинутое нелинейное редактирование. В то время как на первый взгляд это может показаться утомительным и не-интуитивным, это является замечательно мощным и очень хорошим способом управлять проектами точным, согласованным и воспроизводимым образом. Поскольку текстовые скрипты являются вполне читаемыми (по-английски), проекты естественным образом само-документируются. Язык скриптов прост, но мощен, и из базовых операций могут быть построены весьма сложные фильтры, для разработки богатой палитры полезных и уникальных эффектов.&lt;br /&gt;
&lt;br /&gt;
Заинтересовались? На этом сайте, вы можете читать [[more about AviSynth|больше об AviSynth]], исследовать официальное [[Internal filters|руководство по AviSynth]], и просмотреть [[AviSynth FAQ|частые вопросы и ответы]]. Или вы можете перейти прямо на [http://sourceforge.net/project/showfiles.php?group_id=57023 страницу загрузки] на [[SourceForge]]. AviSynth - свободно распространяемая программа с открытым кодом.&lt;br /&gt;
&lt;br /&gt;
== Использование ==&lt;br /&gt;
=== Что нового в AviSynth - Начните отсюда! ===&lt;br /&gt;
&lt;br /&gt;
* [[first script|Ваш первый скрипт]] - Руководство для начинающих.&lt;br /&gt;
* [[Getting started|С чего начать]] - Краткая инструкция об использовании AviSynth.&lt;br /&gt;
* [[Filter introduction|Обзор фильтров]] - Краткий обзор наиболее часто используемых фильтров AviSynth.&lt;br /&gt;
* [[Script examples|Примеры скриптов]] - Несколько примеров, используемых во всем Мире.&lt;br /&gt;
* Несколько руководств, разъясняющих использование AviSynth:&lt;br /&gt;
** [http://www.doom9.org/capture/postprocessing_avisynth.html Руководство захвата аналогового сигнала]. The AviSynth part of the capture guide is about what filters can be used to enhance the quality of the capture. It discusses things like deinterlacing, denoising, cropping and resizing and color adjustment. Which makes it really useful to learn about some of the capabilities of AviSynth in a schematic way.&lt;br /&gt;
** [http://www.animemusicvideos.org/guides/avtech/avisyntha.html Введение в AviSynth от AnimeMusicVideos.org]. Простая инструкция, описывающая деинтерлизинг, изменение размера и некоторые другие базовые действия.&lt;br /&gt;
** [http://www.animemusicvideos.org/guides/avtech/avspostqual.html Введение в фильтры AviSynth от AnimeMusicVideos.org]. Простая инструкция, описывающая фильтры сглаживания, удаления муара, повышения резкости, управления цветом и некоторых других.&lt;br /&gt;
* [[Troubleshooting|Обнаружение проблем]] в Ваших скриптах и конфигурации.&lt;br /&gt;
&lt;br /&gt;
=== Фильтры, внешние плагины, скриптовые функции и утилиты ===&lt;br /&gt;
&lt;br /&gt;
* [[Internal filters|Внутренние фильтры]] - Официальный список включенных в AviSynth фильтров с описанием, сгруппированный по категориям.&lt;br /&gt;
* [[External filters|Внешние фильтры]] - Документация некоторых скриптовых функций и плагинов для AviSynth версии 2.5x.&lt;br /&gt;
** [[External plugins old|Внешние плагины (устар.)]] - Документация по плагинам AviSynth версий v1.0x/v2.0x (устаревшие плагины, однако некоторые из них по прежнему могут быть использованы).&lt;br /&gt;
* [http://www.avisynth.org/warpenterprises/ Коллекция плагинов AviSynth] собранная WarpEnterprises.&lt;br /&gt;
* [[Shared functions|Общие фукнции]] - Полезные скриптовые функции.&lt;br /&gt;
* [[Utilities]] - Список GUIs, командных, групповых и других AviSynth-утилит.&lt;br /&gt;
&lt;br /&gt;
=== AviSynth Синтаксис ===&lt;br /&gt;
&lt;br /&gt;
* [[AviSynth Syntax|Синтаксис]] - The official reference documentation.&lt;br /&gt;
** [[Grammar|Грамматика]] - The grammar of AviSynth script language. An introduction to AviSynth scripting.&lt;br /&gt;
** [[Script variables|Переменные]] - How to declare and use them in scripts.&lt;br /&gt;
** [[Operators|Операторы]] - Available operators and relative precedence.&lt;br /&gt;
** [[Clip properties|Свойства клипа]] - Functions that return a property of a clip.&lt;br /&gt;
** [[Control structures|Структуры управления]] - Language constructs for script flow control.&lt;br /&gt;
** [[Internal functions|Встроенные функции]] - Ready-made non-clip functions to use in scripts.&lt;br /&gt;
** [[User defined script functions|Определяемые пользователем скриптовые функции]] - How to define and use them in scripts.&lt;br /&gt;
** [[Plugins|Плагины]] - How to load plugins (AviSynth, VirtualDub, VFAPI and C-plugins), autoloading and name-precedence.&lt;br /&gt;
** [[Runtime environment|Runtime-окружение]] - Scripting on a per clip frame basis.&lt;br /&gt;
* [[Scripting reference|Руководство по скриптам]] - Beyond scripting basics.&lt;br /&gt;
** [[The full AviSynth grammar|Полное руководство по грамматике]] - The AviSynth grammar revisited and explained in detail.&lt;br /&gt;
** [[The script execution model|Модель выполнения скриптов]] - The steps behind the scenes from the script to the final video clip output. The filter graph. Scope and lifetime of variables. Evaluation of runtime scripts.&lt;br /&gt;
** [[User functions|Функции пользователя]] - How to effectively write and invoke user defined script functions; common pitfalls to avoid; ways to organise your function collection and create libraries of functions, and many more.&lt;br /&gt;
** [[Block statements|Состояния блоков (?)]] - Techniques and coding idioms for creating blocks of AviSynth script statements.&lt;br /&gt;
** [[Arrays|Массивы]] - Using arrays (and array operators) for manipulating collections of data in a single step.&lt;br /&gt;
** [[Scripting at runtime|Выполнение скриптов]] - How to unravel the power of runtime filters and create complex runtime scripts that can perform interesting (and memory/speed efficient) editing/processing operations and effects.&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Main_Page/de&amp;diff=1850</id>
		<title>Main Page/de</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Main_Page/de&amp;diff=1850"/>
		<updated>2008-07-22T20:06:17Z</updated>

		<summary type="html">&lt;p&gt;Fizick: framserver/de&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;p style=&amp;quot;clear:both; margin-top:-3px; margin-bottom: 1em; font-variant: small-caps; text-align: center; font-size: 105%;&amp;quot;&amp;gt;&amp;lt;!-- These should be fundamental categories --&amp;gt; &lt;br /&gt;
[http://sourceforge.net/project/showfiles.php?group_id=57023 Download] | [[AviSynth FAQ]] | [[Internal filters|Interne Filter]] | [[External filters|Externe Filter]] - [http://www.avisynth.org/warpenterprises/ download] | [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=33 Doom9 Forum] | [http://sourceforge.net/projects/avisynth2/ Projekt Seite] | [[Feedback]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Was ist AviSynth? ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;AviSynth&#039;&#039;&#039; ist ein leistungsfähiges Programm für die Nachbearbeitung von Videos. Es bietet fast unendlich viele Wege ein Video zu schneiden und zu bearbeiten. &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;AviSynth&#039;&#039;&#039; selber enthält keine grafische Nutzeroberfläche, sondern basiert auf einem einfachen Skriptsystem, das auch erweitertes nichtlineares Bearbeiten möglich macht. AviSynth arbeitet dabei als [[FrameServer/de|FrameServer]], womit eine sofortige und sehr schnelle Bearbeitung ohne temporäre Daten möglich ist. Die Ausgabe d.h. z.B. das Betrachten des bearbeiteten Videos wird dann von herkömmlichen Programmen übernommen, die von AviSynth versorgt werden.&lt;br /&gt;
&lt;br /&gt;
Dies mag zwar auf den ersten Blick schwierig und nicht intuitiv erscheinen, kann aber bemerkenswert leistungsfähig sein und ist ein sehr guter Weg, um die eigenen Projekte überschaubar zu machen. Da Textdateien vom Menschen lesbar sind, sind die Projekte von sich aus schon dokumentiert. Und weil es eine einfache und leistungsfähige Programmiersprache nutzt, kann man aus grundlegenden Funktionen komplexe Filter entwickeln und so eine große Palette aus nützlichen und einmaligen Effekten schaffen. &lt;br /&gt;
&lt;br /&gt;
Interessiert? Hier auf dieser Internetseite kannst du [[Mehr_über_AviSynth | mehr über AviSynth]] lesen, im offiziellen [[Internal filters|Handbuch]] suchen und dir die [[AviSynth FAQ | FAQ]] angucken. Oder du springst sofort zur [http://sourceforge.net/project/showfiles.php?group_id=57023 Downloadseite] bei [[SourceForge]].&lt;br /&gt;
&lt;br /&gt;
Falls du nur begrenzte Online-Zeit hast, kannst du auch einen [http://www.avisynth.org/warpenterprises/index.html#snapshot Snapshot herunterladen] von dieser Seite (dieser wird manuell erstellt, ist also nicht immer &amp;quot;up to date&amp;quot;!).&lt;br /&gt;
&lt;br /&gt;
== Benutzung ==&lt;br /&gt;
&lt;br /&gt;
=== Alles über Skripte ===&lt;br /&gt;
&lt;br /&gt;
* [[DeinErstesSkript | Dein erstes Skript]] - eine Anleitung für Anfänger.&lt;br /&gt;
* Sortierte [[SkriptBeispiele | Beispiele von Skripten]] - wie man alles kombiniert im echten Leben.&lt;br /&gt;
* [[GesammelteFunktionen | Gesammelte Funktionen]], die man allgemein wiederverwenden kann.&lt;br /&gt;
* Die offizielle [[SkriptGrammatik | Skriptgrammatik]].&lt;br /&gt;
&lt;br /&gt;
=== Filter ===&lt;br /&gt;
 &lt;br /&gt;
* Die am [[HäufigstenGenutztenFilter | häufigsten genutzten Filter]] als Starthilfe für AviSynth.&lt;br /&gt;
* Die offizielle Liste der internen [[FilterNachKategorie | Filter nach Kategorie]] sortiert.&lt;br /&gt;
* Externe Filter (Plugins):&lt;br /&gt;
** [[Sektion 3: Filter, Plugins und Farbräume | 3rd-Party Plugins für AviSynth v1.0x/v2.0x#q3.4]] und &lt;br /&gt;
** [[Sektion 3: Filter, Plugins und Farbräume | 3rd-Party Plugins für AviSynth v2.5x#q3.5]] von einigen unserer besten Entwicklern, zusammengestellt für dein Download-Vergnügen.&lt;br /&gt;
** [http://www.avisynth.org/warpenterprises/ Avisynth Filter Kollektion], zusammengestellt von WarpEnterprises.&lt;br /&gt;
&lt;br /&gt;
=== Tipps &amp;amp; Anleitungen === &lt;br /&gt;
&lt;br /&gt;
* In der [[AviSynthFAQ Deutsch | AviSynth FAQ]] findest du Antworten auf die häufigsten Fragen.&lt;br /&gt;
* Die [[AviSynthAnleitungen | Avisynth Anleitungen]] behandeln spezielle Konvertierungen und allgemeine Aufgaben.&lt;br /&gt;
* Zusätzliche Anleitungen zur [[Fehlersuche]] in deinem Skript und in der Konfiguration.&lt;br /&gt;
* [[AnfängerTips | Tipps für Anfänger]] erleichtern einfache Aufgaben.&lt;br /&gt;
* [[FortgeschrittenenTips | Tipps für Fortgeschrittene]] für die schwierigeren Aufgaben.&lt;br /&gt;
* [[ProfiTips | Tipps für Profis]] für harte und spezielle Aufgaben.&lt;br /&gt;
* Keine Hilfe gefunden? Besuche mal das [[DoomNeunForum | Forum von Doom9]] für Hilfe und Fragen.&lt;br /&gt;
&lt;br /&gt;
== Entwicklung == &lt;br /&gt;
&lt;br /&gt;
* [[get involved|Mitmachen]] ?&lt;br /&gt;
* Besuche die offizielle [http://www.avisynth.org/SourceForge SourceForge] Projektseite. &lt;br /&gt;
* Lerne wie man AviSynth und seine Plugins [[Compile AviSynth|kompiliert]].&lt;br /&gt;
* Schau dir das AviSynth [[Filter SDK]] an für Plugin-Programmier-Tipps.&lt;br /&gt;
* Besuche das [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=69 Entwickler Forum].&lt;br /&gt;
* Siehe die aktuelle [[Changelist|Change List]] an.&lt;br /&gt;
* Über die Entwicklung von [[AviSynth v3]] (welches systemübergreifend sein wird).&lt;br /&gt;
&lt;br /&gt;
== AviSynth Wiki ==&lt;br /&gt;
&lt;br /&gt;
Willkommen zu unserem [http://www.Mediawiki.org Wiki]! &lt;br /&gt;
&lt;br /&gt;
Dies wird hoffentlich in einer großen Ansammlung an AviSynth Tipps, Skripten und einem (kurzen) Geschichtsrückblick enden. Da nichts davon geschieht, ohne dass jemand den Ball ins Rollen bringt, habe ich ein paar grundlegende Dinge zusammengestellt. Sei so frei, tauche ein und hilf mit! Hier sind einige grundlegende [http://tavi.sourceforge.net/FormatierungsRegeln Befehle], um mit Wikis zu arbeiten. Und... ja wir haben ein Problem mit Sonderzeichen wie Umlauten. Aber das wird...&lt;br /&gt;
&lt;br /&gt;
Beim Seitenlayout wurden wir inspiriert von [http://easytopicmaps.com EasyTopicMaps] (mit Erlaubnis).&lt;br /&gt;
&lt;br /&gt;
== AviSynth Dokumentations Copyright ==&lt;br /&gt;
&lt;br /&gt;
Alle Rechte vorbehalten. Copyright (c) 2002-2007 AviSynth Entwickler und Beiträger.&lt;br /&gt;
&lt;br /&gt;
Seid dem 5. August 2007 ist die folgende Dokumentation unter der [http://creativecommons.org/licenses/by-sa/3.0/ CreativeCommons Attribution-ShareAlike 3.0 Lizenz] veröffentlicht worden (abgekürzt &amp;quot;CC BY-SA 3.0&amp;quot;, sehe auch [http://creativecommons.org/licenses/by-sa/3.0/legalcode ausführliche Lizenz Bedingungen]). Weitere Informationen bekommen Sie [[Avisynth:Copyrights|hier]].&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Strona_g%C5%82%C3%B3wna&amp;diff=1898</id>
		<title>Strona główna</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Strona_g%C5%82%C3%B3wna&amp;diff=1898"/>
		<updated>2008-07-22T19:57:37Z</updated>

		<summary type="html">&lt;p&gt;Fizick: /* FAQ, przewodniki i zaawansowane zagadnienia */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;p style=&amp;quot;clear:both; margin-top:-3px; margin-bottom: 1em; font-variant: small-caps; text-align: center; font-size: 105%;&amp;quot;&amp;gt;&amp;lt;!-- These should be fundamental categories --&amp;gt; &lt;br /&gt;
[http://sourceforge.net/project/showfiles.php?group_id=57023 Pobierz] | [[FAQ AviSynth]] | [[Domyślne filtry]] | [[Dodatkowe filtry]] - [http://www.avisynth.org/warpenterprises/ pobierz] | [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=33 forum Doom9] | [http://sourceforge.net/projects/avisynth2/ Strona projektu] | [[Opinie]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Co to jest AviSynth? ==&lt;br /&gt;
&lt;br /&gt;
AviSynth (w skrócie &#039;&#039;&#039;AVS&#039;&#039;&#039;) jest potężnym narzędziem przeznaczonym do obróbki wideo. Działa jako [[serwer klatek]], zapewniając możliwość natychmiastowej edycji bez potrzeby tworzenia plików tymczasowych.&lt;br /&gt;
&lt;br /&gt;
Sam w sobie, AviSynth nie posiada interfejsu graficznego (GUI), polegając na skryptowaniu, które pozwala na zaawansowaną edycję nieliniową. Chociaż na pierwszy rzut oka może się to wydawać skomplikowane i mało intuicyjne, jest to bardzo dobra metoda zarządzania projektami w precyzyjny, spójny i łatwo powtarzalny sposób, dająca olbrzymie możliwości. Ponieważ tekstowe skrypty są przyswajalne przez ludzi, każdy projekt jest jednocześnie swoją dokumentacją. Użyty język skryptowy jest prosty, ale potężny, a z podstawowych operacji można stworzyć kompleksowe filtry, by z czasem uzyskać własny zestaw użytecznych i unikalnych efektów.&lt;br /&gt;
&lt;br /&gt;
Ciekawy? Będąc na tej stronie, możesz przeczytać [[więcej o AviSynth]], przeszukać oficjalną [[Domyślne filtry|dokumentację]], i przejrzeć [[FAQ AviSynth]]. Lub po prostu przejdź do [http://sourceforge.net/project/showfiles.php?group_id=57023 strony pobierań] na [[SourceForge/pl|SourceForge]]. AviSynth jest programem wolnym, otwartym i darmowym.&lt;br /&gt;
&lt;br /&gt;
== Użytkowanie ==&lt;br /&gt;
&lt;br /&gt;
=== Nie znasz AviSynth? Zacznij od tego ===&lt;br /&gt;
&lt;br /&gt;
* [[Pierwszy skrypt]] - przewodnik dla zupełnych nowicjuszy,&lt;br /&gt;
* [[Wprowadzenie do filtrów]] - instruktażowy przewodnik, dzięki któremu zaczniesz przygodę z AviSynth.&lt;br /&gt;
* [[Przykłady skryptów]] - pokazują, jak to wszystko wygląda naprawdę.&lt;br /&gt;
* [[Problemy]] z twoimi skryptami i konfiguracją - oraz jak sobie z nimi radzić.&lt;br /&gt;
&lt;br /&gt;
=== Filtry, dodatkowe pluginy, skryptowane funkcje oraz narzędzia ===&lt;br /&gt;
&lt;br /&gt;
* [[Domyślne filtry]] - lista i oficjalne opisy umieszczonych w AviSynth filtrów, posortowane wg. kategorii.&lt;br /&gt;
* [[Dodatkowe filtry]] - dokumentacja pluginów i skryptowanych funkcji napisanych przez użytkowników do AviSynth 2.5x.&lt;br /&gt;
* [[Dodatkowe pluginy, stare|Dodatkowe pluginy (stare)]] - dokumentacja pluginów do AviSynth 1.0x/2.0x (stare, ale niektóre wciąż używane).&lt;br /&gt;
* [http://www.avisynth.org/warpenterprises/ Kolekcja pluginów AviSynth], autorstwa WarpEnterprises.&lt;br /&gt;
* [[Targowisko funkcji]] - często używane funkcje.&lt;br /&gt;
* [[Narzędzia]] - lista graficznych, tekstowych, skryptowych i innych narzędzi związanych z AviSynth.&lt;br /&gt;
&lt;br /&gt;
=== Składnia AviSynth ===&lt;br /&gt;
&lt;br /&gt;
* [[Składnia AviSynth]] - oficjalna dokumentacja.&lt;br /&gt;
** [[Pluginy]] - jak je wczytywać (pluginy AviSynth, [http://www.virtualdub.org/ VirtualDub], VFAPI i w C), autowczytywanie i kolejność nazw.&lt;br /&gt;
** [[Zmienne skryptów]] - jak je deklarować i używać w skryptach.&lt;br /&gt;
** [[Operatory]] - dostępne operatory i relatywna kolejność.&lt;br /&gt;
** [[Funkcje użytkownika]] - jak je definiować i używać w skryptach.&lt;br /&gt;
** [[Przepływ sterowania]] - kontrola wykonywania instrukcji.&lt;br /&gt;
** [[Wbudowane funkcje]] - gotowe funkcje, do użycia w skryptach.&lt;br /&gt;
** [[Właściwości klipu]] - funkcje zwracające właściwość klipu.&lt;br /&gt;
** [[Środowisko runtime]] - skryptowanie na bazie klatek.&lt;br /&gt;
* [[Dokumentacja skryptowania]] - wykracza poza podstawy.&lt;br /&gt;
** [[Model wykonywania skryptu]] - To, co dzieje się od wczytania skryptu do uzyskania obrazu wideo, a czego ty nie widzisz. Graf filtrów. Zakres i czas działania zmiennych. Wykorzystanie skryptów runtime.&lt;br /&gt;
** [[Funkcje użytkownika]] - jak w sposób efektywny pisać i wywoływać zdefiniowane przez siebie funkcje skryptowe. Pospolite błędy, których należy unikać. Sposoby organizacji twoich funkcji, tworzenie bibliotek funkcji, i dużo więcej.&lt;br /&gt;
** [[Instrukcje blokowe]] - tworzenie bloków instrukcji w AviSynth.&lt;br /&gt;
** [[Tablice]] - używanie tablic do operowania na całych zestawach danych za jednym zamachem.&lt;br /&gt;
** [[Skryptowanie runtime]] - jak wyzwolić moc filtrów runtime i stworzyć kompleksowe skrypty, zdolne do interesujących (i efektywnych w wykorzystaniu pamięci/prędkości) operacji edycji/przetwarzania.&lt;br /&gt;
&lt;br /&gt;
=== FAQ, przewodniki i zaawansowane zagadnienia ===&lt;br /&gt;
&lt;br /&gt;
* [[FAQ AviSynth/pl]] - odpowiedzi na wiele często spotykanych pytań.&lt;br /&gt;
* [[Format obrazu]] - wprowadzenie do formatów obrazu (&#039;&#039;aspect ratio&#039;&#039; - DAR, PAR, SAR), skalowanie rozdzielczości klipu.&lt;br /&gt;
* [[Przewodniki]] - wskazówki dotyczące konkretnych rodzajów konwersji i pospolitych zadań.&lt;br /&gt;
* [[Zagadnienia zaawansowane]] - o takich rzeczach, jak: błędne próbkowanie chromy, konwersja kolorów, wideo hybrydowe, kompensacja ruchu i inne.&lt;br /&gt;
&lt;br /&gt;
== Rozwój programu ==&lt;br /&gt;
&lt;br /&gt;
* Chcesz zaoferować [[pomoc]]?&lt;br /&gt;
* Oficjalna [http://www.avisynth.org/SourceForge strona projektu na SourceForge] (nieaktualna, ale może zawierać informacje jeszcze nie przeniesione do tej wiki).&lt;br /&gt;
* Naucz się [[Kompilacja AviSynth|kompilować AviSynth]] i jego pluginy.&lt;br /&gt;
* [[AviSynth SDK/pl|SDK]] - programowanie pluginów AviSynth.&lt;br /&gt;
* [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=69 Forum developerskie AviSynth].&lt;br /&gt;
* Coraz dłuższa [[Changelist/pl|lista zmian]].&lt;br /&gt;
* Informacje o pracach nad [[AviSynth v3]] (który będzie niezależny od systemu operacyjnego).&lt;br /&gt;
&lt;br /&gt;
== Prawa autorskie ==&lt;br /&gt;
&lt;br /&gt;
Prawa do dokumentacji AviSynth są zastrzeżone.&lt;br /&gt;
Copyright (c) 2002-2007 AviSynth developers and contributors.&lt;br /&gt;
&lt;br /&gt;
Od 5 listopada 2007, niniejsza dokumentacja jest dostępna na warunkach [http://creativecommons.org/licenses/by-sa/3.0/deed.pl licencji Creative Commons Uznanie autorstwa-Na tych samych warunkach 3.0] (skracanej &amp;quot;CC BY-SA 3.0&amp;quot;), zobacz także [http://creativecommons.org/licenses/by-sa/3.0/legalcode pełne warunki]. Więcej informacji możesz znaleźć [[AviSynth:Copyrights/pl|tutaj]].&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Najcz%C4%99%C5%9Bciej_zadawane_pytania&amp;diff=1908</id>
		<title>Najczęściej zadawane pytania</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Najcz%C4%99%C5%9Bciej_zadawane_pytania&amp;diff=1908"/>
		<updated>2008-07-22T19:56:48Z</updated>

		<summary type="html">&lt;p&gt;Fizick: cancel redirection&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Informacje ogólne ==&lt;br /&gt;
&lt;br /&gt;
[[FAQ informacje ogólne|Ta strona]] zawiera pewne ogólne informacje dotyczące AviSynth. Opisuje jego historię i różne wersje krążące po internecie. Wyjaśnia, jak rozpocząć z nim pracę, jak tworzyć skrypty i używać pluginów. Omawia także niektóre z tekstowych i graficznych narzędzi obsługujących skrypty AviSynth.&lt;br /&gt;
&lt;br /&gt;
== Wczytywanie klipów (wideo, audio i pojedynczych obrazków) do AviSynth ==&lt;br /&gt;
&lt;br /&gt;
[[FAQ wczytywanie plików|Ta strona]] wyjaśnia, jak zaimportować powszechnie używane formaty multimediów do AviSynth. Mówi o tym, których z wbudowanych filtrów bądź zewnętrznych pluginów możesz do tego użyć, oraz o tym jak ich użyć. Znajdziesz tam omówienie wielu formatów i sposobów na wczytanie ich do AviSynth.&lt;br /&gt;
&lt;br /&gt;
== Odtwarzanie lub kodowanie skryptów ==&lt;br /&gt;
&lt;br /&gt;
[[FAQ serwowanie klatek|Ta strona]] opisuje &#039;&#039;frameserving&#039;&#039; - serwowanie klatek z i do AviSynth. Wyjaśnia, jak wczytywać skrypty AviSynth do wspieranych enkoderów i odtwarzaczy, oraz co zrobić, gdy skrypty nie są wspierane.&lt;br /&gt;
&lt;br /&gt;
== Pospolite komunikaty błędów ==&lt;br /&gt;
&lt;br /&gt;
[[FAQ częste błędy|Ta strona]] opisuje pewne często spotykane komunikaty błędów, oraz wyjaśnia, co zrobić by ich więcej nie spotkać.&lt;br /&gt;
&lt;br /&gt;
== Różne rodzaje materiału źródłowego ==&lt;br /&gt;
&lt;br /&gt;
[[FAQ rodzaje materiału źródłowego|Ta strona]] mówi, co należy zrobić gdy w finalnym pliku ścieżki audio i wideo nie są zsynchronizowane. Omawia wideo o zmiennym FPS (VFR). Wyjaśnia, jak rozpoznawać i pracować z obrazem progresywnym, przeplecionym, hybrydowym, poddanym telecine lub blendingowi.&lt;br /&gt;
&lt;br /&gt;
== Format kolorów YV12 i związane z nim problemy ==&lt;br /&gt;
&lt;br /&gt;
[[FAQ YV12/pl|Ta strona]] zawiera informacje o przestrzeni kolorów YV12 oraz problemach przy obróbce i kodowaniu związanych z jej używaniem.&lt;br /&gt;
&lt;br /&gt;
== Używanie w AviSynth pluginów VirtualDub ==&lt;br /&gt;
&lt;br /&gt;
[[FAQ używanie pluginów VirtualDub|Ta strona]] wyjaśnia, jak podczas pracy z AviSynth możesz użyć pluginów napisanych do programu [http://www.virtualdub.org/ VirtualDub].&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=%D0%94%D0%BE%D0%B1%D1%80%D0%BE_%D0%BF%D0%BE%D0%B6%D0%B0%D0%BB%D0%BE%D0%B2%D0%B0%D1%82%D1%8C&amp;diff=2040</id>
		<title>Добро пожаловать</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=%D0%94%D0%BE%D0%B1%D1%80%D0%BE_%D0%BF%D0%BE%D0%B6%D0%B0%D0%BB%D0%BE%D0%B2%D0%B0%D1%82%D1%8C&amp;diff=2040"/>
		<updated>2008-07-18T07:41:37Z</updated>

		<summary type="html">&lt;p&gt;Fizick: some Russian text. Wilbert, please change link to this page at mainpage&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;p style=&amp;quot;clear:both; margin-top:-3px; margin-bottom: 1em; font-variant: small-caps; text-align: center; font-size: 105%;&amp;quot;&amp;gt;&amp;lt;!-- These should be fundamental categories --&amp;gt; &lt;br /&gt;
[http://sourceforge.net/project/showfiles.php?group_id=57023 Download] | [[AviSynth FAQ]] | [[Internal filters]] | [[External filters]] - [http://www.avisynth.org/warpenterprises/ download] | [http://forum.doom9.org/forumdisplay.php?s=&amp;amp;forumid=33 Doom9 forum] | [http://sourceforge.net/projects/avisynth2/ Project page] | [[Feedback]]&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Внимание: данная страница и сайт в целом переведены на русский язык далеко не полностью (то есть вообще не переведены). Имеющаяся команда переводчиков сосредоточила имеющиеся силы на переводе офф-лайновой документации, распространяющейся с дистрибутивом AviSynth (смотри сайт [http://avisynth.org.ru www.avisynth.org.ru]).&lt;br /&gt;
&lt;br /&gt;
Однако вы можете переводить и дополнять статьи Wiki данного сайта самостоятельно, добавляя к английским именам страниц окончание /ru (или создать страницы с русским именем - можно и то и другое с перенаправлением)&lt;br /&gt;
&lt;br /&gt;
== Что такое AviSynth? ==&lt;br /&gt;
&lt;br /&gt;
AviSynth - это мощное средство для пост-обработки видео. Он предоставляет методы для редактирования и обработки видео файлов. AviSynth работает как [[frameserver|фреймсервер]], обеспечивая мгновенное редактирования без необходимости временных файлов.&lt;br /&gt;
&lt;br /&gt;
AviSynth сам по себе не имеет графического интерфейса пользователя (GUI), но вместо этого зависит от системы скриптов (сценариев, команд), которая позволяет продвинутое нелинейное редактирование. В то время как на первый взгляд это может показаться утомительным и не-интуитивным, это является замечательно мощным и очень хорошим способом управлять проектами точным, согласованным и воспроизводимым образом. Поскольку текстовые скрипты являются вполне читаемыми (по-английски), проекты естественным образом само-документируются. Язык скриптов прост, но мощен, и из базовых операций могут быть построены весьма сложные фильтры, для разработки богатой палитры полезных и уникальных эффектов.&lt;br /&gt;
&lt;br /&gt;
Заинтересовались? На этом сайте, вы можете читать [[more about AviSynth|больше об AviSynth]], исследовать официальное [[Internal filters|руководство по AviSynth]], и просмотреть [[AviSynth FAQ|частые вопросы и ответы]]. Или вы можете перейти прямо на [http://sourceforge.net/project/showfiles.php?group_id=57023 страницу загрузки] на [[SourceForge]]. AviSynth - свободно распространяемая программа с открытым кодом.&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=GreyScale&amp;diff=352</id>
		<title>GreyScale</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=GreyScale&amp;diff=352"/>
		<updated>2008-01-09T23:23:33Z</updated>

		<summary type="html">&lt;p&gt;Fizick: yv12&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:FuncDef|Greyscale(clip &#039;&#039;clip&#039;&#039; [, string &#039;&#039;matrix&#039;&#039;])}}&lt;br /&gt;
&lt;br /&gt;
Converts the input clip to greyscale (without changing the color format).&lt;br /&gt;
&lt;br /&gt;
In YCbCr based formats (YUY2, YV12), the chroma channels are set to 128. In RGB based formats, the conversion produces the luma using the coefficients given in the &#039;&#039;matrix&#039;&#039; parameter (rec601 by default, which reflects the behaviour in old AviSynth versions). This option is added in v2.56. When setting &#039;&#039;matrix&#039;&#039;=&amp;quot;rec709&amp;quot;, the clip is converted to greyscale using Rec.709 coefficients. When setting &#039;&#039;matrix&#039;&#039;=&amp;quot;Average&amp;quot; the luma is calculated as (R+G+B)/3. See [[Color conversions]] for an explanation of these coefficients.&lt;br /&gt;
&lt;br /&gt;
[[Category:Internal filters]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Filter_SDK/Getting_started_with_audio&amp;diff=827</id>
		<title>Filter SDK/Getting started with audio</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Filter_SDK/Getting_started_with_audio&amp;diff=827"/>
		<updated>2007-12-01T19:25:43Z</updated>

		<summary type="html">&lt;p&gt;Fizick: sync with offline IanB&amp;#039;s fixes&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The best filters to take a look at if you are searching for a way to get started with an audio filter is the [http://avisynth2.cvs.sourceforge.net/avisynth2/avisynth/src/audio/ internal audio filters] of AviSynth. Mainly [http://avisynth2.cvs.sourceforge.net/avisynth2/avisynth/src/audio/audio.cpp?view=markup audio.cpp] is interesting.&lt;br /&gt;
&lt;br /&gt;
Basically you override GetAudio(...) instead of GetFrame, and fill the buffer with data. A simple filter could look like this:&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Filter creation - skip if no audio:&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
 AVSValue __cdecl HalfVolume::Create(AVSValue args, void*, IScriptEnvironment* env) {&lt;br /&gt;
   if (!args[0].AsClip()-&amp;gt;GetVideoInfo().AudioChannels())&lt;br /&gt;
     return args[0];&lt;br /&gt;
&lt;br /&gt;
  return new HalfVolume(args[0].AsClip());&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Constructor:&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
 HalfVolume::HalfVolume(PClip _child)&lt;br /&gt;
     : GenericVideoFilter(ConvertAudio::Create(_child, SAMPLE_INT16 | SAMPLE_FLOAT, SAMPLE_FLOAT)) {   &lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
This is a bit tricky. It&#039;ll require you to include [http://avisynth2.cvs.sourceforge.net/avisynth2/avisynth/src/audio/convertaudio.cpp?view=markup convertaudio.cpp]. What it does is automatic sample type conversion. Basically what it does is that you tell that your filter &#039;&#039;supports&#039;&#039; SAMPLE_INT16 and SAMPLE_FLOAT, and that it &#039;&#039;prefers&#039;&#039; SAMPLE_FLOAT. If the input isn&#039;t 16 bit or float, it&#039;ll be converted to float.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;GetAudio override:&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
 void __stdcall HalfVolume::GetAudio(void* buf, __int64 start, __int64 count, IScriptEnvironment* env) {&lt;br /&gt;
   child-&amp;gt;GetAudio(buf, start, count, env);&lt;br /&gt;
   int channels = vi.AudioChannels();&lt;br /&gt;
 &lt;br /&gt;
   if (vi.SampleType() == SAMPLE_INT16) {&lt;br /&gt;
     short* samples = (short*)buf;&lt;br /&gt;
     for (int i=0; i&amp;lt;count; i++) {&lt;br /&gt;
       for(int j=0;j&amp;lt;channels;j++) {&lt;br /&gt;
          samples[i*channels+j] /= 2;&lt;br /&gt;
       }&lt;br /&gt;
     }&lt;br /&gt;
   } else if (vi.SampleType() == SAMPLE_FLOAT) {&lt;br /&gt;
     SFLOAT* samples = (SFLOAT*)buf;&lt;br /&gt;
     for (int i=0; i&amp;lt;count; i++) {&lt;br /&gt;
       for(int j=0;j&amp;lt;channels;j++) {&lt;br /&gt;
          samples[i*channels+j] /= 2.0f;&lt;br /&gt;
       }&lt;br /&gt;
     }&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
Implementation of a half volume filter. Very explicit, so it isn&#039;t going to be the fastest possible, but it should serve the purpose. Furthermore have a look [http://forum.doom9.org/showthread.php?s=&amp;amp;threadid=72760&amp;amp;highlight=ConvertAudio here] and look also at [http://avisynth2.cvs.sourceforge.net/avisynth2/avisynth/src/audio/audio.cpp?view=markup audio.cpp] for a bunch of more advanced stuff. A lot of technical details are also to be found in AviSynth [[Filter_SDK/Two-Five_Audio|Two-Five Audio]].&lt;br /&gt;
&lt;br /&gt;
Back to [[Filter_SDK|Filter SDK]].&lt;br /&gt;
&lt;br /&gt;
[[Category:FilterSDK]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Filter_SDK&amp;diff=857</id>
		<title>Filter SDK</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Filter_SDK&amp;diff=857"/>
		<updated>2007-11-25T11:11:22Z</updated>

		<summary type="html">&lt;p&gt;Fizick: added non-clip&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;AviSynth external Filter SDK is a package for developers to create your own filters (plugins) for AviSynth.&lt;br /&gt;
&lt;br /&gt;
The package consists of:&lt;br /&gt;
&lt;br /&gt;
* this documentation text files (in HTML or Wiki format);&lt;br /&gt;
* the header file &#039;avisynth.h&#039; (recent version) with all declarations to include in plugin source code;&lt;br /&gt;
* SimpleSample plugin source codes;&lt;br /&gt;
* may be some extra files in &#039;Extra&#039; folder.&lt;br /&gt;
&lt;br /&gt;
You must have some [[Filter_SDK/SDK_necessaries|necessary software]].&lt;br /&gt;
&lt;br /&gt;
[[Filter_SDK/Ben_docs|Ben&#039;s AviSynth Docs]] is the documentation written for AviSynth 1.0 by Ben Rudiak-Gould, in its original form.&lt;br /&gt;
&lt;br /&gt;
See more about the modifications for AviSynth 2.5 in the [[Filter_SDK/Two-Five_SDK|AviSynth Two-Five SDK]].&lt;br /&gt;
&lt;br /&gt;
Also, [[Filter_SDK/Simple_sample|Simple sample]] has some very simple examples covering development of a filter that does virtually nothing through to one that draws a variable sized square, in the middle of the screen, in all [[Color_spaces|Color spaces]].&lt;br /&gt;
&lt;br /&gt;
One thing not covered in [[Filter_SDK/Simple_sample|Simple sample]], is how to [[Filter_SDK/Change_frame_size|change frame size]] in a filter. Also have a look at [[Filter_SDK/Getting_started_with_audio|Getting started with Audio]].&lt;br /&gt;
&lt;br /&gt;
See [[Filter_SDK/Non-clip_sample|Non-clip sample]] how to create runtime AviSynth functions.&lt;br /&gt;
&lt;br /&gt;
There are several different Colorspaces in AviSynth. See more information about [[Color_spaces|Color spaces]] and [[Filter_SDK/Working_with_images|Working with Images]].&lt;br /&gt;
&lt;br /&gt;
Read more about the [[Filter_SDK/Internal_functions|Internal Functions]] in AviSynth.&lt;br /&gt;
&lt;br /&gt;
You can also browse various topic on [[Filter_SDK/Assembler_optimizing|Assembler Optimizing]].&lt;br /&gt;
&lt;br /&gt;
Once you&#039;ve got the basics down on AVS development (Ben&#039;s text is quite good), the [http://virtualdub.org/filtersdk SDK] for [[VirtualDub]] is also a good read.  Good news is you won&#039;t have to worry about writing [http://function-pointer.org function pointers] and [http://www.charlespetzold.com/pw5/index.html raw Win32]; meanwhile, Avery knows his stuff when it comes to video &amp;amp; CPU optimization techniques, so you better pay attention.&lt;br /&gt;
&lt;br /&gt;
Some video related ebooks (PDF) can be downloaded freely from [http://www.snellwilcox.com/reference.html Snell &amp;amp; Wilcox].&lt;br /&gt;
&lt;br /&gt;
Please read AviSynth [[Filter_SDK/SDK_history|SDK History]].&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
 &lt;br /&gt;
Note: Avisynth Filter SDK parts are under specific [[Filter_SDK/SDK_license|SDK license terms]].&lt;br /&gt;
&lt;br /&gt;
[[Category:FilterSDK]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Filter_SDK/Data_alignment&amp;diff=837</id>
		<title>Filter SDK/Data alignment</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Filter_SDK/Data_alignment&amp;diff=837"/>
		<updated>2007-09-27T17:21:19Z</updated>

		<summary type="html">&lt;p&gt;Fizick: Undo revision 3771 by Special:Contributions/195.55.130.44 (User talk:195.55.130.44)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;(Until something more AviSynth related can be written this is from the [[Filter_SDK/AMD_optimization_guide|AMD Optimization Guide]])&lt;br /&gt;
&lt;br /&gt;
== Memory alignment ==&lt;br /&gt;
&lt;br /&gt;
In general, avoid misaligned data references. All data whose size is a power of two is considered aligned if it is naturally aligned. For example:&lt;br /&gt;
&lt;br /&gt;
* Word accesses are aligned if they access an address divisible by two.&lt;br /&gt;
* Doubleword accesses are aligned if they access an address divisible by four.&lt;br /&gt;
* Quadword accesses are aligned if they access an address divisible by eight.&lt;br /&gt;
* TBYTE accesses are aligned if they access an address divisible by eight.&lt;br /&gt;
&lt;br /&gt;
In AviSynth each frame is most of the time aligned to an address divideable by 16. The exception for this rule is when crop() has been used.  Furthermore each line is also most of the time aligned to an address divideable by 16 (or 8 for planar chroma).&lt;br /&gt;
&lt;br /&gt;
== Store to Load Forwarding ==&lt;br /&gt;
&lt;br /&gt;
Whenever some data is written to memory it is put in the cache. It is however possible for the processor to access this data quite fast after it has been written.  This is called Store To Load forwarding.&lt;br /&gt;
&lt;br /&gt;
Avoid memory-size mismatches when different instructions operate on the same data. When an instruction stores and another instruction reloads the same data, keep their operands aligned and keep the loads/stores of each operand the same size. &lt;br /&gt;
&lt;br /&gt;
The following code examples result in a store-to-load-forwarding (STLF) stall:&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Example (avoid):&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
 MOV [FOO], EAX&lt;br /&gt;
 MOV [FOO+4], EDX&lt;br /&gt;
 ...&lt;br /&gt;
 MOVQ MM0, [FOO]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Example (preferred):&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
 MOV [FOO], EAX&lt;br /&gt;
 MOV [FOO+4], EDX&lt;br /&gt;
 ...&lt;br /&gt;
 MOVD MM0, [FOO]&lt;br /&gt;
 PUNPCKLDQ MM0, [FOO+4]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Example (avoid):&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
 MOVQ [foo], MM0&lt;br /&gt;
 ...&lt;br /&gt;
 MOV EAX, [foo]&lt;br /&gt;
 MOV EDX, [foo+4]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Example (preferred):&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
 MOVD [foo], MM0&lt;br /&gt;
 PSWAPD MM0, MM0&lt;br /&gt;
 MOVD [foo+4], MM0&lt;br /&gt;
 PSWAPD MM0, MM0&lt;br /&gt;
 ...&lt;br /&gt;
 MOV EAX, [foo]&lt;br /&gt;
 MOV EDX, [foo+4]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
Back to [[Filter_SDK/Assembler_optimizing|Assembler Optimizing]].&lt;br /&gt;
&lt;br /&gt;
[[Category:FilterSDK]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=SelectOdd&amp;diff=464</id>
		<title>SelectOdd</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=SelectOdd&amp;diff=464"/>
		<updated>2007-09-27T17:20:51Z</updated>

		<summary type="html">&lt;p&gt;Fizick: Undo revision 3772 by Special:Contributions/222.240.208.14 (User talk:222.240.208.14)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Select]] [[Category:Internal filters]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=ISSE&amp;diff=799</id>
		<title>ISSE</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=ISSE&amp;diff=799"/>
		<updated>2007-09-27T17:17:09Z</updated>

		<summary type="html">&lt;p&gt;Fizick: Undo revision 3781 by Special:Contributions/74.231.24.2 (User talk:74.231.24.2)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Integer SSE is a set of instructions found in most modern processors. Integer SSE is an extension of [[MMX]]. Actually, Integer SSE is a &#039;&#039;subset&#039;&#039; of the [[SSE]] command set, mostly used for video processing. These instructions are also present in AMD Athlon (all versions), AMD Duron (all versions).&lt;br /&gt;
&lt;br /&gt;
Integer SSE instructions:&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;MASKMOVQ&#039;&#039;&#039; &#039;&#039;mmreg1, mmreg2&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;MOVNTQ&#039;&#039;&#039; &#039;&#039;mem64, mmreg&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PAVGB&#039;&#039;&#039; &#039;&#039;mmreg1, mmreg2&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PAVGB&#039;&#039;&#039; &#039;&#039;mmreg, mem64&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PAVGW&#039;&#039;&#039; &#039;&#039;mmreg1, mmreg2&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PAVGW&#039;&#039;&#039; &#039;&#039;mmreg, mem64&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PEXTRW&#039;&#039;&#039; &#039;&#039;reg32, mmreg, imm8&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PINSRW&#039;&#039;&#039; &#039;&#039;mmreg, reg32, imm8&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PINSRW&#039;&#039;&#039; &#039;&#039;mmreg, mem16, imm8&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PMAXSW&#039;&#039;&#039; &#039;&#039;mmreg1, mmreg2&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PMAXSW&#039;&#039;&#039; &#039;&#039;mmreg, mem64&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PMAXUB&#039;&#039;&#039; &#039;&#039;mmreg1, mmreg2&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PMAXUB&#039;&#039;&#039; &#039;&#039;mmreg, mem64&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PMINSW&#039;&#039;&#039; &#039;&#039;mmreg1, mmreg2&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PMINSW&#039;&#039;&#039; &#039;&#039;mmreg, mem64&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PMINUB&#039;&#039;&#039; &#039;&#039;mmreg1, mmreg2&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PMINUB&#039;&#039;&#039; &#039;&#039;mmreg, mem64&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PMOVMSKB&#039;&#039;&#039; &#039;&#039;reg32, mmreg&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PMULHUW&#039;&#039;&#039; &#039;&#039;mmreg1, mmreg2&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PMULHUW&#039;&#039;&#039; &#039;&#039;mmreg, mem64&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PSADBW&#039;&#039;&#039; &#039;&#039;mmreg1, mmreg2&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PSADBW&#039;&#039;&#039; &#039;&#039;mmreg, mem64&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PSHUFW&#039;&#039;&#039; &#039;&#039;mmreg1, mmreg2, imm8&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PSHUFW&#039;&#039;&#039; &#039;&#039;mmreg, mem64, imm8&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PREFETCHNTA&#039;&#039;&#039; &#039;&#039;mem8&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PREFETCHT0&#039;&#039;&#039; &#039;&#039;mem8&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PREFETCHT1&#039;&#039;&#039; &#039;&#039;mem8&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;PREFETCHT2&#039;&#039;&#039; &#039;&#039;mem8&#039;&#039;&lt;br /&gt;
:&#039;&#039;&#039;SFENCE&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Related links:&lt;br /&gt;
* [[Filter_SDK/Assembler_optimizing|Filter SDK: Assembler optimizing]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Glossary]]&lt;br /&gt;
[[Category:FilterSDK]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=SelectEvery&amp;diff=486</id>
		<title>SelectEvery</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=SelectEvery&amp;diff=486"/>
		<updated>2007-09-27T17:16:51Z</updated>

		<summary type="html">&lt;p&gt;Fizick: Undo revision 3782 by Special:Contributions/217.169.44.14 (User talk:217.169.44.14)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Select]] [[Category:Internal filters]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Filter_SDK/Simple_sample_1.4&amp;diff=817</id>
		<title>Filter SDK/Simple sample 1.4</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Filter_SDK/Simple_sample_1.4&amp;diff=817"/>
		<updated>2007-09-27T17:16:32Z</updated>

		<summary type="html">&lt;p&gt;Fizick: Undo revision 3783 by Special:Contributions/195.55.130.44 (User talk:195.55.130.44)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;SimpleSample 1.4:&lt;br /&gt;
&lt;br /&gt;
 /*&lt;br /&gt;
 	SimpleSample plugin for Avisynth -- a simple sample&lt;br /&gt;
 &lt;br /&gt;
 	Copyright (C) 2002-2003 Simon Walters, All Rights Reserved&lt;br /&gt;
 &lt;br /&gt;
 	This program is free software; you can redistribute it and/or modify&lt;br /&gt;
 	it under the terms of the GNU General Public License as published by&lt;br /&gt;
 	the Free Software Foundation.&lt;br /&gt;
 &lt;br /&gt;
 	This program is distributed in the hope that it will be useful,&lt;br /&gt;
 	but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
 	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
 	GNU General Public License for more details.&lt;br /&gt;
 &lt;br /&gt;
 	You should have received a copy of the GNU General Public License&lt;br /&gt;
 	along with this program; if not, write to the Free Software&lt;br /&gt;
 	Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.&lt;br /&gt;
 &lt;br /&gt;
 	The author can be contacted at:&lt;br /&gt;
 	Simon Walters&lt;br /&gt;
 	siwalters@hotmail.com&lt;br /&gt;
 &lt;br /&gt;
 	V1.0 - 1st release.&lt;br /&gt;
 	V1.0a - Revised version to put colourspace checking in the right place.&lt;br /&gt;
   V1.0b - Added detailed comments.  // sh0dan&lt;br /&gt;
 	V1.1 - Added sh0dan&#039;s planar (YV12) code&lt;br /&gt;
 	V1.2 - Revert to RGB24 colourspace only to show simple pixel manipulation;&lt;br /&gt;
 	V1.3 - add in a parameter to vary the size of the square.&lt;br /&gt;
 	V1.4 - Add in RGB32 colourspace code&lt;br /&gt;
 &lt;br /&gt;
 */&lt;br /&gt;
 //following 2 includes needed&lt;br /&gt;
 #include &amp;quot;windows.h&amp;quot;&lt;br /&gt;
 #include &amp;quot;avisynth.h&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 /****************************&lt;br /&gt;
  * The following is the header definitions.&lt;br /&gt;
  * For larger projects, move this into a .h file&lt;br /&gt;
  * that can be included.&lt;br /&gt;
  ****************************/&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 class SimpleSample : public GenericVideoFilter {   &lt;br /&gt;
   // SimpleSample defines the name of your filter class. &lt;br /&gt;
   // This name is only used internally, and does not affect the name of your filter or similar.&lt;br /&gt;
   // This filter extends GenericVideoFilter, which incorporates basic functionality.&lt;br /&gt;
   // All functions present in the filter must also be present here.&lt;br /&gt;
 	int SquareSize;&lt;br /&gt;
 &lt;br /&gt;
 public:&lt;br /&gt;
   // This defines that these functions are present in your class.&lt;br /&gt;
   // These functions must be that same as those actually implemented.&lt;br /&gt;
   // Since the functions are &amp;quot;public&amp;quot; they are accessible to other classes.&lt;br /&gt;
   // Otherwise they can only be called from functions within the class itself.&lt;br /&gt;
 &lt;br /&gt;
 	SimpleSample(PClip _child,	int _SquareSize, IScriptEnvironment* env);&lt;br /&gt;
   // This is the constructor. It does not return any value, and is always used, &lt;br /&gt;
   //  when an instance of the class is created.&lt;br /&gt;
   // Since there is no code in this, this is the definition.&lt;br /&gt;
 &lt;br /&gt;
   ~SimpleSample();&lt;br /&gt;
   // The is the destructor definition. This is called when the filter is destroyed.&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 	PVideoFrame __stdcall GetFrame(int n, IScriptEnvironment* env);&lt;br /&gt;
   // This is the function that AviSynth calls to get a given frame.&lt;br /&gt;
   // So when this functions gets called, the filter is supposed to return frame n.&lt;br /&gt;
 };&lt;br /&gt;
 &lt;br /&gt;
 /***************************&lt;br /&gt;
  * The following is the implementation &lt;br /&gt;
  * of the defined functions.&lt;br /&gt;
  ***************************/&lt;br /&gt;
 &lt;br /&gt;
 //Here is the acutal constructor code used&lt;br /&gt;
 SimpleSample::SimpleSample(PClip _child, int _SquareSize, IScriptEnvironment* env) :&lt;br /&gt;
 	GenericVideoFilter(_child), SquareSize(_SquareSize) {&lt;br /&gt;
   // This is the implementation of the constructor.&lt;br /&gt;
   // The child clip (source clip) is inherited by the GenericVideoFilter,&lt;br /&gt;
   //  where the following variables gets defined:&lt;br /&gt;
   //   PClip child;   // Contains the source clip.&lt;br /&gt;
   //   VideoInfo vi;  // Contains videoinfo on the source clip.&lt;br /&gt;
 	if (!vi.IsRGB()) // is input not RGB (24 or 32) &lt;br /&gt;
 		env-&amp;gt;ThrowError(&amp;quot;SimpleSample: input to filter must be in an RGB colourspace&amp;quot;);&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 // This is where any actual destructor code used goes&lt;br /&gt;
 SimpleSample::~SimpleSample() {&lt;br /&gt;
   // This is where you can deallocate any memory you might have used.&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 PVideoFrame __stdcall SimpleSample::GetFrame(int n, IScriptEnvironment* env) {&lt;br /&gt;
 // This is the implementation of the GetFrame function.&lt;br /&gt;
 // See the header definition for further info.&lt;br /&gt;
 &lt;br /&gt;
 	PVideoFrame src = child-&amp;gt;GetFrame(n, env);&lt;br /&gt;
    // Request frame &#039;n&#039; from the child (source) clip.&lt;br /&gt;
 	PVideoFrame dst = env-&amp;gt;NewVideoFrame(vi);&lt;br /&gt;
    // Construct a frame based on the information of the current frame&lt;br /&gt;
    // contained in the &amp;quot;vi&amp;quot; struct.&lt;br /&gt;
 	&lt;br /&gt;
 	const unsigned char* srcp = src-&amp;gt;GetReadPtr();&lt;br /&gt;
   // Request a Read pointer from the source frame.&lt;br /&gt;
   // This will return the position of the upperleft pixel in YUY2 images,&lt;br /&gt;
   // and return the lower-left pixel in RGB.&lt;br /&gt;
   // RGB images are stored upside-down in memory. &lt;br /&gt;
   // You should still process images from line 0 to height.&lt;br /&gt;
 &lt;br /&gt;
 	unsigned char* dstp = dst-&amp;gt;GetWritePtr();&lt;br /&gt;
 	// Request a Write pointer from the newly created destination image.&lt;br /&gt;
   // You can request a writepointer to images that have just been&lt;br /&gt;
   // created by NewVideoFrame. If you recieve a frame from PClip-&amp;gt;GetFrame(...)&lt;br /&gt;
   // you must call env-&amp;gt;MakeWritable(&amp;amp;frame) be recieve a valid write pointer.&lt;br /&gt;
 	&lt;br /&gt;
 	const int dst_pitch = dst-&amp;gt;GetPitch();&lt;br /&gt;
   // Requests pitch (length of a line) of the destination image.&lt;br /&gt;
   // For more information on pitch see: http://www.avisynth.org/index.php?page=WorkingWithImages&lt;br /&gt;
 	// (short version - pitch is always equal to or greater than width to allow for seriously fast assembly code)&lt;br /&gt;
 &lt;br /&gt;
 	const int dst_width = dst-&amp;gt;GetRowSize();&lt;br /&gt;
   // Requests rowsize (number of used bytes in a line.&lt;br /&gt;
   // See the link above for more information.&lt;br /&gt;
 &lt;br /&gt;
 	const int dst_height = dst-&amp;gt;GetHeight();&lt;br /&gt;
   // Requests the height of the destination image.&lt;br /&gt;
 &lt;br /&gt;
 	const int src_pitch = src-&amp;gt;GetPitch();&lt;br /&gt;
 	const int src_width = src-&amp;gt;GetRowSize();&lt;br /&gt;
 	const int src_height = src-&amp;gt;GetHeight();&lt;br /&gt;
 	&lt;br /&gt;
 	int w, h;&lt;br /&gt;
 &lt;br /&gt;
 	// This version of SimpleSample is intended to show some simple pixel manipulation.&lt;br /&gt;
 	// It is designed purely for clarity and not as good or clever code :-)&lt;br /&gt;
 &lt;br /&gt;
 	&lt;br /&gt;
 &lt;br /&gt;
 	if (vi.IsRGB24()) {&lt;br /&gt;
 		// The code just deals with RGB24 colourspace where each pixel is represented by&lt;br /&gt;
 		// 3 bytes, Blue, Green and Red.&lt;br /&gt;
 		// Although this colourspace is the easiest to understand, it is very rarely used because&lt;br /&gt;
 		// a 3 byte sequence (24bits) cannot be processed easily using normal 32 bit registers.&lt;br /&gt;
 		&lt;br /&gt;
 		for (h=0; h &amp;lt; src_height;h++) {       // Loop from bottom line to top line.&lt;br /&gt;
 			for (w = 0; w &amp;lt; src_width; w+=3) {   // Loop from left side of the image to the right side 1 pixel (3 bytes) at a time&lt;br /&gt;
 				// stepping 3 bytes (a pixel width in RGB24 space)&lt;br /&gt;
 				&lt;br /&gt;
 				*(dstp + w) = *(srcp + w);					// Copy each Blue byte from source to destination.&lt;br /&gt;
 				*(dstp + w + 1) = *(srcp + w + 1);     // Copy Green.&lt;br /&gt;
 				*(dstp + w + 2) = *(srcp + w + 2);		// Copy Red&lt;br /&gt;
 			}															&lt;br /&gt;
 			&lt;br /&gt;
 			srcp = srcp + src_pitch; // Add the pitch (note use of pitch and not width) of one line (in bytes) to the source pointer&lt;br /&gt;
 			dstp = dstp + dst_pitch; // Add the pitch to the destination pointer.&lt;br /&gt;
 		}&lt;br /&gt;
 		// end copy src to dst&lt;br /&gt;
 		&lt;br /&gt;
 		//Now draw a white square in the middle of the frame&lt;br /&gt;
 		// Normally you&#039;d do this code within the loop above but here it is in a separate loop for clarity;&lt;br /&gt;
 		&lt;br /&gt;
 		dstp = dst-&amp;gt;GetWritePtr();  // reset the destination pointer to the bottom, left pixel. (RGB colourspaces only)&lt;br /&gt;
 		dstp = dstp + (dst_height/2 - SquareSize/2)*dst_pitch;  // move pointer to SquareSize/2 lines from the middle of the frame;&lt;br /&gt;
 		for (h=0; h &amp;lt; SquareSize;h++) { // only scan 100 lines &lt;br /&gt;
 			for (w = dst_width/2 - SquareSize*3/2; w &amp;lt; dst_width/2 + SquareSize*3/2; w+=3) { // only scans the middle SquareSize pixels of a line &lt;br /&gt;
 				*(dstp + w) = 255;		// Set Blue to maximum value.&lt;br /&gt;
 				*(dstp + w + 1) = 255;     // and Green.&lt;br /&gt;
 				*(dstp + w + 2) = 255;		// and Red - therefore the whole pixel is now white.&lt;br /&gt;
 			}															&lt;br /&gt;
 			dstp = dstp + dst_pitch; &lt;br /&gt;
 		}&lt;br /&gt;
 	}&lt;br /&gt;
 &lt;br /&gt;
 	if (vi.IsRGB32()) {&lt;br /&gt;
 		// This code deals with RGB32 colourspace where each pixel is represented by&lt;br /&gt;
 		// 4 bytes, Blue, Green and Red and &amp;quot;spare&amp;quot; byte that could/should be used for alpha&lt;br /&gt;
 		// keying but usually isn&#039;t.&lt;br /&gt;
 &lt;br /&gt;
 		// Although this colourspace isn&#039;t memory efficient, code end ups running much&lt;br /&gt;
 		// quicker than RGB24 as you can deal with whole 32bit variables at a time&lt;br /&gt;
 		// and easily work directly and quickly in assembler (if you know how to that is :-)&lt;br /&gt;
 		&lt;br /&gt;
 		for (h=0; h &amp;lt; src_height;h++) {       // Loop from bottom line to top line.&lt;br /&gt;
 			for (w = 0; w &amp;lt; src_width/4; w+=1) {	// and from leftmost pixel to rightmost one. &lt;br /&gt;
 				*((unsigned int *)dstp + w) = *((unsigned int *)srcp + w);	// Copy each whole pixel from source to destination.&lt;br /&gt;
 			}																					// by temporarily treating the src and dst pointers as&lt;br /&gt;
 																								// pixel pointers intead of byte pointers&lt;br /&gt;
 			srcp = srcp + src_pitch; // Add the pitch (note use of pitch and not width) of one line (in bytes) to the source pointer&lt;br /&gt;
 			dstp = dstp + dst_pitch; // Add the pitch to the destination pointer.&lt;br /&gt;
 		}&lt;br /&gt;
 		// end copy src to dst&lt;br /&gt;
 		&lt;br /&gt;
 		//Now draw a white square in the middle of the frame&lt;br /&gt;
 		// Normally you&#039;d do this code within the loop above but here it is in a separate loop for clarity;&lt;br /&gt;
 		&lt;br /&gt;
 		dstp = dst-&amp;gt;GetWritePtr();  // reset the destination pointer to the bottom, left pixel. (RGB colourspaces only)&lt;br /&gt;
 		dstp = dstp + (dst_height/2 - SquareSize/2)*dst_pitch;  // move pointer to SquareSize/2 lines from the middle of the frame;&lt;br /&gt;
 &lt;br /&gt;
 		int woffset = dst_width/8 - SquareSize/2;  // lets precalulate the width offset like we do for the lines.&lt;br /&gt;
 &lt;br /&gt;
 		for (h=0; h &amp;lt; SquareSize;h++) { // only scan SquareSize number of lines &lt;br /&gt;
 			for (w = 0; w &amp;lt; SquareSize; w+=1) { // only scans the middle SquareSize pixels of a line &lt;br /&gt;
 				*((unsigned int *)dstp + woffset + w) = 0x00FFFFFF;		// Set Red,Green and Blue to maximum value in 1 instruction.&lt;br /&gt;
 			}	&lt;br /&gt;
 			dstp = dstp + dst_pitch; &lt;br /&gt;
 		}&lt;br /&gt;
   }&lt;br /&gt;
 	&lt;br /&gt;
   // As we now are finished processing the image, we return the destination image.&lt;br /&gt;
 	return dst;&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 // This is the function that created the filter, when the filter has been called.&lt;br /&gt;
 // This can be used for simple parameter checking, so it is possible to create different filters,&lt;br /&gt;
 // based on the arguments recieved.&lt;br /&gt;
 &lt;br /&gt;
 AVSValue __cdecl Create_SimpleSample(AVSValue args, void* user_data, IScriptEnvironment* env) {&lt;br /&gt;
     return new SimpleSample(args[0].AsClip(),&lt;br /&gt;
 		 args[1].AsInt(0),	// Corresponds to our 1st parameter - the size of the square in pixels.&lt;br /&gt;
 		 env);  &lt;br /&gt;
     // Calls the constructor with the arguments provied.&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 // The following function is the function that actually registers the filter in AviSynth&lt;br /&gt;
 // It is called automatically, when the plugin is loaded to see which functions this filter contains.&lt;br /&gt;
 &lt;br /&gt;
 extern &amp;quot;C&amp;quot; __declspec(dllexport) const char* __stdcall AvisynthPluginInit2(IScriptEnvironment* env) {&lt;br /&gt;
     env-&amp;gt;AddFunction(&amp;quot;SimpleSample&amp;quot;, &amp;quot;c[SIZE]i&amp;quot;, Create_SimpleSample, 0);&lt;br /&gt;
     // The AddFunction has the following paramters:&lt;br /&gt;
     // AddFunction(Filtername , Arguments, Function to call,0);&lt;br /&gt;
     &lt;br /&gt;
     // Arguments is a string that defines the types and optional names of the arguments for you filter.&lt;br /&gt;
     // c - Video Clip&lt;br /&gt;
     // i - Integer number&lt;br /&gt;
     // f - Float number&lt;br /&gt;
     // s - String&lt;br /&gt;
     // b - boolean&lt;br /&gt;
 &lt;br /&gt;
 	 // The word inside the [ ] lets you used named parameters in your script&lt;br /&gt;
 	 // e.g last=SimpleSample(last,size=100).&lt;br /&gt;
 	 // but last=SimpleSample(last,100) will also work automagically&lt;br /&gt;
 &lt;br /&gt;
     return &amp;quot;`SimpleSample&#039; SimpleSample plugin&amp;quot;;&lt;br /&gt;
     // A freeform name of the plugin.&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
Back to [[Filter_SDK/Simple_sample|Simple Sample]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FilterSDK]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=RGB&amp;diff=893</id>
		<title>RGB</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=RGB&amp;diff=893"/>
		<updated>2007-09-27T17:15:03Z</updated>

		<summary type="html">&lt;p&gt;Fizick: Undo revision 3787 by Special:Contributions/74.231.24.2 (User talk:74.231.24.2)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;RGB (from Red, Green, Blue) is a color model - or [[Color_spaces|color space]] - that consists of three primary colors (Red, Green and Blue, of course) which are added together at different proportions to create any other color. Thus RGB is an additive color model.&lt;br /&gt;
&lt;br /&gt;
The number of bits used to provide R,G,B information (ie the color depth) determines the maximum number of color variations that can be represented by a specific RGB model. Typical values for modern video is 8 bits (one byte) for each R,G,B primary. Typical specific RGB formats for video are [[RGB32]] and [[RGB24]].&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&#039;&#039;&#039;Related Links&#039;&#039;&#039;&lt;br /&gt;
* [http://en.wikipedia.org/wiki/RGB RGB Color Model at Wikipedia]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/SRGB_color_space sRGB Colorspace]&lt;br /&gt;
&lt;br /&gt;
[[Category:Glossary]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Planar&amp;diff=781</id>
		<title>Planar</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Planar&amp;diff=781"/>
		<updated>2007-09-27T17:14:13Z</updated>

		<summary type="html">&lt;p&gt;Fizick: Undo revision 3789 by Special:Contributions/74.231.24.2 (User talk:74.231.24.2)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Planar image format is a format for storing images where each color component needed to represent a pixel is placed &#039;&#039;at a separate place&#039;&#039; (block) in memory. This is in contrast with how [[interleaved]] images are stored in memory.&lt;br /&gt;
&lt;br /&gt;
Some examples of planar image formats are [[YV12]], [[I420]].&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
Related links:&lt;br /&gt;
* [http://www.fourcc.org/fccyuv.htm#Planar%20YUV%20Formats Planar YUV Formats]&lt;br /&gt;
* [http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnwmt/html/YUVFormats.asp YUV Formats]&lt;br /&gt;
&lt;br /&gt;
[[Category:Glossary]]&lt;br /&gt;
[[Category:FilterSDK]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Spline64Resize&amp;diff=632</id>
		<title>Spline64Resize</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Spline64Resize&amp;diff=632"/>
		<updated>2007-09-27T17:13:51Z</updated>

		<summary type="html">&lt;p&gt;Fizick: Undo revision 3790 by Special:Contributions/141.104.22.222 (User talk:141.104.22.222)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Resize]] [[Category:Internal filters]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Filter_SDK/Simple_sample&amp;diff=807</id>
		<title>Filter SDK/Simple sample</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Filter_SDK/Simple_sample&amp;diff=807"/>
		<updated>2007-06-17T17:35:17Z</updated>

		<summary type="html">&lt;p&gt;Fizick: full packages&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Here are the sources for the series of examples developed in [http://forum.doom9.org/showthread.php?s=&amp;amp;threadid=48261 this doom9 thread]. You can also get links to full packages with project files included in this thread.&lt;br /&gt;
&lt;br /&gt;
Note: the samples are for version 2.5&lt;br /&gt;
&lt;br /&gt;
* [[Filter_SDK/Simple_sample_1.0b|Simple Sample 1.0b]] - simple documented sample that just copies the source frame to the destination in RGB and YUV colourspaces.&lt;br /&gt;
* [[Filter_SDK/Simple_sample_1.1|Simple Sample 1.1]] - additions to handle planar colourspaces (e.g. YV12).&lt;br /&gt;
* [[Filter_SDK/Simple_sample_1.2|Simple Sample 1.2]] - Revert to RGB24 colourspace only to show simple pixel manipulation.&lt;br /&gt;
* [[Filter_SDK/Simple_sample_1.3a|Simple Sample 1.3a]] - Add in code to handle parameters in filters.&lt;br /&gt;
* [[Filter_SDK/Simple_sample_1.4|Simple Sample 1.4]] - Add in RGB32 colourspace code.&lt;br /&gt;
* [[Filter_SDK/Simple_sample_1.5a|Simple Sample 1.5a]] - Add in YUY2 code.&lt;br /&gt;
* [[Filter_SDK/Simple_sample_1.6|Simple Sample 1.6]] - and finally YV12 as well - yippee.&lt;br /&gt;
* [[Filter_SDK/Simple_sample_1.7|Simple Sample 1.7]] - Add in ability to use info from 2 clips only the YUY2 colorspace code altered.&lt;br /&gt;
* [[Filter_SDK/Simple_sample_Calls|Classes and function calls in AviSynth plugins]] - about classes and function calls in AviSynth plugins.&lt;br /&gt;
&lt;br /&gt;
Back to [[Filter_SDK|Filter SDK]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FilterSDK]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Filter_SDK/SDK_history&amp;diff=853</id>
		<title>Filter SDK/SDK history</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Filter_SDK/SDK_history&amp;diff=853"/>
		<updated>2007-05-12T00:07:41Z</updated>

		<summary type="html">&lt;p&gt;Fizick: developer&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The &amp;quot;Writing Avisynth plugins&amp;quot; article was written by Ben Rudiak-Gould (Avisynth creator). It was taken from AviSynth 1.0 documentation as it was (year 2000) at http://math.berkeley.edu/~benrg/avisynth-extensions.html (Ben&#039;s home page). The current (November 2006) mirror is at http://www.neuron2.net/www.math.berkeley.edu/benrg/avisynth-extensions.html&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
Preliminary version of AviSynth 2.0-2.5 FilterSDK documentation has been created at 2003 as a section of AviSynth online (wiki) documentation at the official AviSynth site www.avisynth.org (maintained by Richard Berg).&lt;br /&gt;
&lt;br /&gt;
{{Underline|Developers:}}&lt;br /&gt;
&lt;br /&gt;
* Klaus Post (&#039;sh0dan&#039;):&lt;br /&gt;
: AviSynthTwoFiveAudio, AviSynthTwoFivePixelType, AviSynthTwoFiveSDK, ChangeFrameSize, ColorSpaces, DataAlignment, DataStorageInAviSynth, EnvInvoke, EnvSaveString, SimpleMmxOptimization, TwoFiveInvert, TwoFiveFastInvert and some other wiki pages.&lt;br /&gt;
* Wilbert Dijkhof (&#039;Wilbert&#039;):&lt;br /&gt;
: CompilingAvisynth and some other wiki pages.&lt;br /&gt;
&lt;br /&gt;
{{Underline|Contributors:}}&lt;br /&gt;
&lt;br /&gt;
* Simon Walters (&#039;SiWalters&#039;):&lt;br /&gt;
: SimpleSample 1.0 to 1.7 wiki pages.&lt;br /&gt;
* &#039;trevlac&#039;:&lt;br /&gt;
: SimpleSampleClass wiki page.&lt;br /&gt;
* Avery Lee (&#039;phaeron&#039;):&lt;br /&gt;
: Some texts in AssemblerOptimizing wiki pages, &amp;quot;as freely available for any use&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Thanks to other Avisynth community people for wiki pages improving/correction! &lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
The package of off-line (HTML) AviSynth external FilterSDK documentation version 2.5.7 was created at 2006 at sourceforge.net CVS for distribution with AviSynth v2.5.7 installation.&lt;br /&gt;
&lt;br /&gt;
Most documents were converted from wiki pages (some modifyed/updated). Some new documents are added too.&lt;br /&gt;
&lt;br /&gt;
{{Underline|Developer:}}&lt;br /&gt;
&lt;br /&gt;
* Alexander Balakhnin (&#039;Fizick&#039;):&lt;br /&gt;
: SDKNecessaries, SDKLicense, SDKHistory, wiki pages converting/editing.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
FilterSDK documentation has been reposted to the new Avisynth mediawiki in 2007.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
Back to [[Filter SDK]].&lt;br /&gt;
&lt;br /&gt;
[[Category:FilterSDK]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
	<entry>
		<id>http://www.avisynth.nl/index.php?title=Filter_SDK/Ben_docs&amp;diff=771</id>
		<title>Filter SDK/Ben docs</title>
		<link rel="alternate" type="text/html" href="http://www.avisynth.nl/index.php?title=Filter_SDK/Ben_docs&amp;diff=771"/>
		<updated>2007-05-05T07:33:43Z</updated>

		<summary type="html">&lt;p&gt;Fizick: Restored AvisynthPluginInit, added notes and moved to bottom&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Writing Avisynth plugins ==&lt;br /&gt;
&lt;br /&gt;
=== An example ===&lt;br /&gt;
&lt;br /&gt;
I&#039;ll start off with a complete, working Avisynth plugin. It&#039;s called &amp;quot;Invert&amp;quot;, and it produces a photo-negative of the input clip.&lt;br /&gt;
&lt;br /&gt;
Here&#039;s Invert.cpp:&lt;br /&gt;
&lt;br /&gt;
 #include &amp;quot;windows.h&amp;quot;&lt;br /&gt;
 #include &amp;quot;avisynth.h&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 class Invert : public GenericVideoFilter {&lt;br /&gt;
 public:&lt;br /&gt;
     Invert(PClip _child) : GenericVideoFilter(_child) {}&lt;br /&gt;
     PVideoFrame __stdcall GetFrame(int n, IScriptEnvironment* env);&lt;br /&gt;
 }; &lt;br /&gt;
 &lt;br /&gt;
 PVideoFrame __stdcall Invert::GetFrame(int n, IScriptEnvironment* env) {&lt;br /&gt;
 &lt;br /&gt;
     PVideoFrame src = child-&amp;gt;GetFrame(n, env);&lt;br /&gt;
     PVideoFrame dst = env-&amp;gt;NewVideoFrame(vi);&lt;br /&gt;
 &lt;br /&gt;
     const unsigned char* srcp = src-&amp;gt;GetReadPtr();&lt;br /&gt;
     unsigned char* dstp = dst-&amp;gt;GetWritePtr();&lt;br /&gt;
 &lt;br /&gt;
     const int src_pitch = src-&amp;gt;GetPitch();&lt;br /&gt;
     const int dst_pitch = dst-&amp;gt;GetPitch();&lt;br /&gt;
     const int row_size = dst-&amp;gt;GetRowSize();&lt;br /&gt;
     const int height = dst-&amp;gt;GetHeight();&lt;br /&gt;
 &lt;br /&gt;
     for (int y = 0; y &amp;lt; height; y++) {&lt;br /&gt;
         for (int x = 0; x &amp;lt; row_size; x++) {&lt;br /&gt;
             dstp[x] = srcp[x] ^ 255;&lt;br /&gt;
         }&lt;br /&gt;
         srcp += src_pitch;&lt;br /&gt;
         dstp += dst_pitch;&lt;br /&gt;
     }&lt;br /&gt;
 &lt;br /&gt;
     return dst;&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 AVSValue __cdecl Create_Invert(AVSValue args, void* user_data, IScriptEnvironment* env) {&lt;br /&gt;
     return new Invert(args[0].AsClip());&lt;br /&gt;
 } &lt;br /&gt;
 &lt;br /&gt;
 extern &amp;quot;C&amp;quot; __declspec(dllexport) const char* __stdcall AvisynthPluginInit(IScriptEnvironment* env) { &lt;br /&gt;
     env-&amp;gt;AddFunction(&amp;quot;Invert&amp;quot;, &amp;quot;c&amp;quot;, Create_Invert, 0);&lt;br /&gt;
     return &amp;quot;`Invert&#039; sample plugin&amp;quot;;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
Compile this file into a DLL named Invert.dll. Now create an Avisynth script which looks something like this:&lt;br /&gt;
&lt;br /&gt;
 LoadPlugin(&amp;quot;d:\path\Invert.dll&amp;quot;)&lt;br /&gt;
 clip = AVISource(&amp;quot;d:\path2\video.avi&amp;quot;)&lt;br /&gt;
 return clip.Invert()&lt;br /&gt;
&lt;br /&gt;
If all is well, you should see a photo negative of your video clip when you open this script.&lt;br /&gt;
How it works&lt;br /&gt;
&lt;br /&gt;
Here&#039;s a line-by-line breakdown of Invert.cpp.&lt;br /&gt;
&lt;br /&gt;
 #include &amp;quot;avisynth.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
This header declares all the classes and miscellaneous constants that you might need when writing a plugin. All external plugins should #include it.&lt;br /&gt;
&lt;br /&gt;
External plugins do not link with avisynth.dll, so they can&#039;t directly access functions that are defined in the main Avisynth source code. Therefore, every important function in avisynth.h is either defined inline or declared as virtual. The virtual functions act as callbacks for external DLLs.&lt;br /&gt;
&lt;br /&gt;
 class Invert : public GenericVideoFilter {&lt;br /&gt;
&lt;br /&gt;
An Avisynth filter is simply a C++ class implementing the IClip interface. IClip has four pure virtual methods: GetVideoInfo, GetFrame, GetParity, and GetAudio.&lt;br /&gt;
&lt;br /&gt;
The class GenericVideoFilter is a simple do-nothing filter defined in avisynth.h. It derives from IClip and implements all four methods. Most filters can inherit from GenericVideoFilter rather than directly from IClip; this saves you from having to implement methods that you don&#039;t care about, like GetAudio.&lt;br /&gt;
&lt;br /&gt;
 Invert(PClip _child) : GenericVideoFilter(_child) {}&lt;br /&gt;
&lt;br /&gt;
A PClip is a &amp;quot;smart pointer&amp;quot; to an IClip. It maintains a reference count on the IClip object and automagically deletes it when the last PClip referencing it goes away. For obvious reasons, you should always use PClip rather than IClip* to refer to clips.&lt;br /&gt;
&lt;br /&gt;
Like a genuine pointer, a PClip is only four bytes long, so you can pass it around by value. Also like a pointer, a PClip can be assigned a null value (0), which is often useful as a sentinel. Unlike a pointer, PClip is initialized to 0 by default.&lt;br /&gt;
&lt;br /&gt;
You&#039;ll need to make sure your class doesn&#039;t contain any circular PClip references, or any PClips sitting in dynamically allocated memory that you forget to delete. Other than that, you don&#039;t have to worry about the reference-counting machinery.&lt;br /&gt;
&lt;br /&gt;
Avisynth filters have a standardized output channel via IClip, but (unlike [[VirtualDub]] filters) no standardized input channel. Each filter is responsible for obtaining its own source material -- usually (as in this case) from another clip, but sometimes from several different clips, or from a file.&lt;br /&gt;
&lt;br /&gt;
GenericVideoFilter has a single constructor taking a single clip, which it then simply passes through to its output. We will override the GetFrame method to do something more useful, while leaving the other three methods as-is to pass through aspects of the clip that we don&#039;t need to change.&lt;br /&gt;
&lt;br /&gt;
 PVideoFrame Invert::GetFrame(int n, IScriptEnvironment* env) {&lt;br /&gt;
&lt;br /&gt;
This method is called to make our filter produce frame n of its output. The second argument, env, is for our purposes simply a callback suite. It is actually implemented in Avisynth by a class called ScriptEnvironment. One instance of this class is created for each opened AVS script, so there may sometimes be several instances active at once. It is important that the callback functions be called through the proper instance. A particular instance of your class will only be used in one ScriptEnvironment, but different instances might be used in different ScriptEnvironments.&lt;br /&gt;
&lt;br /&gt;
This method returns a PVideoFrame, which is a smart pointer like PClip.&lt;br /&gt;
&lt;br /&gt;
     PVideoFrame src = child-&amp;gt;GetFrame(n, env);&lt;br /&gt;
&lt;br /&gt;
&amp;quot;child&amp;quot; is a protected member of GenericVideoFilter, of type PClip. It contains the clip that was passed to the constructor. For our filter to produce frame n we need the corresponding frame of the input. If you need a different frame from the input, all you have to do is pass a different frame number to child-&amp;gt;GetFrame.&lt;br /&gt;
&lt;br /&gt;
GetFrame calls are usually intercepted by Avisynth&#039;s internal caching code, so the frame request may never actually reach the child filter.&lt;br /&gt;
&lt;br /&gt;
      PVideoFrame dst = env-&amp;gt;NewVideoFrame(vi);&lt;br /&gt;
&lt;br /&gt;
The NewVideoFrame callback allocates space for a video frame of the supplied size. (In this case it will hold our filter&#039;s output.) The frame buffer is uninitialized raw memory (except that in the debug build it gets filled with the repeating byte pattern 0A 11 0C A7 ED, which is easy to recognize because it looks like &amp;quot;ALLOCATED&amp;quot;).&lt;br /&gt;
&lt;br /&gt;
&amp;quot;vi&amp;quot; is another protected member of GenericVideoFilter (the only other member, actually). It is a struct of type VideoInfo, which contains information about the clip (like frame size, frame rate, pixel format, audio sample rate, etc.). NewVideoFrame uses the information in this struct to return a frame buffer of the appropriate size.&lt;br /&gt;
&lt;br /&gt;
Frame buffers are reused once all the PVideoFrame references to them go away. So usually NewVideoFrame won&#039;t actually need to allocate any memory from the heap.&lt;br /&gt;
&lt;br /&gt;
     const unsigned char* srcp = src-&amp;gt;GetReadPtr();&lt;br /&gt;
     unsigned char* dstp = dst-&amp;gt;GetWritePtr();&lt;br /&gt;
&lt;br /&gt;
All frame buffers are readable, but not all are writable.&lt;br /&gt;
&lt;br /&gt;
The rule about writability is this: A buffer is writable if and only if there is exactly one PVideoFrame pointing to it. In other words, you can only write to a buffer if no one else might be reading it. This rule guarantees that as long as you hold on to a PVideoFrame and don&#039;t write to it yourself, that frame will remain unchanged. The only drawback is that you can&#039;t have two PVideoFrames pointing to a writable buffer. This can sometimes be an inconvenience, as I&#039;ll explain later.&lt;br /&gt;
&lt;br /&gt;
Any buffer you get from NewVideoFrame is guaranteed to be writable (as long as you only assign it to one PVideoFrame!). Our filter&#039;s dst came from NewVideoFrame, so we can safely call dst-&amp;gt;GetWritePtr(). However, frames you get from other clips via GetFrame may not be writable, in which case GetWritePtr() will return a null pointer.&lt;br /&gt;
&lt;br /&gt;
There is an IsWritable() method which you can call to find out if a buffer is writable or not, and there&#039;s a MakeWritable callback (described below) to ensure that it is.&lt;br /&gt;
&lt;br /&gt;
     const int src_pitch = src-&amp;gt;GetPitch();&lt;br /&gt;
     const int dst_pitch = dst-&amp;gt;GetPitch();&lt;br /&gt;
&lt;br /&gt;
Just as in VirtualDub, the &amp;quot;pitch&amp;quot; of a frame buffer is the offset (in bytes) from the beginning of one scan line to the beginning of the next. The source and destination buffers won&#039;t necessarily have the same pitch.&lt;br /&gt;
&lt;br /&gt;
Buffers created by NewVideoFrame are always quadword (8-byte) aligned and always have a pitch that is a multiple of 8.&lt;br /&gt;
&lt;br /&gt;
     const int row_size = dst-&amp;gt;GetRowSize();&lt;br /&gt;
&lt;br /&gt;
The row size is the length of each row in bytes (not pixels). It&#039;s usually equal to the pitch or slightly less, but it may be significantly less if the frame in question has been through Crop.&lt;br /&gt;
&lt;br /&gt;
Since our source and destination frames have the same width and pixel format, they will always have the same row size. Thus I only need one row_size variable, and I could just as well have called src-&amp;gt;GetRowSize().&lt;br /&gt;
&lt;br /&gt;
     const int height = dst-&amp;gt;GetHeight();&lt;br /&gt;
&lt;br /&gt;
The height is the height. (In pixels.) Again, for our filter this is the same for the source and the destination.&lt;br /&gt;
&lt;br /&gt;
     for (int y = 0; y &amp;lt; height; y++) {&lt;br /&gt;
         for (int x = 0; x &amp;lt; row_size; x++)&lt;br /&gt;
             dstp[x] = srcp[x] ^ 255;&lt;br /&gt;
         srcp += src_pitch;&lt;br /&gt;
         dstp += dst_pitch;&lt;br /&gt;
     }&lt;br /&gt;
&lt;br /&gt;
This is the code that does the actual work. The &amp;quot;srcp += src_pitch; dstp += dst_pitch;&amp;quot; idiom is a useful way of dealing with potentially differing pitches without too much grief.&lt;br /&gt;
&lt;br /&gt;
     return dst;&lt;br /&gt;
&lt;br /&gt;
GetFrame returns the newly-created frame. Our own references to this frame and to the source frame will go away with the src and dst variables. Our caller will become sole owner of the destination frame (which therefore will still be writable), and the source frame will be retained in the cache and eventually recycled. All through the magic of C++ classes.&lt;br /&gt;
&lt;br /&gt;
 AVSValue __cdecl Create_Invert(AVSValue args, void* user_data, IScriptEnvironment* env) {&lt;br /&gt;
&lt;br /&gt;
In order to use our new filter, we need a scripting-language function which creates an instance of it. This is that function.&lt;br /&gt;
&lt;br /&gt;
Script functions written in C++ take three arguments. args contains all the arguments passed to the function by the script. user_data contains the void pointer which you passed to AddFunction (see below). Usually you won&#039;t need this. env contains the same IScriptEnvironment pointer that will later be passed to GetFrame.&lt;br /&gt;
&lt;br /&gt;
AVSValue is a variant type which can hold any one of the following: a boolean value (true/false); an integer; a floating-point number; a string; a video clip (PClip); an array of AVSValues; or nothing (&amp;quot;undefined&amp;quot;). You can test which one it is with the methods IsBool(), IsInt(), IsFloat(), IsString(), IsClip(), IsArray(), and Defined() (which returns true if the AVSValue is not &amp;quot;undefined&amp;quot;). You can get the value with AsBool(), AsInt(), etc. For arrays, you can use the ArraySize() method to get the number of elements, and [] indexing to get the elements themselves. For convenience, IsFloat() and AsFloat() will work with integers also. But boolean values are not treated as numeric (unlike C).&lt;br /&gt;
&lt;br /&gt;
The name &amp;quot;Create_Invert&amp;quot; is arbitrary. This function will actually be known as &amp;quot;Invert&amp;quot; in scripts, because that&#039;s the name we pass to AddFunction below.&lt;br /&gt;
&lt;br /&gt;
     return new Invert(args[0].AsClip());&lt;br /&gt;
&lt;br /&gt;
The args argument passed to a script function will always be an array. The return value should be any one of the other types (never an array).&lt;br /&gt;
&lt;br /&gt;
The types of the values in the args array are guaranteed to match one of the function signatures that you pass to AddFunction, just as in VirtualDub. Therefore, there&#039;s no need to worry about IsClip here.&lt;br /&gt;
&lt;br /&gt;
Create_Invert simply creates and returns a filter instance; it is automatically converted to an AVSValue via the constructor AVSValue(IClip*).&lt;br /&gt;
&lt;br /&gt;
 extern &amp;quot;C&amp;quot; __declspec(dllexport) const char* __stdcall AvisynthPluginInit2(IScriptEnvironment* env) {&lt;br /&gt;
&lt;br /&gt;
This is the only function which gets exported from the DLL. It is called by the script function LoadPlugin the first time this plugin in loaded in a particular script. If several scripts are open at once and more than one of them loads this plugin, AvisynthPluginInit2 may be called more than once with different IScriptEnvironments. Therefore:&lt;br /&gt;
&lt;br /&gt;
* You should not save the env parameter in a global variable.&lt;br /&gt;
* If you need to initialize any static data, you should do it in DLLMain, not in this function. &lt;br /&gt;
&lt;br /&gt;
The main purpose of the AvisynthPluginInit2 function is to call env-&amp;gt;AddFunction.&lt;br /&gt;
&lt;br /&gt;
     env-&amp;gt;AddFunction(&amp;quot;Invert&amp;quot;, &amp;quot;c&amp;quot;, Create_Invert, 0);&lt;br /&gt;
&lt;br /&gt;
As promised, we now call AddFunction to let Avisynth know of the existence of our filter. This function takes four arguments: the name of the new script function; the parameter-type string; the C++ function implementing the script function; and the user_data cookie.&lt;br /&gt;
&lt;br /&gt;
The parameter-type string is similar to the corresponding entity in [[VirtualDub]], except that:&lt;br /&gt;
&lt;br /&gt;
* No return type is given. Function return values are not type-checked; you can return anything you like.&lt;br /&gt;
* There are more types: along with &#039;i&#039;nt and &#039;s&#039;tring you can specify &#039;b&#039;ool, &#039;f&#039;loat, and &#039;c&#039;lip.&lt;br /&gt;
* You can follow any type with &#039;*&#039; or &#039;+&#039; to indicate &amp;quot;zero or more&amp;quot; or &amp;quot;one or more&amp;quot; respectively. In this case all the matching arguments will be gathered into a sub-array. &lt;br /&gt;
:: For example, if your type string is &amp;quot;is+f&amp;quot;, then the integer argument will be args[0], the string arguments will be args[1][0], args[1][1], etc. (and there will be args[1].ArraySize() of them), and the float argument will be args[2].&lt;br /&gt;
* &#039;.&#039; matches a single argument of any type. To match multiple arguments of any type, use &amp;quot;.*&amp;quot; or &amp;quot;.+&amp;quot;.&lt;br /&gt;
* You can have named arguments, by specifying the name in [brackets] before the type. Named arguments are also optional arguments; if the user omits them, they will be of the undefined type instead of the type you specify. For convenience, AVSValue offers a set of As...() functions which take default values. See avisynth.h. &lt;br /&gt;
&lt;br /&gt;
     return &amp;quot;`Invert&#039; sample plugin&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
The return value of AvisynthPluginInit is a string which can contain any message you like, such as a notice identifying the version and author of the plugin. This string becomes the return value of LoadPlugin, and will almost always be ignored. You can also just return 0 if you prefer.&lt;br /&gt;
&lt;br /&gt;
== Variations ==&lt;br /&gt;
&lt;br /&gt;
=== An in-place filter ===&lt;br /&gt;
&lt;br /&gt;
The Invert filter could easily do its work in a single buffer, rather than copying from one buffer to another. Here&#039;s a new implementation of GetFrame that does this.&lt;br /&gt;
&lt;br /&gt;
 PVideoFrame Invert::GetFrame(int n, IScriptEnvironment* env) {&lt;br /&gt;
 &lt;br /&gt;
     PVideoFrame frame = child-&amp;gt;GetFrame(n, env);&lt;br /&gt;
     &lt;br /&gt;
     env-&amp;gt;MakeWritable(&amp;amp;frame);&lt;br /&gt;
     &lt;br /&gt;
     unsigned char* p = frame-&amp;gt;GetWritePtr();&lt;br /&gt;
     const int pitch = frame-&amp;gt;GetPitch();&lt;br /&gt;
     const int row_size = frame-&amp;gt;GetRowSize();&lt;br /&gt;
     const int height = frame-&amp;gt;GetHeight();&lt;br /&gt;
     &lt;br /&gt;
     for (int y = 0; y &amp;lt; height; y++) {&lt;br /&gt;
         for (int x = 0; x &amp;lt; row_size; x++)&lt;br /&gt;
             p[x] ^= 255;&lt;br /&gt;
             p += pitch;&lt;br /&gt;
         }&lt;br /&gt;
     }&lt;br /&gt;
     return frame;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
The key difference between this version of the function and the original version is the presence of the MakeWritable callback. This is necessary because this time &amp;quot;we don&#039;t know where that frame&#039;s been.&amp;quot; Someone else in the filter chain may be holding a reference to it, in which case we won&#039;t be allowed to write to it.&lt;br /&gt;
&lt;br /&gt;
MakeWritable is a simple solution to this problem. It is implemented as follows (in avisynth.cpp):&lt;br /&gt;
&lt;br /&gt;
 bool ScriptEnvironment::MakeWritable(PVideoFrame* pvf) {&lt;br /&gt;
     const PVideoFrame&amp;amp; vf = *pvf;&lt;br /&gt;
     &lt;br /&gt;
     // If the frame is already writable, do nothing.&lt;br /&gt;
     &lt;br /&gt;
     if (vf-&amp;gt;IsWritable()) {&lt;br /&gt;
         return false;&lt;br /&gt;
     }&lt;br /&gt;
     &lt;br /&gt;
     // Otherwise, allocate a new frame (using NewVideoFrame) and&lt;br /&gt;
     // copy the data into it.  Then modify the passed PVideoFrame&lt;br /&gt;
     // to point to the new buffer.&lt;br /&gt;
     &lt;br /&gt;
     else {&lt;br /&gt;
         const int row_size = vf-&amp;gt;GetRowSize();&lt;br /&gt;
         const int height = vf-&amp;gt;GetHeight();&lt;br /&gt;
         PVideoFrame dst = NewVideoFrame(row_size, height);&lt;br /&gt;
         BitBlt(dst-&amp;gt;GetWritePtr(), dst-&amp;gt;GetPitch(), vf-&amp;gt;GetReadPtr(), vf-&amp;gt;GetPitch(), row_size, height);&lt;br /&gt;
         *pvf = dst;&lt;br /&gt;
         return true;&lt;br /&gt;
     }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
=== A filter that changes the frame size ===&lt;br /&gt;
&lt;br /&gt;
In order to effect a change in frame size, two things must happen:&lt;br /&gt;
&lt;br /&gt;
* your GetVideoInfo method must return a VideoInfo struct with the appropriate size, and&lt;br /&gt;
* your GetFrame method must return video frames of the appropriate size. &lt;br /&gt;
&lt;br /&gt;
If you derive your filter class from GenericVideoFilter, then a convenient way to achieve both of these things is to assign the new values to vi.width and vi.height in your class constructor. This way you won&#039;t have to override GetVideoInfo, since GenericVideoFilter&#039;s implementation just returns vi. And if you allocate your output frames using env-&amp;gt;NewVideoFrame(vi), then they will be of the appropriate size as well.&lt;br /&gt;
&lt;br /&gt;
For an example of a simple filter which does this, see [[Crop]] or [[StackVertical]].&lt;br /&gt;
&lt;br /&gt;
=== A filter which processes audio ===&lt;br /&gt;
&lt;br /&gt;
Audio processing is handled through the GetAudio method, which has the following prototype:&lt;br /&gt;
&lt;br /&gt;
 void GetAudio(void* buf, int start, int count, IScriptEnvironment* env);&lt;br /&gt;
&lt;br /&gt;
You must fill in the buffer with count samples beginning with sample number start. A sample may vary from one to four bytes, depending on whether the audio is 8- or 16-bit and mono or stereo. The flags vi.stereo and vi.sixteen_bit will tell you this.&lt;br /&gt;
&lt;br /&gt;
If you cannot do your audio processing in-place, you must allocate your own buffer for the source audio using new or malloc.&lt;br /&gt;
&lt;br /&gt;
=== A filter which rearranges frames ===&lt;br /&gt;
&lt;br /&gt;
Many of the built-in filters do nothing more than rearrange video frames (for example [[Trim]], [[Splice]], [[SelectEvery]], [[Interleave]], [[Reverse]], and [[ChangeFPS]]). If you want to do this, you can write a GetFrame method like this:&lt;br /&gt;
&lt;br /&gt;
 PVideoFrame GetFrame(int n, IScriptEnvironment* env) {&lt;br /&gt;
     return child-&amp;gt;GetFrame(ConvertFrameNumber(n), env);&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
But you must also do three other things:&lt;br /&gt;
&lt;br /&gt;
* Write a companion GetParity method so that field information is preserved; for example, bool GetParity(int n) { return child-&amp;gt;GetParity(ConvertFrameNumber(n)); };&lt;br /&gt;
* Set vi.num_frames and/or call vi.SetFPS at instance construction time, if you change the frame count or frame rate;&lt;br /&gt;
* Decide what you want to do with the audio track, and write a GetAudio method if necessary. &lt;br /&gt;
&lt;br /&gt;
=== Other useful methods in IScriptEnvironment ===&lt;br /&gt;
&lt;br /&gt;
 __declspec(noreturn) virtual void ThrowError(const char* fmt, ...);&lt;br /&gt;
&lt;br /&gt;
This function throws an exception (of type AvisynthError). Usually, your error message will end up being displayed on the user&#039;s screen in lieu of the video clip they were expecting.&lt;br /&gt;
&lt;br /&gt;
You can safely call ThrowError from anywhere except inside GetParity and GetVideoInfo.&lt;br /&gt;
&lt;br /&gt;
I declared this function as __declspec(noreturn) to prevent &amp;quot;not all control paths return a value&amp;quot; warnings. But it didn&#039;t work -- I still get the warnings. Go figure.&lt;br /&gt;
&lt;br /&gt;
 virtual long GetCPUFlags();&lt;br /&gt;
&lt;br /&gt;
This is exactly the same as the corresponding [[VirtualDub]] function (to the point of being implemented with code taken directly from VirtualDub -- sorry Avery ;-) ).&lt;br /&gt;
&lt;br /&gt;
To find out if you&#039;re running on a CPU that supports MMX, test env-&amp;gt;GetCPUFlags() &amp;amp; CPUF_MMX. There&#039;s a complete list of flags in avisynth.h.&lt;br /&gt;
&lt;br /&gt;
 virtual char* SaveString(const char* s, int length = -1);&lt;br /&gt;
&lt;br /&gt;
This function copies its argument to a safe &amp;quot;permanent&amp;quot; location and returns a pointer to the new location.&lt;br /&gt;
&lt;br /&gt;
Each ScriptEnvironment instance has a buffer set aside for storing strings, which is expanded as needed. The strings are not deleted until the ScriptEnvironment instance goes away (when the script file is closed, usually). This is usually all the permanence that is needed, since all related filter instances will already be gone by then.&lt;br /&gt;
&lt;br /&gt;
The returned pointer is not const-qualified, and you&#039;re welcome to write to it, as long as you don&#039;t stray beyond the bounds of the string.&lt;br /&gt;
&lt;br /&gt;
 virtual char* Sprintf(const char* fmt, ...);&lt;br /&gt;
 virtual char* VSprintf(const char* fmt, char* val);&lt;br /&gt;
&lt;br /&gt;
These store strings away in the same way as SaveString, but they treat their arguments like printf and vprintf.&lt;br /&gt;
&lt;br /&gt;
Currently there&#039;s a size limit of 4096 characters on strings created this way. (The implementation uses _vsnprintf, so you don&#039;t need to worry about buffer overrun.)&lt;br /&gt;
&lt;br /&gt;
 virtual AVSValue Invoke(const char* name, const AVSValue args, const char** arg_names=0);&lt;br /&gt;
&lt;br /&gt;
You can use this to call a script function. There are many script functions which can be useful from other filters; for example, the [[Bob]] filter uses [[SeparateFields]], and several source filters use [[Splice|UnalignedSplice]]. Some functions, like [[Weave]], are implemented entirely in terms of other functions.&lt;br /&gt;
&lt;br /&gt;
If you&#039;re calling a function taking exactly one argument, you can simply pass it in the args parameter; Invoke will convert it into an array for you. In order to call a function taking multiple arguments, you will need to create the array yourself; it can be done like this:&lt;br /&gt;
&lt;br /&gt;
 AVSValue args[5] = { clip, 0, true, 4.7, &amp;quot;my hovercraft is full of eels&amp;quot; };&lt;br /&gt;
 env-&amp;gt;Invoke(&amp;quot;Frob&amp;quot;, AVSValue(args, 5));&lt;br /&gt;
&lt;br /&gt;
In this case Frob would need to have a parameter-type string like &amp;quot;cibfs&amp;quot; or &amp;quot;cfbfs&amp;quot; or &amp;quot;cf.*&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
The arg_names parameter can be used to specify named arguments. Named arguments can also be given positionally, if you prefer.&lt;br /&gt;
&lt;br /&gt;
Invoke throws IScriptEnvironment::NotFound if it can&#039;t find a matching function prototype. You should be prepared to catch this unless you know that the function exists and will accept the given arguments.&lt;br /&gt;
&lt;br /&gt;
 virtual void BitBlt(unsigned char* dstp, int dst_pitch, const unsigned char* srcp, int src_pitch, int row_size, int height);&lt;br /&gt;
&lt;br /&gt;
This brilliantly-named function does a line-by-line copy from the source to the destination. It&#039;s useful for quite a number of things; the built-in filters DoubleWeave, FlipVertical, AddBorders, PeculiarBlend, StackVertical, StackHorizontal, and ShowFiveVersions all use it to do their dirty work.&lt;br /&gt;
&lt;br /&gt;
 typedef void (__cdecl *ShutdownFunc)(void* user_data, IScriptEnvironment* env);&lt;br /&gt;
 virtual void AtExit(ShutdownFunc function, void* user_data);&lt;br /&gt;
&lt;br /&gt;
If you find yourself wanting an AvisynthPluginShutdown export, this is the way to get that effect. Functions added through AtExit are called (in the opposite order that they were added) when the corresponding ScriptEnvironment goes away. &lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
== Notes to Ben&#039;s docs ==&lt;br /&gt;
&lt;br /&gt;
This is original documentation written for AviSynth 1.0 by [[User:BenRG|Ben Rudiak-Gould]] - copied from http://math.berkeley.edu/~benrg/avisynth-extensions.html&lt;br /&gt;
&lt;br /&gt;
Mirror is available now online at the http://www.neuron2.net/www.math.berkeley.edu/benrg/avisynth-extensions.html&lt;br /&gt;
&lt;br /&gt;
For AviSynth 2.5, see the converted [[Filter_SDK/Two-Five_Invert|Two-Five Invert]] plugin filter source.&lt;br /&gt;
&lt;br /&gt;
Plugin exported function name is replaced from &#039;AvisynthPluginInit&#039; for AviSynth 1.0-2.0 &lt;br /&gt;
to &#039;AvisynthPluginInit2&#039; for AviSynth 2.5. &lt;br /&gt;
&lt;br /&gt;
For other changes see [[Filter_SDK/Two-Five_SDK|Two-Five SDK]].&lt;br /&gt;
&lt;br /&gt;
Please do not edit the Ben&#039;s text!&lt;br /&gt;
&lt;br /&gt;
[[Category:FilterSDK]]&lt;/div&gt;</summary>
		<author><name>Fizick</name></author>
	</entry>
</feed>