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:
-rw-r--r--source/blender/alembic/intern/abc_mesh.cc3
-rw-r--r--source/blender/blenkernel/intern/customdata.c8
-rw-r--r--source/blender/blenloader/intern/versioning_280.c3
-rw-r--r--source/blender/editors/uvedit/uvedit_unwrap_ops.c1
-rw-r--r--source/blender/makesdna/DNA_customdata_types.h10
5 files changed, 15 insertions, 10 deletions
diff --git a/source/blender/alembic/intern/abc_mesh.cc b/source/blender/alembic/intern/abc_mesh.cc
index de227be0044..7f7afe0ce5e 100644
--- a/source/blender/alembic/intern/abc_mesh.cc
+++ b/source/blender/alembic/intern/abc_mesh.cc
@@ -973,8 +973,7 @@ static void *add_customdata_cb(void *user_data, const char *name, int data_type)
return cd_ptr;
}
- /* create a new layer, taking care to construct the hopefully-soon-to-be-removed
- * CD_MTEXPOLY layer too, with the same name. */
+ /* Create a new layer. */
numloops = mesh->totloop;
cd_ptr = CustomData_add_layer_named(loopdata, cd_data_type, CD_DEFAULT, NULL, numloops, name);
return cd_ptr;
diff --git a/source/blender/blenkernel/intern/customdata.c b/source/blender/blenkernel/intern/customdata.c
index 76098db5fd1..5bfb14824b4 100644
--- a/source/blender/blenkernel/intern/customdata.c
+++ b/source/blender/blenkernel/intern/customdata.c
@@ -26,6 +26,9 @@
#include "MEM_guardedalloc.h"
+/* Since we have versioning code here (CustomData_verify_versions()). */
+#define DNA_DEPRECATED_ALLOW
+
#include "DNA_customdata_types.h"
#include "DNA_meshdata_types.h"
#include "DNA_ID.h"
@@ -4191,9 +4194,10 @@ bool CustomData_verify_versions(struct CustomData *data, int index)
* Better to be safe here, and fix issue on the fly rather than crash... */
/* 0 structnum is used in writing code to tag layer types that should not be written. */
else if (typeInfo->structnum == 0 &&
- /* XXX Not sure why those two are exception, maybe that should be fixed? */
- !ELEM(layer->type, CD_PAINT_MASK, CD_FACEMAP)) {
+ /* XXX Not sure why those three are exception, maybe that should be fixed? */
+ !ELEM(layer->type, CD_PAINT_MASK, CD_FACEMAP, CD_MTEXPOLY)) {
keeplayer = false;
+ printf("%d\n", layer->type);
CLOG_WARN(&LOG, ".blend file read: removing a data layer that should not have been written");
}
}
diff --git a/source/blender/blenloader/intern/versioning_280.c b/source/blender/blenloader/intern/versioning_280.c
index 4b55364f0b1..5d899ef73a6 100644
--- a/source/blender/blenloader/intern/versioning_280.c
+++ b/source/blender/blenloader/intern/versioning_280.c
@@ -1180,12 +1180,11 @@ void blo_do_versions_280(FileData *fd, Library *UNUSED(lib), Main *bmain)
/* MTexPoly now removed. */
if (DNA_struct_find(fd->filesdna, "MTexPoly")) {
- const int cd_mtexpoly = 15; /* CD_MTEXPOLY, deprecated */
for (Mesh *me = bmain->meshes.first; me; me = me->id.next) {
/* If we have UV's, so this file will have MTexPoly layers too! */
if (me->mloopuv != NULL) {
CustomData_update_typemap(&me->pdata);
- CustomData_free_layers(&me->pdata, cd_mtexpoly, me->totpoly);
+ CustomData_free_layers(&me->pdata, CD_MTEXPOLY, me->totpoly);
BKE_mesh_update_customdata_pointers(me, false);
}
}
diff --git a/source/blender/editors/uvedit/uvedit_unwrap_ops.c b/source/blender/editors/uvedit/uvedit_unwrap_ops.c
index 14cdb674698..a42a6eba3ff 100644
--- a/source/blender/editors/uvedit/uvedit_unwrap_ops.c
+++ b/source/blender/editors/uvedit/uvedit_unwrap_ops.c
@@ -2282,7 +2282,6 @@ static void uvedit_unwrap_cube_project(BMesh *bm,
* component, but clusters all together around the center of map. */
BM_ITER_MESH (efa, &iter, bm, BM_FACES_OF_MESH) {
- /* tf = CustomData_bmesh_get(&em->bm->pdata, efa->head.data, CD_MTEXPOLY); */ /* UNUSED */
if (use_select && !BM_elem_flag_test(efa, BM_ELEM_SELECT)) {
continue;
}
diff --git a/source/blender/makesdna/DNA_customdata_types.h b/source/blender/makesdna/DNA_customdata_types.h
index c38222a3eb3..75a417150c8 100644
--- a/source/blender/makesdna/DNA_customdata_types.h
+++ b/source/blender/makesdna/DNA_customdata_types.h
@@ -30,6 +30,8 @@
extern "C" {
#endif
+#include "DNA_defs.h"
+
/** descriptor and storage for a custom data layer */
typedef struct CustomDataLayer {
/** Type of data in layer. */
@@ -107,9 +109,11 @@ typedef enum CustomDataType {
CD_PROP_FLT = 10,
CD_PROP_INT = 11,
CD_PROP_STR = 12,
- CD_ORIGSPACE = 13, /* for modifier stack face location mapping */
- CD_ORCO = 14, /* undeformed vertex coordinates, normalized to 0..1 range */
- /* CD_MTEXPOLY = 15, */ /* deprecated */
+ CD_ORIGSPACE = 13, /* for modifier stack face location mapping */
+ CD_ORCO = 14, /* undeformed vertex coordinates, normalized to 0..1 range */
+#ifdef DNA_DEPRECATED
+ CD_MTEXPOLY = 15, /* deprecated */
+#endif
CD_MLOOPUV = 16,
CD_MLOOPCOL = 17,
CD_TANGENT = 18,