Ever wanted to know where your mental ray render spends all its time? Trying to optimise your mental ray render but there are two many options
and you do not get enough feedback then mrProfiler might be the utility shader you are looking for. mrProfiler is a profiling shader that
is totally non-intrusive to the render process itself. This means it works with all standard and third-party mental ray shaders including material,
light, photon, lens shaders, etc. While it is rendering you will even see the normal render output just at the very end the image will
be overwritten with a different output.
mrProfile produces as output a heatmap and a threadmap of the rendering process. The heatmap shows visually the amount of
time spend for each individual pixel in the image showing clearly which bits in the image take very long or no time at all. Each pixel
displayed in the heatmap is the addition of the time of all the samples that were used to generate the final color of that pixel.
The mrProfiler shader lets you control the color distribution in the heatmap and set the minimum and maximal threshold (in milliseconds)
or let it automatically scale to the maximum time used for an individual pixel.
The threadmap which is stored in the alpha channel in the output image shows the distribution of different threads spanned by mental ray
to render the output image. The number of threads in the image does surprisingly not necessarily correspond to the amount of CPU or
hardware threads available on your machine. The mental ray message window of your application will contain additional output information
produced by mrProfiler to further understand how many threads were used in the image so it is easier to understand the color coding
in the threadmap. Each grey value in the image corresponds to one thread number. The occupied area typically will follow the task
(bucket) size set in the rendering setting.
