pub fn write_slice_metadata_json(
path: &Path,
limits: (f64, f64),
scale: ScaleMode,
variable: &str,
units: Option<&str>,
long_name: Option<&str>,
standard_name: Option<&str>,
time_label: Option<&str>,
depth_index: usize,
) -> Result<(), Box<dyn Error>>Expand description
Write machine-readable metadata alongside the raster export. This keeps variable names, CF/COARDS attributes, limits, and slice coordinates intact even in workflows that only ingest PNG files.