This page has been translated automatically.
Видеоуроки
Interface
Essentials
Advanced
Подсказки и советы
Основы
Программирование на C#
Рендеринг
Professional (SIM)
Принципы работы
Свойства (properties)
Компонентная Система
Рендер
Физика
Редактор UnigineEditor
Обзор интерфейса
Работа с ассетами
Настройки и предпочтения
Работа с проектами
Настройка параметров ноды
Setting Up Materials
Настройка свойств
Освещение
Landscape Tool
Sandworm
Использование инструментов редактора для конкретных задач
Расширение функционала редактора
Встроенные объекты
Ноды (Nodes)
Объекты (Objects)
Эффекты
Декали
Источники света
Geodetics
World Nodes
Звуковые объекты
Объекты поиска пути
Players
Программирование
Основы
Настройка среды разработки
Примеры использования
C++
C#
UnigineScript
UUSL (Unified UNIGINE Shader Language)
Плагины
Форматы файлов
Materials and Shaders
Rebuilding the Engine Tools
GUI
Двойная точность координат
API
Containers
Common Functionality
Controls-Related Classes
Engine-Related Classes
Filesystem Functionality
GUI-Related Classes
Math Functionality
Node-Related Classes
Objects-Related Classes
Networking Functionality
Pathfinding-Related Classes
Physics-Related Classes
Plugins-Related Classes
IG Plugin
CIGIConnector Plugin
Rendering-Related Classes
Работа с контентом
Оптимизация контента
Материалы
Визуальный редактор материалов
Сэмплы материалов
Material Nodes Library
Miscellaneous
Input
Math
Matrix
Textures
Art Samples
Tutorials
Внимание! Эта версия документация УСТАРЕЛА, поскольку относится к более ранней версии SDK! Пожалуйста, переключитесь на самую актуальную документацию для последней версии SDK.
Внимание! Эта версия документации описывает устаревшую версию SDK, которая больше не поддерживается! Пожалуйста, обновитесь до последней версии SDK.

Unigine::FieldAnimation Class

Header: #include <UnigineFields.h>
Inherits from: Field

This class allows you to create and modify field animation objects.

See also#

  • A set of UnigineScript samples located in the <UnigineSDK>/data/samples/fields/ folder:
    • animation_00
    • animation_01

FieldAnimation Class

Members


static FieldAnimationPtr create ( const Math::vec3 & size ) #

Creates a new field animation node of the specified size:
  • If the field animation is of an ellipse shape, its radius values along the axes must be specified.
  • Otherwise, dimensions of the cube must be specified.

Arguments

  • const Math::vec3 & size - A size of the field animation along X, Y and Z axes in units.

void setAnimationScale ( float scale ) #

Sets the animation scale value indicating the scale for speed of vegetation swaying.

Arguments

  • float scale - The scale for speed of vegetation swaying value.

float getAnimationScale ( ) const#

Returns the animation scale value indicating the scale for speed of vegetation swaying.

Return value

The scale for speed of vegetation swaying value.

void setAttenuation ( float attenuation ) #

Sets an attenuation coefficient value for the Field Animation.

Arguments

  • float attenuation - An attenuation coefficient value. If a too small value is provided, 1E-6 will be used instead.

float getAttenuation ( ) const#

Returns the current attenuation coefficient for the Field Animation that indicates how much animation fades away starting from the center of the animation field to its edges:
  • By the minimum value of 0, no animation will be visible.
  • The higher the value, the more intensive animation will be at the edges of the animation field.

Return value

Current attenuation coefficient value.

void setEllipse ( bool ellipse ) #

Transforms a cube-shaped field animation into an ellipse-shaped one or vice versa.

Arguments

  • bool ellipse - true for the ellipse-shaped Field Animation, false for the cube-shaped one.

bool isEllipse ( ) const#

Returns a value indicating if the Field Animation is of an ellipse shape.

Return value

true if the Field Animation is of an ellipse shape; otherwise, false.

void setLeaf ( float leaf ) #

Sets a leaf animation coefficient value.

Arguments

  • float leaf - A new leaf coefficient value. If a negative value is provided, 0 will be used instead.

float getLeaf ( ) const#

Returns the current leaf animation coefficient value.

Return value

The leaf animation coefficient value.

void setSize ( const Math::vec3 & size ) #

Sets an animation field size.

Arguments

  • const Math::vec3 & size - A new animation field size along the X, Y and Z axes in units. If a negative value is provided, 0 will be used instead.

Math::vec3 getSize ( ) const#

Returns the animation field size:
  • If the field animation is of an ellipse shape, its radius values along the axes will be returned.
  • Otherwise, dimensions of the cube will be returned.

Return value

The current animation field size along the X, Y and Z axes in units.

void setStem ( float stem ) #

Sets a stem animation coefficient value.

Arguments

  • float stem - A new stem animation coefficient value. If a negative value is provided, 0 will be used instead.

float getStem ( ) const#

Returns the current stem animation coefficient value.

Return value

The stem animation coefficient value.

void setWind ( const Math::vec3 & wind ) #

Sets wind coefficients values that define wind direction inside the animation field.

Arguments

  • const Math::vec3 & wind - Wind coefficients values along the X, Y and Z directions.

Math::vec3 getWind ( ) const#

Returns the wind coefficients values that define wind direction inside the animation field.

Return value

Current wind coefficients values along the X, Y, and Z directions.

static int type ( ) #

Returns the type of the object.

Return value

FieldAnimation type identifier.
Last update: 10.03.2022
Build: ()