Photoshop CS5's Showpiece — Content-Aware Fill
Barence writes "If you're looking for reasons to upgrade to Photoshop CS5 when it arrives, a new demo video might just persuade you. Narrated by Bryan O'Neil-Hughes, a product manager on the Photoshop team, the video shows the new content-aware fill tool, which has the potential to revolutionise the way you clean up photos. If you're not happy with an item in your picture, select it, delete it, and Photoshop will analyse the surrounding area and plug the gap as if it never existed."
Photoshop has had that capability natively (ie, not requiring a plugin) since CS4, this is the ability to select an object in an image - litter on a lawn was the example given in the article - and replace its former location in the image with content derived from the surrounding areas. Basically it's like an intelligent, automated version of the Clone Brush tool on steroids.
UNIX? They're not even circumcised! Savages!
Liquid rescale is an implementation of the Seam Carving technology which was incorporated into Photoshop CS4 as a feature titled Content Aware Scale.
This new feature comes from an algorithm titled PatchMatch which was presented at SIGGRAPH 2009:
http://www.cs.princeton.edu/gfx/pubs/Barnes_2009_PAR/index.php
Includes more detail about the algo
- Developed with researches at Princeton
- Demo'd at SIGGRAPH in Aug. 2009
- Old spot-healing tool tried to find one match for the hole; new tool copies multiple patches from the surrounding BG to fit into the hole, as well as finding & copying surrounding patterns
http://www.youtube.com/watch?v=S9vbHRcrbdQ&feature=related
The English word fart is one of the oldest words in the English vocabulary.
A few days ago I was reading about some of the algorithms for doing this, shown at Siggraph in recent years. I think it's real.
GCHQ Quantum Insert installed. If only our tongues were made of glass, how much more careful we would be when we speak
It's a very cool GIMP plugin for some things, but...
This is my source image:
http://s3.images.com/huge.28.142421.JPG
I want to remove the lady on the right, so I select her:
http://img714.imageshack.us/img714/1346/resynthesizerselection.jpg
And then, per the Resynthesizer page's recommendations, I use "Script-Fu/Enhance/Smart remove selection..."
http://img121.imageshack.us/img121/228/resynthesizerresultradi.jpg
Oh dear.
Anybody with access to the Photoshop beta feature want to give that image a stab? For all I know it fails just as spectacularly - but from the research it's based on, I highly suspect it'll fare better.
obvious question: workflow / parameters?
Generally I use the foreground select tool* to select the smallest area to cover the object, then grow selection by a few pixels so that none of the object's edges are poking out and confusing it, then filters - map - resynthesize (ie, use the plugin rather than the script), and have the "tilable" options disabled since they tend to grab samples from the opposite edge of the image (if I want a tilable image, I'll use the tiling filter separately...)
Probably the biggest factor for simple success is to have the object you want to remove be on its own (surrounded on all sides by similar textures) -- if it isn't, then you need to do things the long way -- eg, if you want to remove the leftmost wheelchair from this image, and you want it to be replaced by grass when three of its borders are touching non-grass, then you'll find that it ends up somewhat messy since it attempts to merge four different edge textures. In this case you'll need to copy a section of your desired fill texture (ie, a rectangle of pure grass) into a separate image (specifically, a single layer image with no transparency); then on the original image select the object to remove, open resynthesizer, and select the "fill texture" image as the texture source; this way the generated texture will both match the surroundings of the original as much as possible, while being filled with the "surroundings" that you've specifically chosen. Having taken a sample of "pure grass" and a sample of "pure stone", then removing the top and bottom halves of the wheelchair with each respectively, the results are nicer. (with the exception that the first two images were produced with a mouse and twenty minutes of careful selecting, and the final one was 5 minutes work with a laptop nipple, so there are still some bits of wheelchair poking out of the sides...)
Incidentally, does photoshop have SIOX yet? Having the features "vaguely scribble in the general area of an object to have the object selected precisely" and "automatically and realistically remove a selection" could potentially combine to form "one-click realistic object removal" \o/
I mod down anyone who says "I will be modded down for this", regardless of the rest of their comment