Adjust Blue channel

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
centesimiae
Posts: 18
Joined: 2014-03-14T10:10:54-07:00
Authentication code: 6789

Adjust Blue channel

Post by centesimiae » 2016-08-09T12:21:19-07:00

I have a request from a user to adjust the blue channel from 1.00 to 1.13 as in Photoshop. I understand that the -level operator is to be used, but can someone explain to me the correct usage of that operator in this context. Unfortunately, my graphics understanding is limited. Thanks for any info anyone can provide to enlighten me on how to achieve the desired effect.

snibgo
Posts: 11796
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Adjust Blue channel

Post by snibgo » 2016-08-09T13:09:05-07:00

centesimiae wrote:I have a request from a user to adjust the blue channel from 1.00 to 1.13 as in Photoshop.
Even if I used Photoshop (which I don't), I'd need more information than that. Which PS operation is used? What PS measurement gives "1.00" or "1.13"?
snibgo's IM pages: im.snibgo.com

User avatar
fmw42
Posts: 25124
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Adjust Blue channel

Post by fmw42 » 2016-08-09T15:15:03-07:00

try

Code: Select all

convert image -channel blue -evaluate multiply 1.13 +channel result

centesimiae
Posts: 18
Joined: 2014-03-14T10:10:54-07:00
Authentication code: 6789

Re: Adjust Blue channel

Post by centesimiae » 2016-08-09T15:15:58-07:00

From my limited understanding, Photoshop has a channel mixing interface that you can use to adjust individual channels. I am thinking that those numbers translate to a 13% increase of the blue channel in the image. Sorry, that's all I understand at the moment. I'll try to post more once I do some more research. I was hoping someone could give me a laymen's explanation on how to use the -level operator.

centesimiae
Posts: 18
Joined: 2014-03-14T10:10:54-07:00
Authentication code: 6789

Re: Adjust Blue channel

Post by centesimiae » 2016-08-09T15:21:58-07:00

Yes, I think that is exactly what I was looking for. Thank you so much for your effort and expertise!!!

User avatar
fmw42
Posts: 25124
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Adjust Blue channel

Post by fmw42 » 2016-08-09T15:26:22-07:00

It is the channel mixer in PS, where they use percent, so 113% which translates to multiply by 1.13. It has nothing to do with -level. For that see http://www.imagemagick.org/Usage/color_mods/#levels

Post Reply