Re: [eigen] about Transform API

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]


On Sunday 31 August 2008 00:26:56 Gael Guennebaud wrote:
> to update the list,  this proposal is now implemented and fully
> working (rev 854987).
> An example:
>
> Quaternionf q;
> Vector3f axis;
> Vector3f vec;
> Transform3f t1;
> // ...
>
> Transform3f t2 = Translate3f(tx,ty,tx) * AngleAxis3f(M_PI/2,axis)
>                             * t1 * Scaling(sx,sy,sz) * Translate(vec) * q;
>
> all these products are optimized (assuming the compiler is able to
> optimize unnecessary temporaries)
>
> The classes Translate and Scaling features also operator*(Vector)  and
>  inverse() which might be useful to write generic algorithms taking
> any kind of transformations as input.

Sounds all very good.

> On Thu, Aug 28, 2008 at 4:03 PM, Benoît Jacob <jacob@xxxxxxxxxxxxxxx> wrote:
> > Let's keep the rotate()/scale()/translate() methods because this is what
> > OpenGL people expect first. Then let's also keep the pre... methods too.
>
> just for your information: all these GL functions (glTranslate,
> glRotate, glScale, glLoadIdentity, glLoadMatrix, glMultMatrix,
> glpush/PopMatrix, etc...)  are going to be removed in OpenGL and have
> already been removed in OpenGL ES  2.0.
>
> What remains is something like "glUniformMatrix4fv(matrix_name, data)"
> where "matrix_name" is whatever you want.....
> (but this not at all an argument against the translate/rotate/scale
> functions which are nice to have)

Ah ok, thanks for the explanation. Yes, let's still keep the rotate() methods.

BTW I just committed the Hyperplane changes. Finally I didn't add any check in 
Through. Krita uses it and seems not to have a problem with that. Typically, 
a line with 'inf' or 'nan' coefficients would just not be drawn on screen.

Cheers,
Benoit



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/