UNPKG

@thi.ng/shader-ast-stdlib

Version:

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

17 lines 556 B
/** * Converts linearized 2D index `i` into a vec2 UV coord, based on given * texture `size` (in pixels). * * @param i - * @param size - */ export declare const indexToUV: import("@thi.ng/shader-ast").TaggedFn2<"int", "ivec2", "vec2">; /** * Inverse operation of {@link indexToUV}. Converts vec2 UV coord into * linearized 2D index, based on given texture `width` (in pixels). * * @param i - * @param width - */ export declare const uvToIndex: import("@thi.ng/shader-ast").TaggedFn2<"vec2", "int", "int">; //# sourceMappingURL=index-uv.d.ts.map