diff options
author | YimingWu <xp8110@outlook.com> | 2022-03-29 17:46:30 +0300 |
---|---|---|
committer | YimingWu <xp8110@outlook.com> | 2022-03-29 17:46:56 +0300 |
commit | c4e4924096d1dcfd971aafbbf82d848a774b57db (patch) | |
tree | db2deb2dc65e25ae31076abb0de58192195f22a0 /source/blender/makesdna | |
parent | 0e0977f3e68b2ac1fd021b5dc6ca10e5b9a25da1 (diff) |
GPencil: Fading for build modifier.
Adds fading support for build modifier so it's not a hard cut off
Reviewed By: Antonio Vazquez (antoniov), Matias Mendiola (mendio)
Differential Revision: https://developer.blender.org/D14309
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r-- | source/blender/makesdna/DNA_gpencil_modifier_types.h | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/source/blender/makesdna/DNA_gpencil_modifier_types.h b/source/blender/makesdna/DNA_gpencil_modifier_types.h index 7568dc5ff9a..6603ed1a078 100644 --- a/source/blender/makesdna/DNA_gpencil_modifier_types.h +++ b/source/blender/makesdna/DNA_gpencil_modifier_types.h @@ -392,9 +392,20 @@ typedef struct BuildGpencilModifierData { * For the "Concurrent" mode, when should "shorter" strips start/end. */ short time_alignment; + + /** Build origin control object. */ + struct Object *object; + /** Factor of the stroke (used instead of frame evaluation. */ float percentage_fac; - char _pad[4]; + + /** Weight fading at the end of the stroke. */ + float fade_fac; + /** Target vertexgroup name, MAX_VGROUP_NAME. */ + char target_vgname[64]; + /** Fading strength of opacity and thickness */ + float fade_opacity_strength; + float fade_thickness_strength; } BuildGpencilModifierData; typedef enum eBuildGpencil_Mode { @@ -412,7 +423,7 @@ typedef enum eBuildGpencil_Transition { /* Hide in reverse order */ GP_BUILD_TRANSITION_SHRINK = 1, /* Hide in forward order */ - GP_BUILD_TRANSITION_FADE = 2, + GP_BUILD_TRANSITION_VANISH = 2, } eBuildGpencil_Transition; typedef enum eBuildGpencil_TimeAlignment { @@ -435,6 +446,7 @@ typedef enum eBuildGpencil_Flag { /* Use a percentage instead of frame number to evaluate strokes. */ GP_BUILD_PERCENTAGE = (1 << 4), + GP_BUILD_USE_FADING = (1 << 5), } eBuildGpencil_Flag; typedef struct LatticeGpencilModifierData { |