Field of view

Discuss about anything related to the Irrlicht Engine, or read announcements about any significant features or usage changes.
Post Reply
kenna
Posts: 15
Joined: Sun May 27, 2007 1:22 am
Location: Finland

Field of view

Post by kenna »

Something that has always bothered me, is the limited field of view in most games, the worst being those locked at 90°. I would want to see some code for Irrlicht to allow it to effectively use 100° x 140~180° field of view in 4:3 aspect ratio. 16:9 has a wider screen so it automatically allows for wider field of view, but even then it would need some coding to get it to look decent, and IMHO 16:9 screens suck majestically for work, so 4:3 is very important, at least to me ^^. Then there is also the problem of horizontal field of view, which would also need to wrap a bit.

I'm not a programmer, nor particularly good at advanced mathematics, so I'm quite clueless exactly how to implement it, although I've always thought of wrapping the image, both x- and y-axis...something like this...

Image
(sorry about the small size, for some reason it resizes the image, even though it was only 640x480)

The greenish-yellow area in the centre of the screen is the normal view, and the white areas around it the extended view. The normal view does not have quite as much wrapping as the extended view.

I always loved the view in "Metroid Prime", even though it wasn't even near 180°, but it was still much better than the "flat" view in most FPS games, it felt much more natural due to the "visor view".

So, any ideas?
Luke
Admin
Posts: 449
Joined: Fri Jul 14, 2006 7:55 am
Location: Australia
Contact:

Post by Luke »

for the aspect ratio you can use the command:

Camera->setAspectRatio(4.0f / 3.0f);

and for the field of view you can use:

Camera->setFOV (90*DEGTORAD);

it's nice and easy to use.
Post Reply