diff options
-rw-r--r-- | release/scripts/startup/bl_ui/properties_data_camera.py | 2 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_camera.c | 16 |
2 files changed, 9 insertions, 9 deletions
diff --git a/release/scripts/startup/bl_ui/properties_data_camera.py b/release/scripts/startup/bl_ui/properties_data_camera.py index 25cecc90c70..c74560e14ac 100644 --- a/release/scripts/startup/bl_ui/properties_data_camera.py +++ b/release/scripts/startup/bl_ui/properties_data_camera.py @@ -80,7 +80,7 @@ class DATA_PT_lens(CameraButtonsPanel, Panel): row = col.row() if cam.lens_unit == 'MILLIMETERS': row.prop(cam, "lens") - elif cam.lens_unit == 'DEGREES': + elif cam.lens_unit == 'FOV': row.prop(cam, "angle") row.prop(cam, "lens_unit", text="") diff --git a/source/blender/makesrna/intern/rna_camera.c b/source/blender/makesrna/intern/rna_camera.c index b72bba0422a..0b1e1c215c4 100644 --- a/source/blender/makesrna/intern/rna_camera.c +++ b/source/blender/makesrna/intern/rna_camera.c @@ -112,8 +112,8 @@ void RNA_def_camera(BlenderRNA *brna) {0, NULL, 0, NULL, NULL} }; static EnumPropertyItem prop_lens_unit_items[] = { - {0, "MILLIMETERS", 0, "Millimeters", ""}, - {CAM_ANGLETOGGLE, "DEGREES", 0, "Degrees", ""}, + {0, "MILLIMETERS", 0, "Millimeters", "Specify the lens in millimeters"}, + {CAM_ANGLETOGGLE, "FOV", 0, "Field of View", "Specify the lens as the field of view's angle"}, {0, NULL, 0, NULL, NULL} }; static EnumPropertyItem sensor_fit_items[] = { @@ -154,23 +154,23 @@ void RNA_def_camera(BlenderRNA *brna) RNA_def_property_update(prop, NC_OBJECT | ND_DRAW, NULL); prop = RNA_def_property(srna, "angle_x", PROP_FLOAT, PROP_ANGLE); - RNA_def_property_range(prop, M_PI * (0.367 / 180.0), M_PI * (172.847 / 180.0)); + RNA_def_property_range(prop, DEG2RAD(0.367), DEG2RAD(172.847)); RNA_def_property_clear_flag(prop, PROP_ANIMATABLE); - RNA_def_property_ui_text(prop, "Horizontal FOV", "Camera lens horizontal field of view in degrees"); + RNA_def_property_ui_text(prop, "Horizontal FOV", "Camera lens horizontal field of view"); RNA_def_property_float_funcs(prop, "rna_Camera_angle_x_get", "rna_Camera_angle_x_set", NULL); RNA_def_property_update(prop, NC_OBJECT | ND_DRAW, "rna_Camera_update"); prop = RNA_def_property(srna, "angle_y", PROP_FLOAT, PROP_ANGLE); - RNA_def_property_range(prop, M_PI * (0.367 / 180.0), M_PI * (172.847 / 180.0)); + RNA_def_property_range(prop, DEG2RAD(0.367), DEG2RAD(172.847)); RNA_def_property_clear_flag(prop, PROP_ANIMATABLE); - RNA_def_property_ui_text(prop, "Vertical FOV", "Camera lens vertical field of view in degrees"); + RNA_def_property_ui_text(prop, "Vertical FOV", "Camera lens vertical field of view"); RNA_def_property_float_funcs(prop, "rna_Camera_angle_y_get", "rna_Camera_angle_y_set", NULL); RNA_def_property_update(prop, NC_OBJECT | ND_DRAW, "rna_Camera_update"); prop = RNA_def_property(srna, "angle", PROP_FLOAT, PROP_ANGLE); - RNA_def_property_range(prop, M_PI * (0.367 / 180.0), M_PI * (172.847 / 180.0)); + RNA_def_property_range(prop, DEG2RAD(0.367), DEG2RAD(172.847)); RNA_def_property_clear_flag(prop, PROP_ANIMATABLE); - RNA_def_property_ui_text(prop, "Field of View", "Camera lens field of view in degrees"); + RNA_def_property_ui_text(prop, "Field of View", "Camera lens field of view"); RNA_def_property_float_funcs(prop, "rna_Camera_angle_get", "rna_Camera_angle_set", NULL); RNA_def_property_update(prop, NC_OBJECT | ND_DRAW, "rna_Camera_update"); |