Creating a cartoon effect

A plethora of command-line scripts that perform geometric transforms, blurs, sharpens, edging, noise removal, and color manipulations.
Leekao
Posts: 11
Joined: 2017-02-15T11:38:17-07:00
Authentication code: 1151

Re: Creating a cartoon effect

Post by Leekao »

fmw42 wrote: 2017-02-15T17:00:42-07:00 This is what I get:

Input:
Image

Code: Select all

toon -m 1 -g 5 -b 5 -S 10 -s 200 pNgAaeB.jpg pNgAaeB_toon_m1_g5_b5_S10_s200.jpg
\Image
Wow, that's pretty sweet, I'm going to try it.
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Creating a cartoon effect

Post by snibgo »

Leekao wrote:... 30fps and I'm running all the frames through imagemagick to make em cartoonish and then playing them in 30fps ...
So, you want to capture, process and display video? Ffmpeg or Avisynth would seem more logical choices for tools.
snibgo's IM pages: im.snibgo.com
Leekao
Posts: 11
Joined: 2017-02-15T11:38:17-07:00
Authentication code: 1151

Re: Creating a cartoon effect

Post by Leekao »

snibgo wrote: 2017-02-16T01:35:05-07:00
Leekao wrote:... 30fps and I'm running all the frames through imagemagick to make em cartoonish and then playing them in 30fps ...
So, you want to capture, process and display video? Ffmpeg or Avisynth would seem more logical choices for tools.
Yeah, I guess that would be reasonable, but I do not know how to apply these effects on ffmpeg or avisynth and I know a little imagemagick so I used the tool I know.
can you maybe recommend some articles on how to accomplish smthing like this on ffmpeg or avisynth?
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Creating a cartoon effect

Post by snibgo »

Sorry, I don't know of any good "how-to" pages for ffmpeg. In particular, the filters and how they can interact, with examples.

At one time, I considered writing a series of "snibgo's ffmpeg pages", but never got around to it.

Most of my video work uses IM, but it doesn't process in real-time.
snibgo's IM pages: im.snibgo.com
Leekao
Posts: 11
Joined: 2017-02-15T11:38:17-07:00
Authentication code: 1151

Re: Creating a cartoon effect

Post by Leekao »

Leekao wrote: 2017-02-15T17:08:25-07:00
fmw42 wrote: 2017-02-15T17:00:42-07:00 This is what I get:

Input:
Image

Code: Select all

toon -m 1 -g 5 -b 5 -S 10 -s 200 pNgAaeB.jpg pNgAaeB_toon_m1_g5_b5_S10_s200.jpg
\Image
Wow, that's pretty sweet, I'm going to try it.
The living room and the cats look awesome, but faces are really distorted.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Creating a cartoon effect

Post by fmw42 »

try lowering the smoothing -S to get more detail

toon -m 1 -g 5 -b 5 -S 1 -s 200 pNgAaeB.jpg pNgAaeB_toon_m1_g5_b5_S1_s200.jpg
Leekao
Posts: 11
Joined: 2017-02-15T11:38:17-07:00
Authentication code: 1151

Re: Creating a cartoon effect

Post by Leekao »

fmw42 wrote: 2017-02-16T14:05:09-07:00 try lowering the smoothing -S to get more detail

toon -m 1 -g 5 -b 5 -S 1 -s 200 pNgAaeB.jpg pNgAaeB_toon_m1_g5_b5_S1_s200.jpg
It's really nice but the faces still distorted/
Image
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Creating a cartoon effect

Post by fmw42 »

Sorry, nothing can be done about that. It is the detail in your face that is brought out by the cartoon script. After all, it is a "cartoon" and things are expected to look unreal. You can smooth more, but you did not like that one either.
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Creating a cartoon effect

Post by snibgo »

@Leekao: You might be interested in my "Cartoon and texture" page, though the methods take more time.

One cartoon result, with no added lines, is:
Image
With added lines:
Image
snibgo's IM pages: im.snibgo.com
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Creating a cartoon effect

Post by fmw42 »

Here is the result from using the online editor at http://pho.to/

Image
Post Reply