BSP Compiler Last edited 11 months ago2023-12-18 11:47:12 UTC

This is the second of the four main compiling programs. It takes info from files output by CSG, checks for leaks, performs the space partitioning step by splitting the map into areas called leafs, generates collision data, and otherwise generates all the necessary data structures for the BSP file to make it playable. It's not optimized or lit up yet, that's the job for VIS and RAD compilers. For VIS it generates the portal file.

If there are leaks, a pointfile or line file is generated instead, and this can be loaded into the editor to trace those leaks.

More info from DOE, Snowdog:
BSP: The BSP tool is the one that actually converts the .map file data into a useable .bsp file that the game engine can load. Once the BSP tool is run the map is essentially playable with the exception that it will have no visibility matrix and will have no lighting at all. Those crucial features are applied by the next two tools VIS and RAD.

Stands for "Binary Space Partition".

Input/process/output

Inputs:
  • .bsp file from CSG
  • intermediate files from CFG
Processes:
  • Check that the "outside" of the level don't "leak" into the "insides"
  • Splits up the geometry using the BSP algorithm
  • Generates the rest of the structural data for BSP file
  • Generates collision data (clip hulls)
Outputs (on success):
  • BSP file data added:
    • Models, nodes, leafs, clipnodes, faces, vertices, etc.
    • BSP file is playable at this stage
  • Portal file for VIS compiler
Outputs (on leaky maps):
  • A point/line file to trace leaks in the editor
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.