Texture alignment

From Valve Developer Community
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Hammer has several modes of projecting textures onto brush faces.

Todo: Hammer++ Hammer++ allows the user to manually edit the UV normal vectors; explain this.

World Alignment

World alignment is an option in the Hammer Face Edit Dialog. When it is enabled, it means that the texture is projected along the global x, y, or z axis (whichever is closest to the orientation of the face).

An illustration of World alignment on a face. Note the distortion on the angled face.

Face Alignment

With face alignment, the texture is projected directly onto the face, whichever direction it points.

Note that quite often, a face already points in the same direction as the Hammer grid. In that case, both "world" and "face" will be checked in the face edit dialog, and they can't be unchecked. This is not a bug; it just indicates that both texture projections apply to the selected face. Just as often, a face points in the opposite direction as world alignment. In that case there is a difference between "World" and "Face" alignment.

An illustration of Face alignment on a face.

Arbitrary Alignment

Textures can be projected along any direction. When neither "world" nor "face" is checked in the face edit dialog, texture alignment can be considered arbitrary.

Alt+Right Click

Select one face on a brush, and then right click an adjacent face while holding alt. The texture on the second face will be aligned and shifted to match seamlessly at the shared edge. The effect is as if you had "folded" the texture around the edge. This technique is useful for aligning textures across multiple faces.

The blue box illustrates the new texture projection of the face on the left

Align to View

An often-overlooked feature is Align to View: the ability to project textures using the angles of the camera. The usefulness of this feature is limited, but it illustrates how much flexibility there is in texture alignment.

The distortion of Hammer's default camera FOV is apparent here, but pulling the view back would show how these textures are perfectly aligned.