Material Definition Language API nvidia_logo_transpbg.gif Up
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
mi::neuraylib::Target_function_description Struct Reference

Description of target function. More...

Public Attributes

const char * path
 The path from the material root to the expression that should be translated, e.g., "surface.scattering". More...
 
const char * base_fname
 The base name of the generated functions. If NULL is passed, the function name will be 'lambda' followed by an increasing counter. Note, that this counter is tracked per link unit. That means, you need to provide functions names when using multiple link units in order to avoid collisions. More...
 
Size argument_block_index
 The index of argument block that belongs to the compiled material the function is generated from or ~0 if none of the added function required arguments. It allows to get the layout and a writable pointer to argument data. This is an output parameter which is available after adding the function to the link unit. More...
 
Size function_index
 The index of the generated function for accessing the callable function information of the link unit or ~0 if the selected function is an invalid distribution function. ~0 is not an error case, it just means, that evaluating the function will result in 0. In case the function is a distribution function, the returned index will be the index of the init function, while sample, evaluate, and pdf will be accessible by the consecutive indices, i.e., function_index + 1, function_index + 2, function_index + 3. This is an output parameter which is available after adding the function to the link unit. More...
 
ITarget_code::Distribution_kind distribution_kind
 Return the distribution kind of this function (or NONE in case expressions). This is an output parameter which is available after adding the function to the link unit. More...
 
Sint32 return_code
 A return code. For the meaning of the error codes correspond to the codes add_material_expression (code * 10) and add_material_df (code * 100). 0: Success. ~0: The function has not yet been processed -1: Invalid parameters (NULL pointer). -2: Invalid path (non-existing). -7: The backend does not implement this function, yet. More...
 

Detailed Description

Description of target function.