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:
authorGermano Cavalcante <mano-wii>2021-04-01 16:41:12 +0300
committerGermano Cavalcante <germano.costa@ig.com.br>2021-04-01 16:54:49 +0300
commitf674976edd884d7a9a409042708f2b1169fd4e98 (patch)
tree1b2b293170e06d635aa6d3145db61bd4f6d4e535 /source/blender/makesrna
parent7a757662bc0a99b6f4720bb0e92735e54f9a1441 (diff)
Curve: Remove 'CU_2D' flag used for nurbs
This fixes T86440 As the CU_2D flag is set for nurbs, a Curve can have 2D nurbs mixed with 3D. But the UI does not allow this mixing. It updates all nurbs to 2D or 3D when set. So remove this specific flag for nurbs. This may break old files, since 2D curves with mixed 3D are now set as 3D. Differential Revision: https://developer.blender.org/D10738
Diffstat (limited to 'source/blender/makesrna')
-rw-r--r--source/blender/makesrna/intern/rna_curve.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/source/blender/makesrna/intern/rna_curve.c b/source/blender/makesrna/intern/rna_curve.c
index 3e90b4bd9d4..e670b17b79a 100644
--- a/source/blender/makesrna/intern/rna_curve.c
+++ b/source/blender/makesrna/intern/rna_curve.c
@@ -357,9 +357,8 @@ static void rna_Curve_dimension_set(PointerRNA *ptr, int value)
}
else {
cu->flag &= ~CU_3D;
+ BKE_curve_dimension_update(cu);
}
-
- BKE_curve_curve_dimension_update(cu);
}
static const EnumPropertyItem *rna_Curve_fill_mode_itemf(bContext *UNUSED(C),
@@ -721,10 +720,6 @@ static Nurb *rna_Curve_spline_new(Curve *cu, int type)
nu->resolv = cu->resolv;
nu->flag = CU_SMOOTH;
- if ((cu->flag & CU_3D) == 0) {
- nu->flag |= CU_2D;
- }
-
BLI_addtail(BKE_curve_nurbs_get(cu), nu);
return nu;