From 8ce1090d4e8160165281be4b0827dbc1ba28dc8a Mon Sep 17 00:00:00 2001 From: Karsten Schwenk Date: Sun, 8 Jun 2014 12:16:28 +0200 Subject: Cycles: Ashikhmin-Shirley anisotropic BSDF * Ashikhmin-Shirley anisotropic BSDF was added as closure * Anisotropic BSDF node now has two distributions Reviewers: brecht, dingto Differential Revision: https://developer.blender.org/D549 --- source/blender/makesrna/intern/rna_nodetree.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'source/blender/makesrna/intern/rna_nodetree.c') diff --git a/source/blender/makesrna/intern/rna_nodetree.c b/source/blender/makesrna/intern/rna_nodetree.c index c39d3826d8b..b1a2f12d781 100644 --- a/source/blender/makesrna/intern/rna_nodetree.c +++ b/source/blender/makesrna/intern/rna_nodetree.c @@ -2952,6 +2952,12 @@ static EnumPropertyItem node_glossy_items[] = { {0, NULL, 0, NULL, NULL} }; +static EnumPropertyItem node_anisotropic_items[] = { + {SHD_ANISOTROPIC_WARD, "WARD", 0, "Ward", ""}, + {SHD_ANISOTROPIC_ASHIKHMIN_SHIRLEY, "ASHIKHMIN_SHIRLEY", 0, "Ashikhmin-Shirley", ""}, + {0, NULL, 0, NULL, NULL} +}; + static EnumPropertyItem node_toon_items[] = { {SHD_TOON_DIFFUSE, "DIFFUSE", 0, "Diffuse", ""}, {SHD_TOON_GLOSSY, "GLOSSY", 0, "Glossy", ""}, @@ -3699,6 +3705,17 @@ static void def_glossy(StructRNA *srna) RNA_def_property_update(prop, NC_NODE | NA_EDITED, "rna_Node_update"); } +static void def_anisotropic(StructRNA *srna) +{ + PropertyRNA *prop; + + prop = RNA_def_property(srna, "distribution", PROP_ENUM, PROP_NONE); + RNA_def_property_enum_sdna(prop, NULL, "custom1"); + RNA_def_property_enum_items(prop, node_anisotropic_items); + RNA_def_property_ui_text(prop, "Distribution", ""); + RNA_def_property_update(prop, NC_NODE | NA_EDITED, "rna_Node_update"); +} + static void def_toon(StructRNA *srna) { PropertyRNA *prop; -- cgit v1.2.3