tags:

views:

29

answers:

2

What is the sh code for image manipulation?

A: 

Are you looking for something like ImageMagick?

David
no not really it has to be in bourne shell script
GuzzyD
@GuzzyD: A shell script should easily be able to call this utility. Do you mean that it can't use any utilities and has to be _entirely_ within a script?
David
yeah well basically just raw scripting...its pretty hard cos at the moment im doing an assignment and ive done the renaming, short listing and long listing part of the sh scripting code but this part i have no clue. so if u can help me then many thanks! ;)
GuzzyD
@GuzzyD: I could be mistaken, but I don't believe shell scripts can natively perform any real image manipulation. Technically it could read in an image file as a series of characters and modify them, but that's _really_ low-level and is going to require a _ton_ of work to drive the logic. For all practical purposes, shell scripts generally call other tools to perform actions like this.
David
ohhhh ok...cheers thanks! ;)
GuzzyD
A: 

Try ImageMagick. There is nice command line utility available: convert:

Use the convert program to convert between image formats as well as resize an image, blur, crop, despeckle, dither, draw on, flip, join, re-sample, and much more.

Ivan Nevostruev