© Square Enix © Goodbye Kansas


Table of Contents

This page contains information about the V-Ray TexFloatOp node.


Overview


The V-Ray Float Operations texture performs mathematical operations on float values.


 

Parameters


A – Specifies float operand A.

B – Specifies float operand B.

Mode – Determines what output to use when no output parameter is specified. Useful if the type of the operation needs to be animated.

Product – Performs a multiplication operation and returns the product (A * B).
Ratio – Performs a division operation and returns the ratio (A : B).
Sum – Performs an addition operation and returns the sum (A + B).
Difference – Performs a subtraction operation and returns the difference (A - B).
Power – Performs an exponentiation operation and returns the power (A ^ B).
Sin – Performs a sine function and returns the result.
Cos – Performs a cosine function and returns the result.
Min – Performs a comparison and returns the minimum value.
Max – Performs a comparison and returns the maximum value.
abs – Outputs the absolute value of A.
ceil – Performs a ceiling function.
exp – Performs an exponential function.
floor – Performs a floor function.
log – Performs a natural logarithmic function.
log10 – Performs a common logarithmic function (base 10).
sqrt – Performs a square root function.
fmod – Performs a division operation and returns the remainder of A / B.
average – Returns the average of A and B.
tan – Performs a tangent function and returns the result.
asin – Performs an arcsine function and returns the result.
acos – Performs an arccosine function and returns the result.
atan – Performs an arctangent function and returns the result.
atan2 – Performs an arctangent function with two arguments and returns the result.
bias-schlick – Performs a faster bias approximation, described by Christophe Schlick, based on the original definition by Kenneth Perlin.1
gain-schlick – Performs a faster gain approximation, described by Christophe Schlick, based on the original definition by Kenneth Perlin.2
bias-perlin – Implements the original bias definition by Kenneth Perlin.3
gain-perlin – Implements the original gain definition by Kenneth Perlin.4



Bias and Gain Equations


The exact equations for the Christophe Schlick and Kenneth Perlin definitions are:

  1. bias_schlick(x, a) := x / ((1 / a - 2) * (1 - x) + 1)
  2. gain_shclick(x, a) :=
      { bias_schlick(2 * x, a) / 2 , if a < 0.5 }
      { (bias_schlick(2 * x - 1, 1 - a) + 1) / 2 , if a >= 0.5 }
  3. bias_perlin(x, a) := x ^ (ln(a) / ln(0.5))
  4. gain_perlin(x, a) :=
      { bias_perlin(2 * x, 1 - a) / 2 , if a < 0.5 }
      { 1 - bias_perlin(2 - 2 * x, 1 - a) / 2 , if a >= 0.5 }


References


[*] Kenneth Perlin and Eric M Hoffert. Hypertexture. SIGGRAPH, 1989.
[*] Christophe Schlick. Fast alternatives to Perlin’s bias and gain functions. Graphics Gems, 4, 1994