diff --git a/cameraview/src/main/java/com/otaliastudios/cameraview/filter/ThreeParameterFilter b/cameraview/src/main/java/com/otaliastudios/cameraview/filter/ThreeParameterFilter new file mode 100644 index 00000000..e609145d --- /dev/null +++ b/cameraview/src/main/java/com/otaliastudios/cameraview/filter/ThreeParameterFilter @@ -0,0 +1,31 @@ +package com.otaliastudios.cameraview.filter; + +/** + * A special {@link Filter} that accepts two floats parameters. + * This is done by extending {@link OneParameterFilter}. + * + * The parameters will always be between 0F and 1F, so subclasses should + * map this range to their internal range if needed. + * + * A standardized range is useful for different applications. For example: + * - Filter parameters can be easily mapped to gestures since the range is fixed + * - {@link BaseFilter} can use this setters and getters to make a filter copy + */ +public interface ThreeParameterFilter extends TwoParameterFilter { + + /** + * Sets the third parameter. + * The value should always be between 0 and 1. + * + * @param value parameter + */ + void setParameter3(float value); + + /** + * Returns the third parameter. + * The returned value should always be between 0 and 1. + * + * @return parameter + */ + float getParameter3(); +}