UNPKG

@thi.ng/shader-ast-stdlib

Version:

Function collection for modular GPGPU / shader programming with @thi.ng/shader-ast

19 lines 713 B
/** * GLSL 100 trunc() polyfill. */ export declare const trunc: import("@thi.ng/shader-ast").TaggedFn1<"float", "float">; /** * Returns `x - y * trunc(x / y)`, i.e. essentially the same as JS `%` operator. * Result will always have the sign of `x`. */ export declare const modulo: import("@thi.ng/shader-ast").TaggedFn2<"float", "float", "float">; /** * Same as * [`foldback01`](https://docs.thi.ng/umbrella/math/functions/foldback01.html). * Folds `x` into the closed `[0,1]` interval, using infinite internal * reflection on either side of the interval. * * @param x */ export declare const foldback01: import("@thi.ng/shader-ast").TaggedFn1<"float", "float">; //# sourceMappingURL=interval.d.ts.map