22.03.17 ver 3.5 beta 7
        - p_Hair: Initial version.
        - p_sss: Initial version.
        - p_flame: Initial version.
        - p_LightTK: Fixed crash with 'Light Category'.
        - p_Sheet: Added "Fresnel Roughness".
        - p_Sheet: Added 'Skip Specular Inside'.
        - p_Sheet: Added single scattering sss.
        - p_Sheet: Fixed tk_z pass.
        - p_Sheet: Minor optimizations.
03.04.16 ver 3.5 beta 5
        - Project: Updated to VC 2012.
        - p_Sheet: Fixed ignoring GPU_GI and GI_NEXT.
        - p_Sheet: Improved performance with 'Quality' > 1.
        - p_Sheet: Added 'Beckmann' distribution model for 'Glossy' and 'Reflection'.
        - p_Sheet: Minor optimizations.
30.12.15 ver 3.5 beta 4
        - p_Sheet: Minor optimizations.
        - p_Sheet: Added 'Ignore Bump' parameter for Occlusion and Indirect.
        - p_Sheet: Added 'Quality' parameter for Indirect.
        - p_Sheet: Fixed render of SpecialC passes with 'render_pass'.
14.12.15 ver 3.5 beta 3
        - p_Sheet: Minor optimizations.
        - p_Sheet: Added 'optimization_threshold' parameter.
        - p_Sheet: Added 'render_pass' parameter.
        - p_Sheet: Merged 'tk_indirect' and 'tk_ambient' pass.
        - p_Sheet: 'Incandenscence' renamed to 'Emission'.
        - p_Sheet: Increased quality of direct and indirect lighting.
30.11.15 ver 3.5 beta 2
        - p_Sheet: Some fixes for passes.
        - p_Sheet: Added predefined 'key' light category.
        - p_Sheet: Added 'tk_lights' pass. R=key light, B=rim light, G=other lights.
        - p_Sheet: Some GUI fixes.
24.11.15 ver 3.5 beta 1
        - p_physical_lens_dof: Added 'SpecialC11-20'.
        - p_grade_color: 'Invert' is moved bellow in a code.
        - p_grade_color: Added some checks.
        - p_HairTK: Added NaN check for passes.
        - p_HairTK: Light from Native IBL source handled like Indirect lighting.
        - p_HairTK: Now, Importance sampling controled by mi_shaderstate_set().
        - p_MegaTK: Added NaN check for passes.
        - p_MegaTK: Light from Native IBL source handled like Indirect lighting.
        - p_MegaTK: Now, Importance sampling controled by mi_shaderstate_set().
        - p_MegaTK: Added 'Opacity Mode' parameter for control ray type for opacity.
        - p_MegaTK: Added new diffuse, based on Disney shader formula.
        - p_MegaTK: Added 'SpecialC11-20'.
        - p_MegaTK: Added 'Clamp' and 'Clamp Value' parameters.
        - p_MegaTK: Added 'Passes in Refract' parameter.
        - p_mix: Fixed passes.
        - p_mix: Optimized performance for Mix mode.
        - p_ray_marcher: Initial version.
        - p_Sheet: Initial version.
05.06.14 ver 3.4 beta 8
        - p_HairTK: Fixed self shadowing introduced in beta 7
        - p_MegaTK: Improved NaN fixer, Win only
16.03.14 ver 3.4 beta 7
        - p_HairTK: Fixed Native IBL lighting
11.12.13 ver 3.4 beta 6
        - p_HairTK: Added importance sampling. It may improve performance up to 30% for hairs with transparency and trace shadow
        - p_MegaTK: Added importance sampling. It may improve performance up to 30% for complex tracing scenes
        - p_mix: Added p_mix shader. Work in progress
16.07.13 ver 3.4 beta 5
        - p_HairTK: Fixed possible bug with indirect (hair segment spots)
        - p_HairTK: mi_compute_irradiance() function is replaced with mi_compute_avg_radiance(), so no need divide IndirectColor to PI
        - p_MegaTK: Fixed possible bug with shadow flicking in reflection with incremental mi file
        - p_MegaTK: Restored original transparency mode (introduced in beta 4)
10.05.13 ver 3.4 beta 4
        - p_MegaTK: Added 'Propagate Alpha' option for refraction
        - p_MegaTK: Added 'Thin Walled' option for refraction
        - p_MegaTK: 'continue' and 'transparent' rays used for transparency now for better support standart mr passes(experemental)
        - p_HairTK: Added 'sRGB Variation' option for more uniform variations in sRGB space
        - p_HairTK: Fixed bug with negative value in hair color if some variations used (mostly for dark color). It may significantly improves the hair performance in such case
        - p_HairTK: Some minor optimizations for opaque hair
02.04.13 ver 3.4 beta 3
        - p_MegaTK: Fixed bug with incorrect IOR value for objects reflected in glass
        - p_MegaTK: Fixed bug with russian roulette optimization + Unified Sampling. Glass should be less noisy now
07.02.13 ver 3.4 beta 2
        - p_LightsTK: 'Emit Diffuse' and 'Emit Specular' are scalar now
        - p_MegaTK: All 'Metalness' parameters support value more than 1.0
        - p_math_output: Fixed bug with value more than 1.0 (introduced in 3.3 version), that may cause of damage of shadow pass
        - p_OpenEXR_saver: Switched to OpenEXR 1.7.1 library
15.10.12 ver 3.4 beta 1
        - p_MegaTK: mi_compute_irradiance() function is replaced with mi_compute_avg_radiance(), so no need divide IndirectColor to PI
        - p_MegaTK: Added 'Metalness' parameter for Phong, Blinn, Velvet and Fur specular models
        - p_MegaTK: Added 'Metalness' for reflection
        - Switched to VS2008
18.01.11 ver 3.3.1
        - p_hair_mapping: Fixed rare crash bug. Actually it's mental ray bug, state->bary[0] return NaN value
        - p_HairTK: Added experimental option 'FixShaveUV' for fix Shave texture mapping issue
        - p_HairTK: Fixed bug with NaN value in some passes with zero hair alpha
13.01.10 ver 3.3
        - Added p_shader_replacer shader (mostly for override shader on Fur)
        - p_MegaTK: Can be used as photonic shader (diffuse, opacity, reflect and refract)
        - p_MegaTK: Changed default value for 'Opacity Mode' from 'Alpha' to 'Average'(need for Maya's swatch)
        - p_MegaTK and p_HairTK: Added SpecialC5-SpecialC10 passes
        - p_scatter_wrap: Enabled the support for instance light lists (Mode 4)
        - p_scatter_wrap: Fixed bug with wrong light direction if 'Spread' == 0
        - p_scatter_wrap: Fixed NaN value if 'Max Scatter Distance' == 0
        - p_scatter_wrap: Improved sampling pattern for 'Shadow Blur'
        - p_HairTK: Added 'Color Variation' parameter
        - p_scatter_wrap: Added 'Thin Wall Translucence' effect
        - p_HairTK: Added 'Visible for FG' parameter
        - p_MegaTK: Fixed bug in 'Fur Diffuse' part. It may produce a little bit different result
        - Added p_dielectric_interface shader
        - p_motion_to_rgb: Added 'SmoothKit' and 'ReelSmart' mode
        - p_MegaTK: Fixed bug with NaN value in reflect/refract part. Fixed reflect/refract amount
        - p_HairTK: Added 'Coefficient Back Diffuse' parameter. Diffuse may be look different
        - p_HairTK: Added 'Saturation Variation' and 'Gain Variation' parameters
        - p_HairTK: Fixed possible bug with incorrect specular normal. Result may be different. Default deviation value was changed (to -0.25)
        - Added p_eye texture shader
        - p_MegaTK_pass: Fixed bug with resaving all frame images when incremental mi and p_OpenEXR_saver used
        - p_OpenEXR_saver: Added meta data to file (like camera matrix, focal, aperture...)
        - p_MegaTK and p_HairTK: Fixed crash with detail shadow in rare cases. Actually it's mental ray bug
        - p_HairTK: Fixed rare crash bug with rasterizer and raytracing enabled. Actually it's mental ray bug, state->bary[0] return NaN value
        - p_MegaTK_pass: Fixed possible crash if 'half' buffer type used with 'frame buffer gamma'. Now frame buffer is always 'float'. It's mental ray bug that was fixed in (Autodesk branch) and
        - p_math_output: Fixed possible 'inf' value
        - p_MegaTK: Added some optimization for final gather with bump if 'Ignore Bump' enabled
13.11.08 ver 3.2.2
        - p_HairTK: Fixed bug with very slow rendering with raytracing in scanline mode if used not TK lights
        - p_MegaTK: Fixed bug with very slow rendering with raytracing in scanline mode if used not TK lights
        - p_HairTK: Fixed bug with NaN value in incandescence pass
        - p_MegaTK: Fixed possible bug with NaN value in incandescence pass
        - p_HairTK: Fixed unneeded alpha premult for all passes in rasterizer mode
        - p_MegaTK: Fixed unneeded alpha premult for all passes in rasterizer mode
10.11.08 ver 3.2.1
        - p_HairTK: Fixed bug with strange dots with trasparency
        - p_HairTK: Transparency depth now limited only by 'Transparency Depth' in shader. 0 mean unlimited depth
        - p_HairTK: If 'Transparency Depth' reached full opaque hair used instead of multiplied to alpha (black tip)
        - p_HairTK: Some minor optimizations and fixes
        - p_MegaTK_pass: Now if 'Contrast All Buffers' disabled, it override value in options
        - p_HairTK: Fixed bug with very slow render with transparency in scanline mode if used not TK lights
24.10.08 ver 3.2
        - Finally removed p_saturation, p_fg_light and p_fg_no_light
        - Switched to new frame buffer API. Now used named buffers. Only mental ray and higher. According this change p_MegaTK, p_MegaTK_pass, p_math_output and p_OpenEXR_saver shaders was edited
        - In p_MegaTK_pass shader 'OpenEXR' renamed to 'OpenEXR (mi)'. Now exr is always multichannel (because of mental ray 3.6 change/limitation). In mental ray it crash if more than 8 buffers saved to same file (it's mental ray bug, will be fixed in future versions), please be carefull
        - Added 'Contrast All Buffers' option for p_MegaTK_pass shader. Warning, this option may dramatically slowdown render
        - For p_MegaTK shader enabled the support for instance light lists (Mode 4)
        - Added p_HairTK shader (still for test only)
        - Removed trick/hack code from p_LightTK and p_MegaTK, that may cause of error or crash in very rare case. This code replaced by mi_shaderstate_get() contruction
        - p_CSG shader works correct as shadow shader (only black shadow)
        - Added 'Swap AB' parameter for p_CSG shader
        - Added p_HairTK_shadow shader
        - Switched to OpenEXR 1.6.1 library. Added 'B44' and 'B44A' compressions
        - Added 'Visible in Reflect' and 'Visible in Refract' options for occlusion in p_MegaTK shader
        - Added 'Russian Roulette Level' option for p_MegaTK shader
        - Added 'Ignore Normals' option for Reflect/Refract of p_MegaTK shader
        - Added p_physical_lens_dof shader
        - Added 11 presets for p_MegaTK shader (Maya only)
        - Fixed possible memory leak in p_MegaTK_exit function
        - Added p_hair_mapping texture shader
        - Added 'Diffuse Roughness' parameter for p_MegaTK shader
        - Improved shader GUI in 3dsMax for some shaders. Possible enum menu unstable in Max :(
14.12.07 ver 3.1.2
        - Fixed bug in p_SpotTK. Area behind the spot cone not return TK. It may cause of unneeded lighting and incorrect passes.
        - Fixed bug in p_PointTK and p_SpotTK. Shadow may disappear if some components of light color equal zero (for example r=0.5 g=0.1 b=0.0)
        - Fixed bug in p_MegaTK shader with 'Fur' model (Maya only)
18.06.07 ver 3.1.1
        - Fixed bug with 'Attenuation' in p_shadow_transparency shader (attenuation did't work before)
        - Fixed bug with 'Bent Normal' pass in p_MegaTK shader under linux
        - Added '$ifndef "shaders_p_mi_included"' to mi file to avoid multiple inclusions
        - Fixed bug (artifacts in passes) in p_PointTK and p_SpotTK with 'Linear Distance' attenuation
12.05.07 ver 3.1
        - Added 'Reflection Falloff' and 'Refraction Falloff' to p_MegaTK
        - Added NaN remover to p_MegaTK, all NaN and infinite values will be replaced by zero
        - Fixed problem with basis vector in occlusion in p_MegaTK shader, now vector should be in world space
        - Added 'Inverse Transparency' to p_shadow_transparency shader
        - Added 'Opacity Mode' for occlusion in p_MegaTK shader
        - p_MegaTK shader can be used as shadow shader now
        - Added 'Ignore Bump' option for indirect illumination in p_MegaTK shader
        - Fixed problem with fresnel value more than 1, it happen before sometimes with bump
        - Fixed problem with 'Enable Filtering' option in p_MegaTK_pass shader. Before filtering always be enabled
        - Added p_grade_color shader
        - Added 'Absorbsion In' and 'Absorbsion Out' in p_MegaTK instead of 'Trasparency/Absorb'
        - Removed 'Fading Distance' in p_MegaTK and replaced with 'Falloff Start' and 'Falloff Stop' in reflect/refract
        - Added 'Falloff to Color' option in p_MegaTK shader for reflect and refract
        - Added some optimization for FG rays with multi sampled reflection/refraction. Now for FG always used only 1 sample. 'Path Indirect Samples' divide to 8 for FG rays
        - Added 'Reflection Depth' and 'Refraction Depth' override for p_MegaTK
        - Added 'Wet Specular' model for p_MegaTK shader
        - Commented some unneeded shader: 'p_fg_light', 'p_fg_no_light' and 'p_saturation'. Please read comments in shaders_p.mi for more details
        - Added 'Quadratic Distance', 'Cubic Distance' and 'Cubic' attenuation type for p_PointTK and p_SpotTK shaders
        - Added different modes for p_motion_to_rgb shader ('Camera Space', 'Raster Space' and 'Krokodove')
        - Fixed problem with incorrect saving of mental ray motion vectors with p_OpenEXR_saver
        - Changed logic of specular pass in p_MegaTK_pass shader. Now if you have enabled only 'specular' without 'specular_shd' in specular pass will be specular combined with shadow
        - Added 'Environment' and 'Shadow' slots for p_ray_type shader. Added 'Reflection Depth' and 'Refraction Depth'
        - Fixed problem in p_color_to_float shader with 'shadow' and 'displacement'
        - Added 'Light Threshold' to p_PointTK and p_SpotTK
        - Added 'Light Radius' and 'Shadow Rays' to p_PointTK, p_SpotTK and p_DirectTK shaders
        - Added 'Soft Cone Falloff' parameter to p_SpotTK
        - Fixed bug in p_shadow_transparency shader in 'simple' or 'sort' shadow mode (before only first shadow shader taken into account)
08.12.06 ver 3.0.1
        - Fixed bug with russian roulette in p_MegaTK shader, now russian roulette used only if reflect and refract enabled
        - Some path tracing optimization in p_MegaTK. It may be slightly faster on some scenes (about 5%)
        - Fixed bug with writing black channels in p_OpenEXR_saver shader under 64 bit arch
        - Now in p_OpenEXR_saver shader TK channels use mi_mem_test_allocate() function instead of 'new' for allocating memory
        - Added automatic declaration for p_math_output and p_OpenEXR_saver shaders from p_MegaTK_pass geometry shader, mostly for XSI
        - Fixed bug in p_MegaTK_pass geometry shader, now you can save to single OpenEXR file only standard mental ray passes without p_MegaTK passes
        - Some docs improve
03.09.06 ver 3.0
        - Added 'Self Shadow' option for p_shadow shader
        - Recoded Reflect/Refract part of p_MegaTK:
                - now samples on isotropic or anisotropic reflect/refract distributed more accurate,
                - changed attenuation method in refract, it's like dielectric_material now,
                - added 'Anisotropic' for refraction (thanks to Mikhail Lyossin for code)
        - Supported Fur effect on polygon object for 3dsmax version
        - Recoded 'Cone' parameter of p_SpotTK, now it estimated in degrees and named 'Soft Cone Angle'
        - Now in p_PointTK and p_SpotTK shaders during computing 'Linear' and 'Quadratic' attenuation 'Start' parameter used to define where attenuation begin
        - Added Bump slot for p_maya_shadingengine shader
        - Added p_float4_to_color shader
        - Added 'Russian Roulette Optimization' option for disable it in p_MegaTK shader
        - Added SpecialC3 and Special4 channels for p_MegaTK shader
        - Added 'Gamma' for Occlusion in p_MegaTK shader
        - Added 'Samples Decrease Factor' to p_MegaTK shader
        - Added 'Path Indirect Diffuse' to p_MegaTK shader
        - Added 'Shadow Transparency' for p_scatter_wrap shader
        - p_scatter_wrap shader now return 'color' type, fixed bug with wrong light counter
        - p_scatter_wrap shader added 'scatter_color', 'wrap_color' and 'terminator_color' parameters
        - p_OpenEXR_saver shader now use 'OpenEXR 1.4' library
        - p_MegaTK_pass shader now support saving passes to single OpenEXR file
        - Fixed bug with alpha value more than 1 in p_MegaTK shader
        - Now shaders_p.dll and p_EXR_saver.dll(win version) combined to single dll file (shaders_p.dll)
03.02.06 ver 2.9
        - Added p_maya_shadingengine shader
        - Modified p_scatter_wrap shader, added 'Trace Depth' parameter and some change in Scattering part for more beauty result
        - Added 'Premultiply Alpha' parameter to p_z shader
        - Added p_OpenEXR_saver output shader for saving multichannels exr file
        - Now in p_MegaTK shader when reach max reflection or refraction trace depth call environment instead of black
        - Increase reflection and refraction rendering speed on p_MegaTK
        - Added 'Add to Original Normal' parameter to p_MegaTK bump (mostly for 3dsmax)
        - Fixed bump problem in p_MegaTK shader
        - Added Attenuation Type for p_SpotTK and p_PointTK light shaders
16.11.05 ver 2.8
        - Added p_MegaTK_pass geometry shader
        - Fixed bug with p_facing_ratio (return > 1 and < 0 value) Some change in code
        - Fixed bug in p_PointTK, p_SpotTK and p_DirectTK shaders (crash in some case when light category specified)
09.10.05 ver 2.7
        - Added p_scatter_wrap shader
        - Added short names for all parameters
        - Added bump to p_MegaTK (Input Normal)
25.09.05 ver 2.6.1
        - Fixed bug in linux version of p_MegaTK shader (crash during reflection computing)
17.09.05 ver 2.6
        - Added p_shadow_transparency shadow shader
        - Changed blinn model in p_MegaTK shader (now like renderman blinn)
        - Fixed two bugs with NaN value with multiple reflection
11.07.05 ver 2.5.1
        - Now p_MegaTK shader work with all lights, but correct passes still possible only with LightTK
07.07.05 ver 2.5
        - Added Fur Diffuse and Fur Specular models to p_MegaTK shader (on basis of gg_fakefur shader from mrClasses by Gonzalo Garramuno)
        - Added internal occlusion and bent normal pass (on basis of Dirtmap shader by Daniel Rind)
        - Added Anisotropic Reflection
        - Added Light Category for p_MegaTK and for p_LightTK
16.05.05 ver 2.4.1
        - Fixed bug with wrong refraction direction inside object
        - Increase rendering speed of refraction
29.04.05 ver 2.4
        - Added Emit Diffuse and Emit Specular parametrs for all p_LightTK
        - Added p_math_output shader (for Maya)
30.03.05 ver 2.3
        - Added Reflect/Refract to p_z
        - Add z to p_MegaTK
        - Add Saturation Mode to p_saturation shader
12.02.05 ver 2.2
        - Added p_PointTK and p_DirectTK
        - Some change in p_MegaTK
18.01.05 ver 2.1
        - Added p_MegaTK and p_SpotTK
12.01.05 ver 2.0
        - Renamed solid_alpha param in flat_p shader to override_alpha and added alpha param
        - Renamed flat_p to p_constant
        - Renamed all shaders to same type
11.01.05 ver 1.9
        - Added ray_type_p, bake_read_p and shadow_p
26.11.04 ver 1.8
        - Removed (commented) mix_p shader
        - Added some new commented shaders (still for test only)
22.10.04 ver 1.7
        - Added z, fisheye and buffer_writer
29.09.04 ver 1.6
        - Added color_to_float_p and saturation_p