diff options
author | Antonio Vazquez <blendergit@gmail.com> | 2022-05-02 18:28:24 +0300 |
---|---|---|
committer | Antonio Vazquez <blendergit@gmail.com> | 2022-05-02 18:36:58 +0300 |
commit | 0d9e22d43ca18d8326aed33fabe3177dcf0663b8 (patch) | |
tree | c8a7e49048142f2d15657cf0b4d9062f57f71338 /source/blender/makesdna | |
parent | b1e0be0d2553742fcceda9cfe29ebb70f26b06a1 (diff) |
GPencil: New Noise modifier random in Keyframes only
This is for some animation styles that usually copy and paste keyframes and they want avoid that both frames look equal, but they don't want noise randomness changes in the inbetween frames.
The patch adds a new random `Mode` option to select when the noise change.
Reviewed By: pepeland
Maniphest Tasks: T97099
Differential Revision: https://developer.blender.org/D14566
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r-- | source/blender/makesdna/DNA_gpencil_modifier_types.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/source/blender/makesdna/DNA_gpencil_modifier_types.h b/source/blender/makesdna/DNA_gpencil_modifier_types.h index b0e7342c9cb..535533565dd 100644 --- a/source/blender/makesdna/DNA_gpencil_modifier_types.h +++ b/source/blender/makesdna/DNA_gpencil_modifier_types.h @@ -102,7 +102,8 @@ typedef struct NoiseGpencilModifierData { /** Noise Frequency scaling */ float noise_scale; float noise_offset; - char _pad[4]; + short noise_mode; + char _pad[2]; /** How many frames before recalculate randoms. */ int step; /** Custom index for passes. */ @@ -127,6 +128,11 @@ typedef enum eNoiseGpencil_Flag { GP_NOISE_INVERT_MATERIAL = (1 << 11), } eNoiseGpencil_Flag; +typedef enum eNoiseRandomGpencil_Mode { + GP_NOISE_RANDOM_STEP = 0, + GP_NOISE_RANDOM_KEYFRAME = 1, +} eNoiseRandomGpencil_Mode; + typedef struct SubdivGpencilModifierData { GpencilModifierData modifier; /** Material for filtering. */ |