summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xmkindex.pl8
1 files changed, 5 insertions, 3 deletions
diff --git a/mkindex.pl b/mkindex.pl
index bfb41dd..b787ead 100755
--- a/mkindex.pl
+++ b/mkindex.pl
@@ -399,6 +399,10 @@ sub expand_rgba {
my $src_band = $src_ds->GetRasterBand(1);
my $ct = $src_band->GetRasterColorTable() or return;
+ if ($config{progress}) {
+ print STDERR "Processing input file $map->{filename}.\n";
+ &{$config{progress}}(0.0);
+ }
&debug("Expansion to RGBA required.");
my $dst_nb = 4; # RGBA
@@ -426,7 +430,6 @@ sub expand_rgba {
$dst_ds->SetGCPs( $src_ds->GetGCPs(), $src_ds->GetGCPProjection() )
if $src_ds->GetGCPCount();
- &{$config{progress}}(0.0) if $config{progress};
for (my $y = 0; $y < $ySize; $y++) {
my $src_data = $src_band->ReadRaster(0, $y, $xSize, 1);
@@ -444,8 +447,7 @@ sub expand_rgba {
$dst_ds->Band(1+$b)->WriteRaster(0, $y, $xSize, 1, $_);
}
- &{$config{progress}}( (1+$y) / $ySize )
- if $config{progress};
+ &{$config{progress}}( (1+$y) / $ySize ) if $config{progress};
}
# Erase (hence flush and close) the previous dataset