Post Reply 

Script-Fu Batch Filetype Conversion

Mar 10, 2011, 19:22 (This post was last modified: Mar 10, 2011 19:23 by IAMRYO.)
Post: #1
Script-Fu Batch Filetype Conversion
Hi All,

Sorry if this has been addressed elsewhere. I'm having a terrible time finding help with this specific problem:

I have 80+ images in an awful format (DICOM) and I need to convert them to jpeg. I'd rather not go through them individually, and I think it can be done with a batch script in Gimp, but I don't know the first thing about how to do that.

I've found a listing in Script-Fu called file-save-jpeg but I don't know what to do with it oreven if I'm on the right track...

Help here would be MUCH appreciated.

Ryan
Find all posts by this user
Quote this message in a reply
Mar 10, 2011, 20:11
Post: #2
RE: Script-Fu Batch Filetype Conversion
I'd definitely like to get these all done in the same command... Can you help me out with that?
Find all posts by this user
Quote this message in a reply
Mar 10, 2011, 23:11
Post: #3
RE: Script-Fu Batch Filetype Conversion
Unfortunately, Yes. I can do it at home on Linux if it's that much of a nightmare.
Find all posts by this user
Quote this message in a reply
Mar 11, 2011, 01:14
Post: #4
RE: Script-Fu Batch Filetype Conversion
You're a lifesaver ofnuts! Thanks!
Find all posts by this user
Quote this message in a reply
Mar 11, 2011, 03:47
Post: #5
RE: Script-Fu Batch Filetype Conversion
Welp.. I'm at home and just tried it - here's what I got:

img00000: command not found
convert: unable to open image `*.dcm': @ error/blob.c/OpenBlob/2498.
convert: missing an image filename `.jpg' @ error/convert.c/ConvertImageCommand/2970.
Find all posts by this user
Quote this message in a reply
Mar 11, 2011, 16:50
Post: #6
RE: Script-Fu Batch Filetype Conversion
That's what I thought from the error. I tried running it again with *.*, but that didn't work.

The filenames for whatever reason don't have the .dcm extension, but are most definitely DICOMs. They're ultrasound images from a hospital and I can open them in GIMP. I just want to be able to share them.

I can try renaming them I suppose.
Find all posts by this user
Quote this message in a reply
Mar 11, 2011, 17:42
Post: #7
RE: Script-Fu Batch Filetype Conversion
No extensions at all...
Find all posts by this user
Quote this message in a reply
Mar 11, 2011, 21:01
Post: #8
RE: Script-Fu Batch Filetype Conversion
Wow, talk about baby steps... I'm not sure if I'm entering the command in correctly.. I tried a few different variations, but keep ending up with this error or similar:

ryan@MintBox ~/Desktop/srs00001 $ for f in *.dcm; do convert $f $(img00000 $f .dcm).jpg;done
img00000: command not found
convert: no encode delegate for this image format `.jpg' @ error/constitute.c/WriteImage/1157.
Find all posts by this user
Quote this message in a reply
Mar 11, 2011, 21:03
Post: #9
RE: Script-Fu Batch Filetype Conversion
Here's another attempt:

ryan@MintBox ~/Desktop/srs00001 $ for f in *.dcm; do convert $f $img00000.dcm .jpg ; done
convert: unable to open image `.dcm': @ error/blob.c/OpenBlob/2498.
convert: no decode delegate for this image format `.dcm' @ error/constitute.c/ReadImage/532.
Find all posts by this user
Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Batch adding logo to lots of pictures kenny1999 2 384 Sep 27, 2014 08:02
Last Post: rich2005
  batch processing to obtain several different versions of a picture esteban 3 326 Sep 23, 2014 14:44
Last Post: esteban
  batch processing (OSX) pace514 3 404 Sep 21, 2014 08:03
Last Post: rich2005
  Create new images button & Save as override from Script-fu beniman 12 615 Sep 10, 2014 10:57
Last Post: paynekj
  Batch conversion of images qazmlpok 4 3,616 Feb 18, 2014 19:35
Last Post: MBG

Forum Jump:


GIMP ForumPortalArchiveContactTermsRSS