import { ActorRefFrom, AnyActorRef } from 'xstate'; import { Bounds } from '@itk-viewer/utils/bounding-box.js'; import { BuiltImage, MultiscaleSpatialImage } from '@itk-viewer/io/MultiscaleSpatialImage.js'; import { AxisType } from './slice-utils.js'; import { Image } from './image.js'; export declare const imageWorker: import("xstate").StateMachine<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, { [x: string]: import("xstate").ActorRef; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }>, { [k: string]: unknown; type: string; }, import("xstate").EventObject> | undefined; }, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, "idle" | "buildingImage", string, { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").NonReducibleUnknown, import("xstate").EventObject, import("xstate").MetaObject, { readonly id: "imageWorker"; readonly initial: "idle"; readonly context: ({ input }: { spawn: { (logic: TSrc, ...[options]: { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } extends infer T ? T extends { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } ? T extends { src: TSrc; } ? import("xstate").ConditionalRequired<[options?: ({ id?: T["id"] | undefined; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } & { [K in import("xstate").RequiredActorOptions]: unknown; }) | undefined], import("xstate").IsNotNever>> : never : never : never): ActorRefFrom; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, "src", TSrc>["logic"]>; (src: TLogic, options?: { id?: never; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } | undefined): ActorRefFrom; }; input: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; readonly states: { readonly idle: { readonly on: { readonly buildImageInImageSpace: { readonly target: "buildingImage"; }; }; }; readonly buildingImage: { readonly invoke: { readonly input: ({ context, event }: { context: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; event: { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }; readonly src: "imageSpaceBuilder"; readonly onDone: { readonly actions: readonly [import("xstate").ActionFunction<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").DoneActorEvent<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, string>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, undefined, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, import("xstate").EventObject>]; readonly target: "idle"; }; }; }; }; }>; export type ImageWorker = ActorRefFrom; export declare const imageBuilder: import("xstate").StateMachine<{ slice: number; axis: AxisType; scale: number; image: MultiscaleSpatialImage; imageActor?: Image; builtImage?: BuiltImage; worker?: ImageWorker; }, import("xstate").AnyEventObject, { [x: string]: import("xstate").ActorRef; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }>, { [k: string]: unknown; type: string; }, import("xstate").EventObject> | undefined; }, "idle" | "buildingImage", string, import("xstate").NonReducibleUnknown, import("xstate").MetaObject, { readonly id: "imageWorker"; readonly initial: "idle"; readonly context: ({ input }: { spawn: { (logic: TSrc, ...[options]: { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } extends infer T ? T extends { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } ? T extends { src: TSrc; } ? import("xstate").ConditionalRequired<[options?: ({ id?: T["id"] | undefined; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } & { [K in import("xstate").RequiredActorOptions]: unknown; }) | undefined], import("xstate").IsNotNever>> : never : never : never): ActorRefFrom; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, "src", TSrc>["logic"]>; (src: TLogic, options?: { id?: never; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } | undefined): ActorRefFrom; }; input: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; readonly states: { readonly idle: { readonly on: { readonly buildImageInImageSpace: { readonly target: "buildingImage"; }; }; }; readonly buildingImage: { readonly invoke: { readonly input: ({ context, event }: { context: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; event: { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }; readonly src: "imageSpaceBuilder"; readonly onDone: { readonly actions: readonly [import("xstate").ActionFunction<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").DoneActorEvent<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, string>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, undefined, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, import("xstate").EventObject>]; readonly target: "idle"; }; }; }; }; }>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject> | import("xstate").ActorRef, { [k: string]: unknown; type: string; }, import("xstate").EventObject> | undefined; }, import("xstate").Values<{ imageWorker: { src: "imageWorker"; logic: import("xstate").StateMachine<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, { [x: string]: import("xstate").ActorRef; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }>, { [k: string]: unknown; type: string; }, import("xstate").EventObject> | undefined; }, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, "idle" | "buildingImage", string, { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").NonReducibleUnknown, import("xstate").EventObject, import("xstate").MetaObject, { readonly id: "imageWorker"; readonly initial: "idle"; readonly context: ({ input }: { spawn: { (logic: TSrc, ...[options]: { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } extends infer T ? T extends { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } ? T extends { src: TSrc; } ? import("xstate").ConditionalRequired<[options?: ({ id?: T["id"] | undefined; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } & { [K in import("xstate").RequiredActorOptions]: unknown; }) | undefined], import("xstate").IsNotNever>> : never : never : never): ActorRefFrom; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, "src", TSrc>["logic"]>; (src: TLogic, options?: { id?: never; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } | undefined): ActorRefFrom; }; input: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; readonly states: { readonly idle: { readonly on: { readonly buildImageInImageSpace: { readonly target: "buildingImage"; }; }; }; readonly buildingImage: { readonly invoke: { readonly input: ({ context, event }: { context: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; event: { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }; readonly src: "imageSpaceBuilder"; readonly onDone: { readonly actions: readonly [import("xstate").ActionFunction<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").DoneActorEvent<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, string>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, undefined, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, import("xstate").EventObject>]; readonly target: "idle"; }; }; }; }; }>; id: string | undefined; }; findSliceIndex: { src: "findSliceIndex"; logic: import("xstate").PromiseActorLogic<{ builtImage: BuiltImage; sliceIndex: number; }, { image: MultiscaleSpatialImage; builtImage: BuiltImage; scale: number; slice: number; axis: AxisType; }, import("xstate").EventObject>; id: string | undefined; }; }>, never, never, never, "done" | "building" | "findingSliceIndex", string, { image: MultiscaleSpatialImage; imageActor: Image; scale: number; slice: number; axis: AxisType; }, import("xstate").NonReducibleUnknown, import("xstate").EventObject, import("xstate").MetaObject, { readonly id: "imageBuilder"; readonly context: ({ input }: { spawn: { (logic: TSrc, ...[options]: ({ src: "imageWorker"; logic: import("xstate").StateMachine<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, { [x: string]: import("xstate").ActorRef; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }>, { [k: string]: unknown; type: string; }, import("xstate").EventObject> | undefined; }, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, "idle" | "buildingImage", string, { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").NonReducibleUnknown, import("xstate").EventObject, import("xstate").MetaObject, { readonly id: "imageWorker"; readonly initial: "idle"; readonly context: ({ input }: { spawn: { (logic: TSrc_1, ...[options]: { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } extends infer T ? T extends { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } ? T extends { src: TSrc_1; } ? import("xstate").ConditionalRequired<[options?: ({ id?: T["id"] | undefined; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } & { [K in import("xstate").RequiredActorOptions]: unknown; }) | undefined], import("xstate").IsNotNever>> : never : never : never): ActorRefFrom; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, "src", TSrc_1>["logic"]>; (src: TLogic, options?: { id?: never; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } | undefined): ActorRefFrom; }; input: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; readonly states: { readonly idle: { readonly on: { readonly buildImageInImageSpace: { readonly target: "buildingImage"; }; }; }; readonly buildingImage: { readonly invoke: { readonly input: ({ context, event }: { context: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; event: { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }; readonly src: "imageSpaceBuilder"; readonly onDone: { readonly actions: readonly [import("xstate").ActionFunction<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").DoneActorEvent<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, string>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, undefined, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, import("xstate").EventObject>]; readonly target: "idle"; }; }; }; }; }>; id: string | undefined; } extends infer T ? T extends { src: "imageWorker"; logic: import("xstate").StateMachine<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, { [x: string]: import("xstate").ActorRef; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }>, { [k: string]: unknown; type: string; }, import("xstate").EventObject> | undefined; }, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, "idle" | "buildingImage", string, { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").NonReducibleUnknown, import("xstate").EventObject, import("xstate").MetaObject, { readonly id: "imageWorker"; readonly initial: "idle"; readonly context: ({ input }: { spawn: { (logic: TSrc_1, ...[options]: { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } extends infer T ? T extends { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } ? T extends { src: TSrc_1; } ? import("xstate").ConditionalRequired<[options?: ({ id?: T["id"] | undefined; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } & { [K in import("xstate").RequiredActorOptions]: unknown; }) | undefined], import("xstate").IsNotNever>> : never : never : never): ActorRefFrom; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, "src", TSrc_1>["logic"]>; (src: TLogic, options?: { id?: never; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } | undefined): ActorRefFrom; }; input: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; readonly states: { readonly idle: { readonly on: { readonly buildImageInImageSpace: { readonly target: "buildingImage"; }; }; }; readonly buildingImage: { readonly invoke: { readonly input: ({ context, event }: { context: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; event: { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }; readonly src: "imageSpaceBuilder"; readonly onDone: { readonly actions: readonly [import("xstate").ActionFunction<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").DoneActorEvent<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, string>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, undefined, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, import("xstate").EventObject>]; readonly target: "idle"; }; }; }; }; }>; id: string | undefined; } ? T extends { src: TSrc; } ? import("xstate").ConditionalRequired<[options?: ({ id?: T["id"] | undefined; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } & { [K in import("xstate").RequiredActorOptions]: unknown; }) | undefined], import("xstate").IsNotNever>> : never : never : never) | ({ src: "findSliceIndex"; logic: import("xstate").PromiseActorLogic<{ builtImage: BuiltImage; sliceIndex: number; }, { image: MultiscaleSpatialImage; builtImage: BuiltImage; scale: number; slice: number; axis: AxisType; }, import("xstate").EventObject>; id: string | undefined; } extends infer T_1 ? T_1 extends { src: "findSliceIndex"; logic: import("xstate").PromiseActorLogic<{ builtImage: BuiltImage; sliceIndex: number; }, { image: MultiscaleSpatialImage; builtImage: BuiltImage; scale: number; slice: number; axis: AxisType; }, import("xstate").EventObject>; id: string | undefined; } ? T_1 extends { src: TSrc; } ? import("xstate").ConditionalRequired<[options?: ({ id?: T_1["id"] | undefined; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } & { [K_1 in import("xstate").RequiredActorOptions]: unknown; }) | undefined], import("xstate").IsNotNever>> : never : never : never)): ActorRefFrom; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }>, { [k: string]: unknown; type: string; }, import("xstate").EventObject> | undefined; }, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, "idle" | "buildingImage", string, { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").NonReducibleUnknown, import("xstate").EventObject, import("xstate").MetaObject, { readonly id: "imageWorker"; readonly initial: "idle"; readonly context: ({ input }: { spawn: { (logic: TSrc_1, ...[options]: { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } extends infer T ? T extends { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } ? T extends { src: TSrc_1; } ? import("xstate").ConditionalRequired<[options?: ({ id?: T["id"] | undefined; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } & { [K in import("xstate").RequiredActorOptions]: unknown; }) | undefined], import("xstate").IsNotNever>> : never : never : never): ActorRefFrom; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, "src", TSrc_1>["logic"]>; (src: TLogic, options?: { id?: never; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } | undefined): ActorRefFrom; }; input: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; readonly states: { readonly idle: { readonly on: { readonly buildImageInImageSpace: { readonly target: "buildingImage"; }; }; }; readonly buildingImage: { readonly invoke: { readonly input: ({ context, event }: { context: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; event: { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }; readonly src: "imageSpaceBuilder"; readonly onDone: { readonly actions: readonly [import("xstate").ActionFunction<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").DoneActorEvent<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, string>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, undefined, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, import("xstate").EventObject>]; readonly target: "idle"; }; }; }; }; }>; id: string | undefined; }; findSliceIndex: { src: "findSliceIndex"; logic: import("xstate").PromiseActorLogic<{ builtImage: BuiltImage; sliceIndex: number; }, { image: MultiscaleSpatialImage; builtImage: BuiltImage; scale: number; slice: number; axis: AxisType; }, import("xstate").EventObject>; id: string | undefined; }; }>, "src", TSrc>["logic"]>; (src: TLogic, options?: { id?: never; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } | undefined): ActorRefFrom; }; input: { image: MultiscaleSpatialImage; imageActor: Image; scale: number; slice: number; axis: AxisType; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, import("xstate").AnyEventObject, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; imageActor: Image; scale: number; slice: number; axis: AxisType; }; readonly on: { readonly cancel: { readonly target: ".done"; }; }; readonly initial: "building"; readonly states: { readonly building: { readonly entry: readonly [import("xstate").ActionFunction<{ slice: number; axis: AxisType; scale: number; image: MultiscaleSpatialImage; imageActor?: Image; builtImage?: BuiltImage; worker?: ImageWorker; }, import("xstate").AnyEventObject, import("xstate").AnyEventObject, undefined, import("xstate").Values<{ imageWorker: { src: "imageWorker"; logic: import("xstate").StateMachine<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, { [x: string]: import("xstate").ActorRef; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }>, { [k: string]: unknown; type: string; }, import("xstate").EventObject> | undefined; }, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, "idle" | "buildingImage", string, { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").NonReducibleUnknown, import("xstate").EventObject, import("xstate").MetaObject, { readonly id: "imageWorker"; readonly initial: "idle"; readonly context: ({ input }: { spawn: { (logic: TSrc, ...[options]: { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } extends infer T ? T extends { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } ? T extends { src: TSrc; } ? import("xstate").ConditionalRequired<[options?: ({ id?: T["id"] | undefined; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } & { [K in import("xstate").RequiredActorOptions]: unknown; }) | undefined], import("xstate").IsNotNever>> : never : never : never): ActorRefFrom; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, "src", TSrc>["logic"]>; (src: TLogic, options?: { id?: never; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } | undefined): ActorRefFrom; }; input: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; readonly states: { readonly idle: { readonly on: { readonly buildImageInImageSpace: { readonly target: "buildingImage"; }; }; }; readonly buildingImage: { readonly invoke: { readonly input: ({ context, event }: { context: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; event: { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }; readonly src: "imageSpaceBuilder"; readonly onDone: { readonly actions: readonly [import("xstate").ActionFunction<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").DoneActorEvent<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, string>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, undefined, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, import("xstate").EventObject>]; readonly target: "idle"; }; }; }; }; }>; id: string | undefined; }; findSliceIndex: { src: "findSliceIndex"; logic: import("xstate").PromiseActorLogic<{ builtImage: BuiltImage; sliceIndex: number; }, { image: MultiscaleSpatialImage; builtImage: BuiltImage; scale: number; slice: number; axis: AxisType; }, import("xstate").EventObject>; id: string | undefined; }; }>, never, never, never, never>, ({ context: { scale, slice, axis, worker } }: import("xstate").ActionArgs<{ slice: number; axis: AxisType; scale: number; image: MultiscaleSpatialImage; imageActor?: Image; builtImage?: BuiltImage; worker?: ImageWorker; }, import("xstate").AnyEventObject, import("xstate").AnyEventObject>) => void]; readonly on: { readonly builtImage: { readonly actions: readonly [import("xstate").ActionFunction<{ slice: number; axis: AxisType; scale: number; image: MultiscaleSpatialImage; imageActor?: Image; builtImage?: BuiltImage; worker?: ImageWorker; }, import("xstate").AnyEventObject, import("xstate").AnyEventObject, undefined, import("xstate").Values<{ imageWorker: { src: "imageWorker"; logic: import("xstate").StateMachine<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, { [x: string]: import("xstate").ActorRef; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }>, { [k: string]: unknown; type: string; }, import("xstate").EventObject> | undefined; }, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, "idle" | "buildingImage", string, { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").NonReducibleUnknown, import("xstate").EventObject, import("xstate").MetaObject, { readonly id: "imageWorker"; readonly initial: "idle"; readonly context: ({ input }: { spawn: { (logic: TSrc, ...[options]: { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } extends infer T ? T extends { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; } ? T extends { src: TSrc; } ? import("xstate").ConditionalRequired<[options?: ({ id?: T["id"] | undefined; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } & { [K in import("xstate").RequiredActorOptions]: unknown; }) | undefined], import("xstate").IsNotNever>> : never : never : never): ActorRefFrom; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, "src", TSrc>["logic"]>; (src: TLogic, options?: { id?: never; systemId?: string; input?: import("xstate").InputFrom | undefined; syncSnapshot?: boolean; } | undefined): ActorRefFrom; }; input: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; readonly states: { readonly idle: { readonly on: { readonly buildImageInImageSpace: { readonly target: "buildingImage"; }; }; }; readonly buildingImage: { readonly invoke: { readonly input: ({ context, event }: { context: { image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }; event: { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }; readonly src: "imageSpaceBuilder"; readonly onDone: { readonly actions: readonly [import("xstate").ActionFunction<{ image: MultiscaleSpatialImage; listeners: AnyActorRef[]; }, import("xstate").DoneActorEvent<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, string>, { type: "buildImageInImageSpace"; scale: number; normalizedImageBounds: Bounds; }, undefined, { src: "imageSpaceBuilder"; logic: import("xstate").PromiseActorLogic<{ imageType: import("itk-wasm").ImageType; name: string; origin: number[]; spacing: number[]; direction: Float64Array; size: number[]; data: ArrayBuffer; ranges: import("@itk-viewer/io/types.js").Ranges | number[][] | undefined; metadata: Map; }, { image: MultiscaleSpatialImage; scale: number; normalizedImageBounds: Bounds; }, import("xstate").EventObject>; id: string | undefined; }, never, never, never, import("xstate").EventObject>]; readonly target: "idle"; }; }; }; }; }>; id: string | undefined; }; findSliceIndex: { src: "findSliceIndex"; logic: import("xstate").PromiseActorLogic<{ builtImage: BuiltImage; sliceIndex: number; }, { image: MultiscaleSpatialImage; builtImage: BuiltImage; scale: number; slice: number; axis: AxisType; }, import("xstate").EventObject>; id: string | undefined; }; }>, never, never, never, never>]; readonly target: "findingSliceIndex"; }; }; }; readonly findingSliceIndex: { readonly invoke: { readonly src: "findSliceIndex"; readonly input: ({ context }: { context: { slice: number; axis: AxisType; scale: number; image: MultiscaleSpatialImage; imageActor?: Image; builtImage?: BuiltImage; worker?: ImageWorker; }; event: import("xstate").AnyEventObject; self: import("xstate").ActorRef, import("xstate").StateValue, string, unknown, any, any>, import("xstate").AnyEventObject, import("xstate").AnyEventObject>; }) => { image: MultiscaleSpatialImage; builtImage: BuiltImage; scale: number; slice: number; axis: AxisType; }; readonly onDone: { readonly actions: readonly [import("xstate").ActionFunction<{ slice: number; axis: AxisType; scale: number; image: MultiscaleSpatialImage; imageActor?: Image; builtImage?: BuiltImage; worker?: ImageWorker; }, import("xstate").DoneActorEvent<{ builtImage: BuiltImage; sliceIndex: number; }, string>, import("xstate").AnyEventObject, undefined, never, never, never, never, never>]; readonly target: "done"; }; }; }; readonly done: { readonly type: "final"; }; }; }>; export type ImageBuilder = ActorRefFrom; export type ImageBuilderSnapshot = ReturnType; //# sourceMappingURL=image-builder.d.ts.map