I'm wondering if there is any command to process raw images, for example,

cat raw1.img | raw2jpg -w 640 -h 480 -pitch 1024 -pixelformat R8G8B8

and more examples:

cat raw1.img raw2.img >y-merge.img

tr='transpose -pitch 1024 -depth 24'
cat <(cat raw1.img | $tr) <(cat raw2.img | $tr) | transpose -pitch 480 >x-merge.img

and something like this:

cat gamebitmap.dat | (
    w=`readint32`
    h=`readint32`
    raw2png -w $w -h $h -depth 24 -pixelformat R8G8B8
) | png2svg -extractoutline -fuzzy -error 8 -smooth

Seems a little tricky, but is it possible? does ImageMagick support such raw formats?

link|improve this question

feedback

1 Answer

up vote 0 down vote accepted

Which type of raw file?

There's Sony, Kodak, Nikon, Olympus, etc. Full list

Have you tried convert from ImageMagick, e.g.

convert raw1.img raw1.jpg

What does

file raw1.img

say?

What happens if you rename raw1.img to one of the extensions listed in the link, e.g. raw1.arw or raw1.crw?

link|improve this answer
Here I mentioned the raw image format for: 1. uncompressed bitmap, and 2. the basic parameters like width/height/pitch/pixelformat is specified at command-line, rather then embedded in the image file. – Xie Jilei Dec 22 '10 at 8:34
This full list is awesome! It's definitely what I want. The idea behind is I want to convert between game picture files, and I don't want to bother programming any short piece of C codes. – Xie Jilei Dec 22 '10 at 8:39
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.