Expression operation. More...
Public Member Functions | |
KzuExpressionValidatorOperation (int value) | |
Constructs a KzuExpressionValidatorOperation of an integer value. | |
KzuExpressionValidatorOperation (KzuExpressionValidatorOperation enum_) | |
Constructs a copy of a KzuExpressionValidatorOperation object. | |
int | getValue () |
Returns the integer value of the enumeration constant. | |
final int | swigValue () |
Returns the integer value of the enumeration constant. | |
Static Public Member Functions | |
static KzuExpressionValidatorOperation | swigToEnum (int swigValue) |
Converts an integer value to the matching enumeration constant. | |
static KzuExpressionValidatorOperation | toEnum (int value) |
Converts an integer value to the matching enumeration constant. | |
Public Attributes | |
KZU_EXPRESSION_VALIDATOR_OPERATION_ABS =(6) | |
Absolute value: abs(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_ACOS =(50) | |
Arccosine: acos(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_ACQUIRE =(32) | |
Acquires a resource by a string. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_ADD =(1) | |
Addition: param1 + param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_APPEND_RANGE =(113) | |
Adds one item (param1) to a value range (param0): appendRange(ValueRange(1,2,3), 4) -> ValueRange(1,2,3,4) Ignores input ranges that are not a ValueRange: appendRange(SplitStringRange("1,2,3", ","), 4) -> ValueRange(4) Accepts null ValueRanges: appendRange(nullptr, 5) -> ValueRange(5) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_ASIN =(49) | |
Arcsine: asin(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_ATAN =(51) | |
Arctangent: atan(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_ATAN2 =(52) | |
2-argument arctangent: atan2(param1, param2) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_BITWISE_AND =(96) | |
Performs the logical AND operation on each pair of the corresponding bits of the binary representations of two integers: param1 & param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_BITWISE_LEFT_SHIFT =(99) | |
Shifts the bits in the binary representation of an integer (param1) to the left by a given number of positions (param2): param1 << param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_BITWISE_NOT =(95) | |
Inverts the bits of the binary representation of an integer: ~param1. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_BITWISE_OR =(97) | |
Performs the logical OR operation on each pair of the corresponding bits of the binary representations of two integers: param1 | param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_BITWISE_RIGHT_SHIFT =(100) | |
Shifts the bits in the binary representation of an integer (param1) to the right by a given number of positions (param2): param1 >> param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_BITWISE_XOR =(98) | |
Performs the logical exclusive or (XOR) operation on each pair of the corresponding bits of the binary representations of two integers: param1 ^ param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_CEIL =(9) | |
Round towards positive infinity: ceil(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_CLAMP =(60) | |
Clamp a value between a floor and a ceiling. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_COMPARE_EQUAL =(37) | |
Equal comparison. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_COMPARE_GREATER =(33) | |
Greater than comparison. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_COMPARE_GREATER_OR_EQUAL =(34) | |
Greater than or equal comparison. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_COMPARE_LESS =(35) | |
Less than comparison. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_COMPARE_LESS_OR_EQUAL =(36) | |
Less than or equal comparison. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_COMPARE_NOT_EQUAL =(38) | |
Not equal comparison. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_CONTINUE_IF =(110) | |
Stops executing a binding when the input parameter evaluates to false: continueIf(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_COS =(47) | |
Cosine: cos(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_CREATE_ITERATOR =(79) | |
Create iterator. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_CREATE_ROTATION =(20) | |
Create a rotation quaternion using Euler angles stored in param1, param2 and param3. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_CREATE_ROTATION_X =(21) | |
Create a rotation quaternion using X rotation Euler angle in param1. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_CREATE_ROTATION_Y =(22) | |
Create a rotation quaternion using Y rotation Euler angle in param1. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_CREATE_ROTATION_Z =(23) | |
Create a rotation quaternion using Z rotation Euler angle in param1. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_CREATE_VIEW =(80) | |
Create iterator. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_CROSS =(55) | |
Cross product: cross(param1, param2) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_DIVIDE =(4) | |
Division, param1 / param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_DOT =(54) | |
Dot product: dot(param1, param2) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_EVALUATE =(78) | |
Evaluate register contents. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_EXTRACT_EULER_X =(28) | |
Extract X rotation angle from rotation defined in param1. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_EXTRACT_EULER_Y =(29) | |
Extract Y rotation angle from rotation defined in param1. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_EXTRACT_EULER_Z =(30) | |
Extract Z rotation angle from rotation defined in param1. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_FLOOR =(10) | |
Round towards negative infinity: floor(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_GET_AMBIENT =(70) | |
Acquire operation for getAmbient(). | |
KZU_EXPRESSION_VALIDATOR_OPERATION_GET_CAMERA_NORMAL_MATRIX =(111) | |
Acquire operation for getCameraNormalMatrix(). | |
KZU_EXPRESSION_VALIDATOR_OPERATION_GET_CAMERA_POSITION =(69) | |
Acquire operation for getCameraPosition(). | |
KZU_EXPRESSION_VALIDATOR_OPERATION_GET_CAMERA_WORLD_MATRIX =(66) | |
Acquire operation for getCameraWorldMatrix(). | |
KZU_EXPRESSION_VALIDATOR_OPERATION_GET_COLUMN =(108) | |
Gets a column vector in a matrix: getColumn(matrix, index) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_GET_CURRENT_VALUE =(31) | |
Gets the current value of the target. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_GET_FIELD =(57) | |
Get a field by index from a vector or matrix type or an indexed range. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_GET_NORMAL_MATRIX =(68) | |
Acquire operation for getNormalMatrix(). | |
KZU_EXPRESSION_VALIDATOR_OPERATION_GET_PROJECTION_CAMERA_WORLD_MATRIX =(65) | |
Acquire operation for getProjectionCameraWorldMatrix(). | |
KZU_EXPRESSION_VALIDATOR_OPERATION_GET_ROW =(106) | |
Returns a row vector in a matrix: getRow(matrix, index) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_GET_VIEW_POSITION =(76) | |
Acquire operation for getViewPosition(). | |
KZU_EXPRESSION_VALIDATOR_OPERATION_GET_WORLD_MATRIX =(67) | |
Acquire operation for getWorldMatrix(). | |
KZU_EXPRESSION_VALIDATOR_OPERATION_HSL_TO_SRGB =(101) | |
Converts an HSL color to SRGB. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_INVALID =(-1) | |
Invalid operation for placeholder purposes. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_INVERSE =(56) | |
Inversion. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_LENGTH =(104) | |
Returns the length of a vector: length(vector) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_LINEAR_TO_SRGB =(72) | |
Linear to sRGB color conversion operation. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_LINEARSTEP =(62) | |
Apply linearstep interpolation between two values. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_LOGICAL_AND =(39) | |
Greater or equal comparison. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_LOGICAL_NOT =(41) | |
Greater or equal comparison. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_LOGICAL_OR =(40) | |
Greater or equal comparison. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_LOOK_AT_CONSTRAINT =(258) | |
Orients SRT3D transformation in param1 to look at position specified by param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_MAX =(8) | |
Maximum value: max(param1, param2) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_MIN =(7) | |
Minimum value: min(param1, param2) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_MIX =(61) | |
Apply linear interpolation between two values. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_MODULO =(5) | |
Modulo: param1 mod param2 NOTE: This is the actual modulo operation, not remainder. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_MULTIPLY =(3) | |
Multiplication: param1 * param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_NORMALIZE =(105) | |
Normalizes a vector: normalize(vector) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_ORIENTATION_CONSTRAINT =(257) | |
Locks rotation component of SRT3D transformation param1 to position component of param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_POSITION_CONSTRAINT =(256) | |
Locks position component of SRT3D transformation param1 to position component of param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_POW =(12) | |
Exponent: pow(param1, param2) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_PREMULTIPLY_COLOR =(75) | |
Transpose a matrix. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_PROCESSOR =(512) | |
Processor operator is a special case. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_PROCESSOR_0 =(512) | |
Convenience identifier for first operation processor. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_PROCESSOR_1 =(513) | |
Convenience identifier for second operation processor. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_PROCESSOR_2 =(514) | |
Convenience identifier for third operation processor. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_PROCESSOR_3 =(515) | |
Convenience identifier for fourth operation processor. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_REMAINDER =(19) | |
Remainder: param1 % param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_REVERSED_CYLINDRICAL_LOOK_AT_CONSTRAINT =(260) | |
Orients SRT3D transformation in param2 to look at position specified by param1. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_REVERSED_LOOK_AT_CONSTRAINT =(259) | |
Orients SRT3D transformation in param2 to look at position specified by param1. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_ROTATE =(24) | |
Rotate param1 by rotation defined in param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_ROTATE_X =(25) | |
Rotate param1 by X rotation defined in param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_ROTATE_Y =(26) | |
Rotate param1 by Y rotation defined in param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_ROTATE_Z =(27) | |
Rotate param1 by Z rotation defined in param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_ROUND =(11) | |
Round towards nearest integer or away from zero if halfway: round(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_SET_COLUMN =(109) | |
Sets a column vector in a matrix: setColumn(matrix, index, vector) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_SET_FIELD =(58) | |
Set a field by index in a vector or matrix type or an indexed range. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_SET_ROW =(107) | |
Sets a row vector in a matrix: setRow(matrix, index, vector) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_SIGN =(103) | |
Returns the sign of a number: sign(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_SIN =(46) | |
Sine: sin(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_SINC =(53) | |
Sinc: sinc(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_SMOOTHERSTEP =(64) | |
Apply smootherstep interpolation between two values. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_SMOOTHSTEP =(63) | |
Apply smoothstep interpolation between two values. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_SPLIT =(77) | |
Split input into a range. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_SQRT =(13) | |
Square root: sqrt(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_SRGB_TO_HSL =(102) | |
Converts an SRGB color to HSL. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_SRGB_TO_LINEAR =(73) | |
Linear to sRGB color conversion operation. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_STEP =(14) | |
Step function of param1 to param2 border. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_STRING_FORMAT =(112) | |
Calls the string formatting function with a format string from (param1) and format arguments from the range parameter (param2): stringFormat("foo: {}, bar: {}", ValueRange("baz", 3)) -> ("foo: baz, bar: 3"). | |
KZU_EXPRESSION_VALIDATOR_OPERATION_SUBTRACT =(2) | |
Subtraction: param1 - param2. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TAN =(48) | |
Tangent: tan(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TERNARY_CONDITIONAL =(71) | |
Ternary conditional (select) operation. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TEXTURE_GET_ADDRESSING_MODE =(89) | |
Gets the addressing mode of a texture: textureGetAddressingMode(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TEXTURE_GET_ANISOTROPY_LEVEL =(93) | |
Gets the anisotropy level of a texture: textureGetAnisotropyLevel(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TEXTURE_GET_DEPTH_COMPARE_FUNCTION =(90) | |
Gets the depth compare function of a texture: textureGetDepthCompareFunction(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TEXTURE_GET_FILTER_MODE =(91) | |
Gets the filter mode of a texture: textureGetFilterMode(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TEXTURE_GET_HEIGHT =(86) | |
Gets the height of a texture: textureGetHeight(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TEXTURE_GET_MIPMAP_MODE =(92) | |
Gets the mipmap mode of a texture: textureGetMipmapMode(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TEXTURE_GET_MULTISAMPLE_LEVEL =(94) | |
Gets the multisample level of a texture: textureGetMultisampleLevel(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TEXTURE_GET_PIXEL_FORMAT =(88) | |
Gets the pixel format of a texture: textureGetPixelFormat(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TEXTURE_GET_SIZE =(87) | |
Gets the size of a texture: textureGetSize(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TEXTURE_GET_WIDTH =(85) | |
Gets the width of a texture: textureGetWidth(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TO_BOOL =(15) | |
Converts to boolean: bool(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TO_COLOR4 =(81) | |
Converts to Color: color(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TO_FLOAT =(17) | |
Converts to float: float(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TO_INT =(16) | |
Converts to integer: int(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TO_MATRIX3x3 =(42) | |
Converts to string: matrix3x3(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TO_MATRIX4x4 =(43) | |
Converts to string: matrix4x4(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TO_SRT2D =(44) | |
Converts to string: srt2d(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TO_SRT3D =(45) | |
Converts to string: srt3d(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TO_STRING =(18) | |
Converts to string: to_string(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TO_VECTOR2 =(82) | |
Converts to Color: color(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TO_VECTOR3 =(83) | |
Converts to Color: color(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TO_VECTOR4 =(84) | |
Converts to Color: color(param1) | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TRANSFORM =(59) | |
Transforms a vector by a same-sized matrix. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_TRANSPOSE =(74) | |
Transpose a matrix. | |
KZU_EXPRESSION_VALIDATOR_OPERATION_WRITE =(0) | |
Simple write operation. | |
Expression operation.
Each operation in an expression binding is identified by an integer operation code.
All operations that can be executed component-wise are executed per-component. For example, the
division of two vector2 components is [param1.x / param2.x, param1.y / param2.y]. The same applies to
single-parameter operations. For example, absolute value is [abs(param1.x), abs(param1.y)].
You can define arguments specifying an arbitrary rotation as either SRT3D Euler rotations or quaternions.
Operations are encoded as follows:
Operation codes from the binary use only the first byte: 0-255.
Engine-only operations, e.g. constraints use 256 and the first byte: 256-511.
Animation validators use 512 and the first byte: 512-767
Since only the operation codes come from the binary format, the remaining values can be mapped anywhere
without breaking loading.
The encoding intentionally ensures only 16 bits are needed for the enumeration.
KzuExpressionValidatorOperation | ( | int | value | ) |
Constructs a KzuExpressionValidatorOperation of an integer value.
value | Integer value to convert to enumeration constant. |
Constructs a copy of a KzuExpressionValidatorOperation object.
enum_ | KzuExpressionValidatorOperation to be copy constructed. |
int getValue | ( | ) |
|
static |
Converts an integer value to the matching enumeration constant.
Used internally by SWIG generated code.
swigValue | Integer value to convert to enumeration constant. |
Returns the integer value of the enumeration constant.
Used internally by SWIG generated code.
|
static |
Converts an integer value to the matching enumeration constant.
value | Integer value to convert to enumeration constant. |
KZU_EXPRESSION_VALIDATOR_OPERATION_GET_CURRENT_VALUE =(31) |
Gets the current value of the target.
This operation has no parameters, but it returns the value of the binding target before modifications.
Used by modifier bindings.
KZU_EXPRESSION_VALIDATOR_OPERATION_MODULO =(5) |
Modulo: param1 mod param2
NOTE: This is the actual modulo operation, not remainder.
KZU_EXPRESSION_VALIDATOR_OPERATION_POSITION_CONSTRAINT =(256) |
Locks position component of SRT3D transformation param1 to position component of param2.
Values beyond this point are NOT shared in the binary format and are unknown to Studio, only being internal to the engine.
KZU_EXPRESSION_VALIDATOR_OPERATION_PROCESSOR =(512) |
Processor operator is a special case.
The OpCode refers to index of an expression processor, which points to a different array than the regular binding processors.
To get the referred processor index from the operation code, subtract the base value.
KZU_EXPRESSION_VALIDATOR_OPERATION_REVERSED_CYLINDRICAL_LOOK_AT_CONSTRAINT =(260) |
Orients SRT3D transformation in param2 to look at position specified by param1.
The orientation is calculated in cylindrical fashion. Up vector always points to positive Y axis.
KZU_EXPRESSION_VALIDATOR_OPERATION_STEP =(14) |
Step function of param1 to param2 border.
1 if param1 >= param2, 0 otherwise