$g) { $b=$r-$g; } else { $b=$g-$r; } $ct=0; while (strlen($t)>10) { $ntlen=strlen($t); $c=0; while ($c<$ntlen) { $gt=substr($t,$c-1,1)*1; $nt=substr($t,$c,1)*1; /* if ($gt>$nt) { $res=$gt-$nt; } else { $res=$nt-$gt; } */ $ft.=$gt-$nt; $c++; } $t=substr($ft,0,1).str_replace("-","",str_replace("0","",substr($ft,1,strlen($ft)-1))); $ft=""; $ct++; } $ro=255-$r; $go=255-$g; $bo=255-$b; ?>