Cargo Features

[dependencies]
glam = { version = "0.30.0", default-features = false, features = ["std", "debug-glam-assert", "glam-assert", "scalar-math", "cuda", "fast-math", "core-simd", "bytecheck", "approx", "bytemuck", "mint", "rand", "serde", "libm"] }
default = std

The std feature is set by default whenever glam is added without default-features = false somewhere in the dependency tree.

std default

enable support for the standard library

debug-glam-assert

enable additional glam checks if debug assertions are enabled

glam-assert

always enable additional glam checks

scalar-math

this is primarily for testing the fallback implementation

cuda

align types to match CUDA requirements

fast-math

Enables platform specific optimizations that might speed-up certain operations.
This will cause APIs to output different results depending on the platform used and will likely break cross-platform determinism.
This should NOT be enabled by intermediate libraries, deferring the decision to the end binary build instead.

core-simd

experimental nightly portable-simd support

bytecheck

Enables bytecheck of rkyv

"alloc" is needed to support to_bytes()/deserialize() in tests.

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.

approx implicit feature

Enables approx

approx:

Approximate floating point equality comparisons and assertions

Affects features::impl_approx

bytemuck implicit feature

Enables bytemuck

bytemuck:

A crate for mucking around with piles of bytes

Affects features::impl_bytemuck

mint implicit feature

Enables mint

mint:

Math interoperability standard types

Affects features::impl_mint

rand implicit feature

Enables rand

rand:

Random number generators and other randomness functionality

Affects features::impl_rand

serde implicit feature

Enables serde

serde:

A generic serialization/deserialization framework

Affects features::impl_serde

rkyv bytecheck?

Affects features::impl_rkyv

libm implicit feature

Enables libm

libm:

libm in pure Rust