Log inGet started
Package

billboard.shaderModule

Newest version

This package holds more than this page lists. See all of its files in its world.

README.md

billboard

Cards that face the camera, for any surface shader: zero_billboard(c) turns an instance drawn with a flat mesh in its local XY plane toward the camera around its own origin and at its own scale, zero_billboard_axis(c, axis) turns it about a fixed world axis, and zero_billboard_streak(c) turns it about the instance's own Y axis — rotate an element so +Y points along its velocity and stretch its Y scale by its speed, and it draws as a streak along its motion. Call any of them from vertex_clip.

#include "@builtin::shaderModules.billboard"

fn vertex_clip(c: ClipVertex) -> ClipVertex {
    return zero_billboard(c);
}