Skip to main content

Module image

Module image 

Source
Expand description

Image types for embedded or referenced images.

Image represents an image reference within a document. Core stores only the path and dimensions – actual binary data lives in the Smithy layer (inside the HWPX ZIP or HWP5 BinData stream).

§Examples

use hwpforge_core::image::{Image, ImageFormat};
use hwpforge_foundation::HwpUnit;

let img = Image::new(
    "BinData/image1.png",
    HwpUnit::from_mm(50.0).unwrap(),
    HwpUnit::from_mm(30.0).unwrap(),
    ImageFormat::Png,
);
assert!(img.path.ends_with(".png"));

Structs§

Image
An image reference within the document.
ImageStore
Storage for binary image data keyed by path.

Enums§

ImageFormat
Supported image formats.