Hello Johannes,

Johannes Brunen wrote:
> there are some quirks however. Attached you can find a slightly modified 
> version which allows movement of two clip planes by keystrokes.
[SNIP - keys]
> Moving the clip planes results in some strange artefacts. I do currently not 
> know what is wrong here.

when updating the Transforms for the plane geometry you also need to 
translate it, the Quaternion only describes the rotation, but if the 
plane does not contain the origin a separate translation is necessary:

             Matrix rotMat;
             Vec4f v1(0.f, 0.f, -1.f, 0.f);
             Quaternion q(v1, data._equation);
             rotMat.setTransform(q);

             Matrix mat;
             Vec3f v2(0.0f, 0.0f, data._equation[3]);
             mat.setTranslate(v2);

             mat.multLeft(rotMat);

> There is also another problem (possibly related). If I have more than one 
> object I got failures on the following occasions:
> a) The objects intersect.
> b) The objects don't intersect but overlap after some camera movement.

hm, let me know if the above fixes the problem as well.

> P.S.: Today I send another mail to the group about a problem with file 
> loading I encountered. Unfortunately, the list blocked the mail due to 
> attachmenent size. Could you take a look please.

ok, will see if we can find it.

        Cheers,
                Carsten



------------------------------------------------------------------------------
This SF.net email is sponsored by:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to