User Tools

Site Tools


Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
mapping:compiling_new [2006-05-01 13:55]
Thrawn Just some visual/formal improvements
mapping:compiling_new [2013-01-07 12:07] (current)
Line 1: Line 1:
-====== Compiling Maps for Ca3DE ======+====== Compiling Maps for Cafu ======
  
-When you have finished editing a map in CaWE, you’ll want to run it with Ca3DE. The engine however requires that the map is in a precomputed form, and this section describes how you turn your map into a fully precomputed world file. The process of turning your **cmap map file** into a for the engine usable **cw world file** is called //​compiling//​.+When you have finished editing a map in CaWE, you’ll want to run it with Cafu. The engine however requires that the map is in a precomputed form, and this section describes how you turn your map into a fully precomputed world file. The process of turning your **cmap map file** into a for the engine usable **cw world file** is called //​compiling//​.
  
-The CaWE mapping editor ​has built-in compiler that does this job for you. In this tutorial, you'll learn how to handle ​it.+As to not force you to run the compile procedure for all your cmap files [[mapping:​compiling|by hand]], the CaWE mapping editor ​provides ​"​Compile"​ menu with which you can easily and very conveniently accomplish this task. In this section, you'll learn how to use it.
  
-===== Step 1Configurate ​the compiler =====+{{ mapping:tut_compile1s.jpg}} You will find the "​Compile"​ menu in the top menu bar of CaWE. It's items can roughly be separated into three distinct groups: The upper group tells CaWE //what// to do, the middle group says //how// to do it and the lower group is for //​stopping//​ the compile process early. The function of all items is explained in greater detail below:
  
-You can find the compiler menu in the CaWE mapping editor in the menu bar. When you click on it, a menu will open, let's have a look at it: 
  
-{{mapping:tut_compile1s.jpg}}+===== Step 1The compile steps =====
  
-You can roughtly seperate it into 3 parts. ​The upper part tells Ca3DE //what to do//, the middle part //how to do it// and the lower part if you want to //stop it//.+The upper group of menu items tells CaWE which steps of the compile process should be run. You can turn the individual parts on or off by checking or unchecking ​the mark in the appropriate line.
  
-The upper part is responsible for the configuration ​of the compiler. ​The entries there can be activated/​deactivated ​by clicking ​on them onceThe marker ​on the left shows that it is activatedif it is missing, the entry is deactivated.+  - **Save Map:** Saves the map. Checking this does exactly the same as a click on the "File -> Save" menu item before compiling the map. Having this checked ​is practical and recommended when you work on a map and want to test it "​live"​ in the Cafu engine every now and then, because it makes sure that the compilers pick up the latest version ​of your map with the most recent changes. 
 +  - **Run CaBSP:** This is the crucial step that runs the CaBSP compiler ​on your mapCaBSP takes your map file and creates a world file for use by the Cafu engine from it (the map file is not modified). As all other compilation steps build on this one and the generated cw file, you cannot turn it off to omit CaBSP. 
 +  - **Run CaPVS:** Runs the CaPVS compiler ​on the intermediate result obtained from CaBSP. CaPVS precomputes the PVS (Potentially Visibility Set) for the world file. This can be a lengthy process on its own, and you may wish to skip it when you're just testing your map. However, it also has a potential for improving the rendering performance of your map significantly,​ so you should never leave this out for release maps. 
 +  - **Run CaLight:** Runs the CaLight compiler on your map, which precomputes the static lighting of your maps by using physically accurate Radiosity methods. CaLight too can take very much time to complete, and should therefore never be run without a preceding CaPVS pass. However, for testing you may want to skip CaLight as well as CaPVS, because your map will be full-bright when CaLight ​is not runwhich may be sufficient for checking e.g. the geometry or entity placement during map development. 
 +  - **Start Engine:** If this entry is checked, Cafu will automatically be launched with your map when the compiling process is finished.
  
-__**Here is what the entries do:**__ 
  
-**1.Save map:** The last saved map file is turned into a working map for Ca3DE. If this entry is marked, the map file you are currently working with is being saved at the beginning of the compile process ​to make sure the __actual__ version is being compiled (and not an older version that was saved before).+===== Step 2Starting ​the compile process ​=====
  
-**2.Run CaBSP:** You can't deactivate this entryIt turns your map file into the world file that is required ​by Ca3DE.+After you have selected which steps should be included in the compile process, you can start it with varying quality settings by clicking on one of the three items of the middle group ("​Quick",​ "​Normal",​ or "High Quality"​). 
 +These settings mostly affect the quality of the lighting generated ​by CaLight, and therefore have a direct impact on its run-time.
  
-**3.Run CaPVS:** This entry defines if CaPVS is run after CaBSPCaPVS optimizes ​the world file which brings you on complex maps massive performance boosts.+After you started the compile process, a console window opens, showing compile details and progress information. 
 +Note that you can simply close the console window at any time and continue to work on your map while the compilation process keeps running in the backgroundJust use the "View -> Screen Elements -> Console"​ menu to toggle the console window ​on and off. The three menu items to start a compile will be grayed-out while another compilation is running, so that starting two compile processes simultaneously is not possible.
  
-**4.Run CaLight:** This entry defines if CaLight is run when compiling ​the map. It calculates ​the sun lighting in your map.+However, you can stop the entire currently running compilation process prematurely by clicking on the "​Compile -> Abort" menu item.
  
-**5.Start Engine:** If this entry is markedCa3DE will be launched automatically after the compiling ​process is finished.+If you activated the "Start Engine" itemCafu will be started when the compile ​process is complete and you'll just have to click on "​OK"​ in the Cafu dialog to start and play your map!
  
-===== Step 2: Compiling your map ===== 
  
-After you have configurated the compileryou can start it. You can do this by clicking on one of the 3 entries you can find in the middle part (**Quick, Normal, High Quality**). The compiling process can be accelerated (clicking on "​Quick"​),​ but in this case the quality of the lighting is not that good. On the other hand, you can produce optimal results which needs much more compiling time (clicking on High Quality). Normal is an average value.+===== TipsTricks and Trouble-shooting =====
  
-After you started ​the compiling process, ​console window opensit shows the actual process and the progressYou can stop the compiling process by clicking in the compiler menu on **Abort**+Using the "​Compile"​ menu requires that you have setup the "​Configuration"​ dialog of CaWE completely and properly. If compiler cannot be run correctlyplease check if you got all the executable file names right in this dialogPlease refer to [[mapping:​cawe:​install]] for more details.
  
-If you activated the "5. Start Engine"​ entry as an option, Ca3DE will be started ​when compiling ​is done and you just have to click on "OK" in the Ca3DE window ​to start and play your map!+If your map turns out to be pitch-black ​when run in the engine after the last compilation step, a likely cause is that you kept the CaLight compiler enabled, but did not place any radiosity light source (i.e. no light or sky material). For checking this quickly, ​just disable CaLight in the "Compile" ​menu, then start the compilation again and review the result ​in the Cafu engine. Thereafter, you may want to place some light sources into your map by applying materials that cast radiosity light, and re-enable CaLight again in order to compute a proper, realistic radiosity solution.
  
-===== Tips and tricks =====+For quick tests during map development,​ you can save a lot of compile time by turning off the CaPVS and CaLight compile steps. You may get very low frame-rates and only full-bright lighting, but that's usually fine for checking the map geometry. When you're done, or about to release your map for others, you definitively should compile it once with CaPVS and CaLight enabled, in order to obtain the maximum speed and quality.
  
-You can save a lot of compile ​time by turning off CaPVS and CaLightThat for, just don't activate them if you just want to quickly test your mapIn the case your map is very big you might be forced to turn on CaPVS to get respectable framerates in your map.+Very advanced users can also compile ​their maps manually at the command-lineThis offers the possibility ​for further customisations of the compile processCompiling maps at the command-line ​is explained [[mapping:​compiling|here]].
  
-Very advanced users can also compile their maps manually on the old way (offers the possibility for further customisations of the compile options). You can find a tutorial concerning this [[mapping:​compiling|here]]. 
- 
-__**Relevant links:**__ 
- 
-- [[mapping:​compiling|Compiling maps manually]] 
mapping/compiling_new.1146484520.txt.gz · Last modified: 2013-01-07 12:07 (external edit)