diff options
author | Antonio Vazquez <blendergit@gmail.com> | 2020-05-12 18:54:20 +0300 |
---|---|---|
committer | Antonio Vazquez <blendergit@gmail.com> | 2020-05-12 18:54:20 +0300 |
commit | 33f9fe3c620fef1d1ad2cb3443bf503afdb9db3b (patch) | |
tree | a841b5f04d635d0af308f6bfce94c69ca6a2e6c1 /source/blender/makesrna/intern/rna_scene.c | |
parent | 25c67a65d686aa04570db7409618ad779318c17a (diff) | |
parent | f24e9bb0380936bcaf6c194b54342a2977784cff (diff) |
Merge branch 'blender-v2.83-release'
Conflicts:
release/scripts/startup/bl_ui/properties_render.py
source/blender/blenkernel/BKE_blender_version.h
Diffstat (limited to 'source/blender/makesrna/intern/rna_scene.c')
-rw-r--r-- | source/blender/makesrna/intern/rna_scene.c | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/source/blender/makesrna/intern/rna_scene.c b/source/blender/makesrna/intern/rna_scene.c index a04194b5206..6423175e2f4 100644 --- a/source/blender/makesrna/intern/rna_scene.c +++ b/source/blender/makesrna/intern/rna_scene.c @@ -1137,6 +1137,11 @@ static char *rna_SceneEEVEE_path(PointerRNA *UNUSED(ptr)) return BLI_strdup("eevee"); } +static char *rna_SceneGpencil_path(PointerRNA *UNUSED(ptr)) +{ + return BLI_strdup("grease_pencil_settings"); +} + static int rna_RenderSettings_stereoViews_skip(CollectionPropertyIterator *iter, void *UNUSED(data)) { @@ -7204,6 +7209,28 @@ static void rna_def_scene_eevee(BlenderRNA *brna) RNA_def_property_override_flag(prop, PROPOVERRIDE_OVERRIDABLE_LIBRARY); } +static void rna_def_scene_gpencil(BlenderRNA *brna) +{ + StructRNA *srna; + PropertyRNA *prop; + + srna = RNA_def_struct(brna, "SceneGpencil", NULL); + RNA_def_struct_path_func(srna, "rna_SceneGpencil_path"); + RNA_def_struct_ui_text(srna, "Grease Pencil Render", "Render settings"); + + prop = RNA_def_property(srna, "antialias_threshold", PROP_FLOAT, PROP_NONE); + RNA_def_property_float_sdna(prop, NULL, "smaa_threshold"); + RNA_def_property_float_default(prop, 1.0f); + RNA_def_property_range(prop, 0.0f, FLT_MAX); + RNA_def_property_ui_range(prop, 0.0f, 2.0f, 1, 3); + RNA_def_property_ui_text(prop, + "Anti-Aliasing Threshold", + "Threshold for edge detection algorithm (higher values might overblur " + "some part of the image)"); + RNA_def_property_override_flag(prop, PROPOVERRIDE_OVERRIDABLE_LIBRARY); + RNA_def_property_update(prop, NC_SCENE | ND_RENDER_OPTIONS, NULL); +} + void RNA_def_scene(BlenderRNA *brna) { StructRNA *srna; @@ -7677,6 +7704,11 @@ void RNA_def_scene(BlenderRNA *brna) RNA_def_property_struct_type(prop, "SceneEEVEE"); RNA_def_property_ui_text(prop, "EEVEE", "EEVEE settings for the scene"); + /* Grease Pencil */ + prop = RNA_def_property(srna, "grease_pencil_settings", PROP_POINTER, PROP_NONE); + RNA_def_property_struct_type(prop, "SceneGpencil"); + RNA_def_property_ui_text(prop, "Grease Pencil", "Grease Pencil settings for the scene"); + /* Nestled Data */ /* *** Non-Animated *** */ RNA_define_animate_sdna(false); @@ -7695,6 +7727,7 @@ void RNA_def_scene(BlenderRNA *brna) rna_def_scene_display(brna); rna_def_scene_eevee(brna); rna_def_view_layer_eevee(brna); + rna_def_scene_gpencil(brna); RNA_define_animate_sdna(true); /* *** Animated *** */ rna_def_scene_render_data(brna); |