
Fluid Paint Simulation - anonfunction
http://david.li/paint/
======
zokier
You can compare this to what I believe is the state of the art system,
"Wetbrush":

[https://www.youtube.com/watch?v=gwyqh4d-WU8](https://www.youtube.com/watch?v=gwyqh4d-WU8)
(SIGGRAPH Asia 2015)

[https://www.youtube.com/watch?v=k_ndr3qDXKo](https://www.youtube.com/watch?v=k_ndr3qDXKo)
(Adobe demo)

~~~
pavlov
Of commercial applications, Corel Painter remains the professional natural
media paint tool:

[http://www.painterartist.com/en/product/painter/](http://www.painterartist.com/en/product/painter/)

It's been around for about 25 years and some of the UI is a bit creaky, but on
the upside, it's pretty fast on modern desktops and it still gets regular
updates. Brush strokes with 3D depth ("impasto") were introduced a long time
ago, maybe late '90s.

------
mholt
His other work is cool too: [http://david.li/](http://david.li/)

~~~
lumberingjack
the green Vortex Spheres maxed out my gtx 1070 what the heck

~~~
egeozcan
I have a 1080 and didn't even turn on the fans. Something is wrong.

------
kepano
This seems obvious but somehow I never considered that you need three
dimensions to replicate the feel of most paints.

~~~
fjdlwlv
If you are accustomed to seeing prints and photos and computer scans, it's
easy to overlook how oil paint is like a sculpture. Watercolor, not so much.

------
chris_st
Another "natural paint" painting program is ArtRage [1]. They have, bar none,
the friendliest, most supportive discussion forums I've ever seen on the
internet.

Oh yeah, the painting program's pretty good too :-)

[1] [https://www.artrage.com](https://www.artrage.com)

------
mistercow
This is very cool. One thing that I think could be improved: It looks like the
model is treating the white background as if it is also paint. This leads to
some weird results when painting over existing strokes.

Really awesome work though.

~~~
fake-name
This could be intentional. It's a fairly common technique to paint on top of a
wet white basecoat[1].

[1]: [https://en.wikipedia.org/wiki/Wet-on-
wet](https://en.wikipedia.org/wiki/Wet-on-wet)

~~~
mistercow
Hmm, good point. I'm guessing it also makes the model a lot simpler.

------
dorianm
I loved it, I feel like it could make some nice backgrounds and decorative
paintings will a little more tries:
[http://imgur.com/a/XBUgn](http://imgur.com/a/XBUgn)

And it's open source:
[https://github.com/dli/paint](https://github.com/dli/paint) (I posted my
issues there)

------
Justsignedup
Fantastic. One criticism. On click please make the paint "dip" and paint, and
the paint on the brush should wear out. Then it'll really feel like painting.
Click again is to re-dip in the color of choosing.

This will even let for mixing of colors like on a painter's palette.

:) Very nice tool.

~~~
thomasjudge
To "really feel like painting" for me it would have to simulate spending hours
with blue tape, spilling on my shoes, making multiple trips to home depot...
sounds like a job for VR... ;)

------
haxiomic
Great stuff! Reminds me of Verve Painter[1], which is a fleshed out fluid-
simulation-based oil painting app

[1]
[https://www.youtube.com/watch?v=PBO2hNv_tTE](https://www.youtube.com/watch?v=PBO2hNv_tTE)

------
Ono-Sendai
Cool. Something like this could combine nicely with my automatic painting
algorithm:
[http://www.forwardscattering.org/post/42](http://www.forwardscattering.org/post/42)
[http://www.forwardscattering.org/post/44](http://www.forwardscattering.org/post/44)

------
roesel
20 seconds of drawing with default parameters and laptop temperature went from
40 to 70 °C. Not bad :D.

Nice work though, very beautiful and realistic.

------
ww520
This is awesome. 3D work really have the wow factor. This is definitely at the
WOW level.

Edit: I would say couple this with VR and it would be a truly awesome
experience.

~~~
jayajay
Like MS Paint, but for VR. Interesting, the "websites" of VR will be worlds...
I can totally see people throwing in this kinda stuff "just because wow new
technology" in the same way that websites back in the 90s threw in snowflakes
falling on the screen, custom pointers, epileptic lighting, audio, flash, etc.

~~~
zachrose
I really hope web concepts move gracefully into VR. I suppose "immersive
location" is just like a URL and full-VR experience is just another Content-
Type.

~~~
jayajay
pls no

------
overcast
Looks sweet, but the paint definitely continues sliding in the direction of
the stroke for too long. Paint basically just sticks immediately where you put
it, it doesn't have that type of momentum. Even at the lowest fluidity level.

------
fonosip
A similar app without opengl (for ipads and such) [http://ba.net/util/finger-
oil-painting/](http://ba.net/util/finger-oil-painting/)

~~~
supercoder
iPads support WebGL / OpenGL just fine

~~~
bsaul
Interface doesn't seem to work on an ipad ( maybe because of event handling
though)

------
tantalor
Touch event support please!

------
craigleehi
Here is another eastern watercolor painting tool "Expresii"[1].

[1] [http://www.expresii.com](http://www.expresii.com)

------
anonfunction
Source code: [https://github.com/dli/paint](https://github.com/dli/paint)

------
bsenftner
So bizarre: I saw this post last Saturday, loved the site and David.il's other
pages, showed some friends... Then I could not find the HackerNews post again.
Here it is now, yet it says it was posted within a day, with no history of
being posted before. Odd...

~~~
lkbm
[https://news.ycombinator.com/item?id=13589074](https://news.ycombinator.com/item?id=13589074)

Not surer why it's not showing when you search. I got here by using HN search
for the URL and picking the one with more comments--both showed up for me.

------
jefe_
Amazing how well it handles painting on top of previous strokes.

------
jonr8
See a history of fluid sim applied to watercolor-like painting:
[http://www.expresii.com/blog/innovations-in-digital-
painting...](http://www.expresii.com/blog/innovations-in-digital-painting-
tech6607339) A quick look at David Li's source code seems to suggest Li's work
is based on Mark Harris' GPU implementation (with Jacobi iteration) of Jos
Stam's method.

------
robodale
My MacBook Pro sounds like it's taking off a runway :P

------
olegkikin
Doesn't have dark colors. The darkest paint is brown.

~~~
tracker1
the box in the middle of the color picker is saturation and lightness, drag
towards the left on the top of the box to reduce the brightness downward.

~~~
esrauch
The darkest color comes out as brown for all colors though.

~~~
tracker1
You're right... I hadn't tried black.

------
mfisher87
Reminds me of Verve. I watched the author's channel on Youtube religiously,
hugely enjoying his video demos with each new release. Sad to say there hasn't
been one in like 2 years.

[https://www.youtube.com/user/333taron/videos](https://www.youtube.com/user/333taron/videos)

~~~
snailmailman
Oohh! i was looking for this! i remember seeing this a few years ago and being
really impressed. It looks pretty good, although im not much of an artist so i
dont know how it compares to the paid competition. The UI could use some work
though.

it took me a while to figure out but im having a lot of fun with it. performs
surprisingly well for me on only an intel integrated card.

------
BuffaloBagel
Did you mean to use the term fluidity rather than the term viscosity? I
believe they are mathematically inverse.

------
ygra
Reminds me of [https://www.microsoft.com/en-us/research/project/project-
gus...](https://www.microsoft.com/en-us/research/project/project-gustav-
immersive-digital-painting/) with later became Fresh paint.

------
devwastaken
Quite nice, though the paint colors don't combine like they do in this kind of
oil painting. Can't make bob ross art without that. Also when you try to paint
on the edges, the brush goes away, so its difficult to make a full picture
without making it larger, and then cropping down.

------
aperrien
This reminds me of Bob Ross and his "Happy Little Trees". I think I could
paint some on here if the canvas were bigger, and there was an area off to the
side to mix the paint.

------
koliber
I can't seem to create anything beautiful worth sharing with this. But damn,
it is soothing and relaxing to play with. It feels almost therapeutic! Thank
you!

------
cr0sh
I can't paint or draw worth beans - but I like it!

------
pacaro
See also FreshPaint on any version of windows > 7

------
joakleaf
Is this using Navier-Stokes based fluid simulation?

------
noonespecial
Very nice. Lots of fun. The only thing missing is that the paint doesn't mix,
ie. yellow and blue don't turn greenish etc.

------
kin
At first I was like, "Wow, this is a cool effect, let's try a different col--
HOLY SHIT". Color me impressed!

------
superplussed
Amazing. It seems like it'd be really useful to be able to zoom in and out as
well.

------
marai2
This is oddly therapeutic and calming. My Macbook CPU was just fine as well.
Very cool!

------
divbit
This is great for calligraphy with surface pen - can't find the black ink
though.

------
quakeguy
With Opera 43.0.2442.806 (PGO) i cannot do a stroke at all it seems. Just
reporting.

~~~
mfx
Hitting a bandwith limit?

~~~
quakeguy
Hardware Limit it seems, doing this on a Lenovo minimun laptop, maybe OGL is
outdated.

------
_Codemonkeyism
Like that, though I wish it would work with FF/Win10/XPS13 touch screen.

------
heurist
Pretty cool. Next step is mixing colors and different thicknesses like real
oil :)

------
andyfleming
This is pretty impressive. It'd be really neat if the paint slowly dried!

~~~
beders
Who would like to watch that? ;)

~~~
ww520
Computer can always speed that up.

------
huangc10
Was playing with your other projects too. Great stuff and super fun. Sharing.

------
kdamken
I feel like you deserve the nobel prize for this or something. Mind = blown

------
santaclaus
Cool! Any idea what model or method is used here (or is it heuristic)?

~~~
jonr8
A quick look at the source code seems to suggest Li's work is based on Mark
Harris' GPU implementation (with Jacobi iteration) of Jos Stam's method. Ref:
[http://www.expresii.com/blog/innovations-in-digital-
painting...](http://www.expresii.com/blog/innovations-in-digital-painting-
tech6607339)

------
itomato
This is more of a 'mop' than a 'paint brush'.

------
tucaz
Holy moly! Awesome work. It looks very realistic. Congrats!

------
throwaway2016a
Very nice work. Reminds me a lot of Corel Painter.

------
Jordrok
Very cool!

Man, does it peg the hell out of the CPU though! :P

~~~
exDM69
It was hogging about 60% of one CPU core (Skylake i7) on my PC. Seems like
it's re-drawing the screen at 60 fps even though nothing is happening. Should
be an easy fix.

------
ffwacom
so cool, consider adding an option to remove paint from the brush so you can
scumble the fluid to blend.

------
amelius
What primitives is this using?

------
mshenfield
Color me impressed

------
shankar_mj
Wow !

------
nilved
This is too slow to use on my MacBook... I like the idea though, and it seems
really cool.

------
btzll
Very cool, but please change the color selector. It is not intuitive, and it's
very hard to pick even the most obvious colors.

~~~
bkanber
That's a pretty common HSL-style color picker. It's great for artists and
designers who think in those terms. Curious, do you have much experience in
graphic design, or no?

~~~
btzll
I have zero experience in graphic design, but I do not think the simulation is
made for designers.

~~~
bkanber
It makes sense for artists, designers and painters included. This simulation
looks like oil paint, and this type of color picker is like mixing pigment to
get a hue and then mixing in black and white to change the saturation and
value. I guess that makes sense seeing as this is a paint simulation!

