Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Section
Column
width50%

The VRayAColorOp texture performs an arithmetic operation between two colors and/or textures. This texture is useful for blending textures and colors without the need for a separate V-Ray Blend material.

In the example here, the candle holder is shaded with a V-Ray Material that is set up to imitate brass.  We also add a Coat layer, where we apply a VRayAColorOp texture. For Color A, we apply a V-Ray Curvature texture and set its Mode to Concave. For Color B, we add a green-blue color to imitate patina. We set the Mode of the VRayAColorOp to Sum. This way, we have a base of a brass material, and we are adding a layer of a colored Curvature texture on top, which imitates weathering of the brass. Without the VRayAColorOp texture, we would need to create two separate materials - one for the brass and one for the patina and attach them to a V-Ray Blend material.

Column
width5%


candle_with_holder_TexA_hero_brassPatina_CoatON.Camera.jpg

Image Added

Column
width45%


Align
aligncenter
Image_comparison_slider
AddButtonsfalse
AttachmentImageBeforecandle_with_holder_TexA_hero_brass_CoatOFF.Camera.jpg
AttachmentImageAfter


Inputs

...

Section
Column
width50%

Color A – Specifies the first color. A Texture can also be applied, and it can be blended with the color using the Mix Strength parameter.

Mult A – A multiplier for Color A.

Color B – Specifies the second color. A Texture can also be applied, and it can be blended with the color using the Mix Strength parameter.

Mult B  A multiplier for Color B.

Alpha from Input – When enabled, the alpha value is derived from the Color A shader. In case the Mode is set to Result B, the alpha is derived from the Color B shader.

Result Alpha – Determines a value that overrides the alpha value in the output.

Mode – Specifies the calculation method for the two colors/textures. The selected mode determines the data being output when the Output parameter is set to Default

Result A – Returns the value of A (color_a*mult_a).
Result B
 – Returns the value of B (color_b*mult_b).
Product 
– Performs a multiplication operation and returns the product (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).
Division – Performs a division operation and returns the quotient (A/B).
Minimum – Performs a comparison and returns the minimum value.
Maximum – Performs a comparison and returns the maximum value.
Absolute Difference – Performs a subtraction operation and returns the difference as an absolute value (abs(A-B)).
Lower Intensity Color 
– Returns the value of whichever Color parameter has the lowest intensity.
Greater Intensity Color
 – Returns the value of whichever Color parameter has the greatest intensity.  

Sin – Performs a sine function and returns the result (sin(A)).
Cos – Performs a cosine function and returns the result (cos(A)).
Abs – Returns the absolute value of the first argument (abs(color_a*mult_a)
Ceil – Performs a ceiling function that rounds up to the next integer that is equal to or greater than the largest argument - A or B (ceil(A)); (ceil(B)).
Exp – Performs an exponential function (ea+b).
Floor – Performs a floor function that rounds down to the next integer that is equal to or smaller than the smallest argument - A or B (floor(A)); (floor(B)).
Log – Performs a natural logarithmic function (ln(A)).
Log 10 – Performs a common logarithmic function (base 10) on the first argument (log(A)).
Sqrt – Performs a square root function (√A).
Fmod – Performs a division operation and returns the remainder (A%B). 
Average – Returns the average of A and B (((color_a*mult_a)+(color_b*mult_b))/2).
Tan – Performs a tangent function and returns the result (tan(A.0)).
Asin – Performs an arcsine function and returns the result (asin(A).
Acos – Performs an arccosine function and returns the result (acos(A)).
Atan – Performs an arctangent function and returns the result (atan(A)).
Atan 2 – Performs an arctangent function with two arguments and returns the result (atan2(A,B)).
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

Column
width5%


Column
width45%

...