import * as typegpu16 from "typegpu"; import * as typegpu_data37 from "typegpu/data"; //#region src/3d.d.ts /** * Signed distance function for a sphere * @param point Point to evaluate * @param radius Radius of the sphere */ declare const sdSphere: typegpu16.TgpuFn<(point: typegpu_data37.Vec3f, radius: typegpu_data37.F32) => typegpu_data37.F32>; /** * Signed distance function for a 3d box * @param point Point to evaluate * @param size Half-dimensions of the box */ declare const sdBox3d: typegpu16.TgpuFn<(point: typegpu_data37.Vec3f, size: typegpu_data37.Vec3f) => typegpu_data37.F32>; /** * Signed distance function for a rounded 3d box * @param point Point to evaluate * @param size Half-dimensions of the box * @param cornerRadius Box corner radius */ declare const sdRoundedBox3d: typegpu16.TgpuFn<(point: typegpu_data37.Vec3f, size: typegpu_data37.Vec3f, cornerRadius: typegpu_data37.F32) => typegpu_data37.F32>; /** * Signed distance function for a hollow box frame * @param point Point to evaluate * @param size Half-dimensions of the box * @param thickness Frame thickness */ declare const sdBoxFrame3d: typegpu16.TgpuFn<(point: typegpu_data37.Vec3f, size: typegpu_data37.Vec3f, thickness: typegpu_data37.F32) => typegpu_data37.F32>; /** * Signed distance function for a 3D line segment * @param point Point to evaluate * @param A First endpoint of the line * @param B Second endpoint of the line */ declare const sdLine3d: typegpu16.TgpuFn<(point: typegpu_data37.Vec3f, A: typegpu_data37.Vec3f, B: typegpu_data37.Vec3f) => typegpu_data37.F32>; /** * Signed distance function for an infinite plane * @param point Point to evaluate * @param normal Normal vector of the plane (must be normalized) * @param height Height/offset of the plane along the normal */ declare const sdPlane: typegpu16.TgpuFn<(point: typegpu_data37.Vec3f, normal: typegpu_data37.Vec3f, height: typegpu_data37.F32) => typegpu_data37.F32>; /** * Signed distance function for a 3D capsule * @param point Point to evaluate * @param A First endpoint of the capsule segment * @param B Second endpoint of the capsule segment * @param radius Radius of the capsule */ declare const sdCapsule: typegpu16.TgpuFn<(point: typegpu_data37.Vec3f, A: typegpu_data37.Vec3f, B: typegpu_data37.Vec3f, radius: typegpu_data37.F32) => typegpu_data37.F32>; /** * Unsigned distance function for a filled, zero-thickness triangle in 3D space. * The vertices must be distinct and non-collinear, and may use either winding order. * * @param p Point to evaluate, in the same coordinate space as the vertices * @param a First vertex of the triangle * @param b Second vertex of the triangle * @param c Third vertex of the triangle * @returns Distance to the nearest point on the triangle, including its edges; * zero on the triangle and positive on either side of its plane */ declare const sdTriangle3d: typegpu16.TgpuFn<(p: typegpu_data37.Vec3f, a: typegpu_data37.Vec3f, b: typegpu_data37.Vec3f, c: typegpu_data37.Vec3f) => typegpu_data37.F32>; /** * Signed distance function for a solid cylinder centered at the origin, along the Y axis, * with flat caps at `y = -h` and `y = h`. * * @param p Point to evaluate, relative to the cylinder's center * @param r Radius of the circular cross-section in the XZ plane (non-negative) * @param h Half-height of the cylinder; its full height is `2 * h` (non-negative) * @returns Negative inside the cylinder, zero on its surface, positive outside */ declare const sdCappedCylinder: typegpu16.TgpuFn<(p: typegpu_data37.Vec3f, r: typegpu_data37.F32, h: typegpu_data37.F32) => typegpu_data37.F32>; /** * Signed distance function for a rhombus in the XZ plane, extruded along Y and centered * at the origin. Rounding expands the 2D cross-section; the caps at `y = +/-h` stay flat. * * @param p Point to evaluate, relative to the shape's center * @param la Half-length of the unrounded rhombus's diagonal along X (positive) * @param lb Half-length of the unrounded rhombus's diagonal along Z (positive) * @param h Half-height of the extrusion along Y (non-negative) * @param ra Outward rounding radius in the XZ plane (non-negative). Zero gives a sharp * rhombus with vertices at `(x, z) = (+/-la, 0)` and `(0, +/-lb)`; rounding increases * the X and Z half-extents to `la + ra` and `lb + ra` * @returns Negative inside the solid, zero on its surface, positive outside */ declare const sdRhombus3d: typegpu16.TgpuFn<(p: typegpu_data37.Vec3f, la: typegpu_data37.F32, lb: typegpu_data37.F32, h: typegpu_data37.F32, ra: typegpu_data37.F32) => typegpu_data37.F32>; /** * Signed distance function for a torus lying in the XZ plane, centered at the origin. * * @param point Point to evaluate, relative to the torus's center * @param majorRadius Distance from the center to the middle of the tube (non-negative) * @param minorRadius Radius of the tube (non-negative) * @returns Negative inside the tube, zero on its surface, positive outside */ declare const sdTorus: typegpu16.TgpuFn<(point: typegpu_data37.Vec3f, majorRadius: typegpu_data37.F32, minorRadius: typegpu_data37.F32) => typegpu_data37.F32>; /** * Signed distance function for a capped torus: an arc-shaped section of a torus lying in * the XY plane. The arc's midpoint is at `(0, majorRadius)`, and it extends by `angle / 2` * to each side of it. * * @param point Point to evaluate, relative to the torus's center * @param sc Sine and cosine of the arc's half-angle: `vec2f(sin(angle / 2), cos(angle / 2))` * @param majorRadius Distance from the center to the middle of the tube (non-negative) * @param minorRadius Radius of the tube (non-negative) * @returns Negative inside the tube, zero on its surface, positive outside */ declare const sdCappedTorus: typegpu16.TgpuFn<(point: typegpu_data37.Vec3f, sc: typegpu_data37.Vec2f, majorRadius: typegpu_data37.F32, minorRadius: typegpu_data37.F32) => typegpu_data37.F32>; //#endregion export { sdBox3d, sdBoxFrame3d, sdCappedCylinder, sdCappedTorus, sdCapsule, sdLine3d, sdPlane, sdRhombus3d, sdRoundedBox3d, sdSphere, sdTorus, sdTriangle3d };