hak('run toppm and delete original images ^c to stop')
hak('once again run this and DELETE ORIGINAL IMAGES')

for k = 0:294
  dis('doing image %d',k)
  eval(sprintf('[r g b]=loadpnm(''pic%03d.ppm'');',k))
  [M,N]=size(A);
  r=undsambot(r); % black line at top indicates bottom better
  g=undsambot(g);
  b=undsambot(b);
  eval(sprintf('savepnm(''v%03d.ppm'',r,g,b);',k))
  eval(sprintf('!rm pic%03d.ppm',k))
end%for

