Class BitwiseAND


  • public class BitwiseAND
    extends java.lang.Object
    Given two images of equal dimension, it'll compute resulting image ( concurrently i.e. each row processing to be thrown at thread pool, which will pick up job from queue ) by applying bitwise AND operator on pixel intensity values for each pixel P[i, j] from both of images
    • Constructor Summary

      Constructors 
      Constructor Description
      BitwiseAND()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected java.awt.Color[] extractRow​(int row, java.awt.image.BufferedImage img)
      Given a buffered image & row index, it'll extract out all pixel intensities present along that row
      protected boolean isEligible​(java.awt.image.BufferedImage operandOne, java.awt.image.BufferedImage operandTwo)
      Operand images on which we'll apply any bitwise operation needs to be of same dimension, which is what's ensured here
      java.awt.image.BufferedImage operate​(java.awt.image.BufferedImage operandOne, java.awt.image.BufferedImage operandTwo)
      Concurrent implementation of bitwise AND operator on images of equal dimensions
      java.awt.image.BufferedImage operate​(java.lang.String operandOne, java.lang.String operandTwo)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • BitwiseAND

        public BitwiseAND()
    • Method Detail

      • operate

        public java.awt.image.BufferedImage operate​(java.awt.image.BufferedImage operandOne,
                                                    java.awt.image.BufferedImage operandTwo)
        Concurrent implementation of bitwise AND operator on images of equal dimensions
      • operate

        public java.awt.image.BufferedImage operate​(java.lang.String operandOne,
                                                    java.lang.String operandTwo)
      • extractRow

        protected java.awt.Color[] extractRow​(int row,
                                              java.awt.image.BufferedImage img)
        Given a buffered image & row index, it'll extract out all pixel intensities present along that row
      • isEligible

        protected boolean isEligible​(java.awt.image.BufferedImage operandOne,
                                     java.awt.image.BufferedImage operandTwo)
        Operand images on which we'll apply any bitwise operation needs to be of same dimension, which is what's ensured here