original_string: protected function getEntropyOffsets(\Imagick $original, $targetWidth, $targetHeight)
      {
          $measureImage = clone($original);
          // Enhance edges
          $measureImage->edgeimage(1);
          // Turn image into a grayscale
          $measureImage->modulateImage(100, 0, 100);
          // Turn everything darker than this to pitch black
          $measureImage->blackThresholdImage("#070707");
          // Get the calculated offset for cropping
          return $this->getOffsetFromEntropy($measureImage, $targetWidth, $targetHeight);
      }
code: protected function getEntropyOffsets(\Imagick $original, $targetWidth, $targetHeight)
      {
          $measureImage = clone($original);
          // Enhance edges
          $measureImage->edgeimage(1);
          // Turn image into a grayscale
          $measureImage->modulateImage(100, 0, 100);
          // Turn everything darker than this to pitch black
          $measureImage->blackThresholdImage("#070707");
          // Get the calculated offset for cropping
          return $this->getOffsetFromEntropy($measureImage, $targetWidth, $targetHeight);
      }
code_tokens: protected function getEntropyOffsets ( \ Imagick $ original , $ targetWidth , $ targetHeight ) { $ measureImage = clone ( $ original ) ; // Enhance edges $ measureImage -> edgeimage ( 1 ) ; // Turn image into a grayscale $ measureImage -> modulateImage ( 100 , 0 , 100 ) ; // Turn everything darker than this to pitch black $ measureImage -> blackThresholdImage ( "#070707" ) ; // Get the calculated offset for cropping return $ this -> getOffsetFromEntropy ( $ measureImage , $ targetWidth , $ targetHeight ) ; }
docstring: Get the topleftX and topleftY that will can be passed to a cropping method.
  
  @param  \Imagick $original
  @param  int      $targetWidth
  @param  int      $targetHeight
  @return array
docstring_tokens: Get the topleftX and topleftY that will can be passed to a cropping method .