Skip to content
Browse files

Removed imagecolorat "out of bounds" notice

  • Loading branch information...
1 parent b6afc6f commit 4b15d1dc13b4e03b7b546acfd67acb58548aedf6 @bforchhammer bforchhammer committed
Showing with 2 additions and 2 deletions.
  1. +2 −2 FaceDetector.php
View
4 FaceDetector.php
@@ -108,12 +108,12 @@ protected function compute_ii($canvas, $image_width, $image_height ){
$ii2[$i] = 0;
}
- for($i=1; $i<$ii_w; $i++ ){
+ for($i=1; $i<$ii_w-1; $i++ ){
$ii[$i*$ii_w] = 0;
$ii2[$i*$ii_w] = 0;
$rowsum = 0;
$rowsum2 = 0;
- for($j=1; $j<$ii_h; $j++ ){
+ for($j=1; $j<$ii_h-1; $j++ ){
$rgb = ImageColorAt($canvas, $j, $i);
$red = ($rgb >> 16) & 0xFF;
$green = ($rgb >> 8) & 0xFF;

0 comments on commit 4b15d1d

Please sign in to comment.
Something went wrong with that request. Please try again.