Documentation
Reuse + Store rollup |
The Reuse + Store rollup has 2 main usages:
For V-Ray the rollup also allows to write to a RenderElement directly, see the different descriptions for V-Ray and
mental ray below.
In general RichDirt supports saving values to an image (false color, red is used for AO, green is used for IO).
These saved images can be later read from disc, instead of having to regenerate the effects by shooting rays.
This can add a huge speedup to rendering
How to get the image saved ?
V-Ray supports direct access to Render Elements from RichDirt. Switch on either ´V-Ray: write to vrayextratex render element ´ or ´V-Ray: write false color to vrayextratex render element´. Then RichDirt writes both to the main image and the the RenderElement. False color images can be used later for "load from image file", instead of shooting rays.
You also need to add a Extratex Render Element: Render Setup - Render Elements - add "VRayExtraTex". If you have multiple Render Elements of type VRayExtraTex , all of them are filled. If you also use RichScene and create Render Elements from RichScene at the same time results are added to the RichScene buffers as well.
To save the VRayExtraTex make sure to check the gamma of the file. Often you need to manually set it to 1.0 in the 3ds Max image save dialog. This is due to differences in file formats. For example if you store twice as 8b-bit rla and say once gamma 1.0 and once gamma 2.2 you will later get a good result with gamma 1. Gamma 2.2 however will make midtones of dirt weaker. This can be confusing as one might expect that saving with gamma 2.2 would change pixels in the image file, but it doesnt. Gamma 2.2 is only added like a "comment". Later when the file is loaded this makes a difference as pixel values are de-gammaed with 2.2 so you suddenly get a change. There is no general solution to this, as file formats have different specs for gamma (apply to pixel values or not). Simply make a test with your favorite image format. 3ds Max documentation says that 32 bit by default uses gamma 1.0 which should handle everything smoothly, but ... jpeg for example does not have a 32 bit version. Testing jpg with Max 2017 saving to jpg with default settings creates to short dirt, because on load it pretends to be 2.2. If you manually set gamma 1.0 (for jpeg) , 3ds Max changes the pixel values. So ... on load you get even shorter dirt. Try rla with gamma manually set to 1.0.
mental ray is a little tricky, a ´shader´ can not directly write to a 3ds Max Render Element. Starting with version 1.10 RichDirt checks if a ´named framebuffer´ called ´richdirt´ exists. Only use this path if you are technically very advanced. You will need a plugin to create so called ´geometry shaders ´ which in turn can be used to add a shader that then creates a named framebuffer. Autodesk did ship a plugin called mrGeomShaderObject.dlo with the maxsdk, for example in 2011 this was (C:\Program Files (x86)\Autodesk\Autodesk 3ds Max 2011 SDK\maxsdk\plugin\mrGeomShaderObject.dlo) this plugin allows to add a geometry shader to a 3dsmax scene. mental images (now NVidia) sponsored the website http://www.writingshaders.com/framebuffers.html for an example of a geometry shader that creates framebuffer. You would need a ´named´ framebuffer (not an ´indexed´ framebuffer). In case this is to tricky for you today - the easier way for mental ray users is to directly write the result to the main image (beauty image). Without any changes the main image would contain shadows, lights etc, which one doesn´t want here. Use the ´mental ray´ material, and paste an -instance- of the RichDirt texture into its ´surface´ slot.
Save falsecolor image via mental ray material |
This bypasses any shading like shadows, lights.
It is possible to use several mental ray materials, when using several RichDirt textures.
The easiest way is to enable the material globally in the ´Processing´ tab - use it for ´Material Override´.
enRichPro Copyright © All Rights Reserved