Skip to main content

encode_rois

Function encode_rois 

Source
pub fn encode_rois(
    rois: &[Array2<u8>],
    ctx: Jbig2Context,
) -> Result<(Option<Vec<u8>>, Vec<Vec<u8>>), Box<dyn Error>>
Expand description

Encodes a list of text-only binary PBM ROIs into JBIG2 streams.

ยงArguments

  • rois - A slice of 2D arrays where each array represents a binary image (0/255 or 0/1 values)
  • ctx - JBIG2 encoding context with configuration