VIS Compiler Last edited 4 months ago2023-12-18 11:31:23 UTC

This is the third of the compiling programs. It takes the .pt2 file from the BSP program with all the leaf and portal data, and figures out line of sight, i.e. which leaf portals can see which other leafs. This data is primarily for rendering in-game but is also used by RAD.

This program is not absolutely necessary, but for a final build is a must. It optimizes the map, speeding things up greatly. However, modern RAD compiler requires the visibility data output by the VIS compiler to work, so at the very least run VIS with -fast argument.

An overly complex map can generate a lot of leafs and portals, and this can bog down VIS calculation significantly. Tying detailing brushes to func_walls & co. or func_details reduces cuts on BSP leafs and helps speed up VIS calculations.

More info from DOE, Snowdog:
VIS: This tool creates the visibility matrix for the map based on the levels geometry. This matrix is what determines which polygons the player can see, might see, and can't see from any given point within the level in game. It is critical that this tool be run on every .bsp you create. If it is not run then the entire level will be visible all the time which would, in all but the simplest of box maps, make the map unplayable due to video-lag.

Input/process/output

Inputs:
  • .bsp file from BSP [compiler]
  • Portal file from BSP
Processes:
  • Generates Potentially Visible Set (PVS) data; a lookup table for each leaf on whether every other leaf is visible from it
Outputs:
  • BSP file data added:
    • PVS data on leafs
Compilation programs
  1. CSG
  2. BSP
  3. VIS
  4. RAD

Comments

You must log in to post a comment. You can login or register a new account.