Merge: gamnit: fix field of view issues
authorJean Privat <jean@pryen.org>
Tue, 6 Sep 2016 19:16:12 +0000 (15:16 -0400)
committerJean Privat <jean@pryen.org>
Tue, 6 Sep 2016 19:16:12 +0000 (15:16 -0400)
commitd477e99a7cd65ef4932df2cf6355fa2be43da5f2
tree1aa6a3172e77b22e329c090672b0b6302e5f988c
parentf51fb829cf5752eea5d48d04cb8c60041b930172
parentf2ceffbdd592590e14074ee1b55129f73578f712
Merge: gamnit: fix field of view issues

Erroneous code at creation of the perspective matrix caused a wider than requested frustum and field of view. This caused issues in other gamnit code:

* The service `camera_to_world` had to multiply the result by 1.72 to correct the deformation.
* In `asteronits`, the world was not filling the screen, only part of it.
* In general, it created a cool but not desired wide angle lens / fisheye effect.

After the fix, some clients might have to widen the requested visible area, usually set with `reset_height`. We may have to lower the default `field_of_view_y` as it is a bit high.

Pull-Request: #2307
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
Reviewed-by: Jean Privat <jean@pryen.org>