From f25e7d62b3023812eb594250d22e142c02533482 Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Wed, 8 May 2013 14:20:57 +0000 Subject: Mask modifier for sequences This modifier uses a mask set in the modifier settings and multiplies strip by it. Alpha channel will also be multiplied by mask, which makes it easy to mask some objects on footage and alpha-over them in sequencer. Actually, this modifier sets alpha for byte strips directly (since byte is always straight alpha) and multiplies float buffer by mask (flaots are premulled) so in both cases masked strip could be easy alpha-overed without any artifacts. It uses own structure with only SequenceModifierData property in to preserve both forward and backwards compatibilities (using new structure ensures modifier will be ignored on load in older blenders, the same happens for mesh modifiers actually). Request from Pablo Vazquez. --- source/blender/makesdna/DNA_sequence_types.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source/blender/makesdna/DNA_sequence_types.h') diff --git a/source/blender/makesdna/DNA_sequence_types.h b/source/blender/makesdna/DNA_sequence_types.h index d9057c45380..5dbc80c16a5 100644 --- a/source/blender/makesdna/DNA_sequence_types.h +++ b/source/blender/makesdna/DNA_sequence_types.h @@ -289,6 +289,10 @@ typedef struct BrightContrastModifierData { float contrast; } BrightContrastModifierData; +typedef struct SequencerMaskModifierData { + SequenceModifierData modifier; +} SequencerMaskModifierData; + /* ***************** Scopes ****************** */ typedef struct SequencerScopes { @@ -434,6 +438,7 @@ enum { seqModifierType_Curves = 2, seqModifierType_HueCorrect = 3, seqModifierType_BrightContrast = 4, + seqModifierType_Mask = 5, NUM_SEQUENCE_MODIFIER_TYPES }; -- cgit v1.2.3