From f26ac206c9acd9f1593cde2dc822c9e344507e97 Mon Sep 17 00:00:00 2001 From: William Reynish Date: Wed, 16 Sep 2009 19:58:01 +0000 Subject: *Changed image field order property to enum, making it consistent with the corresponding render option *Tiny edit to image panel. --- source/blender/makesrna/intern/rna_image.c | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) (limited to 'source/blender/makesrna/intern/rna_image.c') diff --git a/source/blender/makesrna/intern/rna_image.c b/source/blender/makesrna/intern/rna_image.c index ad96eaa99ad..8614e6f4ef3 100644 --- a/source/blender/makesrna/intern/rna_image.c +++ b/source/blender/makesrna/intern/rna_image.c @@ -217,6 +217,10 @@ static void rna_def_image(BlenderRNA *brna) {0, "UV", 0, "UV Coordinates", "Use UV coordinates for mapping the image"}, {IMA_REFLECT, "REFLECTION", 0, "Reflection", "Use reflection mapping for mapping the image"}, {0, NULL, 0, NULL, NULL}}; + static const EnumPropertyItem prop_field_order_items[]= { + {0, "EVEN", 0, "Even", "Even Fields first"}, + {IMA_STD_FIELD, "Odd", 0, "Odd", "Odd Fields first"}, + {0, NULL, 0, NULL, NULL}}; srna= RNA_def_struct(brna, "Image", "ID"); RNA_def_struct_ui_text(srna, "Image", "Image datablock referencing an external or packed image."); @@ -242,18 +246,19 @@ static void rna_def_image(BlenderRNA *brna) prop= RNA_def_property(srna, "packed_file", PROP_POINTER, PROP_NONE); RNA_def_property_pointer_sdna(prop, NULL, "packedfile"); RNA_def_property_ui_text(prop, "Packed File", ""); - + + prop= RNA_def_property(srna, "field_order", PROP_ENUM, PROP_NONE); + RNA_def_property_enum_bitflag_sdna(prop, NULL, "flag"); + RNA_def_property_enum_items(prop, prop_field_order_items); + RNA_def_property_ui_text(prop, "Field Order", "Order of video fields. Select which lines are displayed first."); + RNA_def_property_update(prop, NC_IMAGE|ND_DISPLAY, NULL); + /* booleans */ prop= RNA_def_property(srna, "fields", PROP_BOOLEAN, PROP_NONE); RNA_def_property_boolean_sdna(prop, NULL, "flag", IMA_FIELDS); RNA_def_property_ui_text(prop, "Fields", "Use fields of the image."); RNA_def_property_update(prop, NC_IMAGE|ND_DISPLAY, "rna_Image_fields_update"); - prop= RNA_def_property(srna, "odd_fields", PROP_BOOLEAN, PROP_NONE); - RNA_def_property_boolean_sdna(prop, NULL, "flag", IMA_STD_FIELD); - RNA_def_property_ui_text(prop, "Odd Fields", "Standard field toggle."); - RNA_def_property_update(prop, NC_IMAGE|ND_DISPLAY, "rna_Image_reload_update"); - prop= RNA_def_property(srna, "antialias", PROP_BOOLEAN, PROP_NONE); RNA_def_property_boolean_sdna(prop, NULL, "flag", IMA_ANTIALI); RNA_def_property_ui_text(prop, "Anti-alias", "Toggles image anti-aliasing, only works with solid colors"); -- cgit v1.2.3