X-Git-Url: https://git.blender.org/gitweb/gitweb.cgi/blender.git/blobdiff_plain/b282b5275c919b95e9947801b21678341ec21bba..e2203d548e0f53f994af40a7a59a66a39d67c6d1:/source/blender/makesrna/intern/rna_space.c diff --git a/source/blender/makesrna/intern/rna_space.c b/source/blender/makesrna/intern/rna_space.c index 01a58463fb6..1db3e9678a4 100644 --- a/source/blender/makesrna/intern/rna_space.c +++ b/source/blender/makesrna/intern/rna_space.c @@ -152,6 +152,7 @@ EnumPropertyItem clip_editor_mode_items[] = { #include "ED_sequencer.h" #include "ED_clip.h" +#include "IMB_colormanagement.h" #include "IMB_imbuf_types.h" static StructRNA *rna_Space_refine(struct PointerRNA *ptr) @@ -1908,7 +1909,7 @@ static void rna_def_space_buttons(BlenderRNA *brna) {SB_TEXC_MAT_OR_LAMP, "MATERIAL", ICON_MATERIAL, "Material", "Material"}, {0, NULL, 0, NULL, NULL} }; /*actually populated dynamically trough a function */ - + srna = RNA_def_struct(brna, "SpaceProperties", "Space"); RNA_def_struct_sdna(srna, "SpaceButs"); RNA_def_struct_ui_text(srna, "Properties Space", "Properties space data"); @@ -2085,6 +2086,11 @@ static void rna_def_space_image(BlenderRNA *brna) RNA_def_property_clear_flag(prop, PROP_EDITABLE); RNA_def_property_ui_text(prop, "Show UV Editor", "Show UV editing related properties"); + prop = RNA_def_property(srna, "view_settings", PROP_POINTER, PROP_NONE); + RNA_def_property_pointer_sdna(prop, NULL, "view_settings"); + RNA_def_property_struct_type(prop, "ColorManagedViewSettings"); + RNA_def_property_ui_text(prop, "View Settings", "Color management settings used for displaying images on the display"); + prop = RNA_def_property(srna, "show_maskedit", PROP_BOOLEAN, PROP_NONE); RNA_def_property_boolean_funcs(prop, "rna_SpaceImageEditor_show_maskedit_get", NULL); RNA_def_property_clear_flag(prop, PROP_EDITABLE); @@ -2204,6 +2210,11 @@ static void rna_def_space_sequencer(BlenderRNA *brna) RNA_def_property_struct_type(prop, "GreasePencil"); RNA_def_property_ui_text(prop, "Grease Pencil", "Grease pencil data for this space"); RNA_def_property_update(prop, NC_SPACE | ND_SPACE_SEQUENCER, NULL); + + prop = RNA_def_property(srna, "view_settings", PROP_POINTER, PROP_NONE); + RNA_def_property_pointer_sdna(prop, NULL, "view_settings"); + RNA_def_property_struct_type(prop, "ColorManagedViewSettings"); + RNA_def_property_ui_text(prop, "View Settings", "Color management settings used for displaying images on the display"); } static void rna_def_space_text(BlenderRNA *brna) @@ -2998,6 +3009,11 @@ static void rna_def_space_node(BlenderRNA *brna) RNA_def_property_ui_text(prop, "Draw Channels", "Channels of the image to draw"); RNA_def_property_update(prop, NC_SPACE | ND_SPACE_NODE_VIEW, NULL); + prop = RNA_def_property(srna, "view_settings", PROP_POINTER, PROP_NONE); + RNA_def_property_pointer_sdna(prop, NULL, "view_settings"); + RNA_def_property_struct_type(prop, "ColorManagedViewSettings"); + RNA_def_property_ui_text(prop, "View Settings", "Color management settings used for displaying images on the display"); + prop = RNA_def_property(srna, "show_highlight", PROP_BOOLEAN, PROP_NONE); RNA_def_property_boolean_sdna(prop, NULL, "flag", SNODE_SHOW_HIGHLIGHT); RNA_def_property_ui_text(prop, "Highlight", "Highlight nodes that are being calculated"); @@ -3315,6 +3331,12 @@ static void rna_def_space_clip(BlenderRNA *brna) RNA_def_property_enum_items(prop, pivot_items); RNA_def_property_ui_text(prop, "Pivot Point", "Pivot center for rotation/scaling"); RNA_def_property_update(prop, NC_SPACE | ND_SPACE_CLIP, NULL); + + /* color management view settings */ + prop = RNA_def_property(srna, "view_settings", PROP_POINTER, PROP_NONE); + RNA_def_property_pointer_sdna(prop, NULL, "view_settings"); + RNA_def_property_struct_type(prop, "ColorManagedViewSettings"); + RNA_def_property_ui_text(prop, "View Settings", "Color management settings used for displaying images on the display"); }