Hi Michael,

   Bug 4718786 - Incorrect coefficients in CubicSplineSegment
computeCommonCoefficients()

   is submitted for investigation.

Thanks for your bug report.

- Kelvin
------------------
Java 3D Team
Sun Microsystems Inc.

>Date: Sat, 20 Jul 2002 15:43:44 +0200
>From: Michael Nischt <[EMAIL PROTECTED]>
>Subject: [JAVA3D] TCB-Splines and CubicSplineSegments
>To: [EMAIL PROTECTED]
>MIME-version: 1.0
>Content-transfer-encoding: quoted-printable
>Delivered-to: [EMAIL PROTECTED]
>X-Report-Abuse-To: [EMAIL PROTECTED]
>
>Hi all,
>
>I've taken a look at the source in the
>com.sun.j3d.utils.behaviors.interpolators package and
>I wonder about two things:
>
>1.
>in RotPosScaleTCBSplinePathInterpolator.java
>
>   private Matrix4d       sMat        = new Matrix4d();    // line 64:
>
>but sMat is never used.
>
>2.
>in CubicSplineSegment.java
>
>    // variables for destination derivative
>    float    one_minus_t_in;
>    float    one_minus_c_in;
>    float    one_minus_b_in;
>    float    one_plus_c_in;
>    float    one_plus_b_in;
>
>    // variables for source derivative
>    float    one_minus_t_out;
>    float    one_minus_c_out;
>    float    one_minus_b_out;
>    float    one_plus_c_out;
>    float    one_plus_b_out;
>
>    ....
>
>    // compute the common coefficients
>    private void computeCommonCoefficients (TCBKeyFrame kf0,
>                                            TCBKeyFrame kf1,
>                                            TCBKeyFrame kf2,
>                                            TCBKeyFrame kf3) {
>
>        // variables for destination derivative
>        float  one_minus_t_in = 1.0f - kf1.tension;
>        float  one_minus_c_in = 1.0f - kf1.continuity;
>        float  one_minus_b_in = 1.0f - kf1.bias;
>        float  one_plus_c_in  = 1.0f + kf1.continuity;
>        float  one_plus_b_in  = 1.0f + kf1.bias;
>
>        // coefficients for the incoming Tangent
>        ddb = one_minus_t_in * one_minus_c_in * one_minus_b_in;
>        dda = one_minus_t_in * one_plus_c_in * one_plus_b_in;
>
>        // variables for source derivative
>        float  one_minus_t_out = 1.0f - kf2.tension;
>        float  one_minus_c_out = 1.0f - kf2.continuity;
>        float  one_minus_b_out = 1.0f - kf2.bias;
>        float  one_plus_c_out  = 1.0f + kf2.continuity;
>        float  one_plus_b_out  = 1.0f + kf2.bias;
>
>        // coefficients for the outgoing Tangent
>        dsb = one_minus_t_in * one_plus_c_in * one_minus_b_in;
>        dsa = one_minus_t_in * one_minus_c_in * one_plus_b_in;
>    }
>
>
>the one_xxx_y_zz attributes are never used, because of the local definitions.
>and wouldn't it be correct:
>
>        // coefficients for the outgoing Tangent
>        dsb = one_minus_t_out * one_plus_c_out * one_minus_b_out;
>        dsa = one_minus_t_out * one_minus_c_out * one_plus_b_out;
>
>instead of
>
>        // coefficients for the outgoing Tangent
>        dsb = one_minus_t_in * one_plus_c_in * one_minus_b_in;
>        dsa = one_minus_t_in * one_minus_c_in * one_plus_b_in;
>
>
>
>the first looks to me as copyright protection-inserts, but the last one makes
>no sense to me..
>
>regards
>-Michael Nischt
>
>==========================================================================To
unsubscribe, send email to [EMAIL PROTECTED] and include in the body
>of the message "signoff JAVA3D-INTEREST".  For general help, send email to
>[EMAIL PROTECTED] and include in the body of the message "help".

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to