diff --git a/src/livefilter/LiveFilter.scala b/src/livefilter/LiveFilter.scala index d1ba393..08bc521 100644 --- a/src/livefilter/LiveFilter.scala +++ b/src/livefilter/LiveFilter.scala @@ -2,6 +2,7 @@ package livefilter import com.github.sarxos.webcam.WebcamPanel.DrawMode import com.github.sarxos.webcam.{Webcam, WebcamImageTransformer, WebcamPanel, WebcamResolution} +import imagefilters.ImageFilters import java.awt.image.BufferedImage import java.awt.{Color, Dimension} @@ -87,7 +88,7 @@ class LiveFilter extends WebcamImageTransformer { val img: Array[Array[Color]] = toArray(image) // TODO Complete here by changing the assignment with your filters - val filtered: Array[Array[Color]] = img + val filtered: Array[Array[Color]] = ImageFilters.mask(ImageFilters.sepia(ImageFilters.noise(img, 10)), videoMask) updateImage(filtered, image) return image