简体   繁体   中英

Photoshop magic wand-like action in an iOS app

Is there a way to use a magic-wand tool (like in Photoshop) in Xcode for iPhone? What I want to do is to cut out the background of an image (a person standing in front of a white background) to make the background transparent.

Edit: i think i was not specific enough, sorry. I would like the iPhone or iPad app to automatically remove the background of an image just taken with the camera. Thus, i can't use Photoshop for it and need a function or so to do this. I was thinking about a "flood fill" kind of solution similar to this:

http://www.codeproject.com/Articles/16405/Queue-Linear-Flood-Fill-A-Fast-Flood-Fill-Algorith

but was hoping that there is a more convenient solution especially for "cutting" out custom shaped areas of an image.

Thanks!

Floodfill assumes a uniform background color; on a real life photo, it won't ever be uniform. What you need is a Chromakey algorithm. See here:

Green screen / chroma key iOS

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM