Documentation

Crop
in package

V2 Crop operation.

Table of Contents

Properties

$localInput  : LocalInputSource

Methods

__construct()  : mixed
extractMultipleCrops()  : CropFiles
Extracts multiple crop zones from a file, rendering each page once.
extractSingleCrop()  : ExtractedImage
Extracts a crop zone from a file, named "<file>_page<page>-<index of the crop on its page>".

Properties

Methods

extractMultipleCrops()

Extracts multiple crop zones from a file, rendering each page once.

public extractMultipleCrops(array<string|int, CropItem> $crops) : CropFiles

Each image is named "_page-". Crops parsed from an inference know that index; for the others, crops are numbered per page in the order given.

Parameters
$crops : array<string|int, CropItem>

List of crops to extract.

Return values
CropFiles —

list of extracted files, in the same order as the crops

extractSingleCrop()

Extracts a crop zone from a file, named "<file>_page<page>-<index of the crop on its page>".

public extractSingleCrop(CropItem $crop) : ExtractedImage
Parameters
$crop : CropItem

Crop to extract.

Return values
ExtractedImage —

extracted image

On this page

Search results