HairEffect : RenderEffect
HairEffect - superclass: renderEffect; super-superclass:MAXWrapper - classID: #(988153529, 337462665)
The HairEffect RenderEffect available since 3ds Max 8 is responsible for the rendering of the hair.
Constructor:
USAGE
|
s=sphere()
theHair = HairEffect()--create an instance of the effect
addEffect theHair--add to the listin theEffects dialog
--BUT!
--Adding a Hair WSM to a scene object will add
--a HairEffect to the list automatically!
--Thus, you can simply get the existing one:
addModifier $Sphere001 (HairMod())--add Hair WSM to Sphere001
--At this point, if no HairEffect exists in the Effects dialog,
--it will be added automatically. Let's find it by going through
--all effects by index and asking each one for its class:
theEffects = (
for i = 1 to numEffects where classof (getEffect i) == HairEffect collect (getEffect i)
)
--At this point we should have at least one HairEffect.
--Let's take the first one:
if theEffects.count > 0 do theHair = theEffects[1]
|
Properties:
Hair Rendering Options
<HairEffect>.hairMode Integer default: 1 -- integer; Hair_Mode
Get/set the Hair Rendering Mode.
Possible values are:
1- buffer(default)
2- geometry
3- MR prim
<HairEffect>.lightingMode Integer default: 1 -- integer; Lighting_Param
Get/set the Hair Lighting Mode.
Possible values are:
0 -emulation
1 - native(default)
<HairEffect>.mrVoxelRes Integer default: 5 -- integer; mr_Voxel_Res
Get/set the mental ray voxel resolution. Default is 1. This property is used when
translating Hair to mental ray.
<HairEffect>.Raytrace_Reflections_Refractions BooleanClass default: false -- boolean; Raytrace_the_Reflections_and_Refractions
Get/set the state of the Raytrace Reflections/Refractions checkbox.
Motion Blur
<HairEffect>.mbDuration Float default: 0.5 -- float; MB_Duration
Get/set the Motion Blur duration value. Default is 0.5.
<HairEffect>.mbIntervalType Integer default: 1 -- integer; MB_Interval_Type
Get/set the Motion Blur type.
Possible values are:
0 - start
1 - middle(default)
2 - end
Buffer Rendering Options
<HairEffect>.overSampling Integer default: 3 -- integer
Get/set the Oversampling option.
The values corresponding to the options in the User Interface are:
1 - draft
3 - low
8 - med
15 - high
23 - maximum
<HairEffect>.tileMemoryUsage Integer default: 70 -- integer; Tile_Memory_Usage_Param
Get/set the Tile Memory Usage value in MB.
Available in 3ds Max 2009 and higher.
<HairEffect>.transparencyDepth Integer default:30 -- integer; Transparency_Depth_Param
Get/set the Transparency Depth value.
Available in 3ds Max 2009 and higher.
Composite Method
<HairEffect>.compositionMethod Integer default: 0 -- integer; Composition_Method
Get/set the Composite method when rendering in Buffer mode.
Possible values are:
0 - Normal(default)
1 - GBuffer
2 - None
3 - Off
Occlusion Objects
<HairEffect>.occlusionSetType Integer default: 0 -- integer; Occlusion_Set_Type
Get/set the Occlusion type.
Possible values are:
0 - Auto(default)
1 - All
2 - Custom
<HairEffect>.occlusionNodesArray Parameter default: #() -- node array; Occlusion_Nodes; SubAnim
Get/set the Occlusion Nodes array. Default is #().
Global Illumination
<HairEffect>.applyGI BooleanClass default: false -- boolean; Apply_GI
Get/set the state of the Apply Skylight checkbox.
Available in 3ds Max 2009 and higher.
<HairEffect>.GI_Multiplier Float default: 2.0 -- float
Get/set the value of the Multiplier slider.
Available in 3ds Max 2009 and higher.
Lighting
<HairEffect>.shadowDensity Float default: 100.0 -- animatable; float; Shadow_Density
Get/set the Shadow Density value. Specifies the relative darkness of the shadows.
At the default/highest value of 100.0, the shadows are darkest. At the lowest value
of 0.0, the shadows are fully transparent, so they do not render. Range 0.0 to 100.0.
Default is 100.0.
<HairEffect>.useAllLightsBooleanClass default: true -- boolean; Use_All_Lights
Get/set the state of the Use All Lights option. Corresponds to the "Use all lights
at render time" checkbox in the UI.
When set to true (default), all spot lights in the scene illuminate and cast shadows
from hair when the scene is rendered. When set to false, only spot lights with Hair
properties affect the hair.
For details on adding and removing Hair properties to/from spot lights, see the methods
addHairProperties and removeHairProperties in Interface: Hair.