Call of Duty 2: Lightning Documentation: Difference between revisions

From COD Modding & Mapping Wiki
Jump to navigation Jump to search
(New page: Image:Nutshell.png Lighting with COD Tools is a fun and wonderful experience to be had by all! That is why I thought I would write up this handy document describing how to use our ligh...)
Ā 
mNo edit summary
Line 46: Line 46:
*bouncefracion #: This is the intensity of the GI calculation. Higher numbers result in flatter shading where light is present.
*bouncefracion #: This is the intensity of the GI calculation. Higher numbers result in flatter shading where light is present.


=Compiling And Iteration=
== Compiling ==
'''Using Compile Tools'''
Inside <code>call of duty/bin/</code>,''(thanks to Chad G.)'' there is an exe that is an interface with the compiler. Use this application instead of the command line to iterate.
The first section on the left is a list of your maps.
The next section in the middle at the top is where you set your options for compiling the geometry and light map resolution.
The section in the bottom middle is where you set your lighting options.
[[Image:Codtools.jpg]]
== Iteration ==
Iterating on your maps can be a very slow process when it comes to lighting.
You can speed this up somewhat by using lower quality settings.
The first thing you can do is set the '''samplescale''' to higher numbers for a lower light map resolution. The default is 1.
The other thing you can do is use '''fast''' in the lighting section.
After you have tweaked your map enough, you can then use default '''samplescale''' and set the lighting section to '''extra'''.
Using '''modelshadows''' may slow things down, but I have not noticed any big difference in render times.
=Local Lights=
...
=Fine Tuning Your Lighting=
...


Sources: Infinity Ward Docs
Sources: Infinity Ward Docs
[[Category:Call of Duty 2]]
[[Category:Call of Duty 2]]
[[Category:Technical Reference]]
[[Category:Technical Reference]]

Revision as of 03:48, 13 February 2009

Lighting with COD Tools is a fun and wonderful experience to be had by all! That is why I thought I would write up this handy document describing how to use our lighting system, as well as add few tips on giving your maps some drama.


World Spawn

This is where you set the overall look for your map lighting.

There are two ways to edit worldspawn settings. After opening a map in radiant, press the ā€œnā€ key. You can access the worldspawn settings and input values into the key and value boxes.

The other (preferred by me) way is to open the map in a text editor and change the values that you find at the top of the page.

By default, the lighting settings are empty. You can input them manually or just copy and paste from another map to get started.


Direct Light

Direct light is basically anything that is in a direct sunlight. This is where most of the normal and specualar values can be seen.


sunlight

  • Sundirection # # #: The axis are based on world space not local to the light. The first number is the north south axis. The second number is the up down axis. The third is the axis through the light and therefore usless.
    • # 0 0 0 --- light comes from the right
    • # 90 0 0 --- light comes from the bottom
    • # -90 0 0 --- light comes from the top
    • # 0 90 0 --- light comes from the top
    • # 0 180 0 --- light comes from the right
  • sunlight #: The brightness of the sun light. Values over 1 will be overbright.
  • suncolor # # #: there are 3 values to set for suncolor. Radiant uses a range from 0-1 instead of 0-255.


You can pick the rgb values you want and then divide that number by 255 to get the value that fits in the 0-1 range.


Indirect Light

Indirect light is anything that is not in direct sunlight. Bump and spec values are about 30% intensity.


Shadows and Shade

  • ambient #: This is the amount of ambient light added to the scene. I usually use ambient to set what I want the darkest dark to be. If you go too high the map tends to look flat.
  • _color # # #: This is the ambient color value.(Isnt it obvious?) Use the same method for _color as for the suncolor to get the ambient color. This value also mixes with the sun color.
  • diffusefraction #: This is the brightness of the indirect light source. If you use a value of 1, sunlight is not visible.
  • sundiffusecolor # # #: THis is the color of the indirect light source..
  • bouncefracion #: This is the intensity of the GI calculation. Higher numbers result in flatter shading where light is present.


Compiling And Iteration

Compiling

Using Compile Tools

Inside call of duty/bin/,(thanks to Chad G.) there is an exe that is an interface with the compiler. Use this application instead of the command line to iterate.

The first section on the left is a list of your maps.

The next section in the middle at the top is where you set your options for compiling the geometry and light map resolution.

The section in the bottom middle is where you set your lighting options.


Iteration

Iterating on your maps can be a very slow process when it comes to lighting.

You can speed this up somewhat by using lower quality settings.

The first thing you can do is set the samplescale to higher numbers for a lower light map resolution. The default is 1.

The other thing you can do is use fast in the lighting section.

After you have tweaked your map enough, you can then use default samplescale and set the lighting section to extra.

Using modelshadows may slow things down, but I have not noticed any big difference in render times.


Local Lights

...

Fine Tuning Your Lighting

...

Sources: Infinity Ward Docs