Mass image conversion
  • rms
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    rms
    Posts: 599 from 2004/11/27
    Hi all,

    I try to find a tool/way to to batch process a directory full of pictures, resizing them and saving them with a new name.

    I have only and always 300 dpi tif pictures which have to be resized/ scaled down to 25% of their original size, then the dynamic range has to be checked and eventually changed to min. 0 and max 255 and the dpi has to be set to 75 dpi and the picture has to be saved as tif with a new name to disk.

    For now I'm doing that with ADPro for every single file that's why I would like to automate it for a given directory full of pictures.

    I had a look but couldn't really find something suitable and I tried to write an arexx script for ADPro to to that but it's to difficult for me.

    Perhaps someone has some experience with that, or even has a arexx script for ADPro or some other solution...

    Any help would be very much appreciated, thanks in advance.

    Regards

    Christoph
  • »18.08.06 - 19:59
    Profile Visit Website
  • MorphOS Developer
    CISC
    Posts: 619 from 2005/8/27
    From: the land with ...
    You could probably make an ARexx script for ADPro to do it (can't help you though, way too many years since I played with ADPro), and most definitely for ImageFX, but you could also use shell tools like the excellent ImageMagick...


    - CISC
  • »18.08.06 - 20:29
    Profile
  • MorphOS Developer
    bigfoot
    Posts: 508 from 2003/4/11
    Well, I'd say netpbm and the SDK.

    for i in *.tiff; do tifftopnm $i | pnmscale 0.5 | pnmnorm | pnmtotiff >$i.new; done

    That probably does what you want.
    I rarely log in to MorphZone which means that I often miss private messages sent on here. If you wish to contact me, please email me at [username]@asgaard.morphos-team.net, where [username] is my username here on MorphZone.
  • »18.08.06 - 22:06
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    realstar
    Posts: 298 from 2003/2/24
    From: Canada
    You can do this pretty easily with ImageFX. The simple
    way is to use the AutoFX tool, select all the frames
    you want to process and then just add the effects into
    the list. AutoFX will go through and process each one
    the way you want, I think the "lite" version of ImageFX
    may even work.

    (previously available for free via the superbundle)
  • »19.08.06 - 00:05
    Profile Visit Website
  • Moderator
    hooligan
    Posts: 1948 from 2003/2/23
    From: Lahti, Finland
    Realstar, welcome back ;-)

    I have been waiting updates to Hypercannon... :-/
    www.mikseri.net/hooligan <- Free music
  • »19.08.06 - 09:47
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    koan
    Posts: 303 from 2005/11/21
    From: UK
    I'd like to add to bigfoots answer, a similar approach can work with the "convert" command from ImageMagick. In your script you can

    convert -resize 640x480 source.bmp target.jpg

    for example.
  • »19.08.06 - 14:07
    Profile