API Reference · Materials and textures

TextureMapping

Namespace: Ava3D

public sealed record class TextureMapping

Coordinates for one material texture. Selects UV0/UV1, then applies scale, rotation about the origin and offset, following KHR_texture_transform. The material and node's shared UV transform follows this transform. Projected coordinates currently support only the identity per-texture mapping.

Properties

MemberDescription
static TextureMapping Identity { get; }

Shared identity mapping: UV0 with no per-texture transform.

Vector2 Offset { get; set; }

Offset after scale and rotation, in texture coordinates.

float Rotation { get; set; }

Counter-clockwise UV rotation in radians about the origin.

Vector2 Scale { get; set; }

Scale before rotation. Negative values mirror the image.

int TextureCoordinate { get; set; }

Zero selects Mesh.TexCoords; one selects Mesh.TexCoords1. Other sets are diagnosed and disabled.

See also