diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2013-02-27 14:26:58 +0400 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2013-02-27 14:26:58 +0400 |
commit | 3d7867d7f0955cb856c28425e52b18d1a1925d1e (patch) | |
tree | e7faf820de6c8a7ec1410ddf3032aee504392eb3 /source/blender/makesrna/intern | |
parent | 4e59fb23525e09763115ea790ac6903c4cc6d3f4 (diff) |
Added RGBA|RGB channels toggle to sequencer preview
Main purpose of this is to be more compatible with older
versions of blender (before alpha cleanup) where sequencer
used to display premultiplied image on an straight opengl
viewport.
Now sequencer preview would behave closer to image editor
However adding Alpha and R|G|B displays is not so simple
because sequencer is using 2D textures. Would be nice to
implement this options as well, but this is not so much
important IMO.
This hall fix
- #34453: VSE: Subtract function does not work properly
TODO: Make RGBA display default for our startup.blend
Diffstat (limited to 'source/blender/makesrna/intern')
-rw-r--r-- | source/blender/makesrna/intern/rna_space.c | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/source/blender/makesrna/intern/rna_space.c b/source/blender/makesrna/intern/rna_space.c index 0ab74fb617f..6db863a267b 100644 --- a/source/blender/makesrna/intern/rna_space.c +++ b/source/blender/makesrna/intern/rna_space.c @@ -2248,6 +2248,13 @@ static void rna_def_space_sequencer(BlenderRNA *brna) {0, NULL, 0, NULL, NULL} }; + static EnumPropertyItem preview_channels_items[] = { + {SEQ_USE_ALPHA, "COLOR_ALPHA", ICON_IMAGE_RGB_ALPHA, "Color and Alpha", + "Draw image with RGB colors and alpha transparency"}, + {0, "COLOR", ICON_IMAGE_RGB, "Color", "Draw image with RGB colors"}, + {0, NULL, 0, NULL, NULL} + }; + srna = RNA_def_struct(brna, "SpaceSequenceEditor", "Space"); RNA_def_struct_sdna(srna, "SpaceSeq"); RNA_def_struct_ui_text(srna, "Space Sequence Editor", "Sequence editor space data"); @@ -2265,7 +2272,7 @@ static void rna_def_space_sequencer(BlenderRNA *brna) RNA_def_property_enum_items(prop, display_mode_items); RNA_def_property_ui_text(prop, "Display Mode", "View mode to use for displaying sequencer output"); RNA_def_property_update(prop, NC_SPACE | ND_SPACE_SEQUENCER, NULL); - + /* flags */ prop = RNA_def_property(srna, "show_frame_indicator", PROP_BOOLEAN, PROP_NONE); RNA_def_property_boolean_negative_sdna(prop, NULL, "flag", SEQ_NO_DRAW_CFRANUM); @@ -2310,7 +2317,13 @@ static void rna_def_space_sequencer(BlenderRNA *brna) "The channel number shown in the image preview. 0 is the result of all strips combined"); RNA_def_property_range(prop, -5, MAXSEQ); RNA_def_property_update(prop, NC_SPACE | ND_SPACE_SEQUENCER, NULL); - + + prop = RNA_def_property(srna, "preview_channels", PROP_ENUM, PROP_NONE); + RNA_def_property_enum_bitflag_sdna(prop, NULL, "flag"); + RNA_def_property_enum_items(prop, preview_channels_items); + RNA_def_property_ui_text(prop, "Draw Channels", "Channels of the preview to draw"); + RNA_def_property_update(prop, NC_SPACE | ND_SPACE_SEQUENCER, NULL); + prop = RNA_def_property(srna, "draw_overexposed", PROP_INT, PROP_NONE); RNA_def_property_int_sdna(prop, NULL, "zebra"); RNA_def_property_ui_text(prop, "Show Overexposed", "Show overexposed areas with zebra stripes"); |