rectangular gradient

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
xpt
Posts: 59
Joined: 2010-10-06T20:18:24-07:00
Authentication code: 8675308

rectangular gradient

Post by xpt »

Hi,

What's the simplest way to get a rectangular gradient like this:

Image

Thanks
xpt
Posts: 59
Joined: 2010-10-06T20:18:24-07:00
Authentication code: 8675308

Re: rectangular gradient

Post by xpt »

My solution:

Code: Select all

convert -size 106x106 radial-gradient: -negate -gravity center -crop 60x60+0+0 +repage -resize 100x75! gradient_radial.jpg
Good enough?
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: rectangular gradient

Post by fmw42 »

Yes that would be a reasonable way to make an elliptical gradient from a radial-gradient.
Post Reply