Function mupdf_sys::fz_get_pixmap_from_image[][src]

pub unsafe extern "C" fn fz_get_pixmap_from_image(
    ctx: *mut fz_context,
    image: *mut fz_image,
    subarea: *const fz_irect,
    ctm: *mut fz_matrix,
    w: *mut c_int,
    h: *mut c_int
) -> *mut fz_pixmap

Called to get a handle to a pixmap from an image.

image: The image to retrieve a pixmap from.

color_params: The color parameters (or NULL for defaults).

subarea: The subarea of the image that we actually care about (or NULL to indicate the whole image).

trans: Optional, unless subarea is given. If given, then on entry this is the transform that will be applied to the complete image. It should be updated on exit to the transform to apply to the given subarea of the image. This is used to calculate the desired width/height for subsampling.

w: If non-NULL, a pointer to an int to be updated on exit to the width (in pixels) that the scaled output will cover.

h: If non-NULL, a pointer to an int to be updated on exit to the height (in pixels) that the scaled output will cover.

Returns a non NULL pixmap pointer. May throw exceptions.