Cyclone 3DR Script
from Technodigit, part of Hexagon. Copyright 1997-2022.
 
Loading...
Searching...
No Matches
SColorGradient.h
1
2
3
5
6#pragma once
7
8#include "RshPluginScript/RshPluginScriptDefines.h"
9#include "RshPluginScript/SClass/SObject.h"
10
11#ifndef FCT_DOC
12namespace rsh::ScriptBinding
13{
14#endif // !FCT_DOC
15
22class SColorGradient : public SObject
23{
24 //======================================================================================================================
25 // INTERNAL FUNCTION
26 //======================================================================================================================
27 //======================================================================================================================
28 // DOCUMENTED FUNCTION
29 //======================================================================================================================
30
31public:
36 {
37 HIDE,
39 SHOW_FOREGROUND,
41 SHOW_BACKGROUND,
43 };
44
48 {
54 };
55
56public slots:
57
62 // TESTED
64
67 SetMagnification(Number magnification
69 );
70
77 // TESTED
78 Array SetRange(
79 Number MinValue,
81 Number MaxValue
83 );
84
89 // TESTED
90 Array GetRange();
91
97 // TESTED
99 Number Index,
101 Number Red,
103 Number Green,
105 Number Blue,
107 Number Alpha = -1
109 );
110
116 // TESTED
118 Number Index,
120 Number Red,
122 Number Green,
124 Number Blue,
126 Number Alpha = -1
128 );
129
142 Array GetCursorInfo(Number Index);
143
153 // TESTED
154 Array AddCursor(Number Position);
155
164 // TESTED
165 Array DeleteCursor(Number Index);
166
178 // TESTED
179 Array SetCursorPos(Number Index, Number Position);
180
183 // TESTED
185 Number Red,
187 Number Green,
189 Number Blue,
191 Number Alpha = -1
193 );
194
200 // TESTED
202
205 // TESTED
207
214 // TESTED
215 Array SetNbCursor(Number NbCursor
217 );
218
221 // TESTED
222 Number GetNbCursor();
223
226 // TESTED
228
237 Array GetColorFromValue(Number value);
238
241 String toString() ;
242};
243
244Q_DECLARE_METATYPE(SColorGradient::_SColorGradientDummy);
245
246#ifndef FCT_DOC
247} // namespace rsh::ScriptBinding
248#endif // !FCT_DOC
The SColorGradient class allow the user to edit a color gradient. You cannot create a new color gradi...
Definition: SColorGradient.h:23
String toString()
Get the type of the variable.
Array SetCursorPos(Number Index, Number Position)
To set position of an indexed peg.
Array SetNbCursor(Number NbCursor)
To set the number of cursors of the color gradient You can set from 2 cursors to GetNbCursorMax() cur...
Array GetCursorInfo(Number Index)
To get cursor information.
SetMagnification(Number magnification)
You can set the magnification (only for polyline inspection)
Array GetColUndefined()
To get the undefined color of the color gradient.
DisplayFlag
Available options for the display of the gradient palette Use SColorGradient.HIDE.
Definition: SColorGradient.h:36
Array DeleteCursor(Number Index)
Remove a peg of the color gradient.
Array SetColBefore(Number Index, Number Red, Number Green, Number Blue, Number Alpha=-1)
To set the color of a cursor before the value of the cursor.
Number GetNbCursor()
SetDisplayOption(DisplayFlag DisplayPalette)
You can choose how the palette will be displayed.
Array GetColorFromValue(Number value)
To color from a specific value in the gradient.
Number GetNbCursorMax()
SetInterpolation(Interpolation Method)
To define how the color is interpolated between 2 cursors.
Array SetColAfter(Number Index, Number Red, Number Green, Number Blue, Number Alpha=-1)
To set the color of a cursor after the value of the cursor.
Array GetRange()
To get the maximal and minimal value of the color gradient.
SetColUndefined(Number Red, Number Green, Number Blue, Number Alpha=-1)
To set the undefined color of the color gradient.
Interpolation
Interpolation method to define how the color is interpolate between two cursors.
Definition: SColorGradient.h:48
@ HSLLongest
Definition: SColorGradient.h:53
@ HSLShortest
Definition: SColorGradient.h:52
@ HSLCounterClockwise
Definition: SColorGradient.h:50
@ HSLClockwise
Definition: SColorGradient.h:51
@ Linear
Definition: SColorGradient.h:49
Array SetRange(Number MinValue, Number MaxValue)
To update the min and max values of the color gradient, and delete all invalid pegs.
Array AddCursor(Number Position)
Add a new cursor in the color gradient.
This class is an abstract class, you can use these function in its derived classes.
Definition: SObject.h:35