Premium apps Part of Renderloom

UV Unwrap (LSCM) for OBJ, STL and PLY

Cut seams, flatten charts with least-squares conformal maps and pack them into an OBJ with UVs.

A triangle mesh up to 200000 triangles. Coincident vertices are welded and faces oriented before unwrapping.

Edges whose neighbouring faces bend by at least this angle become seams.

More options

Paths of vertex numbers (1-based, as in OBJ, after welding). Consecutive vertices are joined along the shortest edge path. Separate paths with a semicolon or a new line.

Mean |ln(area ratio)| of a chart. Lower values give more, flatter charts.

Try an example: Open cylinder with one manual seam unwraps to a rectangle (OBJ) · Sphere: automatic chart split, area distortion reported (binary STL) · Box with seams at its 90° edges: six undistorted charts (OBJ) · Bent planar sheet keeps its shape exactly (ASCII PLY)

More about this tool

How it works

Upload a triangle mesh to get texture coordinates: seams at sharp edges or along your own vertex paths, charts flattened with least-squares conformal maps (LSCM), packed into the unit square with padding, and a distortion report per chart (angle error, quasi-conformal ratio, area distortion, L² stretch). Download an OBJ with vt coordinates and the UV layout as SVG. Runs on the same engine as Renderloom Sculpt Lab.

  • The mesh is welded (tolerance 1e-6 × bounding-box diagonal), degenerate and duplicate faces are dropped and faces are oriented consistently; a half-edge structure then gives edges and neighbours.
  • Seams: edges whose faces bend by at least the seam angle, manual vertex paths (shortest edge path between consecutive vertices) and the mesh border. Faces connected across non-seam edges form charts; inside a chart, corners are merged across non-seam edges, so a seam inside a chart becomes a cut.
  • Every chart must be a topological disk (Euler characteristic 1 with a border). Closed charts, charts with holes, charts with flipped triangles and charts above the area-distortion limit are split in two by growing regions from two far-apart faces, up to the chart limit.
  • LSCM (Lévy et al. 2002): the Cauchy–Riemann residual of each triangle, weighted by √area, is minimised in the least-squares sense with two far-apart vertices pinned. The normal equations AᵀA·x = Aᵀb are assembled per triangle and solved with the shared Proofline sparse solver: envelope Cholesky after reverse Cuthill–McKee ordering, or SSOR-preconditioned conjugate gradients above 12000 unknowns.
  • Each chart is scaled so its UV area equals its surface area, rotated to its minimum-area bounding rectangle (rotating calipers on the convex hull) and shelf-packed into the unit square with the padding gutter. Distortion uses the singular values σ₁ ≥ σ₂ of each triangle’s Jacobian: σ₁/σ₂ (1 = angles kept), √((σ₁² + σ₂²)/2) (Sander’s L² stretch) and σ₁σ₂ (area ratio, chart scale normalised).

LSCM keeps angles, not areas: curved charts (spheres, organic shapes) show area distortion, which the report quantifies. Packing is a simple shelf packer, not an optimal atlas. Vertex numbers for manual seams refer to the welded mesh.

Sources

Part of Renderloom

How to use the UV Unwrap (LSCM) tool

Give a mesh texture coordinates: seams, conformal charts, packing and a distortion report, exported as an OBJ with vt lines.

What it is for

A mesh needs texture coordinates (UVs) before you can paint it, apply an image texture or bake normal and occlusion maps. This tool cuts the surface into charts, flattens every chart with least-squares conformal maps (LSCM) and packs the charts into the unit square. You download an OBJ with vt lines and an SVG of the layout.

It keeps angles, not areas. A box or a cylinder unwraps without distortion; a sphere cannot, and the tool tells you how much area it had to stretch. It is not an atlas optimiser: the packer places charts row by row and leaves gaps.

Worked example

The first example is an open tube: radius 10, height 30, 48 segments and 12 rings, uploaded as OBJ. Automatic seams is set to Manual seams only and Manual seams (vertex numbers) to 1-577 — vertex 1 at the bottom and vertex 577 straight above it at the top.

The tool reports 1 chart, 12 manual seam edges, 637 UV vertices (624 vertices plus the 13 duplicated along the seam), a mean angle error of 1.755e-5° and a mean area distortion of 1.509e-6. The layout is a rectangle whose sides have the ratio of the polygon's perimeter (2 · 48 · 10 · sin(π/48) ≈ 62.8) to the height 30 — the 2πr : h you expect from rolling out a tube.

The second example, a sphere without seams, cannot stay one piece: a closed surface has no border to flatten. The tool splits it once into 2 charts and reports a mean angle error of 1.504° and a mean area distortion of 0.3463; per chart the area ratio runs from 0.503 to 2.73. Setting Split charts above this area distortion to 0.15 gives 4 charts with 0.1216 and ratios 0.778–1.39.

How to read the result

  • Mean angle error compares every corner angle on the model with the same angle in UV space. Near zero means a checker texture shows square squares.
  • Mean quasi-conformal ratio σ₁/σ₂ is the same idea per triangle: 1 means circles stay circles.
  • Mean area distortion |ln(area ratio)| is 0 when every triangle keeps its share of the chart's area. 0.35 means a typical triangle is about 40 % larger or smaller than it should be.
  • Unit square filled by charts is how much of the texture the charts use; the rest is padding and gaps.
  • Distortion per chart shows which chart causes trouble and which solver was used (Cholesky for most charts, conjugate gradients for very large ones).

Tips and common mistakes

  • Put manual seams where nobody looks: the back of a character, the inside of a handle, along a hard edge.
  • Vertex numbers start at 1, as in OBJ files, and refer to the welded mesh. Two consecutive numbers do not need to share an edge; the seam follows the shortest edge path.
  • Lower the Seam angle (°) for hard-surface models with many bevels, raise it to keep organic shapes in one piece.
  • Set Texture resolution for the padding (px) to the size of the texture you will paint, so the gutter between charts is really 4 pixels.
  • A warning about a projected chart means LSCM could not flatten it (for example a closed mesh with Maximum number of charts set to 1). Allow more charts.

FAQ

Which programs can read the OBJ?

Any program that reads Wavefront OBJ with vt coordinates: Blender, Substance, game engines and Renderloom's own baker.

Why does my sphere show stretched squares near the chart edges?

LSCM preserves angles, so squares stay square but grow towards the borders. Allow more charts with a lower area distortion limit.

Does it keep my existing UVs?

No. It always creates new texture coordinates; the vertex positions and face order stay as in the welded mesh.

Can I see the result on the model?

Yes. Renderloom Sculpt Lab shows the same unwrap with a checker texture on the mesh.

Guide last updated:

For scripts and AI agents

  • JSON API: POST https://renderloomuvunwrap.usefulweb.site/api/v1/calculate (same calculation as this page)
  • Interface description: OpenAPI 3.1 · AI guide: llms.txt
  • MCP server (Streamable HTTP): https://renderloomuvunwrap.usefulweb.site/mcp · tool name renderloom_uv_unwrap
Example request
curl -s -X POST https://renderloomuvunwrap.usefulweb.site/api/v1/calculate \
  -H 'content-type: application/json' \
  -d '{…see OpenAPI examples…}'
Feedback · ideas & bug reports welcome