Hi Allan,

On Wed, 2005-10-05 at 16:29 +0200, Allan Rasmusson wrote:
> Hi.
>     I've been trying to get picking to work on an orthogonal projection 
> using the camera->calcViewRay(...) function.
> 
> I've tried using a matrix camera with the identity matrix as projection 
> matrix and also the new orthogonal camera. What I believe is the problem 
> is that neither the matrix camera nor orhogonal camera has reimplemented 
> the calcViewRay() method.

thanks for the hint. I changed Camera::calcViewRay() to not implicitly
expect a perspective Camera. It should now work with every kind of
Camera (it does work with the OrthographicCamera).

> During my debugging of all this picking-stuff, I believe I found an 
> ambiguity. The doc for camera->calcViewRay() states:
> "Calculate a ray that starts at the camera position and goes through the 
> pixel /x/, /y/ in the viewport /port/. /x/ and /y/ are relative to the 
> viewport's lower left corner."
> 
> In the example "testPicking.cpp" which uses GLUT has (0,0) in the upper 
> left corner however.

Good catch, that's a documentation bug. All the code actually uses the
upper left corner.

Thanks

        Dirk




-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to