\n\n";
while(<*[0-9].jpg *[0-9].JPG>){
if ( ($_=~/(.*).jpg$/) || ($_=~/(.*).JPG$/) ){
$fbase= lc($1);
unless ( (-e "$fbase.mark") && (-e "$fbase.jpg")){
# system("convert $_ /tmp/mkpindex.bmp");
open PH, "convert -verbose $_ /tmp/mkpindex.bmp|";
$ginfo= ; $origsize= (split (' ',$ginfo))[1]; close PH;
# system("convert -geometry $ssize /tmp/mkpindex.bmp ${fbase}s.jpg");
open PH, "convert -verbose -geometry $ssize /tmp/mkpindex.bmp ${fbase}s.jpg|";
$ginfo=;
$ginfo=~/([0-9]+x[0-9]+)/; $ginfo=~/=>([0-9]+x[0-9]+)/;
$ssizereal= $1; close PH;
# system("convert -geometry $msize /tmp/mkpindex.bmp ${fbase}m.jpg");
open PH, "convert -verbose -geometry $msize /tmp/mkpindex.bmp ${fbase}m.jpg|";
$ginfo=;
$ginfo=~/([0-9]+x[0-9]+)/; $ginfo=~/=>([0-9]+x[0-9]+)/;
$msizereal= $1; close PH;
rename "$_", "$fbase.jpg";
system("chmod 644 $fbase.jpg");
unlink "/tmp/mkpindex.bmp";
open MARK, ">$fbase.mark";
print MARK "$origsize\n";
print MARK "$ssizereal\n";
print MARK "$msizereal\n";
close MARK;
}
if (-e "$fbase.mark"){
open MARK, "<$fbase.mark";
$origsize= ; chomp $origsize;
$ssizereal= ; chomp $ssizereal;
$msizereal= ; chomp $msizereal;
close MARK;
}
print FH " \n";
$ssizew= (split(/x/,$ssizereal))[0];
$ssizeh= (split(/x/,$ssizereal))[1];
print FH "$fbase\n";
print FH " | \n";
($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime,$blksize,$blocks)= stat("${fbase}m.jpg");
$KBsize= int(($size+500)/1000);
print FH "表示用($msizereal; ${KBsize}KB) | \n";
($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime,$blksize,$blocks)= stat("$fbase.jpg");
$KBsize= int(($size+500)/1000);
print FH "元画像($origsize; ${KBsize}KB) | \n";
$datestr= localtime $mtime;
print FH "$datestr | \n";
print FH " | \n\n";
$co++;
if ($co==$colnum){
$co=0;
print FH " |