在中文资料中,彩色图片转成线描图的材料很少,无外乎两种:用Matlab或别的语言实现边缘检测算法;用PS去进行边缘检测,抠图,然后再用滤镜进行转换。
老外的一篇Photo to Line Drawing帮助我解决了实际的问题。在PS CS5中操作很简单。
文中High Pass对应 滤镜-》其他-》高反差保留
Sketch->Note Paper对应 滤镜-》素描-》便条纸
Image / Adjustments / Threshold 对应 图像-》调整-》阈值。
There are several Photoshop techniques to convert a photograph to a line drawing. One of them was already discussed in the Drawing/Painting effect Photoshop tutorial.
That Photoshop technique was based on the Film Grain filter. Most of these kind of conversions are done in Photoshop with filters like Smart Blur, Find Edges or Glowing Edges.
In this Photoshop tutorial I'm showing a recently discovered technique that I haven't seen anywhere else and that's the reason why I'm sharing it with you. The technique is based on two filters:
The results are slightly different and often better than other Photoshop techniques I've talked about earlier.
Open an image that doesn't have a lot of rough textures, because like with the other techniques the results are not going to be that good.
In my example I've opened the image of a clock in Photoshop.
Duplicate this background layer by clicking on its icon in the layers palette and while holding the mouse button, drag and drop it on the Create a New Layer icon .
First press Ctrl + D (Command + D on the Mac) to change the foreground color to black:
Select in the menu: Filter / Other / High Pass
Select a very small radius. The radius depends on the size of the image. In my example I've chosen a radius of only 0.3 pixels.
Just make sure that you don't use too much radius like in this example:
Select in the menu: Filter / Sketch / Note Paper...
Use the following values:
The result looks like this:
In our previous step the lines are not black but some shade of gray. We can change this by adding a threshold correction.
Select in the menu: Image / Adjustments / Threshold...
Move the slider to the right until you see a black & white drawing of the image. In my example a Threshold Level of 180 was enough.
Here's the result:
Go to the tool bar and select the Pencil Tool and set the foreground to white by pressing X on your keyboard (this switches the fore- and background colors)
Now remove some a the few distracting pixels by clicking on them with the pencil tool. Make sure that you zoom in and that you use a small sized pencil.
Here's another example:
Have fun!