Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 4 Next »

Almost all the render parameters can be passed to the render as command line options as well. It is mandatory that the plug-in provides a command line text field to let the user add additional render options. In this way, it is not needed to update the plug-in each time a new parameter is added, and in addition other useful flags can be passed to the render.

Paths

Paths are specified through the setPath() function:

void Cmaxwell::setPath(
                         const char* type,     // path type
                         const char* path,     // path name
                         byte& outputBitDepth  // Bit depth per plane
                      (
  • outputBitDepth specifies the bits depth per plane (8,16,32). This parameter is passed by reference so if the current format does not support the given depth, the SDK tries to change it automatically.
  • type must be one of the following values: "RENDER", "ALPHA", "SHADOW", "OBJECT", "MATERIAL", "MOTION", "Z", "ROUGHNESS", "FRESNEL".

Example:

byte depth = 32;
byte ok;
ok = setPath ("RENDER", "C:\\maxwell\\house.exr", 32);  //Correct, EXR format supports 32 bbp.
ok = setPath ("RENDER", "C:\\maxwell\\house.jpg", 16);  //Incorrect, JPG does support 16 bbp so it will be changed to 8 bpp internally.

Additional paths used for searching textures and other dependencies can be specified through:

byte addSearchingPath( const char *pPath );

Render parameters

Global settings of Maxwell Render are set using the function:

byte Cmaxwell::setRenderParameter(
                                   const char* parameterName, // parameter name
                                   dword size, // parameter size
                                   void* parameterData // parameter data
                                 );


Parameters description (parameterName/size/description)

Paths
"MXI FULLNAME" / 0 / char* name: Path of the MXI output file
"SAVE LIGHTS IN SEPARATE FILES" / byte / 0: Save all the lights embedded it the same. 1: Embed all in the same file if the format supports it

Render parameters
"STOP TIME" / dword / default:120 / maximum render time in minutes
"SAMPLING LEVEL" / float / default:25 / maximum sampling level
"NUM THREADS" / dword / default:0 (Automatic) Number of threads.
"ID CPU" / dword / Seed used in the render.
"USE MULTILIGHT" / byte / default: 0 Enable MultiLight
"DO MOTION BLUR" / byte / default: 1 Motion blur on/off
"DO DISPLACEMENT" / byte / default: 1 Displacement on/off
"DO DISPERSION", / byte / default: 1 Dispersion on/off

Simulens
"DO VIGNETTING" / byte / default: 1 Vignetting on/off
"VIGNETTING" / real / default: 1 Vignetting value
"DO SCATTERING LENS" / byte / default: 1 Scattering on/off
"SCATTERING LENS" / real / default: 1 Scattering value

Channels
"DO IDOBJECT CHANNEL" / byte / default: 0 Do Object ID channel
"DO IDMATERIAL CHANNEL" / byte / default: 0 Do Material ID channel
"DO SHADOW PASS CHANNEL" / byte / default: 0 Do Shadow pass channel
"DO RENDER CHANNEL / byte / default: 1 Do render channel
"DO ALPHA CHANNEL" / byte / default: 0 Do alpha channel
"OPAQUE ALPHA" / byte / default: 0 Do alpha opaque
"DO MOTION CHANNEL" / byte / default: 0 Do motion channel
"DO ROUGHNESS CHANNEL" / byte / default: 0 Do roughness channel
"DO FRESNEL CHANNEL" / byte / default: 0 Do fresnel channel
"DO ZBUFFER CHANNEL" / byte / default: 0 Do zbuffer channel
"ZBUFFER RANGE" / 2*real / -a, +b Set the zbuffer range using two values (a) and (b) which are negative and positive distances (-a, +b) from a reference location centred on the focalpoints.
"EMBED CHANNELS" / byte / : 0 Save channels in separate files. 1: Embed them in the same image if the format supports it

Layers
"DO DIRECT LAYER" / byte / default: 1 Calculate direct layer
"DO INDIRECT LAYER" / byte / default: 1 Calculate indirect layer
"DO DIRECT REFLECTION CAUSTIC LAYER" / byte / default: 1 Calculate direct reflection caustic layer
"DO DIRECT REFRACTION CAUSTIC LAYER" / byte / default: 1 Calculate direct refraction caustic layer
"DO INDIRECT REFLECTION CAUSTIC LAYER" / byte / default: 1 Calculate indirect reflection caustic layer
"DO INDIRECT REFRACTION CAUSTIC LAYER" / byte / default: 1 Calculate indirect refraction caustic layer

Tonemapping

Tonemapping used for converting from 32 bits high dynamic range to depths displayable by screen devices (typically 8 bits) is set through the function:

byte Cmaxwell::setToneMapping(
                               real monitorGamma, // monitor gamma (2.2)
                               real burn // burn (0.5)
                             );
  • No labels