×
Menu

Dark Map Rollout (EN)


Выдержка из оригинальной справки. (NDL Gamebryo 1.1)
 
The "Dark" map field is intended to hold a static dark map for the material, typically, but not exclusively, a grayscale map. The map will only need an alpha channel if being used on the PS2.
In Gamebryo, the base map's r,g,b values will be multiplied by the dark map's values causing it to appear dark where the dark map is dark and the regular base texture where the dark map is light.
This behavior also means that the dark map can only darken the base map (hence the name). In other words, white pixels in the dark map will pass the base map's color through untouched but any non-white dark map pixel will darken the base map's pixel.
Dark maps are commonly arranged with a different set of UVs than the base map so that a single surface has an un-tiled dark map that stretches across its entire extent, and the base map is tiled. This is a common solution for creating static lighting.
Using the Max5 Render to Texture feature to create Darkmaps
Once an artist achieves good scene lighting in 3ds max 5 (whether via Radiosity, normal lighting with shadows, or even using the Light Tracer), the next step is to get that information "baked" into the objects so it can be used at runtime in Gamebryo. At this point, 3ds max 5's "Render to Texture" feature becomes useful. The following steps will enable you use the Render-to-texture feature:
1) Create/Load your scene and place lights. Use whatever method desired to achieve the desired lighting. The approach may be as simple as using omni lights with shadows, or as complex as a Radiosity solution.
2) Open the new 'Render to texture' dialog in Max under the 'Rendering' menu.
3) Set the 'File Output Path' to a reasonable directory (likely the same directory as the model). Make sure you have the 'Automatic Unwrap Mapping' turned on and that the default map channel is one you have not already used. (It is set to Channel 3 by default)
4) Under the 'Selected Object Settings', add a 'LightingMap'; this step will render the lighting and the shadows to a texture. Set the map size to whatever works best for the dataset (256x256 is likely a valid initial value). If you are not creating a lighting effect, add whatever type of map you need.
5) Gamebryo will export the resulting baked shell material. The baked material seen in the viewport is the one that will be used. The render/viewport toggle will not affect the output Gamebryo material.
Use a viewer to look at the result, or export to a .NIF file. Repeat these steps until you achieve your desired look. You can also delete the shell material and manually load your lightmaps into the Darkmap slot of the Gamebryo shader to keep things more organized and simple.