SculptBrushParams

c4d.modules.sculpting

New in version R16.021.

The parameters to pass in when registering a Sculpting Brush.

Members

SculptBrushParams.EnableStencil()
Does the brush use stencils?
Settings this to False will let the brush know that you are not going to be using stencils. This will free up some resource and computation time.
Note that setting to False will also remove the tab from the brush interface.
Parameters:enable (bool) – True if the brush uses stencils, otherwise False. Default is True.
SculptBrushParams.EnableStamp()
Does the brush use stamps?
Setting this to False will let the brush know that you are not going to be using stamps. This will free up some resource and computation time.
Note that setting to False will also remove the tab from the brush interface.
Parameters:enable (bool) – True if the brush uses stamps, otherwise False. Default is True.
SculptBrushParams.EnableInvertCheckbox()
Does the brush use the invert checkbox?
Lets the system know if you are using the invert checkbox or not.
Note that by default the invert checkbox is not part of the base .res file so you will need to add it yourself to your own brushes .res file.
To do this just add the following data to your .res file exactly as shown:
GROUP MDATA_SCULPTBRUSH_SETTINGS_GROUP
{
  COLUMNS 3;
  BOOL MDATA_SCULPTBRUSH_SETTINGS_INVERT { }
  STATICTEXT { DUMMY; }
  STATICTEXT { DUMMY; }
}
Parameters:enable (bool) – True if the brush uses the invert checkbox, otherwise False. Default is False.
SculptBrushParams.EnableBuildup()
Does the brush use the buildup slider?
Lets the system know if you are using the buildup slider or not.
Note that by default the buildup slider is not part of the base .res file so you will need to add it yourself to your own brushes .res file.
To do this just add the following data to your .res file exactly as shown:
GROUP MDATA_SCULPTBRUSH_SETTINGS_GROUP
{
  COLUMNS 3;
  REAL MDATA_SCULPTBRUSH_SETTINGS_BUILDUP { MIN 1; MAX 100; MINSLIDER 1; MAXSLIDER 100; CUSTOMGUI REALSLIDER; FIT_H; SCALE_H; }
  STATICTEXT { JOINENDSCALE; }
  STATICTEXT { JOINEND; }
}
Parameters:enable (bool) – True if the brush uses the buildup slider, otherwise False. Default is False.
SculptBrushParams.EnableNonModelPickMode()
Does the brush do anything if the user clicks off of a model?
I.e. have you implemented SculptBrushToolData.HandleNonModelPickMode and :meth:`SculptBrushToolData.DrawNonModelPickMode()?
Private.
Parameters:enable (bool) – True if the brush has implemented SculptBrushToolData.HandleNonModelPickMode() and SculptBrushToolData.DrawNonModelPickMode(), otherwise False. Default is False.
SculptBrushParams.EnableFlood()
Does the brush have a Flood function?
I.e. have you implemented FloodSelectedLayer.
Note that by default the Flood button is not part of the base .res file so you will need to add it yourself to your own brushes .res file.
To do this just add the following data to your .res file exactly as shown:
GROUP MDATA_SCULPTBRUSH_SETTINGS_GROUP
{
  COLUMNS 3;
  BUTTON MDATA_SCULPTBRUSH_SETTINGS_FLOOD{ }
  STATICTEXT { JOINENDSCALE; }
  STATICTEXT { JOINEND; }
}
Parameters:enable (bool) – True if the brush has implemented a Flood function, otherwise False. Default is False.
SculptBrushParams.EnableToolSpecificSmooth()
Does the brush have its own smooth operation that gets used when you press the shift key?
You can check for this in the SculptBrushToolData.ApplyDab() method by checking if (GetBrushOverride() & OVERRIDE_SMOOTHTOOL) is True and then you can implement your own smooth method.
Otherwise it will use the Smooth Brush for smoothing.
Parameters:enable (bool) – True if you are handling smoothing yourself, otherwise False. Default is False.
SculptBrushParams.EnableModifier()

Tells the system that this brush can use modifiers from other brushes (display the modifiers tab).

Parameters:enable (bool) – Set to True if you want this brush to be able to use modifiers from other brushes.
SculptBrushParams.EnableDrawDirection()
When enabled the Draw Direction UI will appear in the settings tab.
Calls can then be made to BrushDabData.GetDrawDirectionNormal() to get the direction of the normal based on the currently selected Draw Direction.
Parameters:enable (bool) – Set to True to display the Draw Direction UI. Disabled by default.
SculptBrushParams.EnableRespectSelections()

When enabled will tell the brush to respect Point and Polygon selections when in Point or Polygon mode respectively.

Parameters:enable (bool) – True if the brush should respect selections, otherwise False. Default is False.
SculptBrushParams.EnableFillToolIsolatedPointRemover()
When this is enabled it will tell the Fill algorithm to remove any isolated points. That is any points that are selected but have no neighboring selections.

This can happen on high resolution meshes due to the nature of the hit detection against screen space pixels defined by the fill tools.
By setting this to False it will keep any isolated points that are selected.
This is set to True by default so isolated points are removed before being sent to the SculptBrushToolData.ApplyDab() function.
Parameters:enable (bool) – True if the brush should remove isolated points, False if it should keep them. Default is True.
SculptBrushParams.EnablePressureHUD()

When enabled will display the pressure value in the sculpting size/pressure HUD.

Parameters:enable (bool) – True if the brush should dispay the pressure value, otherwise False. Default is True.
SculptBrushParams.SetFloodType(type)

Specifies what kind of data the flood operation will change (points or mask).

Parameters:type (int) – The flood data type. Default is SCULPTBRUSHDATATYPE_POINT.
SculptBrushParams.SetBrushMode(mode)

Specifies what type of brush this is (grab or normal).

Parameters:mode (int) – The brush mode. Default is SCULPTBRUSHMODE_NORMAL.
SculptBrushParams.SetFirstHitPointType(type)

Specifies what should happen when the user first clicks on model before dragging.

Parameters:type (int) – The first hitpoint type. Default is FIRSTHITPPOINTTYPE_SELECTED.
SculptBrushParams.SetUndoType(type)

Specifies what kind of data the brush will be changing and storing in the undo system (point or mask).

Parameters:type (int) – The brush data type. Default is SCULPTBRUSHDATATYPE_POINT.

Table Of Contents