Metal Shading Language

Data types and constants

Scalar types

Vector types

Matrix and custom types

Constants

Texture types, samplers & functions

Texture types

Texture samplers

Texture functions

Attributes

Attributes

Control flow and qualifiers

Control flow

Qualifiers

Functions

Common functions

Power functions

Trigonometric functions

Geometric functions