Here you will find documentation on all the descriptions that Cinema 4D currently has. You can list them Alphabetically, by Type or Plugin . The sample Python and C++ code is automatically generated and in some cases may not be 100% correct. If something doesn't work then please refer to the official Cinema 4D SDK documentation for more information.

IDs and information for Ohair

Ohair

Attributes

  • ENGLISH NAME : HairObject
  • NAME : Ohair
  • INCLUDE : Obase
  • PATH : hair/description/ohair.res
  • PLUGIN : hair
  • MAXON online help (may not exist): OHAIR

Elements

ID UI Name Type Parameters Cycle
HAIRSTYLE_PRIORITY Priority PRIORITY
ANIM OFF
NOCAMERA
HAIRSTYLE_LINK Link LINK  
HAIRSTYLE_COUNT Count LONG
ANIM OFF
MIN 1
HAIRSTYLE_SEGMENTS Segments LONG
ANIM OFF
MIN 1
MAX 1024
HAIRSTYLE_LENGTH Length REAL
FORBID_SCALING
UNIT METER
ANIM OFF
MIN 0.0
HAIRSTYLE_ROOT_PLACEMENT Root LONG ANIM
HAIRSTYLE_ROOT_PLACEMENT_FACE Polygon
HAIRSTYLE_ROOT_PLACEMENT_AREA PolygonArea
HAIRSTYLE_ROOT_PLACEMENT_FACE_CENTER PolygonCenter
HAIRSTYLE_ROOT_PLACEMENT_VERTEX PolygonVertex
HAIRSTYLE_ROOT_PLACEMENT_EDGE PolygonEdge
HAIRSTYLE_ROOT_PLACEMENT_UV UV
HAIRSTYLE_ROOT_PLACEMENT_UV_UNIFORM UVGrid
HAIRSTYLE_ROOT_PLACEMENT_VERTEX_FREE Vertex
HAIRSTYLE_ROOT_PLACEMENT_VERTEX_RADIAL SplineVertex
HAIRSTYLE_ROOT_PLACEMENT_SPLINE SplineSegment
HAIRSTYLE_ROOT_PLACEMENT_SPLINE_UNIFORM SplineUniform
HAIRSTYLE_ROOT_PLACEMENT_SPLINE_TIP SplineTip
HAIRSTYLE_ROOT_PLACEMENT_SEGMENTS_2D Spline2D
HAIRSTYLE_ROOT_PLACEMENT_SEGMENTS_3D SplineGuides
HAIRSTYLE_ROOT_PLACEMENT_HAIR_VERTEX HairVertex
HAIRSTYLE_ROOT_PLACEMENT_HAIR_LINE HairLines
HAIRSTYLE_ROOT_PLACEMENT_HAIR_GUIDE HairGuides
HAIRSTYLE_ROOT_PLACEMENT_HAIR_GUIDE_TIP GuideTip
HAIRSTYLE_ROOT_PLACEMENT_FREE Custom
HAIRSTYLE_ROOT_REMAPPING Map LONG ANIM
HAIRSTYLE_ROOT_REMAPPING_NEW New
HAIRSTYLE_ROOT_REMAPPING_OLD Old
HAIRSTYLE_ROOT_REMAPPING_FREE Unroot
HAIRSTYLE_UV_U_SPACING USpacing REAL
ANIM OFF
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_UV_V_SPACING VSpacing REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_UV_U_VAR UVariation REAL
ANIM OFF
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_UV_V_VAR VVariation REAL
ANIM OFF
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_GROWTH Growth LONG ANIM
HAIRSTYLE_GROWTH_NORMALS Normals
HAIRSTYLE_GROWTH_DIRECTION Direction
HAIRSTYLE_GROWTH_RANDOM Random
HAIRSTYLE_GROWTH_DIRECTION_TYPE Axis LONG ANIM
HAIRSTYLE_GROWTH_DIRECTION_X X
HAIRSTYLE_GROWTH_DIRECTION_Y Y
HAIRSTYLE_GROWTH_DIRECTION_Z Z
HAIRSTYLE_GROWTH_DIRECTION_LOCAL Local BOOL ANIM
HAIRSTYLE_ROOT_MIN_SPACING Min.Spacing BOOL ANIM
HAIRSTYLE_ROOT_DISTANCE Distance REAL
ANIM OFF
UNIT METER
MIN 0.0
STEP 0.1
HAIRSTYLE_ROOT_DENSITY Density SHADERLINK ANIM
HAIRSTYLE_ROOT_DENSITY_LEVELS Levels LONG
ANIM OFF
MIN 2
MAX 10000
HAIRSTYLE_POINTS_LINK PointsLink LINK ANIM
HAIRSTYLE_SHELL_SEGMENT EditVertex LONG
ANIM OFF
MIN 0
MAX 1024
HAIRSTYLE_STATE_REROOT Re-Root BUTTON  
HAIRSTYLE_STATE_RESET Regrow BUTTON  
HAIRSTYLE_STATE_STORE Store BUTTON  
HAIRSTYLE_STATE_RESTORE Restore BUTTON  
HAIRSTYLE_STATE_CLEAR Clear BUTTON  
HAIRSTYLE_SYMMETRY_ENABLE Symmetry BOOL ANIM
HAIRSTYLE_SYMMETRY_PLANE Plane LONG ANIM
HAIRSTYLE_SYMMETRY_PLANE_XY XY
HAIRSTYLE_SYMMETRY_PLANE_YZ YZ
HAIRSTYLE_SYMMETRY_PLANE_XZ XZ
HAIRSTYLE_SYMMETRY_EDITOR ShowGuides BOOL ANIM
HAIRSTYLE_SYMMETRY_ROOT AutoRoot BOOL ANIM
HAIRSTYLE_SYMMETRY_EDITABLE MakeEditable BUTTON ANIM
HAIRSTYLE_UPDATE_AUTO AutoUpdate BOOL ANIM
HAIRSTYLE_UPDATE UpdateGuides BUTTON ANIM
HAIRSTYLE_HAIR_COUNT Count LONG MIN
HAIRSTYLE_HAIR_SEGMENTS Segments LONG
MIN 1
MAX 1024
HAIRSTYLE_HAIR_ROOT_PLACEMENT Root LONG  
HAIRSTYLE_ROOT_PLACEMENT_AUTO Auto
HAIRSTYLE_ROOT_PLACEMENT_FACE Polygon
HAIRSTYLE_ROOT_PLACEMENT_AREA PolygonArea
HAIRSTYLE_ROOT_PLACEMENT_FACE_CENTER PolygonCenter
HAIRSTYLE_ROOT_PLACEMENT_VERTEX PolygonVertex
HAIRSTYLE_ROOT_PLACEMENT_EDGE PolygonEdge
HAIRSTYLE_ROOT_PLACEMENT_UV UV
HAIRSTYLE_ROOT_PLACEMENT_UV_UNIFORM UVGrid
HAIRSTYLE_ROOT_PLACEMENT_VERTEX_FREE Vertex
HAIRSTYLE_ROOT_PLACEMENT_VERTEX_RADIAL SplineVertex
HAIRSTYLE_ROOT_PLACEMENT_SPLINE SplineSegment
HAIRSTYLE_ROOT_PLACEMENT_SPLINE_UNIFORM SplineUniform
HAIRSTYLE_ROOT_PLACEMENT_SPLINE_TIP SplineTip
HAIRSTYLE_ROOT_PLACEMENT_SEGMENTS_2D Spline2D
HAIRSTYLE_ROOT_PLACEMENT_SEGMENTS_3D SplineGuides
HAIRSTYLE_ROOT_PLACEMENT_HAIR_VERTEX HairVertex
HAIRSTYLE_ROOT_PLACEMENT_HAIR_LINE HairLines
HAIRSTYLE_ROOT_PLACEMENT_HAIR_GUIDE HairGuides
HAIRSTYLE_ROOT_PLACEMENT_HAIR_GUIDE_TIP GuideTip
HAIRSTYLE_ROOT_PLACEMENT_ASGUIDES AsGuides
HAIRSTYLE_ROOTS_ASNORMALS AsNormal BOOL  
HAIRSTYLE_HAIR_UV_U_SPACING USpacing REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_HAIR_UV_V_SPACING VSpacing REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_HAIR_UV_U_VAR UVariation REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_HAIR_UV_V_VAR VVariation REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_ROOT_OFFSET Offset REAL  
HAIRSTYLE_ROOT_EXTEND Extend REAL MIN
HAIRSTYLE_HAIR_ROOT_NULL_INVALID RemoveInvalid BOOL  
HAIRSTYLE_HAIR_ROOT_MIN_SPACING MinSpacing BOOL  
HAIRSTYLE_HAIR_ROOT_DISTANCE Distance REAL
UNIT METER
MIN 0.0
HAIRSTYLE_HAIR_ROOT_DENSITY Density SHADERLINK  
HAIRSTYLE_HAIR_ROOT_DENSITY_LEVELS Levels LONG
MIN 2
MAX 10000
HAIRSTYLE_HAIR_ROOT_RESTICT RestricttoGuides BOOL  
HAIRSTYLE_HAIR_ROOT_RESTRICT_DISTANCE Distance REAL
UNIT METER
MIN 0.0
HAIRSTYLE_HAIR_ROOT_RESTRICT_COUNT Guides REAL
MIN 1
MAX 100
HAIRSTYLE_HAIR_ROOT_MULTIPLY Clone LONG MIN
HAIRSTYLE_HAIR_ROOT_MULTIPLY_SETROOTS SetRoots BOOL  
HAIRSTYLE_HAIR_ROOT_MULTI_ROOT Root REAL
UNIT METER
MIN 0.0
HAIRSTYLE_HAIR_ROOT_MULTI_TIP Tip REAL
UNIT METER
MIN 0.0
HAIRSTYLE_HAIR_ROOT_MULTI_SCALE Scale REAL
UNIT PERCENT
MIN 0.0
HAIRSTYLE_HAIR_ROOT_MULTI_SCALE_VAR Variation REAL
UNIT PERCENT
MIN 0.0
HAIRSTYLE_HAIR_ROOT_MULTI_SPLINE Offset SPLINE  
HAIRSTYLE_INTERPOLATION_TYPE Type LONG  
HAIRSTYLE_INTERPOLATION_TYPE_LINEAR Linear
HAIRSTYLE_INTERPOLATION_TYPE_SQUARE Square
HAIRSTYLE_INTERPOLATION_TYPE_CUBIC Cubic
HAIRSTYLE_INTERPOLATION_TYPE_QUARTIC Quartic
HAIRSTYLE_INTERPOLATION_GUIDES FromGuides LONG
MIN 1
MAX 1024
HAIRSTYLE_INTERPOLATION_VARIATION Variation REAL
UNIT PERCENT
MIN 0.0
HAIRSTYLE_INTERPOLATION_CLUMP Clump BOOL  
HAIRSTYLE_INTERPOLATION_ATTRACTION Attraction SPLINE  
HAIRSTYLE_FUR FillHairs BOOL  
HAIRSTYLE_FUR_COUNT Count LONG MIN
HAIRSTYLE_FUR_ONLY FillHairsOnly BOOL  
HAIRSTYLE_FUR_SHADOWS Shadows BOOL  
HAIRSTYLE_FUR_CACHE Cache BOOL  
HAIRSTYLE_FUR_SCALE Scale REAL
UNIT PERCENT
MIN 0.0
HAIRSTYLE_FUR_SCALE_VAR Variation REAL
UNIT PERCENT
MIN 0.0
HAIRSTYLE_FUR_THICKNESS Thickness REAL
UNIT PERCENT
MIN 0.0
HAIRSTYLE_FUR_THICKNESS_VAR Variation REAL
UNIT PERCENT
MIN 0.0
HAIRSTYLE_FUR_CLUMP Clump BOOL  
HAIRSTYLE_FUR_CLUMP_STRENGTH Attraction SPLINE  
HAIRSTYLE_PREVIEW Display LONG  
HAIRSTYLE_PREVIEW_NONE None
HAIRSTYLE_PREVIEW_LINES GuideLines
HAIRSTYLE_PREVIEW_POLYGONS GuidePolygons
HAIRSTYLE_PREVIEW_HAIR_LINES HairLines
HAIRSTYLE_PREVIEW_HAIR_POLYGONS HairPolygons
HAIRSTYLE_PREVIEW_CACHE Cache BOOL  
HAIRSTYLE_BACKFACING ShowBackfacing BOOL  
HAIRSTYLE_PREVIEW_NO_SHADING AccurateCPUMaterial BOOL  
HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING EnhancedViewportShading BOOL  
HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING_SPECULAR EnhancedViewportShadingSpecular REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
CUSTOMGUI REALSLIDER
HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING_AO EnhancedViewportShadingAmbientOcclusion REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
CUSTOMGUI REALSLIDER
HAIRSTYLE_PREVIEW_DETAIL Detail REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
CUSTOMGUI REALSLIDER
HAIRSTYLE_EDITOR_GENERATE Generate LONG  
HAIRSTYLE_EDITOR_GENERATE_NONE None
HAIRSTYLE_EDITOR_GENERATE_AS_RENDER AsRender
HAIRSTYLE_EDITOR_GENERATE_POLYGONS_FACING Flat
HAIRSTYLE_EDITOR_GENERATE_POLYGONS_TRI Tri
HAIRSTYLE_EDITOR_GENERATE_POLYGONS_BOX Box
HAIRSTYLE_LOD_AFFECT LOD LONG  
HAIRSTYLE_LOD_AFFECT_NONE None
HAIRSTYLE_LOD_AFFECT_ALL All
HAIRSTYLE_LOD_AFFECT_COUNT Count
HAIRSTYLE_LOD_AFFECT_SEGMENTS Segments
HAIRSTYLE_EDITOR_ASRENDER AsRender BOOL  
HAIRSTYLE_EDITOR_COUNT Count LONG MIN
HAIRSTYLE_EDITOR_SEGCOUNT Segments LONG MIN
HAIRSTYLE_RENDER_HAIR RenderHairs BOOL  
HAIRSTYLE_GENERATE Type LONG  
HAIRSTYLE_GENERATE_NONE None
HAIRSTYLE_GENERATE_SPLINE Spline
HAIRSTYLE_GENERATE_POLYGONS_FACING Flat
HAIRSTYLE_GENERATE_POLYGONS_TRI Triangle
HAIRSTYLE_GENERATE_POLYGONS_BOX Square
HAIRSTYLE_GENERATE_POLYGONS_CYLINDER Circle
HAIRSTYLE_GENERATE_POLYGONS_INSTANCE Instance
HAIRSTYLE_GENERATE_POLYGONS_SWEEP Sweep
HAIRSTYLE_GENERATE_PERFRAME FrameUpdate BOOL  
HAIRSTYLE_INSTANCE_LINK Object LINK  
HAIRSTYLE_INSTANCE_AXIS Axis LONG  
HAIRSTYLE_INSTANCE_AXIS_X X
HAIRSTYLE_INSTANCE_AXIS_Y Y
HAIRSTYLE_INSTANCE_AXIS_Z Z
HAIRSTYLE_INSTANCE_SCALING Scaling LONG  
HAIRSTYLE_INSTANCE_SCALING_UNIFORM Uniform
HAIRSTYLE_INSTANCE_SCALING_ASPECT KeepAspect
HAIRSTYLE_INSTANCE_SCALING_FIT Fit
HAIRSTYLE_INSTANCE_DEFORM Deform LONG  
HAIRSTYLE_INSTANCE_DEFORM_NONE None
HAIRSTYLE_INSTANCE_DEFORM_BEND Bend
HAIRSTYLE_INSTANCE_DEFORM_ALIGN Align
HAIRSTYLE_INSTANCE_HIERARCHY Hierarchy LONG  
HAIRSTYLE_INSTANCE_HIERARCHY_SINGLE First
HAIRSTYLE_INSTANCE_HIERARCHY_REPEAT Forward
HAIRSTYLE_INSTANCE_HIERARCHY_REPEAT_REVERSE Reverse
HAIRSTYLE_INSTANCE_HIERARCHY_CYCLE Cycle
HAIRSTYLE_INSTANCE_HIERARCHY_RANDOM Random
HAIRSTYLE_INSTANCE_REPEAT Repeat LONG MIN
HAIRSTYLE_INSTANCE_MATERIALS KeepTextures BOOL  
HAIRSTYLE_INSTANCE_START Start REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_INSTANCE_END End REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_ROTATION Align LONG  
HAIRSTYLE_ROTATION_FREE Free
HAIRSTYLE_ROTATION_LOOK_X LookX
HAIRSTYLE_ROTATION_LOOK_Y LookY
HAIRSTYLE_ROTATION_LOOK_Z LookZ
HAIRSTYLE_ROTATION_LOOK_CAMERA LookCamera
HAIRSTYLE_ROTATION_RANDOM Random
HAIRSTYLE_ROTATION_LOOK_AT Object
HAIRSTYLE_ROTATION_LOCAL Local BOOL  
HAIRSTYLE_ROTATION_INVERT Invert BOOL  
HAIRSTYLE_ROTATION_LINK LookAt LINK  
HAIRSTYLE_SINGLE_OBJECT SingleObject BOOL  
HAIRSTYLE_CAP_START StartCap BOOL  
HAIRSTYLE_CAP_END EndCap BOOL  
HAIRSTYLE_SLICES Slice BOOL  
HAIRSTYLE_SLICE_NORMAL Axis LONG  
HAIRSTYLE_SLICE_NORMAL_GUIDE Hair
HAIRSTYLE_SLICE_NORMAL_CAMERA Camera
HAIRSTYLE_SLICE_NORMAL_NORMAL Normal
HAIRSTYLE_DYNAMICS_ENABLE Enable BOOL  
HAIRSTYLE_DYNAMICS_COLLISIONS Collisions BOOL  
HAIRSTYLE_DYNAMICS_EXTRA_STIFF Rigid BOOL ANIM
HAIRSTYLE_DYNAMICS_RADIUS Surf.Rad. REAL MIN
HAIRSTYLE_DYNAMICS_FIXED_ROOTS FixedRoots BOOL  
HAIRSTYLE_DYNAMICS_MASS Mass REAL
MIN 0.1
STEP 0.1
HAIRSTYLE_DYNAMICS_DRAG Drag REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_DYNAMICS_ROOT_HOLD HoldRoots REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_DYNAMICS_STIFFNESS Stiffness REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_DYNAMICS_REST_MIX RestMix REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_DYNAMICS_REST_HOLD RestHold REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_DYNAMICS_ELASTIC_LIMIT ElasticLimit REAL
UNIT PERCENT
MIN 0.0
HAIRSTYLE_DYNAMICS_ELASTIC_DEFORM Deform REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
HAIRSTYLE_DYNAMICS_AUTOTIME AutoTime BOOL ANIM
HAIRSTYLE_DYNAMICS_START Start BASETIME ANIM
HAIRSTYLE_DYNAMICS_STOP End BASETIME ANIM
HAIRSTYLE_DYNAMICS_RELAX Relax BUTTON  
HAIRSTYLE_DYNAMICS_FRAMES Frames LONG
ANIM OFF
MIN 1
HAIRSTYLE_DYNAMICS_DRAG_LINK Drag LINK  
HAIRSTYLE_DYNAMICS_STIFFNESS_LINK Stiffness LINK  
HAIRSTYLE_DYNAMICS_REST_HOLD_LINK RestHold LINK  
HAIRSTYLE_DYNAMICS_MASS_LINK Mass LINK  
HAIRSTYLE_DYNAMICS_FORCE_LINK Forces LINK  
HAIRSTYLE_DYNAMICS_DRAG_SPLINE Drag SPLINE  
HAIRSTYLE_DYNAMICS_STIFFNESS_SPLINE Stiffness SPLINE  
HAIRSTYLE_DYNAMICS_REST_HOLD_SPLINE RestHold SPLINE  
HAIRSTYLE_DYNAMICS_MASS_SPLINE Mass SPLINE  
HAIRSTYLE_DYNAMICS_FORCE_SPLINE Forces SPLINE  
HAIRSTYLE_DYNAMICS_APPLY Dynamics LONG ANIM
HAIRSTYLE_DYNAMICS_APPLY_GUIDES Guides
HAIRSTYLE_DYNAMICS_APPLY_HAIRS Hairs
HAIRSTYLE_DYNAMICS_CUSTOM Custom BOOL ANIM
HAIRSTYLE_DYNAMICS_SEGMENTS Segments LONG
ANIM OFF
MIN 1
MAX 1024
HAIRSTYLE_DYNAMICS_SUBDIV Steps LONG
ANIM OFF
MIN 1
MAX 10000
HAIRSTYLE_DYNAMICS_ITERATIONS Iterations LONG
MIN 0
MAX 10000
HAIRSTYLE_DYNAMICS_FORCES_HAIR HairtoHair BOOL  
HAIRSTYLE_DYNAMICS_FORCES_OBJECTS SurfacetoHair BOOL  
HAIRSTYLE_DYNAMICS_GRAVITY Gravity REAL STEP
HAIRSTYLE_DYNAMICS_FORCES_RADIUS Radius REAL
UNIT METER
MIN 0.0
HAIRSTYLE_DYNAMICS_FORCES_STRENGTH Strength REAL  
HAIRSTYLE_DYNAMICS_FORCES_MAXSTRENGTH MaxStrength REAL  
HAIRSTYLE_DYNAMICS_FORCES_FALLOFF Falloff LONG  
HAIRSTYLE_DYNAMICS_FORCES_FALLOFF_CONSTANT Constant
HAIRSTYLE_DYNAMICS_FORCES_FALLOFF_LINEAR Linear
HAIRSTYLE_DYNAMICS_FORCES_FALLOFF_SQUARE Square
HAIRSTYLE_DYNAMICS_FORCES_FALLOFF_CUBIC Cubic
HAIRSTYLE_DYNAMICS_FORCES_FALLOFF_CUSTOM Custom
HAIRSTYLE_DYNAMICS_FORCES_FALLOFF_SPLINE Custom SPLINE  
HAIRSTYLE_DYNAMICS_FORCES_INCEXC Mode LONG  
HAIRSTYLE_DYNAMICS_FORCES_INCEXC_INCLUDE Include
HAIRSTYLE_DYNAMICS_FORCES_INCEXC_EXCLUDE Exclude
HAIRSTYLE_DYNAMICS_FORCES_INCLUDE Forces IN_EXCLUDE
NUM_FLAGS 0
INIT_STATE 0
SEND_SELCHNGMSG 1
SCALE_V
HAIRSTYLE_DYNAMICS_CACHE_ENABLE DynamicsCache BOOL  
HAIRSTYLE_DYNAMICS_CACHE_CALCULATE Calculate BUTTON FIT_H
HAIRSTYLE_DYNAMICS_CACHE_COMPRESSED Compress BOOL ANIM
HAIRSTYLE_DYNAMICS_CACHE_DELETE EmptyCache BUTTON FIT_H
HAIRSTYLE_DYNAMICS_CACHE_CACHE_FRAME UpdateFrame BUTTON FIT_H
HAIRSTYLE_DYNAMICS_EDITABLE Editable BOOL  
HAIRSTYLE_DYNAMICS_CACHE_CACHE_LOAD Load... BUTTON FIT_H
HAIRSTYLE_DYNAMICS_CACHE_CACHE_SAVE Save... BUTTON FIT_H
HAIRSTYLE_DYNAMICS_CACHE_CACHE_LIMIT Cache LONG
MIN 1
MAX 1000
ANIM OFF
HAIRSTYLE_PARTINGS_AUTO AutoPartings BOOL  
HAIRSTYLE_PARTINGS_DISTANCE Distance REAL
UNIT METER
MIN 0.0
HAIRSTYLE_PARTINGS_ANGLE Angle REAL
UNIT DEGREE
MIN 0.0
HAIRSTYLE_PARTINGS_INCLUDE Groups IN_EXCLUDE
NUM_FLAGS 0
INIT_STATE 0
SEND_SELCHNGMSG 1
SCALE_V
HAIRSTYLE_GENERATE_CULL_BACKFACING BackfacingCulling BOOL  
HAIRSTYLE_GENERATE_CULL_OFFSCREEN Off-ScreenCulling BOOL  
HAIRSTYLE_GENERATE_CULL_DISTANCE DistanceClipping BOOL  
HAIRSTYLE_GENERATE_CULL_BACKFACING_FADE BackfacingStart REAL
UNIT DEGREE
MIN 0.0
MAX 180.0
HAIRSTYLE_GENERATE_CULL_BACKFACING_FADE_END End REAL
UNIT DEGREE
MIN 0.0
MAX 180.0
HAIRSTYLE_GENERATE_CULL_DISTANCE_NEARCLIP NearClip REAL UNIT
HAIRSTYLE_GENERATE_CULL_DISTANCE_NEARCLIP_FADE NearFade REAL
UNIT METER
MIN 0.0
HAIRSTYLE_GENERATE_CULL_DISTANCE_FARCLIP FarClip REAL UNIT
HAIRSTYLE_GENERATE_CULL_DISTANCE_FARCLIP_FADE FarFade REAL
UNIT METER
MIN 0.0
HAIRSTYLE_GENERATE_CULL_OFFSCREEN_PERCENT Off-Screen REAL
UNIT PERCENT
MIN 0.0
HAIRSTYLE_SEED Seed LONG MIN
HAIRSTYLE_ROOTS_GENERATE_ITERATIONS RedistributeLoops LONG
MIN 1
MAX 10000
HAIRSTYLE_DEFORMERS_ENABLE Deformers BOOL  
HAIRSTYLE_DEFORMERS_STRENGTH Strength REAL
UNIT PERCENT
MIN 0.0
MAX 100.0
CUSTOMGUI REALSLIDER
HAIRSTYLE_UV_LINK UVTag LINK  

Example Code

The following code does not use the correct values when setting the data. You should check directly in C4D for the correct values that you should use in place of the ones that are shown. This code is just to show you how to access the values for getting and setting the parameters.

Python

import c4d
from c4d import gui
def main():
    obj = c4d.BaseObject(c4d.Ohair)
    doc.InsertObject(obj)
    c4d.EventAdd(c4d.EVENT_FORCEREDRAW)
    
    #You can set parameters two different ways. 
    #First way              
    obj[c4d.HAIRSTYLE_COUNT] = 1
    obj[c4d.HAIRSTYLE_SEGMENTS] = 1
    obj[c4d.HAIRSTYLE_LENGTH] = 0.1
    obj[c4d.HAIRSTYLE_ROOT_PLACEMENT] = c4d.HAIRSTYLE_ROOT_PLACEMENT_FACE
    obj[c4d.HAIRSTYLE_ROOT_REMAPPING] = c4d.HAIRSTYLE_ROOT_REMAPPING_NEW
    obj[c4d.HAIRSTYLE_UV_U_SPACING] = 0.1
    obj[c4d.HAIRSTYLE_UV_V_SPACING] = 0.1
    obj[c4d.HAIRSTYLE_UV_U_VAR] = 0.1
    obj[c4d.HAIRSTYLE_UV_V_VAR] = 0.1
    obj[c4d.HAIRSTYLE_GROWTH] = c4d.HAIRSTYLE_GROWTH_NORMALS
    obj[c4d.HAIRSTYLE_GROWTH_DIRECTION_TYPE] = c4d.HAIRSTYLE_GROWTH_DIRECTION_X
    obj[c4d.HAIRSTYLE_GROWTH_DIRECTION_LOCAL] = True
    obj[c4d.HAIRSTYLE_ROOT_MIN_SPACING] = True
    obj[c4d.HAIRSTYLE_ROOT_DISTANCE] = 0.1
    obj[c4d.HAIRSTYLE_ROOT_DENSITY_LEVELS] = 1
    obj[c4d.HAIRSTYLE_SHELL_SEGMENT] = 1
    obj[c4d.HAIRSTYLE_SYMMETRY_ENABLE] = True
    obj[c4d.HAIRSTYLE_SYMMETRY_PLANE] = c4d.HAIRSTYLE_SYMMETRY_PLANE_XY
    obj[c4d.HAIRSTYLE_SYMMETRY_EDITOR] = True
    obj[c4d.HAIRSTYLE_SYMMETRY_ROOT] = True
    obj[c4d.HAIRSTYLE_UPDATE_AUTO] = True
    obj[c4d.HAIRSTYLE_HAIR_COUNT] = 1
    obj[c4d.HAIRSTYLE_HAIR_SEGMENTS] = 1
    obj[c4d.HAIRSTYLE_HAIR_ROOT_PLACEMENT] = c4d.HAIRSTYLE_ROOT_PLACEMENT_AUTO
    obj[c4d.HAIRSTYLE_ROOTS_ASNORMALS] = True
    obj[c4d.HAIRSTYLE_HAIR_UV_U_SPACING] = 0.1
    obj[c4d.HAIRSTYLE_HAIR_UV_V_SPACING] = 0.1
    obj[c4d.HAIRSTYLE_HAIR_UV_U_VAR] = 0.1
    obj[c4d.HAIRSTYLE_HAIR_UV_V_VAR] = 0.1
    obj[c4d.HAIRSTYLE_ROOT_OFFSET] = 0.1
    obj[c4d.HAIRSTYLE_ROOT_EXTEND] = 0.1
    obj[c4d.HAIRSTYLE_HAIR_ROOT_NULL_INVALID] = True
    obj[c4d.HAIRSTYLE_HAIR_ROOT_MIN_SPACING] = True
    obj[c4d.HAIRSTYLE_HAIR_ROOT_DISTANCE] = 0.1
    obj[c4d.HAIRSTYLE_HAIR_ROOT_DENSITY_LEVELS] = 1
    obj[c4d.HAIRSTYLE_HAIR_ROOT_RESTICT] = True
    obj[c4d.HAIRSTYLE_HAIR_ROOT_RESTRICT_DISTANCE] = 0.1
    obj[c4d.HAIRSTYLE_HAIR_ROOT_RESTRICT_COUNT] = 0.1
    obj[c4d.HAIRSTYLE_HAIR_ROOT_MULTIPLY] = 1
    obj[c4d.HAIRSTYLE_HAIR_ROOT_MULTIPLY_SETROOTS] = True
    obj[c4d.HAIRSTYLE_HAIR_ROOT_MULTI_ROOT] = 0.1
    obj[c4d.HAIRSTYLE_HAIR_ROOT_MULTI_TIP] = 0.1
    obj[c4d.HAIRSTYLE_HAIR_ROOT_MULTI_SCALE] = 0.1
    obj[c4d.HAIRSTYLE_HAIR_ROOT_MULTI_SCALE_VAR] = 0.1
    obj[c4d.HAIRSTYLE_INTERPOLATION_TYPE] = c4d.HAIRSTYLE_INTERPOLATION_TYPE_LINEAR
    obj[c4d.HAIRSTYLE_INTERPOLATION_GUIDES] = 1
    obj[c4d.HAIRSTYLE_INTERPOLATION_VARIATION] = 0.1
    obj[c4d.HAIRSTYLE_INTERPOLATION_CLUMP] = True
    obj[c4d.HAIRSTYLE_FUR] = True
    obj[c4d.HAIRSTYLE_FUR_COUNT] = 1
    obj[c4d.HAIRSTYLE_FUR_ONLY] = True
    obj[c4d.HAIRSTYLE_FUR_SHADOWS] = True
    obj[c4d.HAIRSTYLE_FUR_CACHE] = True
    obj[c4d.HAIRSTYLE_FUR_SCALE] = 0.1
    obj[c4d.HAIRSTYLE_FUR_SCALE_VAR] = 0.1
    obj[c4d.HAIRSTYLE_FUR_THICKNESS] = 0.1
    obj[c4d.HAIRSTYLE_FUR_THICKNESS_VAR] = 0.1
    obj[c4d.HAIRSTYLE_FUR_CLUMP] = True
    obj[c4d.HAIRSTYLE_PREVIEW] = c4d.HAIRSTYLE_PREVIEW_NONE
    obj[c4d.HAIRSTYLE_PREVIEW_CACHE] = True
    obj[c4d.HAIRSTYLE_BACKFACING] = True
    obj[c4d.HAIRSTYLE_PREVIEW_NO_SHADING] = True
    obj[c4d.HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING] = True
    obj[c4d.HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING_SPECULAR] = 0.1
    obj[c4d.HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING_AO] = 0.1
    obj[c4d.HAIRSTYLE_PREVIEW_DETAIL] = 0.1
    obj[c4d.HAIRSTYLE_EDITOR_GENERATE] = c4d.HAIRSTYLE_EDITOR_GENERATE_NONE
    obj[c4d.HAIRSTYLE_LOD_AFFECT] = c4d.HAIRSTYLE_LOD_AFFECT_NONE
    obj[c4d.HAIRSTYLE_EDITOR_ASRENDER] = True
    obj[c4d.HAIRSTYLE_EDITOR_COUNT] = 1
    obj[c4d.HAIRSTYLE_EDITOR_SEGCOUNT] = 1
    obj[c4d.HAIRSTYLE_RENDER_HAIR] = True
    obj[c4d.HAIRSTYLE_GENERATE] = c4d.HAIRSTYLE_GENERATE_NONE
    obj[c4d.HAIRSTYLE_GENERATE_PERFRAME] = True
    obj[c4d.HAIRSTYLE_INSTANCE_AXIS] = c4d.HAIRSTYLE_INSTANCE_AXIS_X
    obj[c4d.HAIRSTYLE_INSTANCE_SCALING] = c4d.HAIRSTYLE_INSTANCE_SCALING_UNIFORM
    obj[c4d.HAIRSTYLE_INSTANCE_DEFORM] = c4d.HAIRSTYLE_INSTANCE_DEFORM_NONE
    obj[c4d.HAIRSTYLE_INSTANCE_HIERARCHY] = c4d.HAIRSTYLE_INSTANCE_HIERARCHY_SINGLE
    obj[c4d.HAIRSTYLE_INSTANCE_REPEAT] = 1
    obj[c4d.HAIRSTYLE_INSTANCE_MATERIALS] = True
    obj[c4d.HAIRSTYLE_INSTANCE_START] = 0.1
    obj[c4d.HAIRSTYLE_INSTANCE_END] = 0.1
    obj[c4d.HAIRSTYLE_ROTATION] = c4d.HAIRSTYLE_ROTATION_FREE
    obj[c4d.HAIRSTYLE_ROTATION_LOCAL] = True
    obj[c4d.HAIRSTYLE_ROTATION_INVERT] = True
    obj[c4d.HAIRSTYLE_SINGLE_OBJECT] = True
    obj[c4d.HAIRSTYLE_CAP_START] = True
    obj[c4d.HAIRSTYLE_CAP_END] = True
    obj[c4d.HAIRSTYLE_SLICES] = True
    obj[c4d.HAIRSTYLE_SLICE_NORMAL] = c4d.HAIRSTYLE_SLICE_NORMAL_GUIDE
    obj[c4d.HAIRSTYLE_DYNAMICS_ENABLE] = True
    obj[c4d.HAIRSTYLE_DYNAMICS_COLLISIONS] = True
    obj[c4d.HAIRSTYLE_DYNAMICS_EXTRA_STIFF] = True
    obj[c4d.HAIRSTYLE_DYNAMICS_RADIUS] = 0.1
    obj[c4d.HAIRSTYLE_DYNAMICS_FIXED_ROOTS] = True
    obj[c4d.HAIRSTYLE_DYNAMICS_MASS] = 0.1
    obj[c4d.HAIRSTYLE_DYNAMICS_DRAG] = 0.1
    obj[c4d.HAIRSTYLE_DYNAMICS_ROOT_HOLD] = 0.1
    obj[c4d.HAIRSTYLE_DYNAMICS_STIFFNESS] = 0.1
    obj[c4d.HAIRSTYLE_DYNAMICS_REST_MIX] = 0.1
    obj[c4d.HAIRSTYLE_DYNAMICS_REST_HOLD] = 0.1
    obj[c4d.HAIRSTYLE_DYNAMICS_ELASTIC_LIMIT] = 0.1
    obj[c4d.HAIRSTYLE_DYNAMICS_ELASTIC_DEFORM] = 0.1
    obj[c4d.HAIRSTYLE_DYNAMICS_AUTOTIME] = True
    obj[c4d.HAIRSTYLE_DYNAMICS_FRAMES] = 1
    obj[c4d.HAIRSTYLE_DYNAMICS_APPLY] = c4d.HAIRSTYLE_DYNAMICS_APPLY_GUIDES
    obj[c4d.HAIRSTYLE_DYNAMICS_CUSTOM] = True
    obj[c4d.HAIRSTYLE_DYNAMICS_SEGMENTS] = 1
    obj[c4d.HAIRSTYLE_DYNAMICS_SUBDIV] = 1
    obj[c4d.HAIRSTYLE_DYNAMICS_ITERATIONS] = 1
    obj[c4d.HAIRSTYLE_DYNAMICS_FORCES_HAIR] = True
    obj[c4d.HAIRSTYLE_DYNAMICS_FORCES_OBJECTS] = True
    obj[c4d.HAIRSTYLE_DYNAMICS_GRAVITY] = 0.1
    obj[c4d.HAIRSTYLE_DYNAMICS_FORCES_RADIUS] = 0.1
    obj[c4d.HAIRSTYLE_DYNAMICS_FORCES_STRENGTH] = 0.1
    obj[c4d.HAIRSTYLE_DYNAMICS_FORCES_MAXSTRENGTH] = 0.1
    obj[c4d.HAIRSTYLE_DYNAMICS_FORCES_FALLOFF] = c4d.HAIRSTYLE_DYNAMICS_FORCES_FALLOFF_CONSTANT
    obj[c4d.HAIRSTYLE_DYNAMICS_FORCES_INCEXC] = c4d.HAIRSTYLE_DYNAMICS_FORCES_INCEXC_INCLUDE
    obj[c4d.HAIRSTYLE_DYNAMICS_CACHE_ENABLE] = True
    obj[c4d.HAIRSTYLE_DYNAMICS_CACHE_COMPRESSED] = True
    obj[c4d.HAIRSTYLE_DYNAMICS_EDITABLE] = True
    obj[c4d.HAIRSTYLE_DYNAMICS_CACHE_CACHE_LIMIT] = 1
    obj[c4d.HAIRSTYLE_PARTINGS_AUTO] = True
    obj[c4d.HAIRSTYLE_PARTINGS_DISTANCE] = 0.1
    obj[c4d.HAIRSTYLE_PARTINGS_ANGLE] = 0.1
    obj[c4d.HAIRSTYLE_GENERATE_CULL_BACKFACING] = True
    obj[c4d.HAIRSTYLE_GENERATE_CULL_OFFSCREEN] = True
    obj[c4d.HAIRSTYLE_GENERATE_CULL_DISTANCE] = True
    obj[c4d.HAIRSTYLE_GENERATE_CULL_BACKFACING_FADE] = 0.1
    obj[c4d.HAIRSTYLE_GENERATE_CULL_BACKFACING_FADE_END] = 0.1
    obj[c4d.HAIRSTYLE_GENERATE_CULL_DISTANCE_NEARCLIP] = 0.1
    obj[c4d.HAIRSTYLE_GENERATE_CULL_DISTANCE_NEARCLIP_FADE] = 0.1
    obj[c4d.HAIRSTYLE_GENERATE_CULL_DISTANCE_FARCLIP] = 0.1
    obj[c4d.HAIRSTYLE_GENERATE_CULL_DISTANCE_FARCLIP_FADE] = 0.1
    obj[c4d.HAIRSTYLE_GENERATE_CULL_OFFSCREEN_PERCENT] = 0.1
    obj[c4d.HAIRSTYLE_SEED] = 1
    obj[c4d.HAIRSTYLE_ROOTS_GENERATE_ITERATIONS] = 1
    obj[c4d.HAIRSTYLE_DEFORMERS_ENABLE] = True
    obj[c4d.HAIRSTYLE_DEFORMERS_STRENGTH] = 0.1
    
    #Second way, using the base container.
    bc = obj.GetDataInstance()
    bc.SetInt32(c4d.HAIRSTYLE_COUNT,1)
    bc.SetInt32(c4d.HAIRSTYLE_SEGMENTS,1)
    bc.SetFloat(c4d.HAIRSTYLE_LENGTH,0.1)
    bc.SetInt32(c4d.HAIRSTYLE_ROOT_PLACEMENT,c4d.HAIRSTYLE_ROOT_PLACEMENT_FACE)
    bc.SetInt32(c4d.HAIRSTYLE_ROOT_REMAPPING,c4d.HAIRSTYLE_ROOT_REMAPPING_NEW)
    bc.SetFloat(c4d.HAIRSTYLE_UV_U_SPACING,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_UV_V_SPACING,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_UV_U_VAR,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_UV_V_VAR,0.1)
    bc.SetInt32(c4d.HAIRSTYLE_GROWTH,c4d.HAIRSTYLE_GROWTH_NORMALS)
    bc.SetInt32(c4d.HAIRSTYLE_GROWTH_DIRECTION_TYPE,c4d.HAIRSTYLE_GROWTH_DIRECTION_X)
    bc.SetBool(c4d.HAIRSTYLE_GROWTH_DIRECTION_LOCAL,True)
    bc.SetBool(c4d.HAIRSTYLE_ROOT_MIN_SPACING,True)
    bc.SetFloat(c4d.HAIRSTYLE_ROOT_DISTANCE,0.1)
    bc.SetInt32(c4d.HAIRSTYLE_ROOT_DENSITY_LEVELS,1)
    bc.SetInt32(c4d.HAIRSTYLE_SHELL_SEGMENT,1)
    bc.SetBool(c4d.HAIRSTYLE_SYMMETRY_ENABLE,True)
    bc.SetInt32(c4d.HAIRSTYLE_SYMMETRY_PLANE,c4d.HAIRSTYLE_SYMMETRY_PLANE_XY)
    bc.SetBool(c4d.HAIRSTYLE_SYMMETRY_EDITOR,True)
    bc.SetBool(c4d.HAIRSTYLE_SYMMETRY_ROOT,True)
    bc.SetBool(c4d.HAIRSTYLE_UPDATE_AUTO,True)
    bc.SetInt32(c4d.HAIRSTYLE_HAIR_COUNT,1)
    bc.SetInt32(c4d.HAIRSTYLE_HAIR_SEGMENTS,1)
    bc.SetInt32(c4d.HAIRSTYLE_HAIR_ROOT_PLACEMENT,c4d.HAIRSTYLE_ROOT_PLACEMENT_AUTO)
    bc.SetBool(c4d.HAIRSTYLE_ROOTS_ASNORMALS,True)
    bc.SetFloat(c4d.HAIRSTYLE_HAIR_UV_U_SPACING,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_HAIR_UV_V_SPACING,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_HAIR_UV_U_VAR,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_HAIR_UV_V_VAR,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_ROOT_OFFSET,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_ROOT_EXTEND,0.1)
    bc.SetBool(c4d.HAIRSTYLE_HAIR_ROOT_NULL_INVALID,True)
    bc.SetBool(c4d.HAIRSTYLE_HAIR_ROOT_MIN_SPACING,True)
    bc.SetFloat(c4d.HAIRSTYLE_HAIR_ROOT_DISTANCE,0.1)
    bc.SetInt32(c4d.HAIRSTYLE_HAIR_ROOT_DENSITY_LEVELS,1)
    bc.SetBool(c4d.HAIRSTYLE_HAIR_ROOT_RESTICT,True)
    bc.SetFloat(c4d.HAIRSTYLE_HAIR_ROOT_RESTRICT_DISTANCE,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_HAIR_ROOT_RESTRICT_COUNT,0.1)
    bc.SetInt32(c4d.HAIRSTYLE_HAIR_ROOT_MULTIPLY,1)
    bc.SetBool(c4d.HAIRSTYLE_HAIR_ROOT_MULTIPLY_SETROOTS,True)
    bc.SetFloat(c4d.HAIRSTYLE_HAIR_ROOT_MULTI_ROOT,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_HAIR_ROOT_MULTI_TIP,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_HAIR_ROOT_MULTI_SCALE,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_HAIR_ROOT_MULTI_SCALE_VAR,0.1)
    bc.SetInt32(c4d.HAIRSTYLE_INTERPOLATION_TYPE,c4d.HAIRSTYLE_INTERPOLATION_TYPE_LINEAR)
    bc.SetInt32(c4d.HAIRSTYLE_INTERPOLATION_GUIDES,1)
    bc.SetFloat(c4d.HAIRSTYLE_INTERPOLATION_VARIATION,0.1)
    bc.SetBool(c4d.HAIRSTYLE_INTERPOLATION_CLUMP,True)
    bc.SetBool(c4d.HAIRSTYLE_FUR,True)
    bc.SetInt32(c4d.HAIRSTYLE_FUR_COUNT,1)
    bc.SetBool(c4d.HAIRSTYLE_FUR_ONLY,True)
    bc.SetBool(c4d.HAIRSTYLE_FUR_SHADOWS,True)
    bc.SetBool(c4d.HAIRSTYLE_FUR_CACHE,True)
    bc.SetFloat(c4d.HAIRSTYLE_FUR_SCALE,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_FUR_SCALE_VAR,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_FUR_THICKNESS,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_FUR_THICKNESS_VAR,0.1)
    bc.SetBool(c4d.HAIRSTYLE_FUR_CLUMP,True)
    bc.SetInt32(c4d.HAIRSTYLE_PREVIEW,c4d.HAIRSTYLE_PREVIEW_NONE)
    bc.SetBool(c4d.HAIRSTYLE_PREVIEW_CACHE,True)
    bc.SetBool(c4d.HAIRSTYLE_BACKFACING,True)
    bc.SetBool(c4d.HAIRSTYLE_PREVIEW_NO_SHADING,True)
    bc.SetBool(c4d.HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING,True)
    bc.SetFloat(c4d.HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING_SPECULAR,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING_AO,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_PREVIEW_DETAIL,0.1)
    bc.SetInt32(c4d.HAIRSTYLE_EDITOR_GENERATE,c4d.HAIRSTYLE_EDITOR_GENERATE_NONE)
    bc.SetInt32(c4d.HAIRSTYLE_LOD_AFFECT,c4d.HAIRSTYLE_LOD_AFFECT_NONE)
    bc.SetBool(c4d.HAIRSTYLE_EDITOR_ASRENDER,True)
    bc.SetInt32(c4d.HAIRSTYLE_EDITOR_COUNT,1)
    bc.SetInt32(c4d.HAIRSTYLE_EDITOR_SEGCOUNT,1)
    bc.SetBool(c4d.HAIRSTYLE_RENDER_HAIR,True)
    bc.SetInt32(c4d.HAIRSTYLE_GENERATE,c4d.HAIRSTYLE_GENERATE_NONE)
    bc.SetBool(c4d.HAIRSTYLE_GENERATE_PERFRAME,True)
    bc.SetInt32(c4d.HAIRSTYLE_INSTANCE_AXIS,c4d.HAIRSTYLE_INSTANCE_AXIS_X)
    bc.SetInt32(c4d.HAIRSTYLE_INSTANCE_SCALING,c4d.HAIRSTYLE_INSTANCE_SCALING_UNIFORM)
    bc.SetInt32(c4d.HAIRSTYLE_INSTANCE_DEFORM,c4d.HAIRSTYLE_INSTANCE_DEFORM_NONE)
    bc.SetInt32(c4d.HAIRSTYLE_INSTANCE_HIERARCHY,c4d.HAIRSTYLE_INSTANCE_HIERARCHY_SINGLE)
    bc.SetInt32(c4d.HAIRSTYLE_INSTANCE_REPEAT,1)
    bc.SetBool(c4d.HAIRSTYLE_INSTANCE_MATERIALS,True)
    bc.SetFloat(c4d.HAIRSTYLE_INSTANCE_START,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_INSTANCE_END,0.1)
    bc.SetInt32(c4d.HAIRSTYLE_ROTATION,c4d.HAIRSTYLE_ROTATION_FREE)
    bc.SetBool(c4d.HAIRSTYLE_ROTATION_LOCAL,True)
    bc.SetBool(c4d.HAIRSTYLE_ROTATION_INVERT,True)
    bc.SetBool(c4d.HAIRSTYLE_SINGLE_OBJECT,True)
    bc.SetBool(c4d.HAIRSTYLE_CAP_START,True)
    bc.SetBool(c4d.HAIRSTYLE_CAP_END,True)
    bc.SetBool(c4d.HAIRSTYLE_SLICES,True)
    bc.SetInt32(c4d.HAIRSTYLE_SLICE_NORMAL,c4d.HAIRSTYLE_SLICE_NORMAL_GUIDE)
    bc.SetBool(c4d.HAIRSTYLE_DYNAMICS_ENABLE,True)
    bc.SetBool(c4d.HAIRSTYLE_DYNAMICS_COLLISIONS,True)
    bc.SetBool(c4d.HAIRSTYLE_DYNAMICS_EXTRA_STIFF,True)
    bc.SetFloat(c4d.HAIRSTYLE_DYNAMICS_RADIUS,0.1)
    bc.SetBool(c4d.HAIRSTYLE_DYNAMICS_FIXED_ROOTS,True)
    bc.SetFloat(c4d.HAIRSTYLE_DYNAMICS_MASS,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_DYNAMICS_DRAG,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_DYNAMICS_ROOT_HOLD,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_DYNAMICS_STIFFNESS,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_DYNAMICS_REST_MIX,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_DYNAMICS_REST_HOLD,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_DYNAMICS_ELASTIC_LIMIT,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_DYNAMICS_ELASTIC_DEFORM,0.1)
    bc.SetBool(c4d.HAIRSTYLE_DYNAMICS_AUTOTIME,True)
    bc.SetInt32(c4d.HAIRSTYLE_DYNAMICS_FRAMES,1)
    bc.SetInt32(c4d.HAIRSTYLE_DYNAMICS_APPLY,c4d.HAIRSTYLE_DYNAMICS_APPLY_GUIDES)
    bc.SetBool(c4d.HAIRSTYLE_DYNAMICS_CUSTOM,True)
    bc.SetInt32(c4d.HAIRSTYLE_DYNAMICS_SEGMENTS,1)
    bc.SetInt32(c4d.HAIRSTYLE_DYNAMICS_SUBDIV,1)
    bc.SetInt32(c4d.HAIRSTYLE_DYNAMICS_ITERATIONS,1)
    bc.SetBool(c4d.HAIRSTYLE_DYNAMICS_FORCES_HAIR,True)
    bc.SetBool(c4d.HAIRSTYLE_DYNAMICS_FORCES_OBJECTS,True)
    bc.SetFloat(c4d.HAIRSTYLE_DYNAMICS_GRAVITY,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_DYNAMICS_FORCES_RADIUS,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_DYNAMICS_FORCES_STRENGTH,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_DYNAMICS_FORCES_MAXSTRENGTH,0.1)
    bc.SetInt32(c4d.HAIRSTYLE_DYNAMICS_FORCES_FALLOFF,c4d.HAIRSTYLE_DYNAMICS_FORCES_FALLOFF_CONSTANT)
    bc.SetInt32(c4d.HAIRSTYLE_DYNAMICS_FORCES_INCEXC,c4d.HAIRSTYLE_DYNAMICS_FORCES_INCEXC_INCLUDE)
    bc.SetBool(c4d.HAIRSTYLE_DYNAMICS_CACHE_ENABLE,True)
    bc.SetBool(c4d.HAIRSTYLE_DYNAMICS_CACHE_COMPRESSED,True)
    bc.SetBool(c4d.HAIRSTYLE_DYNAMICS_EDITABLE,True)
    bc.SetInt32(c4d.HAIRSTYLE_DYNAMICS_CACHE_CACHE_LIMIT,1)
    bc.SetBool(c4d.HAIRSTYLE_PARTINGS_AUTO,True)
    bc.SetFloat(c4d.HAIRSTYLE_PARTINGS_DISTANCE,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_PARTINGS_ANGLE,0.1)
    bc.SetBool(c4d.HAIRSTYLE_GENERATE_CULL_BACKFACING,True)
    bc.SetBool(c4d.HAIRSTYLE_GENERATE_CULL_OFFSCREEN,True)
    bc.SetBool(c4d.HAIRSTYLE_GENERATE_CULL_DISTANCE,True)
    bc.SetFloat(c4d.HAIRSTYLE_GENERATE_CULL_BACKFACING_FADE,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_GENERATE_CULL_BACKFACING_FADE_END,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_GENERATE_CULL_DISTANCE_NEARCLIP,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_GENERATE_CULL_DISTANCE_NEARCLIP_FADE,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_GENERATE_CULL_DISTANCE_FARCLIP,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_GENERATE_CULL_DISTANCE_FARCLIP_FADE,0.1)
    bc.SetFloat(c4d.HAIRSTYLE_GENERATE_CULL_OFFSCREEN_PERCENT,0.1)
    bc.SetInt32(c4d.HAIRSTYLE_SEED,1)
    bc.SetInt32(c4d.HAIRSTYLE_ROOTS_GENERATE_ITERATIONS,1)
    bc.SetBool(c4d.HAIRSTYLE_DEFORMERS_ENABLE,True)
    bc.SetFloat(c4d.HAIRSTYLE_DEFORMERS_STRENGTH,0.1)

if __name__=='__main__':
    main()
             

C++

#include "c4d.h"
#include "../hair/description/ohair.h"
void SampleFunction()
{
    BaseDocument *pDoc = GetActiveDocument();
    BaseObject *pObject = BaseObject::Alloc(Ohair);
    pDoc->InsertObject(pObject);
    pDoc->StartUndo();
    pDoc->AddUndo(UNDO_NEW,pObject);
    pDoc->EndUndo();
    EventAdd(EVENT_FORCEREDRAW);
    
    //You can set parameters two different ways. 

    //First way              
    //Some objects do not store all their data in the container. You need to use GetParameter()/SetParameter() instead. 

    DESCFLAGS_SET flags = DESCFLAGS_SET_PARAM_SET;
    pObject->SetParameter(DescID(HAIRSTYLE_COUNT),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_SEGMENTS),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_LENGTH),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_ROOT_PLACEMENT),GeData(HAIRSTYLE_ROOT_PLACEMENT_FACE),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_ROOT_REMAPPING),GeData(HAIRSTYLE_ROOT_REMAPPING_NEW),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_UV_U_SPACING),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_UV_V_SPACING),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_UV_U_VAR),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_UV_V_VAR),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GROWTH),GeData(HAIRSTYLE_GROWTH_NORMALS),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GROWTH_DIRECTION_TYPE),GeData(HAIRSTYLE_GROWTH_DIRECTION_X),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GROWTH_DIRECTION_LOCAL),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_ROOT_MIN_SPACING),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_ROOT_DISTANCE),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_ROOT_DENSITY_LEVELS),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_SHELL_SEGMENT),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_SYMMETRY_ENABLE),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_SYMMETRY_PLANE),GeData(HAIRSTYLE_SYMMETRY_PLANE_XY),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_SYMMETRY_EDITOR),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_SYMMETRY_ROOT),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_UPDATE_AUTO),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_COUNT),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_SEGMENTS),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_PLACEMENT),GeData(HAIRSTYLE_ROOT_PLACEMENT_AUTO),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_ROOTS_ASNORMALS),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_UV_U_SPACING),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_UV_V_SPACING),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_UV_U_VAR),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_UV_V_VAR),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_ROOT_OFFSET),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_ROOT_EXTEND),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_NULL_INVALID),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_MIN_SPACING),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_DISTANCE),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_DENSITY_LEVELS),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_RESTICT),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_RESTRICT_DISTANCE),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_RESTRICT_COUNT),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_MULTIPLY),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_MULTIPLY_SETROOTS),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_MULTI_ROOT),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_MULTI_TIP),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_MULTI_SCALE),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_HAIR_ROOT_MULTI_SCALE_VAR),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_INTERPOLATION_TYPE),GeData(HAIRSTYLE_INTERPOLATION_TYPE_LINEAR),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_INTERPOLATION_GUIDES),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_INTERPOLATION_VARIATION),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_INTERPOLATION_CLUMP),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_FUR),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_FUR_COUNT),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_FUR_ONLY),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_FUR_SHADOWS),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_FUR_CACHE),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_FUR_SCALE),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_FUR_SCALE_VAR),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_FUR_THICKNESS),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_FUR_THICKNESS_VAR),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_FUR_CLUMP),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_PREVIEW),GeData(HAIRSTYLE_PREVIEW_NONE),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_PREVIEW_CACHE),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_BACKFACING),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_PREVIEW_NO_SHADING),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING_SPECULAR),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING_AO),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_PREVIEW_DETAIL),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_EDITOR_GENERATE),GeData(HAIRSTYLE_EDITOR_GENERATE_NONE),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_LOD_AFFECT),GeData(HAIRSTYLE_LOD_AFFECT_NONE),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_EDITOR_ASRENDER),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_EDITOR_COUNT),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_EDITOR_SEGCOUNT),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_RENDER_HAIR),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GENERATE),GeData(HAIRSTYLE_GENERATE_NONE),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GENERATE_PERFRAME),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_INSTANCE_AXIS),GeData(HAIRSTYLE_INSTANCE_AXIS_X),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_INSTANCE_SCALING),GeData(HAIRSTYLE_INSTANCE_SCALING_UNIFORM),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_INSTANCE_DEFORM),GeData(HAIRSTYLE_INSTANCE_DEFORM_NONE),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_INSTANCE_HIERARCHY),GeData(HAIRSTYLE_INSTANCE_HIERARCHY_SINGLE),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_INSTANCE_REPEAT),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_INSTANCE_MATERIALS),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_INSTANCE_START),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_INSTANCE_END),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_ROTATION),GeData(HAIRSTYLE_ROTATION_FREE),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_ROTATION_LOCAL),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_ROTATION_INVERT),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_SINGLE_OBJECT),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_CAP_START),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_CAP_END),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_SLICES),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_SLICE_NORMAL),GeData(HAIRSTYLE_SLICE_NORMAL_GUIDE),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_ENABLE),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_COLLISIONS),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_EXTRA_STIFF),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_RADIUS),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_FIXED_ROOTS),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_MASS),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_DRAG),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_ROOT_HOLD),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_STIFFNESS),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_REST_MIX),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_REST_HOLD),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_ELASTIC_LIMIT),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_ELASTIC_DEFORM),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_AUTOTIME),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_FRAMES),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_APPLY),GeData(HAIRSTYLE_DYNAMICS_APPLY_GUIDES),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_CUSTOM),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_SEGMENTS),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_SUBDIV),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_ITERATIONS),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_FORCES_HAIR),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_FORCES_OBJECTS),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_GRAVITY),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_FORCES_RADIUS),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_FORCES_STRENGTH),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_FORCES_MAXSTRENGTH),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_FORCES_FALLOFF),GeData(HAIRSTYLE_DYNAMICS_FORCES_FALLOFF_CONSTANT),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_FORCES_INCEXC),GeData(HAIRSTYLE_DYNAMICS_FORCES_INCEXC_INCLUDE),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_CACHE_ENABLE),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_CACHE_COMPRESSED),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_EDITABLE),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DYNAMICS_CACHE_CACHE_LIMIT),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_PARTINGS_AUTO),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_PARTINGS_DISTANCE),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_PARTINGS_ANGLE),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GENERATE_CULL_BACKFACING),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GENERATE_CULL_OFFSCREEN),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GENERATE_CULL_DISTANCE),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GENERATE_CULL_BACKFACING_FADE),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GENERATE_CULL_BACKFACING_FADE_END),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GENERATE_CULL_DISTANCE_NEARCLIP),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GENERATE_CULL_DISTANCE_NEARCLIP_FADE),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GENERATE_CULL_DISTANCE_FARCLIP),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GENERATE_CULL_DISTANCE_FARCLIP_FADE),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_GENERATE_CULL_OFFSCREEN_PERCENT),GeData(0.1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_SEED),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_ROOTS_GENERATE_ITERATIONS),GeData(1),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DEFORMERS_ENABLE),GeData(true),flags);
    pObject->SetParameter(DescID(HAIRSTYLE_DEFORMERS_STRENGTH),GeData(0.1),flags);
    pObject->Message(MSG_UPDATE);            

    //Second way, using the base container.
    BaseContainer *bc =     pObject->GetDataInstance();
    bc->SetInt32(HAIRSTYLE_COUNT,1);
    bc->SetInt32(HAIRSTYLE_SEGMENTS,1);
    bc->SetFloat(HAIRSTYLE_LENGTH,0.1);
    bc->SetInt32(HAIRSTYLE_ROOT_PLACEMENT,HAIRSTYLE_ROOT_PLACEMENT_FACE);
    bc->SetInt32(HAIRSTYLE_ROOT_REMAPPING,HAIRSTYLE_ROOT_REMAPPING_NEW);
    bc->SetFloat(HAIRSTYLE_UV_U_SPACING,0.1);
    bc->SetFloat(HAIRSTYLE_UV_V_SPACING,0.1);
    bc->SetFloat(HAIRSTYLE_UV_U_VAR,0.1);
    bc->SetFloat(HAIRSTYLE_UV_V_VAR,0.1);
    bc->SetInt32(HAIRSTYLE_GROWTH,HAIRSTYLE_GROWTH_NORMALS);
    bc->SetInt32(HAIRSTYLE_GROWTH_DIRECTION_TYPE,HAIRSTYLE_GROWTH_DIRECTION_X);
    bc->SetBool(HAIRSTYLE_GROWTH_DIRECTION_LOCAL,true);
    bc->SetBool(HAIRSTYLE_ROOT_MIN_SPACING,true);
    bc->SetFloat(HAIRSTYLE_ROOT_DISTANCE,0.1);
    bc->SetInt32(HAIRSTYLE_ROOT_DENSITY_LEVELS,1);
    bc->SetInt32(HAIRSTYLE_SHELL_SEGMENT,1);
    bc->SetBool(HAIRSTYLE_SYMMETRY_ENABLE,true);
    bc->SetInt32(HAIRSTYLE_SYMMETRY_PLANE,HAIRSTYLE_SYMMETRY_PLANE_XY);
    bc->SetBool(HAIRSTYLE_SYMMETRY_EDITOR,true);
    bc->SetBool(HAIRSTYLE_SYMMETRY_ROOT,true);
    bc->SetBool(HAIRSTYLE_UPDATE_AUTO,true);
    bc->SetInt32(HAIRSTYLE_HAIR_COUNT,1);
    bc->SetInt32(HAIRSTYLE_HAIR_SEGMENTS,1);
    bc->SetInt32(HAIRSTYLE_HAIR_ROOT_PLACEMENT,HAIRSTYLE_ROOT_PLACEMENT_AUTO);
    bc->SetBool(HAIRSTYLE_ROOTS_ASNORMALS,true);
    bc->SetFloat(HAIRSTYLE_HAIR_UV_U_SPACING,0.1);
    bc->SetFloat(HAIRSTYLE_HAIR_UV_V_SPACING,0.1);
    bc->SetFloat(HAIRSTYLE_HAIR_UV_U_VAR,0.1);
    bc->SetFloat(HAIRSTYLE_HAIR_UV_V_VAR,0.1);
    bc->SetFloat(HAIRSTYLE_ROOT_OFFSET,0.1);
    bc->SetFloat(HAIRSTYLE_ROOT_EXTEND,0.1);
    bc->SetBool(HAIRSTYLE_HAIR_ROOT_NULL_INVALID,true);
    bc->SetBool(HAIRSTYLE_HAIR_ROOT_MIN_SPACING,true);
    bc->SetFloat(HAIRSTYLE_HAIR_ROOT_DISTANCE,0.1);
    bc->SetInt32(HAIRSTYLE_HAIR_ROOT_DENSITY_LEVELS,1);
    bc->SetBool(HAIRSTYLE_HAIR_ROOT_RESTICT,true);
    bc->SetFloat(HAIRSTYLE_HAIR_ROOT_RESTRICT_DISTANCE,0.1);
    bc->SetFloat(HAIRSTYLE_HAIR_ROOT_RESTRICT_COUNT,0.1);
    bc->SetInt32(HAIRSTYLE_HAIR_ROOT_MULTIPLY,1);
    bc->SetBool(HAIRSTYLE_HAIR_ROOT_MULTIPLY_SETROOTS,true);
    bc->SetFloat(HAIRSTYLE_HAIR_ROOT_MULTI_ROOT,0.1);
    bc->SetFloat(HAIRSTYLE_HAIR_ROOT_MULTI_TIP,0.1);
    bc->SetFloat(HAIRSTYLE_HAIR_ROOT_MULTI_SCALE,0.1);
    bc->SetFloat(HAIRSTYLE_HAIR_ROOT_MULTI_SCALE_VAR,0.1);
    bc->SetInt32(HAIRSTYLE_INTERPOLATION_TYPE,HAIRSTYLE_INTERPOLATION_TYPE_LINEAR);
    bc->SetInt32(HAIRSTYLE_INTERPOLATION_GUIDES,1);
    bc->SetFloat(HAIRSTYLE_INTERPOLATION_VARIATION,0.1);
    bc->SetBool(HAIRSTYLE_INTERPOLATION_CLUMP,true);
    bc->SetBool(HAIRSTYLE_FUR,true);
    bc->SetInt32(HAIRSTYLE_FUR_COUNT,1);
    bc->SetBool(HAIRSTYLE_FUR_ONLY,true);
    bc->SetBool(HAIRSTYLE_FUR_SHADOWS,true);
    bc->SetBool(HAIRSTYLE_FUR_CACHE,true);
    bc->SetFloat(HAIRSTYLE_FUR_SCALE,0.1);
    bc->SetFloat(HAIRSTYLE_FUR_SCALE_VAR,0.1);
    bc->SetFloat(HAIRSTYLE_FUR_THICKNESS,0.1);
    bc->SetFloat(HAIRSTYLE_FUR_THICKNESS_VAR,0.1);
    bc->SetBool(HAIRSTYLE_FUR_CLUMP,true);
    bc->SetInt32(HAIRSTYLE_PREVIEW,HAIRSTYLE_PREVIEW_NONE);
    bc->SetBool(HAIRSTYLE_PREVIEW_CACHE,true);
    bc->SetBool(HAIRSTYLE_BACKFACING,true);
    bc->SetBool(HAIRSTYLE_PREVIEW_NO_SHADING,true);
    bc->SetBool(HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING,true);
    bc->SetFloat(HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING_SPECULAR,0.1);
    bc->SetFloat(HAIRSTYLE_PREVIEW_GPU_ENHANCED_SHADING_AO,0.1);
    bc->SetFloat(HAIRSTYLE_PREVIEW_DETAIL,0.1);
    bc->SetInt32(HAIRSTYLE_EDITOR_GENERATE,HAIRSTYLE_EDITOR_GENERATE_NONE);
    bc->SetInt32(HAIRSTYLE_LOD_AFFECT,HAIRSTYLE_LOD_AFFECT_NONE);
    bc->SetBool(HAIRSTYLE_EDITOR_ASRENDER,true);
    bc->SetInt32(HAIRSTYLE_EDITOR_COUNT,1);
    bc->SetInt32(HAIRSTYLE_EDITOR_SEGCOUNT,1);
    bc->SetBool(HAIRSTYLE_RENDER_HAIR,true);
    bc->SetInt32(HAIRSTYLE_GENERATE,HAIRSTYLE_GENERATE_NONE);
    bc->SetBool(HAIRSTYLE_GENERATE_PERFRAME,true);
    bc->SetInt32(HAIRSTYLE_INSTANCE_AXIS,HAIRSTYLE_INSTANCE_AXIS_X);
    bc->SetInt32(HAIRSTYLE_INSTANCE_SCALING,HAIRSTYLE_INSTANCE_SCALING_UNIFORM);
    bc->SetInt32(HAIRSTYLE_INSTANCE_DEFORM,HAIRSTYLE_INSTANCE_DEFORM_NONE);
    bc->SetInt32(HAIRSTYLE_INSTANCE_HIERARCHY,HAIRSTYLE_INSTANCE_HIERARCHY_SINGLE);
    bc->SetInt32(HAIRSTYLE_INSTANCE_REPEAT,1);
    bc->SetBool(HAIRSTYLE_INSTANCE_MATERIALS,true);
    bc->SetFloat(HAIRSTYLE_INSTANCE_START,0.1);
    bc->SetFloat(HAIRSTYLE_INSTANCE_END,0.1);
    bc->SetInt32(HAIRSTYLE_ROTATION,HAIRSTYLE_ROTATION_FREE);
    bc->SetBool(HAIRSTYLE_ROTATION_LOCAL,true);
    bc->SetBool(HAIRSTYLE_ROTATION_INVERT,true);
    bc->SetBool(HAIRSTYLE_SINGLE_OBJECT,true);
    bc->SetBool(HAIRSTYLE_CAP_START,true);
    bc->SetBool(HAIRSTYLE_CAP_END,true);
    bc->SetBool(HAIRSTYLE_SLICES,true);
    bc->SetInt32(HAIRSTYLE_SLICE_NORMAL,HAIRSTYLE_SLICE_NORMAL_GUIDE);
    bc->SetBool(HAIRSTYLE_DYNAMICS_ENABLE,true);
    bc->SetBool(HAIRSTYLE_DYNAMICS_COLLISIONS,true);
    bc->SetBool(HAIRSTYLE_DYNAMICS_EXTRA_STIFF,true);
    bc->SetFloat(HAIRSTYLE_DYNAMICS_RADIUS,0.1);
    bc->SetBool(HAIRSTYLE_DYNAMICS_FIXED_ROOTS,true);
    bc->SetFloat(HAIRSTYLE_DYNAMICS_MASS,0.1);
    bc->SetFloat(HAIRSTYLE_DYNAMICS_DRAG,0.1);
    bc->SetFloat(HAIRSTYLE_DYNAMICS_ROOT_HOLD,0.1);
    bc->SetFloat(HAIRSTYLE_DYNAMICS_STIFFNESS,0.1);
    bc->SetFloat(HAIRSTYLE_DYNAMICS_REST_MIX,0.1);
    bc->SetFloat(HAIRSTYLE_DYNAMICS_REST_HOLD,0.1);
    bc->SetFloat(HAIRSTYLE_DYNAMICS_ELASTIC_LIMIT,0.1);
    bc->SetFloat(HAIRSTYLE_DYNAMICS_ELASTIC_DEFORM,0.1);
    bc->SetBool(HAIRSTYLE_DYNAMICS_AUTOTIME,true);
    bc->SetInt32(HAIRSTYLE_DYNAMICS_FRAMES,1);
    bc->SetInt32(HAIRSTYLE_DYNAMICS_APPLY,HAIRSTYLE_DYNAMICS_APPLY_GUIDES);
    bc->SetBool(HAIRSTYLE_DYNAMICS_CUSTOM,true);
    bc->SetInt32(HAIRSTYLE_DYNAMICS_SEGMENTS,1);
    bc->SetInt32(HAIRSTYLE_DYNAMICS_SUBDIV,1);
    bc->SetInt32(HAIRSTYLE_DYNAMICS_ITERATIONS,1);
    bc->SetBool(HAIRSTYLE_DYNAMICS_FORCES_HAIR,true);
    bc->SetBool(HAIRSTYLE_DYNAMICS_FORCES_OBJECTS,true);
    bc->SetFloat(HAIRSTYLE_DYNAMICS_GRAVITY,0.1);
    bc->SetFloat(HAIRSTYLE_DYNAMICS_FORCES_RADIUS,0.1);
    bc->SetFloat(HAIRSTYLE_DYNAMICS_FORCES_STRENGTH,0.1);
    bc->SetFloat(HAIRSTYLE_DYNAMICS_FORCES_MAXSTRENGTH,0.1);
    bc->SetInt32(HAIRSTYLE_DYNAMICS_FORCES_FALLOFF,HAIRSTYLE_DYNAMICS_FORCES_FALLOFF_CONSTANT);
    bc->SetInt32(HAIRSTYLE_DYNAMICS_FORCES_INCEXC,HAIRSTYLE_DYNAMICS_FORCES_INCEXC_INCLUDE);
    bc->SetBool(HAIRSTYLE_DYNAMICS_CACHE_ENABLE,true);
    bc->SetBool(HAIRSTYLE_DYNAMICS_CACHE_COMPRESSED,true);
    bc->SetBool(HAIRSTYLE_DYNAMICS_EDITABLE,true);
    bc->SetInt32(HAIRSTYLE_DYNAMICS_CACHE_CACHE_LIMIT,1);
    bc->SetBool(HAIRSTYLE_PARTINGS_AUTO,true);
    bc->SetFloat(HAIRSTYLE_PARTINGS_DISTANCE,0.1);
    bc->SetFloat(HAIRSTYLE_PARTINGS_ANGLE,0.1);
    bc->SetBool(HAIRSTYLE_GENERATE_CULL_BACKFACING,true);
    bc->SetBool(HAIRSTYLE_GENERATE_CULL_OFFSCREEN,true);
    bc->SetBool(HAIRSTYLE_GENERATE_CULL_DISTANCE,true);
    bc->SetFloat(HAIRSTYLE_GENERATE_CULL_BACKFACING_FADE,0.1);
    bc->SetFloat(HAIRSTYLE_GENERATE_CULL_BACKFACING_FADE_END,0.1);
    bc->SetFloat(HAIRSTYLE_GENERATE_CULL_DISTANCE_NEARCLIP,0.1);
    bc->SetFloat(HAIRSTYLE_GENERATE_CULL_DISTANCE_NEARCLIP_FADE,0.1);
    bc->SetFloat(HAIRSTYLE_GENERATE_CULL_DISTANCE_FARCLIP,0.1);
    bc->SetFloat(HAIRSTYLE_GENERATE_CULL_DISTANCE_FARCLIP_FADE,0.1);
    bc->SetFloat(HAIRSTYLE_GENERATE_CULL_OFFSCREEN_PERCENT,0.1);
    bc->SetInt32(HAIRSTYLE_SEED,1);
    bc->SetInt32(HAIRSTYLE_ROOTS_GENERATE_ITERATIONS,1);
    bc->SetBool(HAIRSTYLE_DEFORMERS_ENABLE,true);
    bc->SetFloat(HAIRSTYLE_DEFORMERS_STRENGTH,0.1);
    pObject->Message(MSG_UPDATE);                                                      
}
             

Buttons

This node has buttons. Buttons can manually be executed by calling the following code

Python

c4d.CallButton(obj,c4d.HAIRSTYLE_STATE_REROOT)
c4d.CallButton(obj,c4d.HAIRSTYLE_STATE_RESET)
c4d.CallButton(obj,c4d.HAIRSTYLE_STATE_STORE)
c4d.CallButton(obj,c4d.HAIRSTYLE_STATE_RESTORE)
c4d.CallButton(obj,c4d.HAIRSTYLE_STATE_CLEAR)
c4d.CallButton(obj,c4d.HAIRSTYLE_SYMMETRY_EDITABLE)
c4d.CallButton(obj,c4d.HAIRSTYLE_UPDATE)
c4d.CallButton(obj,c4d.HAIRSTYLE_DYNAMICS_RELAX)
c4d.CallButton(obj,c4d.HAIRSTYLE_DYNAMICS_CACHE_CALCULATE)
c4d.CallButton(obj,c4d.HAIRSTYLE_DYNAMICS_CACHE_DELETE)
c4d.CallButton(obj,c4d.HAIRSTYLE_DYNAMICS_CACHE_CACHE_FRAME)
c4d.CallButton(obj,c4d.HAIRSTYLE_DYNAMICS_CACHE_CACHE_LOAD)
c4d.CallButton(obj,c4d.HAIRSTYLE_DYNAMICS_CACHE_CACHE_SAVE)

C++

DescriptionCommand dc;
dc.id = DescID(HAIRSTYLE_STATE_REROOT);             
pObject->Message(MSG_DESCRIPTION_COMMAND, &dc);

DescriptionCommand dc; dc.id = DescID(HAIRSTYLE_STATE_RESET); pObject->Message(MSG_DESCRIPTION_COMMAND, &dc);
DescriptionCommand dc; dc.id = DescID(HAIRSTYLE_STATE_STORE); pObject->Message(MSG_DESCRIPTION_COMMAND, &dc);
DescriptionCommand dc; dc.id = DescID(HAIRSTYLE_STATE_RESTORE); pObject->Message(MSG_DESCRIPTION_COMMAND, &dc);
DescriptionCommand dc; dc.id = DescID(HAIRSTYLE_STATE_CLEAR); pObject->Message(MSG_DESCRIPTION_COMMAND, &dc);
DescriptionCommand dc; dc.id = DescID(HAIRSTYLE_SYMMETRY_EDITABLE); pObject->Message(MSG_DESCRIPTION_COMMAND, &dc);
DescriptionCommand dc; dc.id = DescID(HAIRSTYLE_UPDATE); pObject->Message(MSG_DESCRIPTION_COMMAND, &dc);
DescriptionCommand dc; dc.id = DescID(HAIRSTYLE_DYNAMICS_RELAX); pObject->Message(MSG_DESCRIPTION_COMMAND, &dc);
DescriptionCommand dc; dc.id = DescID(HAIRSTYLE_DYNAMICS_CACHE_CALCULATE); pObject->Message(MSG_DESCRIPTION_COMMAND, &dc);
DescriptionCommand dc; dc.id = DescID(HAIRSTYLE_DYNAMICS_CACHE_DELETE); pObject->Message(MSG_DESCRIPTION_COMMAND, &dc);
DescriptionCommand dc; dc.id = DescID(HAIRSTYLE_DYNAMICS_CACHE_CACHE_FRAME); pObject->Message(MSG_DESCRIPTION_COMMAND, &dc);
DescriptionCommand dc; dc.id = DescID(HAIRSTYLE_DYNAMICS_CACHE_CACHE_LOAD); pObject->Message(MSG_DESCRIPTION_COMMAND, &dc);
DescriptionCommand dc; dc.id = DescID(HAIRSTYLE_DYNAMICS_CACHE_CACHE_SAVE); pObject->Message(MSG_DESCRIPTION_COMMAND, &dc);