Page 1 of 1

convert to jpeg

Posted: Fri Jul 07, 2006 8:11 am
by richards
Hi, I want to convert a GIS picture to JPEG pictures.

I tried "$brainvisa/AimsFileConvert -i tep -o tep_jpeg.jpg" but I get a GIS picture "tep.jpg.ima"

How should I do to convert files to jpeg ?

Posted: Fri Jul 07, 2006 8:26 am
by richards
I reached it with AimsData2Jpeg

It's not worth answering

Posted: Fri Jul 07, 2006 1:15 pm
by riviere
Hi,

AimsFileConvert also works but with a different result:
AimsData2Jpeg extracts a slice from a volume and applies a RGB colormap, while AimsFileConvert still outputs "raw data". AimsFileConvert can only output Jpeg images if they are (after conversion if requested) in a compatible data type: U8 (unsigned bytes) or RGB. You can ask for a conversion using the -t switch (plus optionally the -r switch to rescale the image values to avoid overflows). But in any way AimsFileConvert will output one jpeg file per slice in the volume, so you generally get a series of numbered jpeg files:

Code: Select all

AimsFileConvert -i tep -o tep_jpeg.jpg -t U8 -r
will create several files, tep_jpeg_0000.jpg, tep_jpeg_0001.jpg etc according to the number of slices in the volume.

Moreover AimsData2Jpeg hasn't been maintained (nor used) for long, so is considered obsolete and may disappear one day.

Denis