Welcome

Quake Lenses is like Surround Sound for your eyes. It extends your field of view, allowing you to see more of your surroundings in a small amount of screen space.

This is a fork of Fisheye Quake. It adds support for custom lenses using Lua scripts. Several lenses are included.

For an interactive description of how this works, check out the manual. For a detailed look at different types of lenses, check out the gallery.

Quick Look

> lens fisheye2
> fit 
> lens panini
> hfov 200
> lens vandergrinten
> fit
> lens mercator
> fit
> lens winkeltripel
> fit
> lens cube
> fit

Commands

Commands can be entered via Quake's console by pressing the tilde key (~).

Lens Files

In the lenses folder, you will see a collection of Lua files. These represent the lenses you can use in a game. If you're interested, you can create your own and place it in this folder. Here is an example script:

 1 -- Mercator Projection
 2
 3 -- horizontal and vertical symmetry
 4 hsym = true
 5 vsym = true
 6
 7 -- FOV bounds
 8 max_hfov = 360
 9 max_vfov = 180
10
11 -- horizontal fit size
12 hfit_size = 2*pi
13
14 -- inverse mapping (screen to environment)
15 function xy_to_latlon(x,y)
16    local lon = x
17    local lat = atan(sinh(y))
18    return lat, lon
19 end
20
21 -- forward mapping (environment to screen)
22 function latlon_to_xy(lat,lon)
23    local x = lon
24    local y = log(tan(pi*0.25+lat*0.5))
25    return x,y
26 end
27
28 -- domain test
29 function xy_isvalid(x,y)
30    return abs(x) <= pi
31 end

Selecting a Lens

To change your lens, use the lens command. For example, if you wish to use the "panini" lens, type lens panini. The game will then load the file called "panini.lua" from the lenses folder.

Lens Tab Completion

As a convenience for quickly selecting lenses, you can use the tab-completion feature from TyrQuake. Begin typing the lens name and press tab to try to complete the rest of the name. If more than one lenses match, you can press TAB again to list all the matching lenses. (You can also use this to list all the available lenses, seen below.)

> lens <TAB><TAB>

FOV

You can zoom in and out by specifying a viewing angle for your Field of View (FOV). Type hfov 180 if you want your screen to horizontally cover 180 degrees. Similarly, you can type vfov 90 to cover 90 degrees vertically.

> lens panini
> hfov 90
> lens panini
> hfov 180

Fitting

If the image produced by the lens is not infinite in size, you can fit the whole image on the screen by typing fit. Alternately, if you just want the picture to fit the horizontal or vertical bounds of the screen, you can type hfit or vfit, respectively.

> lens hammer
> hfit
> lens hammer
> vfit

Invalid Modes

If the lens does not support the current zoom mode, Quake Lenses will give you a blank screen, an error message on the console, and will wait for you to enter a valid zoom mode. For example, the cube lens does not support FOV; it can only be zoomed to fit the screen. Another common error happens if the specified FOV is too high for the current lens.