Allows to bake a varying or uniform expression of a compiled material into a texture or constant. More...
#include <imdl_distiller_api.h>
Public Member Functions | |
virtual const char * | get_pixel_type () const =0 |
Returns the pixel type that matches the expression to be baked best. More... | |
virtual bool | is_uniform () const =0 |
Indicates whether the expression to be baked is uniform or varying. More... | |
virtual Sint32 | bake_texture (ICanvas *texture, Uint32 samples=1) const =0 |
Bakes the expression as texture. More... | |
virtual Sint32 | bake_constant (IData *constant, Uint32 samples=1) const =0 |
Bakes the expression as constant. More... | |
![]() | |
virtual Uint32 | retain () const =0 |
Increments the reference count. More... | |
virtual Uint32 | release () const =0 |
Decrements the reference count. More... | |
virtual const IInterface * | get_interface (const Uuid &interface_id) const =0 |
Acquires a const interface from another. More... | |
template<class T> | |
const T * | get_interface () const |
Acquires a const interface from another. More... | |
virtual IInterface * | get_interface (const Uuid &interface_id)=0 |
Acquires a mutable interface from another. More... | |
template<class T> | |
T * | get_interface () |
Acquires a mutable interface from another. More... | |
virtual Uuid | get_iid () const =0 |
Returns the interface ID of the most derived interface. More... | |
Additional Inherited Members | |
![]() | |
typedef Interface_declare< id1, ... > | Self |
Own type. More... | |
typedef Uuid_t< id1, ... > | IID |
Declares the interface ID (IID) of this interface. More... | |
![]() | |
typedef Uuid_t<0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0> | IID |
Declares the interface ID (IID) of this interface. More... | |
![]() | |
static bool | compare_iid (const Uuid &iid) |
Compares the interface ID iid against the interface ID of this interface and of its ancestors. More... | |
![]() | |
static bool | compare_iid (const Uuid &iid) |
Compares the interface ID iid against the interface ID of this interface. More... | |
Allows to bake a varying or uniform expression of a compiled material into a texture or constant.
|
pure virtual |
Bakes the expression as constant.
constant | An instance of mi::IData of suitable type such that the baked constant can be stored in this argument. For pixel types "Float32" and "Float32<3>" the type name of this argument needs to match the pixel type. For pixel type "Rgb_fp" this argument needs to have the type name "Color" . |
samples | The (total) number of samples. |
NULL
pointer).constant
does not match the pixel type corresponding to the expression to be baked.
|
pure virtual |
Bakes the expression as texture.
texture | The baked texture will be stored in this canvas. If the pixel type of canvas does not match the pixel type of the expression to be baked (as indicated by get_pixel_type()), then the pixel data is converted as described in mi::neuraylib::IImage_api::convert(). |
samples | The number of samples (per pixel). |
NULL
pointer).
|
pure virtual |
Returns the pixel type that matches the expression to be baked best.
|
pure virtual |
Indicates whether the expression to be baked is uniform or varying.
Typically, varying expressions are baked into textures, and uniform expressions into constant. However, it is also possible to do it the other way round.