It looks as though the slide was projected to a screen, which was then photographed. So there is also a vignetting, a darkening towards the edges and corners.
The dust is truly horrible. Brushing the slides and re-scanning might be easiest.
Manually removing the dust would be painfully slow. However, we can readily paint approximate areas that are
not dust.
Then we find dust automatically, and remove it. Windows BAT syntax. First, find the dust:
Code: Select all
set SRC=dirty_slide2.jpg
%IM%convert ^
%SRC% ^
( +clone ^
-blur 0x5 ^
) ^
-compose MinusDst -composite ^
-colorspace Gray ^
-threshold 5%% ^
dirty_mask.png ^
-compose Darken -composite ^
b1.png
b1.png is white where we have dust; otherwise black.
Now we erase the dust pixels (make them transparent):
Code: Select all
%IM%convert ^
%SRC% ^
( b1.png -negate ) ^
-alpha off ^
-compose CopyOpacity -composite ^
b3.png
Now we fill in the transparency, by compositing over a blurred copy:
Code: Select all
%IM%convert ^
%SRC% -blur 0x10 ^
b3.png ^
-composite ^
b4.png
Other hole-filling methods are available; see my "Filling holes" pages.
(Result converted to JPG for the web.)
The result isn't perfect, but is a big improvement. Parameters can be tweaked.