This page has been translated automatically.
Видеоуроки
Interface
Essentials
Advanced
Полезные советы
Программирование на C#
Принципы работы
Свойства (properties)
Компонентная Система
Рендер
Физика
Редактор UnigineEditor
Обзор интерфейса
Работа с ассетами
Настройки и предпочтения
Работа с проектами
Настройка параметров узла
Setting Up Materials
Setting Up Properties
Освещение
Landscape Tool
Sandworm (Experimental)
Использование инструментов редактора для конкретных задач
Extending Editor Functionality
Встроенные объекты
Nodes
Objects
Effects
Decals
Light Sources
Geodetics
World Objects
Sound Objects
Pathfinding Objects
Players
Программирование
Основы
Настройка среды разработки
Примеры использования
UnigineScript
C++
C#
Унифицированный язык шейдеров UUSL
File Formats
Rebuilding the Engine Tools
GUI
Двойная точность координат
API
Containers
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
Работа с контентом
Оптимизация контента
Материалы
Art Samples
Tutorials
Внимание! Эта версия документация УСТАРЕЛА, поскольку относится к более ранней версии SDK! Пожалуйста, переключитесь на самую актуальную документацию для последней версии SDK.
Внимание! Эта версия документации описывает устаревшую версию SDK, которая больше не поддерживается! Пожалуйста, обновитесь до последней версии SDK.

Unigine::Palette Class

Header: #include <UniginePalette.h>

This structure represents a set of values for 12 major colors of the color spectre used to define saturation and hue adjustment.

The following code snippet shows a usage example:

Source code (C++)
#include <UniginePalette.h>
			
Palette p = Palette(0.5f);
Render::setColorCorrectionHueShift(p);

Palette Class

Enums

Color#

NameDescription
RED = 0Red color.
ORANGE = 1Orange color.
YELLOW = 2Yellow color.
CHARTREUSE = 3Chartreuse color.
GREEN = 4Green color.
SPRINGGREEN = 5Spring Green color.
CYAN = 6Cyan color.
AZURE = 7Azure color.
BLUE = 8Blue color.
VIOLET = 9Violet color.
MAGENTA = 10Magenta color.
ROSE = 11Rose color.
SIZE = 12The number of colors.

Members


Palette ( ) #

Constructor. Initializes the structure with zero values.

Palette ( const Palette & palette ) #

Constructor. Initializes the structure using the given Palette.

Arguments

  • const Palette & palette - Source Palette.

Palette ( const float (&)[12] palette ) #

Constructor. Initializes the structure using the given array of floats.

Arguments

  • const float (&)[12] palette - Source array of 12 float values.

Palette ( float value ) #

Constructor. Initializes the structure using the given float for all values.

Arguments

  • float value - value to be set for all color values.

Palette & operator= ( const Palette & palette ) #

Performs structure assignment. Destination palette = source palette.

Arguments

  • const Palette & palette - Source palette.

Return value

Result.

bool operator== ( const Palette & palette ) const#

Check if two palettes are the same.

Arguments

  • const Palette & palette - The second palette.

Return value

Returns true if the palettes are the same; otherwise, false.

bool operator== ( const float (&)[12] palette ) const#

Check if two palettes are the same.

Arguments

  • const float (&)[12] palette - The second palette represented by an array of 12 float values.

Return value

Returns true if the palettes are the same; otherwise, false.

bool operator== ( float value ) const#

Check if all values of the palette are equal to the given value.

Arguments

  • float value - The value to check.

Return value

Returns true if all values of the palette are equal to the given value; otherwise, false.

bool operator!= ( const Palette & palette ) const#

Check if two palettes are not the same.

Arguments

  • const Palette & palette - The second palette.

Return value

Returns true if the palettes are not the same; otherwise, false.

bool operator!= ( const float (&)[] palette ) const#

Check if two palettes are not the same.

Arguments

  • const float (&)[] palette - The second palette represented by an array of 12 float values.

Return value

Returns true if the palettes are not the same; otherwise, false.

bool operator!= ( float value ) const#

Check if all values of the palette are not equal to the given value.

Arguments

  • float value - The value to check.

Return value

Returns true if any value of the palette is not equal to the given value; otherwise, false.

void clear ( float value = 0.0f ) #

Sets all color values to the given value.

Arguments

  • float value - The new value.

void copy ( const Palette & src ) #

Copies all values from the given palette.

Arguments

  • const Palette & src - The source palette.
Last update: 24.11.2020
Build: ()