TextureEvaluator

References
This is the interface to a lightweight object capable of evaluating texture color throughout uvw space. Derive from this class to create your own texture evaluator to return from a custom RenderTexture.

Constructors

TextureEvaluator

#
Base class constructor
protected TextureEvaluator()

TextureEvaluator

#
Base class constructor
protected TextureEvaluator(
evaluatorFlags
)

Finalizer

~TextureEvaluator

#
For Dispose pattern
~TextureEvaluator()

Methods

Dispose

#Since v5.1
For Dispose pattern
public void Dispose()

Dispose

#
For Dispose pattern
protected virtual void Dispose(
disposing
)

GetColor

#Since v7.0
Optimized version of GetColor for callers. Much faster in the case of a native (C++) evaluator.
public bool GetColor(
uvw,
is the point for which to evaluate the texture.
duvwdx,
duvwdx is a ray differential.
duvwdy,
duvwdy is a ray differential.
ref Color4f
color
The texture color at this point in UV space.
)
True if the evaluator returned a valid color. Otherwise false.

GetColor

#Since v5.1
Get the color of the texture at a particular point in uvw space. May be called from within a rendering shade pipeline. note For ray differentials see Pharr Humphreys, "Physically Based Rendering", chapter 11.
public virtual Color4f GetColor(
uvw,
is the point for which to evaluate the texture.
duvwdx,
duvwdx is a ray differential.
duvwdy
duvwdy is a ray differential.
)
The texture color at this point in UV space.

Initialize

#Since v6.0
Call this function before calling GetColor for the first time. Ideally, this should be on the main thread, but you can also call it on a worker thread as long as you are sure that Initialize() or GetColor() cannot be called at the same time on another thread.
public virtual bool Initialize()

WriteToByteArray

#Since v7.0 Obsolete v7.26
Fast access to bitmap evaluator - supply size (which you will probably have received from CRhRdkTexture::PixelSize) to see if the data can be extracted direct to a width*height*4 array of unsigned chars.
public virtual SimpleArrayByte WriteToByteArray(
width,
is the point for which to evaluate the texture.
height
duvwdx is a ray differential.
)
obsoleteUse WriteToByteArray2 instead - supports much larger byte arrays
A ByteArray full of the byte values in RGBA order, or null if the function did not succeed

WriteToByteArray2

#Since v7.0
Fast access to bitmap evaluator - supply size (which you will probably have received from CRhRdkTexture::PixelSize) to see if the data can be extracted direct to a width*height*4 array of unsigned chars.
public virtual StdVectorByte WriteToByteArray2(
width,
is the point for which to evaluate the texture.
height
duvwdx is a ray differential.
)
A ByteArray full of the byte values in RGBA order, or null if the function did not succeed

WriteToFloatArray

#Since v7.0 Obsolete v7.26
Fast access to bitmap evaluator - supply size (which you will probably have received from CRhRdkTexture::PixelSize) to see if the data can be extracted direct to a width*height*4 array of unsigned chars.
public virtual SimpleArrayFloat WriteToFloatArray(
width,
is the point for which to evaluate the texture.
height
duvwdx is a ray differential.
)
obsoleteUse WriteToFloatArray2 instead - supports much larger byte arrays
A FloatArray full of the float values in RGBA order, or null if the function did not succeed.

WriteToFloatArray2

#Since v7.0
Fast access to bitmap evaluator - supply size (which you will probably have received from CRhRdkTexture::PixelSize) to see if the data can be extracted direct to a width*height*4 array of unsigned chars.
public virtual StdVectorFloat WriteToFloatArray2(
width,
is the point for which to evaluate the texture.
height
duvwdx is a ray differential.
)
A FloatArray full of the float values in RGBA order, or null if the function did not succeed.