2. COURSE DESCRIPTION: L-0, T-0, P-6 AND C-3
(L-LECTURE ,P-PRACTICAL ,T-TUTORIALS, C- CREDITS)
• “AFT 227- 3 D Texturing” is a basic foundation course about texturing in maya
• These fundamental concepts provide a basis for information of texturing disciplines as they are applied
by the students regardless of their major area of interest.
• This course is foundational in content and provides the students of Design/art with methodologies for
composition and quality performance in three-dimensional presentations.
3. COURSE OBJECTIVE
• execute process and techniques to creating shaders, textures and to build shading trees
• learn about techniques in UV texture mapping for both environments and character
creation.
• work with software, mental ray shaders input and output nodes.
• work with 3D digital painting and texture tools on inorganic and organic forms.
4. COURSE CONTENT (ABOUT , HOW DO I ) PART-1
• About shading and texturing surfaces ( Surface shading , Surface texture , Shading networks , Maya
materials , Surface, displacement, volumetric materials , Layered shaders ,Double-sided shaded surfaces)
• MAYA TEXTURING(2D and 3D textures ,Procedural ,File Adobe Photoshop texture networks ,Texture
filtering )
• Mapping and positioning textures (Texture mapping, Mapping methods , 2D and 3D texture positioning ,
Texture placement vs. label mapping , Object space, world space and tangent space ,Transfer Maps
• Build shading networks (Overview of building shading networks , Open and customize Hypershade,
Open and navigate Hypershade , Show top and bottom level tabs, Hide shape and transform nodes in
Hypershade ,Create Hypershade tabs ,Hide, resize or customize the Create bar, Organize render nodes with
Hypershade sorting bins , Change default connection line colors. ,Create a node,Delete a node and its
network ,Import and export shading networks., Connect nodes ,Show node connections , Assemble nodes
into logical groupings using container nodes in the Hypershade ,Connect render nodes using their default
connections, Connect default output to a specific input attribute , Connect render nodes by dragging
existing connection lines, Connect render nodes using the Connection Editor ,Change existing render node
attribute connections , Delete a render node connection ,Adjust node attributes , Work with shader
libraries,View the Shader Library Gallery, Assign a shading group from the Shader Library, Create and assign
materials to surfaces)
5. COURSE CONTENT (ABOUT , HOW DO I, CASE STUDY)
PART- 2
• Surface Relief
(About surface relief ,Scattering ,Bump maps ,Displacement maps,Feature-based displacement.)
(Connect a texture as a displacement map, Connect a displacement map ,Preview the displacement results
,Adjust displacement sampling rates ,Convert a displacement to polygons ,Change bounding box scale ,Work
with Scattering )
CASE STUDY
(Character texturing, Environment Texturing ,Prop model Texturing)
6. INTRODUCTION TO TEXTURING STRUCTURE IN MAYA
• Visual: - relating to seeing or sight (Anything which is direct contact of light)
• THE HYPERSHADE (SHADER NETWORKING)
+ UV TEXTURE EDITOR(UV MAPP)
= VISUAL APPEARANCE OF TEXTURE (HUD, WORKING PLACE OF
MODELING)
• PUBLISH IN THE FORM OF RENDERING
8. • In the real world, what an object is made of is one of two main
factors that determine the appearance of its surface (the other is
light). This is because when light hits the objects, some of the light
is absorbed and some of it is reflected. The smoother the object,
the shinier it is; the rougher the object, the more matte it is.
• In Autodesk®Maya®, the appearance of a surface is defined by how
it’s shaded.
• Surface shading is a combination of the basic material of an
object and any textures that are applied to it.
• In Maya, materials (also called shaders) define an object’s
substance. Some of the most basic attributes of materials
include color, transparency, and shine.
9. SURFACE TEXTURE
• In visual arts, a texture is any kind of surface detail, both visual and tactile. In
Maya, we create surface detail with textures connected to the material of
objects as texture maps (UV Mapping)
• Before texturing we will understand about Polygon shading models
• Most algorithms use the polygon or surface normal (vector that is
perpendicular to the polygon)
NL
10. CONSTANT SHADING
• Also known as Lambert, faceted and flat shading
• Calculates a single intensity value for each polygon
• Valid if following assumptions are true:
• Light source is at infinity (i.e. angle between light and surface is constant)
• Viewer is at infinity
(i.e. angle between
viewer and surface
is constant)
• Polygon is not an
approximation of
a curved surface
11. INTERPOLATED SHADING
• Shading is linearly interpolated across polygon
• Faster than calculating each pixel, better than flat shading
• Still assumes that polygon represents the true surface
POLYGON MESH SHADING
• Many sets of polygons actually are approximations to curved surfaces
• Shading the polygons to realistically simulate the surface is therefore important
• Several methods exist to achieve this, the most important of which are Gouraud
and Phong shading.
12. GOURAUD SHADING
• This is a form of intensity interpolation shading
• Starts from knowing the normal of the surface at each vertex of the
polygon
• These may be stored with the mesh or may be averaged from the adjacent
polygons
• Next step is to calculate the vertex intensities
• This will use the vertex
normal and the
illumination algorithm
(Henri Gouraud, PhD 1971)
13. • The polygon is then shaded by:
• Interpolating the intensities along each edge
• Interpolating across the polygon between the edges along each scan
line
I1
I2
I3
IP
14. PHONG SHADING
• This is a form of normal-vector interpolation shading
• Starts from the normal vector at each vertex again, but interpolates
the vector rather than the intensity
(Bui-Tong Phong, PhD 1975)
16. POLYGONAL SILHOUETTE
• Approximation is polygonal, so no matter how good the shading
algorithm the silhouette will be faceted
• Can be improved by increasing the polygon count at expense of
processing time
PERSPECTIVE DISTORTION
• Because the interpolation is based on the scan lines, the
number of interpolation increments per polygon depends
on the angle of the polygon to the viewer
• Steep angle = few increments
Shallow angle = more increments
17. ORIENTATION DEPENDENCE
• Because interpolation occurs between vertices and
along scan lines, result depends on orientation of
polygon relative to scan lines
SHARED VERTICES
• Problems occur when adjacent polygons do not share
vertices
• This can lead to discontinuities in shading
19. POLYGONS, MESHES & SCAN CONVERSION
- IN SCAN LINE RENDERING (THE MOST COMMON): EACH POLYGON IS CALCULATED
ALONG EACH SCAN LINE. FROM THE TOP SCAN LINE TO THE BOTTOM OF A FRAME IN THE 2D
PROJECTION PLANE.
V2
V3
Raster
Scan line
V1
20. APPROXIMATING CURVED SURFACES WITH
FLAT POLYGONS
Flat Shading – each
polygon face has a
normal that is used to
perform lighting
calculations.
21. GOURAUD SHADING
• Compute vertex normals
by averaging face normals.
• Compute intensity at each
vertex.
I1
I2
I1,2 I1,3
I3
I1,2,3,4
Raster
Scan line
22. ILLUMINATION / SHADING
• global illumination:
• ray tracing + radiosity
• mapping and other techniques
• texture maps, bump maps, reflection maps,
transparency, anti-aliasing, shadows
ray tracing radiosity
23. LIGHTING TYPES
• Ambient – basic, even
illumination of all objects in a
scene
• Directional – all light rays are in
parallel in 1 direction - like the
sun
• Point – all light rays emanate
from a central point in all
directions – like a light bulb
• Spot – point light with a limited
cone and a fall-off in intensity –
like a flashlight
Penumbra angle
(light starts to drop off
to zero here)
24. LIGHT EFFECTS
• Usually only considering
reflected partLight
absorbed
transmitted
reflected
Light=refl.+absorbed+trans.
Light
ambient
specular
diffuse
Light=ambient+diffuse+specular
25. AMBIENT LIGHT
• is the light in the environment evenly reaching all
surfaces from all directions
• light location doesn’t matter
• eye position doesn’t matter
aaIkI IA: ambient light
ka: material’s ambient reflection coefficient
29. SPECULAR LIGHT
• Light that is reflected from the surface unequally
to all directions
• Models reflections on shiny surfaces
Light
n
dd
n
ss
REIk
IkI
cos N
Lf
Eye
R
f
Phong’s Law:
R
n=inf.
R
n=large
R
n=small
31. SHADING A POLYHEDRA
• Flat (facet) shading:
• Works well for objects
really made of flat faces.
• Appearance depends on
number of polygons for
curved surface objects.
• If polyhedral model is an approximation
then need to smooth.
33. FLAT SHADING
• Polygon meshes approximate smooth curved
surfaces with planar facets. Using the previous
methods does not generate an illusion of smooth
curved surface.
Reason: discontinuity of the normal vectors.
N1 N2
GOURAUD SHADING
• Assign vertex the normal of the smooth surface.
Or
• Average the normal of all neighboring polygons
N1 N2
N
Interpolate colors along edges and scan-lines
39. TEXTURE MAPPING
• Steps:
• Define texture
• Specify mapping from texture to surface
• Lookup texture values during scan conversion
Modeling
Coordinate
System
Image
Coordinate
System
Texture
Coordinate
System
40. Texture Filtering
Size of filter depends on projective warp
– Can prefiltering images
Magnification Minification
41. MIP MAPS
• Keep textures prefiltered at multiple resolutions
• For each pixel, linearly interpolate between
two closest levels (e.g., trilinear filtering)
• Fast, easy for hardware
42. What is Shading?
• Assigning of a color to a pixel in the final image.
• So, everything in shading is about how to select and combine
colors to get the look you want.
WHAT IMPACTS SHADING?
• The lights in a scene.
• The geometry of objects in a scene.
• The normals of objects.
• The shader properties of an object:
• Color,transparency, emissivity, etc…
• The rendering algorithm
• Eg ray-tracing versus scan-line rendering.
43. SHADERS
Lambert: No highlights
Phong: Distinct specular highlights
Phong E: Greater controls for softer highlights
Blinn: Versatile and soft highlights
Anisotropic: Directional highlights, such as hair
or metal
WHAT IS A TEXTURE?
• MAP surface detail from a predefined easy table
(“texture”) to a simple polygon
• Color
• Specular ‘color’ (environment map)
• Normal vector deviation (bump map)
• displacement mapping
• transparency
Textures are images that can be mapped to almost any
surface material
They can be bitmap images or can be created procedurally
• Bitmap textures can be created in an external program,
such as Photoshop, or inside Maya using 3D Paint
• Procedural textures are created using mathematical
formulae internal to Maya
46. UVS AND TEXTURE PLACEMENT
UV mapping overlays a texture onto a
flattened model (done in the UV Texture
Editor)
46
2D textures are mapped using a
place2dTexture node
3D textures are mapped using a
place3DTexture node
47. PHOTOSHOP INTEGRATION
Maya supports importing and exporting the photoshop PSD
format
Both Maya and Photoshop can use layers to combine multiple
bitmaps into a single file
Shading networks are created in the Hypershade based on the
layers of attributes in the PSD file
47
48. SHADERS
Ramp: Control color changes across the shader
Layered: Allows multiple layers to be stacked and
combined
COMMON ATTRIBUTES OF SHADERS
Color
Transparency
Ambient Color
Incandescence
Bump Mapping
Diffuse
Translucence
51. SURFACE LAYERS
• Combine multiple
shaders for astonishing
effects.
• Build up shades like a
painter.
52. RENDERMAN SHADERS
• Renderman is a procedural shader language with tremendous versatility.
• All major feature animated feature films use Renderman as part of production.
• Like programming in C code.
• You write Shaders for Renderman like you would write C code for computers.