Sub topic 1
What UV Coordinates Are and Why Meshes Need Them
Prerequisites
This chapter assumes that you can navigate the Blender 3D viewport, switch between Object Mode and Edit Mode, select mesh components, and create or edit a basic material.
A 3D mesh describes shape. It stores points in three-dimensional space, along with edges and faces that connect those points. An image texture is flat. It is a rectangular grid of pixels. UV coordinates provide the connection between these two forms.
The Working Model
A UV coordinate is a two-dimensional position assigned to a part of a mesh. The letters U and V are used instead of X and Y so they are not confused with the mesh's 3D axes.
Blender usually expresses UV positions in normalized image space:
- U controls the horizontal position.
- V controls the vertical position.
- 0 is the left or bottom edge.
- 1 is the right or top edge.
- Values outside the 0-to-1 range can repeat or extend the image, depending on the texture settings.
For example, a UV coordinate of (0.25, 0.75) points to a location one quarter across the image and three quarters up it. Blender samples the image at that location when it shades the surface.
A triangle's corners have UV coordinates, so Blender can interpolate the coordinates across the triangle. This lets every visible point on the surface receive a corresponding location in the image.
UVs Belong to Face Corners
A common mistake is to think that every mesh vertex can have only one UV coordinate. In Blender, UV data belongs to face corners, also called loops. A single 3D vertex can appear in several faces, and each face corner can use a different UV position.
This is necessary at a texture seam. Imagine a cube corner where three sides meet. The same 3D vertex may need to appear at three separate locations in the flat image. Blender keeps the 3D vertex shared while allowing its face corners to have separate UV coordinates.
| Mesh data | Purpose |
|---|---|
| Vertex | Stores a point in 3D space |
| Face corner or loop | Connects a face to a vertex and stores corner-specific data |
| UV coordinate | Stores the image-space position for that face corner |
You can inspect the active UV map with Python. Run this in Blender's Scripting workspace with a mesh object active and an active UV map available.
import bpy
obj = bpy.context.active_object
if obj is None or obj.type != "MESH":
raise RuntimeError("Select a mesh object before running this script.")
uv_layer = obj.data.uv_layers.active
if uv_layer is None:
raise RuntimeError("The mesh has no active UV map.")
for polygon in obj.data.polygons:
print(f"Face {polygon.index}")
for loop_index in polygon.loop_indices:
vertex_index = obj.data.loops[loop_index].vertex_index
uv = tuple(uv_layer.data[loop_index].uv)
print(f" corner {loop_index}, vertex {vertex_index}, UV {uv}")The loop index identifies the face corner. Notice that the same vertex index can appear more than once with different UV values.
Why Unwrapping Is Needed
Unwrapping is the process of converting the surface of a 3D mesh into one or more flat UV shapes, called islands. It is similar to cutting and flattening a cardboard box. A curved or closed surface cannot usually become flat without cuts, stretching, or both.
The unwrap determines which part of the image appears on each face. It does not change the mesh's shape. Instead, it changes the UV map stored alongside the mesh.
The result depends on:
- The cuts, or seams, that tell Blender where islands may separate.
- The unwrap method, which controls how Blender flattens each island.
- The available image space and how the islands are arranged inside it.
Texture Space and Scale
UV coordinates are independent of the image's pixel dimensions. The same UV map can use a 512-by-512 image or a 4,096-by-4,096 image. The larger image provides more pixels for the same surface area, but it does not automatically improve the UV layout.
Texture detail depends on texel density. A texel is one texture pixel applied to a surface area. If one island is much larger than another even though their real-world surfaces are similar, the material may look sharper on one part and blurry on the other. Keeping island scale consistent is therefore part of making a useful UV map.
Exercise
Why can one 3D vertex need multiple UV coordinates?
Show answer
A vertex may belong to faces on different sides of a seam. Each face corner can then point to a different location in the flat image.