by ricksan » Thu Oct 29, 2009 10:31 pm
The following was excerpted from the aforementioned article, "Getting a loco model from 3D Canvas into Rail Simulator -- A very basic Tutorial to get you started by Kevin Martin and Richard Scott, May 2008." It's available as a free download from UKTrainSim. I edited the excerpt based on my own experience.
Create a flat quad (4-sided plane) and place it under your loco with its Y coordinate set at, or just under, 0. If you set it too low, a thin dark line will appear beneath the railtops.
Use the custom name: To get this, right click on the shadow object (the "quad") and enter "softshadow" in the custom field.
Use the custom texture: To get this, create a simple oblong texture. Call it what you want and remember to use the power-of-2 rule for the texture map dimensions. For example, 128x1024 approximates the ratio of the plan-view dimensions of an 80 ft railcar. To create your artwork, start with an all-black layer. Make another layer and draw a gray rectangle, smaller than the extents of the texture map by, say, 16 pixels on each side. Blur the gray until the blurred edges just about reach the edges of the texture map. Adjust the opacity or brightness of the gray layer so it ends up as a dark gray. As with anything, take a look at what others have done as a guide. Enter the custom shader SubtractATexDiff. You don’t need to create an alpha channel to get the translucent effect around the edge. As the name implies, SubtractATexDiff subtracts from the underlying color: white is totally dark, black is totally transparent, grays are in between.
Last edited by
ricksan on Fri Oct 30, 2009 6:04 am, edited 2 times in total.