From 97cb76a45d689a0d39e1d194f51119412e6c8e00 Mon Sep 17 00:00:00 2001 From: Lukas Treyer Date: Fri, 28 Mar 2014 16:41:56 +0600 Subject: Bevel Factor Mapping MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Bevel Factor Mapping allows to control the relation between bevel factors (number between 0 and 1) and the rendered start and end point of a beveled spline. There are three options: "Resolution", "Segments", "Spline". "Resolution" option maps bevel factors as it was done < 2.71, "Spline" and "Segments" are new. * "Resolution“: Map the bevel factor to the number of subdivisions of a spline (U resolution). * "Segments“: Map the bevel factor to the length of a segment and to the number of subdivisions of a segment. * "Spline": Map the bevel factor to the length of a spline. Reviewers: yakca, sergey, campbellbarton CC: sanne Differential Revision: https://developer.blender.org/D294 --- source/blender/makesdna/DNA_curve_types.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'source/blender/makesdna/DNA_curve_types.h') diff --git a/source/blender/makesdna/DNA_curve_types.h b/source/blender/makesdna/DNA_curve_types.h index ebba59ec785..0c9e9b01a76 100644 --- a/source/blender/makesdna/DNA_curve_types.h +++ b/source/blender/makesdna/DNA_curve_types.h @@ -257,8 +257,10 @@ typedef struct Curve { float ctime; /* current evaltime - for use by Objects parented to curves */ float bevfac1, bevfac2; + char bevfac1_mapping, bevfac2_mapping; + + char pad2[2]; - char pad2[4]; } Curve; /* **************** CURVE ********************* */ @@ -295,6 +297,13 @@ typedef struct Curve { #define CU_TWIST_MINIMUM 3 #define CU_TWIST_TANGENT 4 +/* bevel factor mapping */ +enum { + CU_BEVFAC_MAP_RESOLU = 0, + CU_BEVFAC_MAP_SEGMENT = 1, + CU_BEVFAC_MAP_SPLINE = 2 +}; + /* spacemode */ #define CU_LEFT 0 #define CU_MIDDLE 1 -- cgit v1.2.3