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:
authorRobert Guetzkow <gitcommit@outlook.de>2021-01-26 14:41:47 +0300
committerRobert Guetzkow <gitcommit@outlook.de>2021-01-26 14:41:47 +0300
commit74633c0456b62b35a925c45cbff30508e53e86e9 (patch)
tree80202d41232849f4b789e38a1a8b0be0c7e2a56b /source/blender
parentf066cee92fe8dec37c50618b499e20dfd7c11249 (diff)
parentc399651637a3a9c8e416b8baffc571fa8cfa571f (diff)
Merge branch 'blender-v2.92-release'
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/blenkernel/intern/customdata.c14
-rw-r--r--source/blender/blenloader/intern/versioning_290.c3
-rw-r--r--source/blender/gpu/opengl/gl_backend.cc2
-rw-r--r--source/blender/nodes/geometry/nodes/node_geo_join_geometry.cc14
4 files changed, 31 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/customdata.c b/source/blender/blenkernel/intern/customdata.c
index 5d61b1165ed..446ef12574d 100644
--- a/source/blender/blenkernel/intern/customdata.c
+++ b/source/blender/blenkernel/intern/customdata.c
@@ -5104,6 +5104,10 @@ void CustomData_blend_write(BlendWriter *writer,
const int *layer_data = layer->data;
BLO_write_raw(writer, sizeof(*layer_data) * count, layer_data);
}
+ else if (layer->type == CD_PROP_BOOL) {
+ const bool *layer_data = layer->data;
+ BLO_write_raw(writer, sizeof(*layer_data) * count, layer_data);
+ }
else {
const char *structname;
int structnum;
@@ -5193,6 +5197,16 @@ void CustomData_blend_read(BlendDataReader *reader, CustomData *data, int count)
if (CustomData_verify_versions(data, i)) {
BLO_read_data_address(reader, &layer->data);
+ if (layer->data == NULL) {
+ /* Usually this should never happen, except when a custom data layer has not been written
+ * to a file correctly. */
+ CLOG_WARN(&LOG, "Reallocating custom data layer that was not saved correctly.");
+ const LayerTypeInfo *info = layerType_getInfo(layer->type);
+ layer->data = MEM_calloc_arrayN((size_t)count, info->size, layerType_getName(layer->type));
+ if (info->set_default) {
+ info->set_default(layer->data, count);
+ }
+ }
if (layer->type == CD_MDISPS) {
blend_read_mdisps(reader, count, layer->data, layer->flag & CD_FLAG_EXTERNAL);
}
diff --git a/source/blender/blenloader/intern/versioning_290.c b/source/blender/blenloader/intern/versioning_290.c
index 555b2453c62..d1cbf05c0ba 100644
--- a/source/blender/blenloader/intern/versioning_290.c
+++ b/source/blender/blenloader/intern/versioning_290.c
@@ -1504,7 +1504,7 @@ void blo_do_versions_290(FileData *fd, Library *UNUSED(lib), Main *bmain)
if (!MAIN_VERSION_ATLEAST(bmain, 292, 10)) {
if (!DNA_struct_find(fd->filesdna, "NodeSetAlpha")) {
- LISTBASE_FOREACH (bNodeTree *, ntree, &bmain->nodetrees) {
+ FOREACH_NODETREE_BEGIN (bmain, ntree, id) {
if (ntree->type != NTREE_COMPOSIT) {
continue;
}
@@ -1517,6 +1517,7 @@ void blo_do_versions_290(FileData *fd, Library *UNUSED(lib), Main *bmain)
node->storage = storage;
}
}
+ FOREACH_NODETREE_END;
}
LISTBASE_FOREACH (Scene *, scene, &bmain->scenes) {
diff --git a/source/blender/gpu/opengl/gl_backend.cc b/source/blender/gpu/opengl/gl_backend.cc
index 29ff1b3e81a..84bd9abf156 100644
--- a/source/blender/gpu/opengl/gl_backend.cc
+++ b/source/blender/gpu/opengl/gl_backend.cc
@@ -43,7 +43,7 @@ namespace blender::gpu {
static bool is_faulty_T82856_platform(const char *version, const char *renderer)
{
/* On Linux the driver does not report its version. Test the OpenGL version in stead. */
- if (strstr(version, "4.5.14756") || strstr(version, "4.5.14757")) {
+ if (strstr(version, "4.5.1475")) {
if (strstr(renderer, " RX 460 ") || strstr(renderer, " RX 470 ") ||
strstr(renderer, " RX 480 ") || strstr(renderer, " RX 490 ") ||
strstr(renderer, " RX 560 ") || strstr(renderer, " RX 560X ") ||
diff --git a/source/blender/nodes/geometry/nodes/node_geo_join_geometry.cc b/source/blender/nodes/geometry/nodes/node_geo_join_geometry.cc
index b9c9e5bd02a..02f0aca9c23 100644
--- a/source/blender/nodes/geometry/nodes/node_geo_join_geometry.cc
+++ b/source/blender/nodes/geometry/nodes/node_geo_join_geometry.cc
@@ -43,18 +43,32 @@ static Mesh *join_mesh_topology_and_builtin_attributes(Span<const MeshComponent
int totedges = 0;
int totpolys = 0;
+ int64_t cd_dirty_vert = 0;
+ int64_t cd_dirty_poly = 0;
+ int64_t cd_dirty_edge = 0;
+ int64_t cd_dirty_loop = 0;
+
for (const MeshComponent *mesh_component : src_components) {
const Mesh *mesh = mesh_component->get_for_read();
totverts += mesh->totvert;
totloops += mesh->totloop;
totedges += mesh->totedge;
totpolys += mesh->totpoly;
+ cd_dirty_vert |= mesh->runtime.cd_dirty_vert;
+ cd_dirty_poly |= mesh->runtime.cd_dirty_poly;
+ cd_dirty_edge |= mesh->runtime.cd_dirty_edge;
+ cd_dirty_loop |= mesh->runtime.cd_dirty_loop;
}
const Mesh *first_input_mesh = src_components[0]->get_for_read();
Mesh *new_mesh = BKE_mesh_new_nomain(totverts, totedges, 0, totloops, totpolys);
BKE_mesh_copy_settings(new_mesh, first_input_mesh);
+ new_mesh->runtime.cd_dirty_vert = cd_dirty_vert;
+ new_mesh->runtime.cd_dirty_poly = cd_dirty_poly;
+ new_mesh->runtime.cd_dirty_edge = cd_dirty_edge;
+ new_mesh->runtime.cd_dirty_loop = cd_dirty_loop;
+
int vert_offset = 0;
int loop_offset = 0;
int edge_offset = 0;