Game Development Reference
In-Depth Information
Lighting On
SeparateSpecular On
// Set up alpha blending
Blend SrcAlpha OneMinusSrcAlpha
// Render the back facing parts of the object.
// If the object is convex, these will always be further away
// than the front-faces.
Pass {
Cull Front
SetTexture [_MainTex] {
Combine Primary * Texture
// Render the parts of the object facing us.
// If the object is convex, these will be closer than the
// back-faces.
Pass {
Cull Back
SetTexture [_MainTex] {
Combine Primary * Texture
Step 3. Drag and drop the shader into Unity's Project view.
Step 4. Create a new material. In the shader drop-down selection box
your new shader will be available as Backface On . You can now use the
material like any other.
Level of Detail
Level of detail (LOD) is a technique for providing multiple models and textures
for a single object with reducing levels of detail. For example, you may have
a high polycount, high-resolution textured model, a medium polycount,
medium-resolution textured model, and a low polycount, low-resolution
texture model for a single character. The model that gets drawn by the
renderer will depend on the distance the camera is away from the character.
If the character is close, the highest quality version is used. If the character
is far in the distance, the lowest quality version is used.
Search Nedrilad ::

Custom Search