Search This Blog by Google

Search This Blog

Welcome to Dijemeric Visualizations

Where photography and mathematics intersect with some photography, some math, some math of photography, and an occasional tutorial.

Total Pageviews

Showing posts with label photoshop. Show all posts
Showing posts with label photoshop. Show all posts

Thursday, May 19, 2016

Crafting a macro to create a vintage postcard look with Nik software


Crafting a macro to create a vintage postcard look with Nik software
(c) Ken Osborn May 16, 2016

After visiting a version of Renaissance Italy at a local craft and performance fair in Vallejo CA, I
tried reinterpreting my photos as postcards depicting the era as might have been done in the 1930's.

Something like this:


To create this image took a few steps in Photoshop plus the Nik software plugin (free at https://www.google.com/nikcollection/)

If you have several images it is worthwhile to automate or at least semi-automate the process, as I did with the following macro (aka Action):


Some details

Make a couple of layers with your starting photograph


Blend 'Color' Mode on the top layer



Select the second layer down just below the 'Color' mode layer.  You will convert that to a monochrome version.


Select Silver Effects Pro in the Nik plugin

Where you will have several options to choose from

I selected Antique Plate II 



How it looks before adding color



Bring back the top layer in 'Color' blend mode and you have your postcard!






Saturday, January 05, 2013

Restoring Old Comics and Memories


Restoring Old Comics and Memories
Ken Osborn © 2012

If you know Photoshop, like old comics, and would like to see what they looked like new, read on.   

I was and still am a big fan of Carl Barks duck stories: Donald Duck; his nephews Huey, Dewey, and Louie; Uncle Scrooge and a host of relatives.  Trying to refresh my memory on a Scrooge adventure I found an incredible resource, the Duck Comics Revue by Geoff Moses at http://duckcomicsrevue.blogspot.com/. 

Geoff’s blog is filled with all sorts of goodies including panels from some well remembered stories.  But after a few decades the print had faded.  Those old dime comics were printed on a cheaper paper and were not intended to last forever. 

But with Photoshop it’s possible to restore these faded memories to their former glory.   Below are an original scan of a comic panel from the Duck Comics Revue followed by the restored version.

Faded Original
Restored Contrast and Colors
Starting with the scan, open it in Photoshop and take a look at the histogram. 

Histogram Using Photoshop Levels


The histogram is not evenly spread across the full width with a space at the right (highlights) end consistent with the yellow faded appearance.  Mouse click the ‘Auto’ button to improve the contrast. 
Auto Adjust Levels

Notice that the histogram is now spread across the full width and the contrast has improved. But there is still a yellow cast.  To remove the yellow cast select the white ‘eye dropper’ (it’s the one on the right) and then use it to select an area of the panel border that is yellow but originally white.
Eye Dropper for Bright Whites

Maybe too white
  
This is probably a bit harsh and the original was probably somewhere between bright white and faded yellow, so fade the levels about 50%.

Levels Faded 50%

Scanning the comic book will usually leave the print just a little soft, so a bit of sharpening may make the content a little more readable but it’s easy to overdo it so you may need to fade the sharpening.



 Sharpening a Little Harsh with Halos


Sharpening Faded


Before leaving the topic, here is one more example from a classic Donald Duck adventure, Trick or Treat (1952).

Original from Trick or Treat
Restored Version

And that’s it.  If you want to see a restored version of a 1950’s 3D Donald Duck giveaway, check it out at http://duckcomicsrevue.blogspot.com/2013/01/witch-hazel-remastered.html on Geoff Moses’ blog. 


Wednesday, April 04, 2012

Using L.A.B. in Photoshop - Some Basics


Using LAB in Photoshop – Some Basics
Ken Osborn © 2012

L.A.B. is a color profile like RGB.  Unlike RGB, L.A.B. separates colors into two channels, the ‘a’ and the ‘b’, and the luminosity into a third, ‘L’, channel.  Thus working with L.A.B., unlike working in RGB, allows adjustments to the color independently of the luminosity. 

The default color mode in Photoshop is usually RGB.  To convert an image from RGB to L.A.B. use either the Image>Mode>Lab Color (Fig 1) or Edit>Convert to Profile (Fig 2).  Dan Margulis (“Photoshop Lab Color”) recommends converting to profile.

Fig 1: Changing color mode
 

Fig 2: Convert to Profile


Before showing how to use L.A.B. on an image, I’ll give a tweek or two using RGB so you can compare the results.  I’ll use an image that I think has some potential but is low in contrast and a bit soft (Fig 3).  A quick Auto Adjust in Levels gives the image a bit of snap (Fig 4), but maybe it could be improved a bit more.

Fig 3: Two Tigers at the Oakland Zoo - a bit flat and could be a little sharper


Fig 4: Auto Adjust in RGB Levels - looks better


So let’s see what L.A.B. can do.  Fig 5 shows the same image as Fig 1 after conversion to L.A.B.  There is no obvious visual difference between the two images.

Fig 5: Original image converted to L.A.B. color profile - no differences yet


The histograms are different.  The RGB histogram (fig 6, on right) shows the pixel counts for pixel values 0-255 for each of the three color channels.  L.A.B. separates the two color channels (a and b) from the lightness channel (bottom of the L.A.B. histogram on left).  While both graphic histograms use a plot of counts vs levels (aka pixel values), the values in L.A.B. are specified somewhat differently (Fig 7).

Fig 6: Comparison of RGB and L.A.B. histograms for original image


Fig 7: Color values compared for different color spaces at middle gray


RGB has values of [128, 128, 128] for middle gray.  L.A.B. has color values of [0,0] for middle gray and 54 for lightness.  If the values for a and b are fixed at [0,0] any changes in the L channel will not change the neutrality of the color.  It can be changed from pure white to pure black and every tone of gray in between but no changes to the L channel will introduce any color. 

Let’s take another look at the tiger image to see how this works in practice.  On the left side in Fig 8 the channel a curves slider has been moved to the left resulting in a magenta cast.  On the right side the slider has been moved to the right giving a green cast.  I call the a channel the apple-green-magenta channel.  Don’t know if that will work for you, but if you look at Fig 9, you might guess what I’ll use for the b channel!

Fig 8: Moving the channel a curves slider

Fig 9: Moving the channel b curves slider


Moving the b slider to the right adds blue and moving to the left adds yellow.  I call the b channel the banana-yellow-blue channel.  You saw that coming, right?  No?  Doesn't matter but you might just remember it unless you eat magenta apples and blue bananas.  

Let’s combine slider movements so they are symmetrically equal as in Fig 10.  Using channel b, the tigers show a little more life with an equal boost to both the yellow and blue components.  That looks a little more realistic.  If the green and magenta are also increased in channel a, it gets even better. 

Fig 10: equal additions of blue and yellow in channel b followed by equal additions of magenta and green in channel a


So far I’ve just changed the color but not the lightness value.  The image is still a bit flat, lacking contrast. When the Lightness channel is adjusted, that changes as in Fig 11.  The tiger now has some life!

Fig 11: Bringing the tiger to life with the L channel


I could probably stop here, but I won’t because there is a sharpening trick that works really nicely in L.A.B.  Because the color channels are separate from the lightness channel, sharpening does not affect the colors.  I will combine this process with another for one last attempt to give life to the tiger.

Duplicate the original layer and merge in blend mode multiply.  Egad!  This is not an improvement!  Stay with me. 

Fig 12: Tigers thrown into the dark


Now add a mask and Image>Apply Image as in Fig 13.  Notice that the mask for the upper layer now has some black inside the frame.  This is a selection that we can adjust to change both the luminosity and sharpness.  Make sure the mask is selected before using Apply Image or adjusting the Feather slider in the following two steps.

Fig 13: Using Apply Image


Make sure the ‘mask’ window is viewable (if not Window>Masks) and move the feather slider to the right.  You should see a noticeable increase in sharpness as in Fig 14.  Notice the Density slider. If this slider is moved to the left, the effect of the mask is reduced and the image will approach its original appearance.  So if you want it a little bit darker, go for it.  I’m leaving it where it is now. 

Fig 14: Feather slider in Mask window to increase sharpness.


Fig 15: The tigers can now play


References:
Margulis, Dan "Photoshop LAB Color - The Canyon Conundrum and Other Adventures in the Most Powerful Colorspace," 2006, Peachpit Press, Berkeley.
Mark Lindsay, M.F.A. and a presentation to the Berkeley Camera Club on March 28, 2012
see Mark's work at marklindsayart.com