/* tslint:disable */
/* eslint-disable */

/**
 * The running average, gamma-encoded as RGBA bytes.
 */
export function pt_frame(): Uint8Array;

/**
 * Create the renderer for a `w`×`h` image of the given scene (resets accumulation).
 */
export function pt_init(w: number, h: number, scene: number): void;

/**
 * Trace `passes` more samples per pixel.
 */
export function pt_render(passes: number): void;

/**
 * Samples per pixel accumulated so far.
 */
export function pt_samples(): number;

/**
 * Orbit the camera around the scene centre (radians; `dist` scales the default distance).
 * Resets accumulation.
 */
export function pt_set_camera(yaw: number, pitch: number, dist: number): void;

/**
 * Threads rendering rows: the rayon pool size, or 1 for the single-threaded build.
 */
export function pt_threads(): number;

export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;

export interface InitOutput {
    readonly memory: WebAssembly.Memory;
    readonly pt_frame: () => [number, number];
    readonly pt_init: (a: number, b: number, c: number) => void;
    readonly pt_render: (a: number) => void;
    readonly pt_samples: () => number;
    readonly pt_set_camera: (a: number, b: number, c: number) => void;
    readonly pt_threads: () => number;
    readonly __wbindgen_externrefs: WebAssembly.Table;
    readonly __wbindgen_free: (a: number, b: number, c: number) => void;
    readonly __wbindgen_start: () => void;
}

export type SyncInitInput = BufferSource | WebAssembly.Module;

/**
 * Instantiates the given `module`, which can either be bytes or
 * a precompiled `WebAssembly.Module`.
 *
 * @param {{ module: SyncInitInput }} module - Passing `SyncInitInput` directly is deprecated.
 *
 * @returns {InitOutput}
 */
export function initSync(module: { module: SyncInitInput } | SyncInitInput): InitOutput;

/**
 * If `module_or_path` is {RequestInfo} or {URL}, makes a request and
 * for everything else, calls `WebAssembly.instantiate` directly.
 *
 * @param {{ module_or_path: InitInput | Promise<InitInput> }} module_or_path - Passing `InitInput` directly is deprecated.
 *
 * @returns {Promise<InitOutput>}
 */
export default function __wbg_init (module_or_path?: { module_or_path: InitInput | Promise<InitInput> } | InitInput | Promise<InitInput>): Promise<InitOutput>;
