
This covers the basics of creating procedural textures and lights in Unity. Items covered also include the creation of normal and reflection maps to be used in the Unity engine, as well as a link to the Unity site that covers the many aspects of shaders found in the program.
BEFORE YOU START
Create a new project
Project Structure > Desktop
Dont check anything in this opening window.
Unity will relauch – Fnd the project folder
Find the assets folder.
Move the fbx, normal and diffuses into the asets folder
We could also in Unity drop items into the projects folder
Untiy will generate a materials folder because of the fbx file
LOADING FILES
Load the file by dragging the fbx into the viewport or the heriarchy view
When you drop an object in a scene, it uses the enter of the camera you are using right now. You might see that its in a weird spot. Its better to directly load it in the Heriarchy view.
This will placeed in center of world.
Same controls as Maya
F is to zoom in on object
In heirarchy view, when you click mesh twice, you select the object and the child.
For now, be sure you click Mesh1
material vs. shader.
shader is a realtime engine material
material is for rendering
LOADING SHADERS & LIGHTS
Connect click and control drag your jpg into the base square texture channel
Add a light. Game object > Create Other > Point Light
Move it around.
Change shader type, go to drop down material
Click bump diffuse
Let’s simulate surface tuecture
Grabe the dirty normal > Its a bw of the color
Go to Tuexture Type and choose normal map.
Click appy
Apply this to the crate
Click Mesh one and click and drag the normal into the normal map shader square input.
Tap space bar to maximimaze viewport
Move light around to see how normal map is affected.
If you look at the normal map, look for the “generate from grayscale”
In this setting, you can play and adjust the bumpinessa nd smooth > Click Apply
Make a new shader
Click shader drop down
Choose bump specular to add a specular
use the slider for shininess to adjust the specular
In Preview you can choose light setup and shape
This specular and the bump diffuse is the workhorse in Unity
Now let’s add a reflective
Reflective Bumped Specular – so show the
Place picture in folder
To add the picture into
Grab file and turn it into a reflection > change map into spherical
Use the slider to control the reflection Black
Add this color to the bumped specular node/bump box.
You can turn this into normal map too.
RESOURCES
NDO – Pshop actions to create a map
Specular Map
In the material properties
set image to specular
The alpha channel is what makes the spcular map.
This can be painted by hand in the alpha channel in Photoshop. When you load this, Unity recognizes it. Pretty cool.
File formats in Unity for normals
Using this, gives you additional levels of details.
Unity shader guide
http://unity3d.com/support/documentation/Components/Built-in%20Shader%20Guide.html





