I think that the FOV in buildProjectionMatrixPerspectiveFovLH/RH
methods are wrong calculated.
In fact, if I restrict the field of view I obtain a zoom out, not a zoom in.
I also tried a patch found at hybryd page, but it doesn't work.
Then I looked the GLUPerspective function:
http://developer.apple.com/documentatio ... ive.3.html
If I use
(*this)(0,0) = h / aspectRatio;
(*this)(1,1) = h;
instead of the original settings, FOV seems to work.
Is it a bug?
FOV bug?
I believe Rv had it right here http://irrlicht.sourceforge.net/phpBB2/ ... hp?t=12426. This is the projection matrix code Lightfeather uses, and it seems to work well
You do a lot of programming? Really? I try to get some in, but the debugging keeps me pretty busy.
Crucible of Stars
Crucible of Stars
Using Rv's version a normal FOV is pi/3 rad (60 degrees) instead of pi/2 rad (90 degrees). That should look fine. Rv's version doesn't go crazy when you move the near plane, which the original version does.
You do a lot of programming? Really? I try to get some in, but the debugging keeps me pretty busy.
Crucible of Stars
Crucible of Stars
-
hybrid
- Admin
- Posts: 14143
- Joined: Wed Apr 19, 2006 9:20 pm
- Location: Oldenburg(Oldb), Germany
- Contact:
Ok, both DirectX and OpenGL used something like this, so I have changed all 6 projection matrices to the DirectX default from MSDN. Please try this version (e.g. by copying matrix4.h from SVN to your code or directly using SVN) and report problems back.
The strange aspect ratio was due to a "fix" for the corrected aspect ratio several versions ago. We had to multiply with the aspect ratio to get the Irrlicht matrices working correctly. However, now this had to be changed back
The strange aspect ratio was due to a "fix" for the corrected aspect ratio several versions ago. We had to multiply with the aspect ratio to get the Irrlicht matrices working correctly. However, now this had to be changed back
