Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAras Pranckevicius <aras@nesnausk.org>2022-08-10 18:06:13 +0300
committerAras Pranckevicius <aras@nesnausk.org>2022-08-10 18:06:13 +0300
commitbb3174e15b63809c733b3a1cc39f05bee5042ed3 (patch)
tree17dc18184362a887d7f99dffffe202c56703937f
parent5689dda6f766b0a49c235ed917d113e2bfdab7a4 (diff)
parent8c59b93505b3066c3fd8aac121d08395eb197307 (diff)
Merge branch 'blender-v3.3-release'
-rw-r--r--source/blender/io/wavefront_obj/importer/obj_import_mtl.cc8
-rw-r--r--source/blender/makesrna/intern/rna_camera.c2
2 files changed, 8 insertions, 2 deletions
diff --git a/source/blender/io/wavefront_obj/importer/obj_import_mtl.cc b/source/blender/io/wavefront_obj/importer/obj_import_mtl.cc
index 0023d1159c5..27bb5aa0d71 100644
--- a/source/blender/io/wavefront_obj/importer/obj_import_mtl.cc
+++ b/source/blender/io/wavefront_obj/importer/obj_import_mtl.cc
@@ -134,6 +134,14 @@ static Image *load_texture_image(Main *bmain,
return image;
}
}
+ /* Try taking just the basename from input path. */
+ std::string base_path{tex_map.mtl_dir_path + BLI_path_basename(tex_map.image_path.c_str())};
+ if (base_path != tex_path) {
+ image = load_image_at_path(bmain, base_path, relative_paths);
+ if (image != nullptr) {
+ return image;
+ }
+ }
image = create_placeholder_image(bmain, tex_path);
return image;
diff --git a/source/blender/makesrna/intern/rna_camera.c b/source/blender/makesrna/intern/rna_camera.c
index 99f8c263da6..988e65b4ba8 100644
--- a/source/blender/makesrna/intern/rna_camera.c
+++ b/source/blender/makesrna/intern/rna_camera.c
@@ -695,14 +695,12 @@ void RNA_def_camera(BlenderRNA *brna)
prop = RNA_def_property(srna, "shift_x", PROP_FLOAT, PROP_NONE);
RNA_def_property_float_sdna(prop, NULL, "shiftx");
- RNA_def_property_range(prop, -10.0f, 10.0f);
RNA_def_property_ui_range(prop, -2.0, 2.0, 1, 3);
RNA_def_property_ui_text(prop, "Shift X", "Camera horizontal shift");
RNA_def_property_update(prop, NC_OBJECT | ND_DRAW, "rna_Camera_update");
prop = RNA_def_property(srna, "shift_y", PROP_FLOAT, PROP_NONE);
RNA_def_property_float_sdna(prop, NULL, "shifty");
- RNA_def_property_range(prop, -10.0f, 10.0f);
RNA_def_property_ui_range(prop, -2.0, 2.0, 1, 3);
RNA_def_property_ui_text(prop, "Shift Y", "Camera vertical shift");
RNA_def_property_update(prop, NC_OBJECT | ND_DRAW, "rna_Camera_update");