ImagePreprocessor

interface ImagePreprocessor

Basic interface for image preprocessors. It operates on BufferedImage.

When implementing a new ImagePreprocessor it is recommended to use ImagePreprocessorBase as a base class to automatically add additional features such as saving preprocessor output with ImageSaver.

Functions

apply
Link copied to clipboard
abstract fun apply(image: BufferedImage): BufferedImage

Transforms provided input image.

getOutputShape
Link copied to clipboard
open fun getOutputShape(inputShape: ImageShape): ImageShape

Computes output image shape for the provided inputShape. Note that some input dimensions could equal to null, which means that they are undefined. This is useful for the operations with fixed output size not dependent on the input size.

Inheritors

ImagePreprocessorBase
Link copied to clipboard