All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.blitline.image.functions.ContrastStretchChannel Maven / Gradle / Ivy

There is a newer version: 0.17.1
Show newest version
package com.blitline.image.functions;

import org.apache.commons.lang3.Validate;

public class ContrastStretchChannel extends AbstractFunction {
	@Override
	public String getName() {
		return "contrast_stretch_channel";
	}

	public ContrastStretchChannel(int blackPoint) {
		Validate.isTrue(blackPoint >= 0);
		params.put("black_point", blackPoint);
	}

	public ContrastStretchChannel whitePoint(int whitePoint) {
		Validate.isTrue(whitePoint > (Integer) params.get("black_point"));
		params.put("white_point", whitePoint);
		return this;
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy