1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
//! Read KFBio whole-slide image files (`.kfb`, `.kfbf`) and convert them to OME-Zarr v0.4 (Zarr v2).
//!
//! Two entry points:
//!
//! - [`KfbReader`] — opens a KFBio file and exposes its header, tile index, and
//! associated images.
//! - [`convert_to_zarr`] — decodes all JPEG tiles in parallel and writes a
//! multi-resolution OME-Zarr v0.4 store.
//!
//! Pure Rust, no C dependencies. JPEG decoding via [`zune_jpeg`](https://docs.rs/zune-jpeg).
//! Physical coordinate transforms come from the MPP value in the file header.
//!
//! # Examples
//!
//! ## Convert a KFBio file to OME-Zarr
//!
//! ```no_run
//! use std::path::Path;
//! use kfb2zarr::convert_to_zarr;
//!
//! convert_to_zarr(Path::new("slide.kfb"), Path::new("slide.ome.zarr"))?;
//! # Ok::<(), kfb2zarr::KfbError>(())
//! ```
//!
//! ## Inspect metadata without converting
//!
//! ```no_run
//! use std::path::Path;
//! use kfb2zarr::KfbReader;
//!
//! let reader = KfbReader::open(Path::new("slide.kfb"))?;
//! let header = reader.header();
//! println!("dimensions: {}x{}", header.base_width(), header.base_height());
//! println!("mpp: {}", header.mpp());
//! println!("tiles: {}", reader.tiles().len());
//! # Ok::<(), kfb2zarr::KfbError>(())
//! ```
pub
pub
pub
pub
pub use convert_to_zarr;
pub use KfbError;
pub use KfbReader;
pub use ;