# GpencilModifier(bpy_struct)

base class — `bpy_struct`

subclasses — `ArmatureGpencilModifier`, `ArrayGpencilModifier`, `BuildGpencilModifier`, `ColorGpencilModifier`, `HookGpencilModifier`, `LatticeGpencilModifier`, `MirrorGpencilModifier`, `MultiplyGpencilModifier`, `NoiseGpencilModifier`, `OffsetGpencilModifier`, `OpacityGpencilModifier`, `SimplifyGpencilModifier`, `SmoothGpencilModifier`, `SubdivGpencilModifier`, `ThickGpencilModifier`, `TimeGpencilModifier`, `TintGpencilModifier`

class `bpy.types.``GpencilModifier`(bpy_struct)

  Modifier affecting the grease pencil object

  `name`

    Modifier name

    Type: | string, default “”, (never None)

  `show_expanded`

    Set modifier expanded in the user interface

    Type: | boolean, default False

  `show_in_editmode`

    Display modifier in Edit mode

    Type: | boolean, default False

  `show_render`

    Use modifier during render

    Type: | boolean, default False

  `show_viewport`

    Display modifier in viewport

    Type: | boolean, default False

  `type`
    - `GP_ARRAY` Array, Create array of duplicate instances.
    - `GP_BUILD` Build, Create duplication of strokes.
    - `GP_MIRROR` Mirror, Duplicate strokes like a mirror.
    - `GP_SIMPLIFY` Simplify, Simplify stroke reducing number of points.
    - `GP_SUBDIV` Subdivide, Subdivide stroke adding more control points.
    - `GP_MULTIPLY` Multiple Strokes, Produce multiple strokes along one stroke.
    - `GP_ARMATURE` Armature, Deform stroke points using armature object.
    - `GP_HOOK` Hook, Deform stroke points using objects.
    - `GP_LATTICE` Lattice, Deform strokes using lattice.
    - `GP_NOISE` Noise, Add noise to strokes.
    - `GP_OFFSET` Offset, Change stroke location, rotation or scale.
    - `GP_SMOOTH` Smooth, Smooth stroke.
    - `GP_THICK` Thickness, Change stroke thickness.
    - `GP_TIME` Time Offset, Offset keyframes.
    - `GP_COLOR` Hue/Saturation, Apply changes to stroke colors.
    - `GP_OPACITY` Opacity, Opacity of the strokes.
    - `GP_TINT` Tint, Tint strokes with new color.

    Type: | enum in [‘GP_ARRAY’, ‘GP_BUILD’, ‘GP_MIRROR’, ‘GP_SIMPLIFY’, ‘GP_SUBDIV’, ‘GP_MULTIPLY’, ‘GP_ARMATURE’, ‘GP_HOOK’, ‘GP_LATTICE’, ‘GP_NOISE’, ‘GP_OFFSET’, ‘GP_SMOOTH’, ‘GP_THICK’, ‘GP_TIME’, ‘GP_COLOR’, ‘GP_OPACITY’, ‘GP_TINT’], default ‘GP_ARRAY’, (readonly)

  classmethod `bl_rna_get_subclass`(id, default=None)

    Parameters: | id (string) – The RNA type identifier.
    Returns: | The RNA type or default when not found.
    Return type: | `bpy.types.Struct` subclass

  classmethod `bl_rna_get_subclass_py`(id, default=None)

    Parameters: | id (string) – The RNA type identifier.
    Returns: | The class or default when not found.
    Return type: | type

Inherited Properties

`bpy_struct.id_data` |

Inherited Functions

`bpy_struct.as_pointer` `bpy_struct.driver_add` `bpy_struct.driver_remove` `bpy_struct.get` `bpy_struct.is_property_hidden` `bpy_struct.is_property_overridable_library` `bpy_struct.is_property_readonly` `bpy_struct.is_property_set` `bpy_struct.items` `bpy_struct.keyframe_delete` | `bpy_struct.keyframe_insert` `bpy_struct.keys` `bpy_struct.path_from_id` `bpy_struct.path_resolve` `bpy_struct.pop` `bpy_struct.property_overridable_library_set` `bpy_struct.property_unset` `bpy_struct.type_recast` `bpy_struct.values`

References

`Object.grease_pencil_modifiers` `ObjectGpencilModifiers.new` | `ObjectGpencilModifiers.remove` `UILayout.template_greasepencil_modifier`