Softlight
-
- Posts: 53
- Joined: 2012-05-15T04:56:50-07:00
- Authentication code: 13
Softlight
Hello,
I need to do a transformation with IM that acts like Photoshop's softlight. IM's softlight composite mode gave me a completely different looking result to how Photoshop does it.
Does anyone know what the difference is and how I can imitate a Photoshop-style softlight filter?
The reason for all of this is that I found that if I do an IM -equalize on an image, then put that image on top of the original on Photoshop and apply softlight filter to the top (equalized) layer, the result is like a supremely awesome auto-level (better than Photoshop's autotone). But I need to be able to do this with IM only and the softlight not acting as expected makes it not work. Any ideas?
Thanks,
Alasdair
I need to do a transformation with IM that acts like Photoshop's softlight. IM's softlight composite mode gave me a completely different looking result to how Photoshop does it.
Does anyone know what the difference is and how I can imitate a Photoshop-style softlight filter?
The reason for all of this is that I found that if I do an IM -equalize on an image, then put that image on top of the original on Photoshop and apply softlight filter to the top (equalized) layer, the result is like a supremely awesome auto-level (better than Photoshop's autotone). But I need to be able to do this with IM only and the softlight not acting as expected makes it not work. Any ideas?
Thanks,
Alasdair
Re: Softlight
I would suggest you upload the result from Photoshop and IM so people could see what the difference is.
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Softlight
Also provide your input image(s). You can upload to some free service such as dropbox.com and post the URLs here.
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Softlight
Seems to work fine for me with IM 6.9.0.0 Q16 Mac OSX
original:
equalize in IM:
Softlight compose in IM:
Softlight compose in PS:
75% softlight effect in IM:
What version of IM and platform are you using? Please, always provide this information when asking questions on this form.
original:
equalize in IM:
Code: Select all
convert zelda3_plevel20.jpg -equalize zelda3_plevel20_eq.png
Softlight compose in IM:
Code: Select all
convert zelda3_plevel20.jpg zelda3_plevel20_eq.png -compose softlight -composite zelda3_plevel20_eq_softlight.png
Softlight compose in PS:
Code: Select all
compare -metric rmse zelda3_plevel20_eq_softlight.png zelda3_plevel20_eq_softlight_ps.png null:
287.83 (0.00439201)
75% softlight effect in IM:
Code: Select all
convert zelda3_plevel20.jpg \
\( zelda3_plevel20_eq.png -alpha set -channel a -evaluate set 75% +channel \) \
-compose softlight -composite zelda3_plevel20_eq_softlight_75.png
What version of IM and platform are you using? Please, always provide this information when asking questions on this form.
-
- Posts: 53
- Joined: 2012-05-15T04:56:50-07:00
- Authentication code: 13
Re: Softlight
Oh wow! (Edit: apparently w0w is changed to ???) I feel like a bit of an idiot. What I was typing was:
Instead of:
Thanks a lot for your help Fred!
With a bit of tweaking I got down to the final command:
Notes:
Softlight gives a better result than pegtoplight. Pegtoplight is a little too bright and softlight seems a bit more natural.
The 60% opacity is on the original, which is the background layer, not on the equalized layer. This normalizes the colors somehow.
I'm not entirely sure why this method works so well for "auto-leveling", but I spent all of yesterday trying all the different ways to auto-level an image and this seems to give the best overall result when unsupervised.
Code: Select all
convert test.png -compose softlight -composite equalize.png softlight1.png
Code: Select all
convert test.png equalize.png -compose softlight -composite softlight1.png
With a bit of tweaking I got down to the final command:
Code: Select all
convert \( test.png -alpha set -channel a -evaluate set 60% +channel \) \( test.png -equalize \) -compose softlight -composite output.png
Softlight gives a better result than pegtoplight. Pegtoplight is a little too bright and softlight seems a bit more natural.
The 60% opacity is on the original, which is the background layer, not on the equalized layer. This normalizes the colors somehow.
I'm not entirely sure why this method works so well for "auto-leveling", but I spent all of yesterday trying all the different ways to auto-level an image and this seems to give the best overall result when unsupervised.
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Softlight
this is more efficient, so that you do not read the input twice
But I think it may be better to use the 60% alpha on the equalized image, since it is harsher. That way you can get a result between the input and the equalized value.
Code: Select all
convert text.png \( -clone 0 -alpha set -channel a -evaluate set 60% +channel \) \( -clone 0 -equalize \) \
-delete 0 -compose softlight -composite output.png
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: Softlight
I've been working on this for two years, on and off: automatically making the "best" image from a raw camera file. For a while, I favoured a 50% blend of the "best gamma" image and an equalisation. Then I favoured a sigmoid curve that yielded a given standard deviation. I'm currently working on contrast-limited equalisation. It's the first totally unsupervised method I've found that often gives me results I prefer to Nikon JPEGs.alasdairdf wrote:... I spent all of yesterday trying all the different ways to auto-level an image and this seems to give the best overall result when unsupervised.
snibgo's IM pages: im.snibgo.com
-
- Posts: 53
- Joined: 2012-05-15T04:56:50-07:00
- Authentication code: 13
Re: Softlight
Cools, thanks!this is more efficient, so that you do not read the input twice
Interesting... are you willing to share your experience? What do you think of my method?I've been working on this for two years, on and off: automatically making the "best" image from a raw camera file. For a while, I favoured a 50% blend of the "best gamma" image and an equalisation. Then I favoured a sigmoid curve that yielded a given standard deviation. I'm currently working on contrast-limited equalisation. It's the first totally unsupervised method I've found that often gives me results I prefer to Nikon JPEGs.
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: Softlight
I've published quite a lot on my "Adding zing to photographs" page, but that doesn't yet have the best-gamma, blend-equalize or contrast-limited equalisation processes. It will, when I get around to it.
snibgo's IM pages: im.snibgo.com
-
- Posts: 53
- Joined: 2012-05-15T04:56:50-07:00
- Authentication code: 13
Re: Softlight
That is some magic. You should patent it and sell it Canon.