forked from bartvdbraak/blender
Sphere radius and Kr derivative epsilon (removed in revision 43902) were recovered in the Parameter Editor mode.
Several users requested the recovery as the removal of the two parameters was considered over-simplification for advanced users. As in the Python Scripting mode, the two parameters are in the "advanced edge detection options" section and disabled by default. Also the lower limit of Kr derivative epsilon was changed from 0 to -1000 so as to permit a negative value.
This commit is contained in:
parent
065605e0da
commit
9d2a957a0d
@ -210,6 +210,14 @@ class RENDER_PT_freestyle(RenderButtonsPanel, Panel):
|
||||
col.label(text="Edge Detection Options:")
|
||||
col.prop(freestyle, "use_smoothness")
|
||||
col.prop(freestyle, "crease_angle")
|
||||
if freestyle.mode == "SCRIPT":
|
||||
col.prop(freestyle, "use_material_boundaries")
|
||||
col.prop(freestyle, "use_ridges_and_valleys")
|
||||
col.prop(freestyle, "use_suggestive_contours")
|
||||
col.prop(freestyle, "use_advanced_options")
|
||||
if freestyle.use_advanced_options:
|
||||
col.prop(freestyle, "sphere_radius")
|
||||
col.prop(freestyle, "kr_derivative_epsilon")
|
||||
|
||||
if freestyle.mode == "EDITOR":
|
||||
|
||||
@ -235,13 +243,6 @@ class RENDER_PT_freestyle(RenderButtonsPanel, Panel):
|
||||
|
||||
else: # freestyle.mode == "SCRIPT"
|
||||
|
||||
col.prop(freestyle, "use_material_boundaries")
|
||||
col.prop(freestyle, "use_ridges_and_valleys")
|
||||
col.prop(freestyle, "use_suggestive_contours")
|
||||
col.prop(freestyle, "use_advanced_options")
|
||||
if freestyle.use_advanced_options:
|
||||
col.prop(freestyle, "sphere_radius")
|
||||
col.prop(freestyle, "kr_derivative_epsilon")
|
||||
col.separator()
|
||||
col.operator("scene.freestyle_module_add")
|
||||
|
||||
|
@ -343,7 +343,7 @@ extern "C" {
|
||||
}
|
||||
|
||||
// set parameters
|
||||
if (config->mode == FREESTYLE_CONTROL_SCRIPT_MODE && (config->flags & FREESTYLE_ADVANCED_OPTIONS_FLAG)) {
|
||||
if (config->flags & FREESTYLE_ADVANCED_OPTIONS_FLAG) {
|
||||
controller->setSphereRadius( config->sphere_radius );
|
||||
controller->setSuggestiveContourKrDerivativeEpsilon( config->dkr_epsilon );
|
||||
} else {
|
||||
|
@ -2666,7 +2666,7 @@ static void rna_def_freestyle_settings(BlenderRNA *brna)
|
||||
|
||||
prop= RNA_def_property(srna, "kr_derivative_epsilon", PROP_FLOAT, PROP_NONE);
|
||||
RNA_def_property_float_sdna(prop, NULL, "dkr_epsilon");
|
||||
RNA_def_property_range(prop, 0.0, 1000.0);
|
||||
RNA_def_property_range(prop, -1000.0, 1000.0);
|
||||
RNA_def_property_ui_text(prop, "Kr Derivative Epsilon", "Kr derivative epsilon for computing suggestive contours");
|
||||
RNA_def_property_update(prop, NC_SCENE, NULL);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user