fix for the rna curve interpolation enum, 'ease' was using the same value as Bezier.
This commit is contained in:
@@ -1573,7 +1573,7 @@ static void alfa_bezpart(BezTriple *prevbezt, BezTriple *bezt, Nurb *nu, float *
|
|||||||
|
|
||||||
for(a=0; a<resolu; a++, fac+= dfac) {
|
for(a=0; a<resolu; a++, fac+= dfac) {
|
||||||
if (tilt_array) {
|
if (tilt_array) {
|
||||||
if (nu->tilt_interp==3) { /* May as well support for tilt also 2.47 ease interp */
|
if (nu->tilt_interp==KEY_CU_EASE) { /* May as well support for tilt also 2.47 ease interp */
|
||||||
*tilt_array = prevbezt->alfa + (bezt->alfa - prevbezt->alfa)*(3.0f*fac*fac - 2.0f*fac*fac*fac);
|
*tilt_array = prevbezt->alfa + (bezt->alfa - prevbezt->alfa)*(3.0f*fac*fac - 2.0f*fac*fac*fac);
|
||||||
} else {
|
} else {
|
||||||
key_curve_position_weights(fac, t, nu->tilt_interp);
|
key_curve_position_weights(fac, t, nu->tilt_interp);
|
||||||
@@ -1584,7 +1584,7 @@ static void alfa_bezpart(BezTriple *prevbezt, BezTriple *bezt, Nurb *nu, float *
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (radius_array) {
|
if (radius_array) {
|
||||||
if (nu->radius_interp==3) {
|
if (nu->radius_interp==KEY_CU_EASE) {
|
||||||
/* Support 2.47 ease interp
|
/* Support 2.47 ease interp
|
||||||
* Note! - this only takes the 2 points into account,
|
* Note! - this only takes the 2 points into account,
|
||||||
* giving much more localized results to changes in radius, sometimes you want that */
|
* giving much more localized results to changes in radius, sometimes you want that */
|
||||||
|
|||||||
@@ -346,5 +346,9 @@ typedef enum eBezTriple_KeyframeType {
|
|||||||
#define CU_CHINFO_SMALLCAPS (1<<4)
|
#define CU_CHINFO_SMALLCAPS (1<<4)
|
||||||
#define CU_CHINFO_SMALLCAPS_CHECK (1<<5) /* set at runtime, checks if case switching is needed */
|
#define CU_CHINFO_SMALLCAPS_CHECK (1<<5) /* set at runtime, checks if case switching is needed */
|
||||||
|
|
||||||
|
/* mixed with KEY_LINEAR but define here since only curve supports */
|
||||||
|
#define KEY_CU_EASE 3
|
||||||
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|||||||
@@ -29,6 +29,7 @@
|
|||||||
#include "rna_internal.h"
|
#include "rna_internal.h"
|
||||||
|
|
||||||
#include "DNA_curve_types.h"
|
#include "DNA_curve_types.h"
|
||||||
|
#include "DNA_key_types.h"
|
||||||
#include "DNA_material_types.h"
|
#include "DNA_material_types.h"
|
||||||
#include "DNA_scene_types.h"
|
#include "DNA_scene_types.h"
|
||||||
|
|
||||||
@@ -1252,10 +1253,10 @@ static void rna_def_curve(BlenderRNA *brna)
|
|||||||
static void rna_def_curve_nurb(BlenderRNA *brna)
|
static void rna_def_curve_nurb(BlenderRNA *brna)
|
||||||
{
|
{
|
||||||
static EnumPropertyItem spline_interpolation_items[] = {
|
static EnumPropertyItem spline_interpolation_items[] = {
|
||||||
{BEZT_IPO_CONST, "LINEAR", 0, "Linear", ""},
|
{KEY_LINEAR, "LINEAR", 0, "Linear", ""},
|
||||||
{BEZT_IPO_LIN, "CARDINAL", 0, "Cardinal", ""},
|
{KEY_CARDINAL, "CARDINAL", 0, "Cardinal", ""},
|
||||||
{BEZT_IPO_BEZ, "BSPLINE", 0, "BSpline", ""},
|
{KEY_BSPLINE, "BSPLINE", 0, "BSpline", ""},
|
||||||
{BEZT_IPO_BEZ, "EASE", 0, "Ease", ""},
|
{KEY_CU_EASE, "EASE", 0, "Ease", ""}, /* todo, define somewhere, not one of BEZT_IPO_* */
|
||||||
{0, NULL, 0, NULL, NULL}};
|
{0, NULL, 0, NULL, NULL}};
|
||||||
|
|
||||||
StructRNA *srna;
|
StructRNA *srna;
|
||||||
|
|||||||
Reference in New Issue
Block a user