RNA: Remove Unused dof.is_hq_supported and dof.use_high_quality

It's not necessary anymore since we assume it's always high quality.
This commit is contained in:
Clément Foucault 2018-07-24 17:59:46 +02:00
parent cfaea24117
commit a76198cb23
Notes: blender-bot 2023-02-14 10:54:29 +01:00
Referenced by issue #56095, Inconsistent behavior of the Normal Transformation Orientation
3 changed files with 2 additions and 29 deletions

View File

@ -883,14 +883,9 @@ class CYCLES_CAMERA_PT_dof_viewport(CyclesButtonsPanel, Panel):
cam = context.camera
dof_options = cam.gpu_dof
hq_support = dof_options.is_hq_supported
sub = flow.column(align=True)
subhq = sub.column()
subhq.active = hq_support
subhq.prop(dof_options, "use_high_quality")
sub.prop(dof_options, "fstop")
if dof_options.use_high_quality and hq_support:
sub.prop(dof_options, "blades")
sub.prop(dof_options, "blades")
class CYCLES_PT_context_material(CyclesButtonsPanel, Panel):

View File

@ -250,15 +250,10 @@ class DATA_PT_camera_dof_aperture(CameraButtonsPanel, Panel):
col.prop(dof_options, "rotation")
col.prop(dof_options, "ratio")
else:
hq_support = dof_options.is_hq_supported
col = flow.column()
col.label("Viewport")
sub = col.column()
sub.active = hq_support
sub.prop(dof_options, "use_high_quality")
col.prop(dof_options, "fstop")
if dof_options.use_high_quality and hq_support:
col.prop(dof_options, "blades")
col.prop(dof_options, "blades")
class DATA_PT_camera_background_image(CameraButtonsPanel, Panel):

View File

@ -2024,11 +2024,6 @@ static void rna_Stereo3dFormat_update(Main *bmain, Scene *UNUSED(scene), Pointer
}
}
static bool rna_gpu_is_hq_supported_get(PointerRNA *UNUSED(ptr))
{
return true;
}
static ViewLayer *rna_ViewLayer_new(
ID *id, Scene *UNUSED(sce), Main *bmain, const char *name)
{
@ -4115,18 +4110,6 @@ static void rna_def_gpu_dof_fx(BlenderRNA *brna)
RNA_def_property_range(prop, 0.0000001f, FLT_MAX);
RNA_def_property_ui_range(prop, 1.0f, 2.0f, 0.1, 3);
RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL);
prop = RNA_def_property(srna, "use_high_quality", PROP_BOOLEAN, PROP_NONE);
RNA_def_property_boolean_sdna(prop, NULL, "high_quality", 1);
RNA_def_property_ui_text(prop, "High Quality", "Use high quality depth of field");
RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, "rna_GPUDOFSettings_update");
/* NOTE: high quality is always supported */
prop = RNA_def_property(srna, "is_hq_supported", PROP_BOOLEAN, PROP_NONE);
RNA_def_property_boolean_funcs(prop, "rna_gpu_is_hq_supported_get", NULL);
RNA_def_property_clear_flag(prop, PROP_EDITABLE);
RNA_def_property_ui_text(prop, "High Quality", "Use high quality depth of field");
RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL);
}
static void rna_def_gpu_ssao_fx(BlenderRNA *brna)