Howto:Multi-channel lightmap: Difference between revisions

no edit summary
No edit summary
No edit summary
Line 5: Line 5:


Start by setting up your lighting scheme in Blender.
Start by setting up your lighting scheme in Blender.
Create the light sources you want to map (bake) in your blend. You can have up to 4 lightmaps per multi-channel light map in FlightGear. Each of those four lightmaps can be a single light source or a combination of light sources. In other words, you could potentially have 2 lights on the left combined into one lightmap and two on the right into another lightmap, leaving 2 channels open for 2 more lightmaps of any configuration.
Create the light sources you want to map (bake) in your blend. You can have up to 4 lightmaps per multi-channel light map in FlightGear. Each of those four lightmaps can be a single light source or a combination of light sources. In other words, you could potentially have 5 lights on the left combined into one lightmap and two on the right into another lightmap, leaving 2 channels open for 2 more lightmaps of any configuration.




This is what your cockpit or subject will look like when looking at it in the Material Viewport if using only the normal white light.
This is what your cockpit or subject will look like when looking at it in the Material Viewport if using only one normal white light.


[[File:Blend3a.jpg|800px|Lighting Scheme]]
[[File:Blend3a.jpg|800px|Lighting Scheme]]




You can set up your lights to mimic the 3 color channels used in the shader and thus bake three different light sources into three different channels in one bake session if you wish. This would eliminate some steps in Gimp during the next part of the process, but for the purpose of this tutorial, we'll take the longer approach so you can see how it is possible to work with images and their channels. This is what you might expect to see if you do a light source per color channel (rgb).
You can set up your lights to mimic the 3 color channels used in the shader and thus bake three different light sources into three different channels in one bake session if you wish. However in this case you can only use one light source per channel. This would eliminate some steps in Gimp during the next part of the process, but for the purpose of this tutorial, we'll take the longer approach so you can see how it is possible to work with images and their channels. This is what you might expect to see if you do a light source per color channel (rgb).


[[File:Blend6a.jpg|800px|Setting up colored light sources]]
[[File:Blend6a.jpg|800px|Setting up colored light sources]]
Line 200: Line 200:




That is it, you now have a four channel lightmap with up to four differnet light configurations per channel to use in FlightGear.
That is it, you now have a four channel lightmap with a different light configurations per channel to use in FlightGear.


[[File:Tutorial 19.jpg|800px|The finished four channel lightmap with included alpha channel mask (rgba)]]
[[File:Tutorial 19.jpg|800px|The finished four channel lightmap with included alpha channel mask (rgba)]]
This is what the final rgba lightmap looks like. You can verify that it is correctly configured by examining it in Gimp using the Channel tab.


[[File:Tutorial 20.jpg|thumb|Close up visual of final four channel lightmap ready for export to FlightGear]]
[[File:Tutorial 20.jpg|thumb|Close up visual of final four channel lightmap ready for export to FlightGear]]
Here the green and blue channel are off so you can see the red channel and alpha channel (you wont see anything if you turn off the alpha.


[[File:Tutorial 21.jpg|thumb|Verifying the four channels (showing the red channel)]]
[[File:Tutorial 21.jpg|thumb|Verifying the four channels (showing the red channel)]]


[[File:Tutorial 22.jpg|thumb|Verifying the four channels (showing all channels)]]
 
This is showing the alpha channel. Note that it has some transparency. That is correct. If it is solid black then you don't have a correctly configured alpha channel'


[[File:Tutorial 23.jpg|thumb|Verifying the four channels (showing the alpha channel)]]
[[File:Tutorial 23.jpg|thumb|Verifying the four channels (showing the alpha channel)]]
330

edits