Blender Dynamic Paint



Blender's Dynamic Paint feature allows you to simulate effects like rain puddles. SottoZen's latest video tutorial gives a quick introduction. I always really like their videos and this tutorial is well produced too, except for the sound - you need a better microphone guys! Hi guys, we made this new tutorial about Dynamic Paint in Blender. Today we take a look at setting up a dynamic paint system but rather than using a mesh to generate or act like a brush we will enable Blenders particle system and paint using an emitter. Welcome to the Complete Guide to Dynamic Paint in Blender 2.9.In this class you will learn everything there is to know about Dynamic Paint and how it works. It was also created for all skill levels. So whether you are a complete beginner or an intermediate Blender user, this class is for you! In his latest video, Daniel Kreuter illustrates different options for Blender's Dynamic Paint option. Also check out his videos on smoke, fluids, cloth and softbody animation! Daniel writes: Yet another tutorial this time about the Dynamic Paint tools in Blender. It's not a step by step tutorial! In recent years there has been increased interest in systems with a free license. In the field of 3D design a powerful system with a free license is the Blender.

I made an overview video that shows how Dynamic Paint can be used in Blender.

Dynamic Paint has wide potential to simulate physical motions and video effects, striking paint brush and canvas meshes.

For example, drops of blood could be made by it. Once the brush touches the plane, the paint color spreads on the plane over time. In the end, the blood devours the whole surface:

With fading displacement, the horns jump at a moment, then fade out. it is seemingly a simplified swimming fin of a Jaws, or moving wave from it. Seems fit on a ocean material:

When paint brush is fluid, the water forms solid ice as it trickle on the canvas plane.:

When particles on a monkey are integrated with weight paint made by other brush particles, the monkey’s particles appear like colonized blobs on collision points. Particles don’t need to be sphere, no matter what meshes are OK if they can become particles, like hairs or light emitters:

Articles -> Blender: Dynamic Paint Guide

Creation date: 2010-10-7
Last update: 2010-12-1

Dynamic Paint is a new tool for Blender I've been working on. It allows you to 'paint' animated textures with other objects and particles. This guide explains what all those settings are for.

If you are new to Dynamic Paint and don't know how to get started, you should read my Dynamic Paint Basics tutorial. It should help you to get started. This guide helps you to fully use this feature.

Dynamic Paint isn't currently part of official Blender, so you have to use a special build that has it. You can download a Windows build and code patch from MiikaHweb Blender Builds page. GraphicAll.org has some builds for other OS. Check out my blog for more info about Dynamic Paint.

Note: This article isn't currently up-to-date with latest development. Some features may differ or be missing.

Tutorial contents

1. Canvas: Main Settings
2. Canvas: Output Types
3. Canvas: Advanced Settings
4. Paint: Main Settings
5. Paint: Advanced Settings
6. Info and Samples

'Resolution' defines outputted texture dimensions. For example using 256 will lead to 256x256 image output. Doubling the resolution will likely quadruple baking time and vice versa.

'Antialiasing' does smoothen paint edges using a 5x multisampling method. It will also slightly increase baking time.

'Substeps' are extra frames calculated between 'real' frames. This helps getting a smooth paint flow on fast moving objects, but also directly multiplies baking time.

For example if you set one substep, Dynamic Paint will calculate one extra sample between each frame, calculating following frames : 1.0, 1.5, 2.0, 2.5 etc. But only saves whole frames.

This video shows a paint map of a fast moving object without substeps:And now with 5 substeps:
Get the Flash Player to see this video.

Frame 'Begin' and 'End' values can be used to define baking start and end frames.

'Bake Dynamic Paint' starts the baking process. Canvas must be UV-unwrapped and scene must have at least one active paint object. You can see bake process at console window and on mouse cursor. Pressing ESC will stop the bake.

Dynamic Paint system can output three different texture types: paint maps, wetmaps and displacement maps.

Paint map

Paint map is the 'color texture'. It shows paint color and alpha.

'Premultiply Alpha' makes color values to be multiplied by alpha while saving the texture. This is usually recommended to be turned on.

This video shows how paint map looks like:

When added as a texture to the canvas object: you get paint colors.

Texture influence settings used in that render:

Wetmap

Wetmap is a black-and-white texture that visualizes paint wetness. White being maximum wetness, black being completely dry. Paint dries within defined time period. Some 'paint effects' affect wet paint only.

Basically wetmap equals to a paint map of white paint with fading enabled. It is a separate output because you usually want to use both paint map and wetmap simultaneously.

This video shows a wetmap:

Get the Flash Player to see this video.

If you set wetmap to influence normal, specular and ray mirror, render should look something like this:

An example of wetmap influence settings:

If you use both paint map and wetmap, you can easily get a nice looking paint surface. You can also use any output texture as a mask for Blender's procedural textures etc. So keep playing with different combinations and you can get any kind of results.

Paint

Displacement map

Displacement map is a texture supposed to be used with 'Displace' modifier or with texture displace. It is sort of depth map visualizing distance (or depth) of paint object intersection.

'Strength' value defines how deep intersection is considered as maximum displacement. Use same value on displace modifier strength or on texture displace 'scale' value.

'Type' drop-box defines output texture type: 'Displace' is the standard type used by Blender, it's directly compatible with Blender displace tools.

You can also choose output file format between PNG and OpenEXR. OpenEXR is a 32-bit per channel floating point texture, so displace result is likely be smoother when using it. You need, however, a build that supports OpenEXR.

This is an example of a dispalce texture:

And this is how it looks like when used to displace a mesh. Remember that you have to subdivide the mesh before you can displace it:

These texture influence and displace map output settings were used in the previous render:

Please note that enabling more output types doesn't cause a noticeable increase in bake times. So there is no need to disable texture outputs in terms of saving in bake times.

First three sliders let you to define paint drying, fading and flattening behavior. 'Time' value defines number of frames it takes to revert from maximum value to zero. 'Slow' drying enables logarithmic drying. Basically it makes high wetness to dry faster than low wetness.

Enabling 'Paint Fade', makes paint to fade or disappear during time. 'Flatten Displace' makes displace map to flatten back to zero depth during time.

'UV Layer' can be used to define the used UV-layer. If not defined or if mesh only has one layer, the active one is used.

Paint Effects

'Paint Effects' is a Dynamic Paint sub-tool that generates animated movement on canvas surface.

In the 'Effect' drop-box you can select different effects. This menu only defines which effect related settings are visible. To enable an effect, click the 'Do Effect' checkbox below. You can also tweak effect speed from the value below.

'Spreading' makes wet paint to spread on mesh surface. Only wet paint moves, so as the paint dries, it's movement slows down and eventually stops.

This is how spreading effect looks like:
Get the Flash Player to see this video.

'Dripping' is similar to spreading effect, but only moves paint in gravity direction.

This is how dripping effect looks like:
Get the Flash Player to see this video.

Blender Dynamic Paint Vertex Group

'Shrinking' makes paint to disappear from edges, eventually completely vanishing.

This is how shrinking effect looks like:
Get the Flash Player to see this video.
In case you are wondering why eyes behave differently, that's because they actually aren't connected to the head mesh. :p

Effect system is far from perfect, but it works well enough for most scenarios. You should try to unwrap UVs to as large pieces as possible and have at least two pixel space between each UV island. If you still experience strange behavior near UV island edges, try to use higher canvas resolution.

'Affect Paint' checkbox defines whether that paint object affects paint or wetmaps.

Blender Dynamic Paint 2.79

Paint Color selection box allows you to select color this object paints on color map.

Paint Alpha is the transparency of the paint. 1.0 means completely solid, while 0.0 is invisible.

Paint Material

'Use object material' makes Dynamic Paint to use the paint object material instead. Material and all it's textures are included. Final color equals the shadeless render color of the object. 'Paint Alpha' value is used to multiply the material alpha value so you can still manually adjust the paint final alpha. You can even use alpha values greater than 1.0 to amplify faint textures etc.

Material can be either 'Surface' or 'Volumetric' type. All texture types are supported, but only those texture 'Mapping' settings that don't require a camera.

This is an example of textured painting:

Surface Material

When using surface type materials, paint color is defined by the material diffuse color and alpha by material alpha. Following texture mapping types are supported. Other mapping methods will be simply ignored.

Volumetric Material

In case of a volumetric material, paint color is sampled from the volume at the exact point of the canvas pixel. Material 'Transmission color' is used as paint color and 'Density' as paint alpha.

To paint with smoke, you just have to use the smoke domain as a paint object. Just remember that domain has to have a renderable volumetric material.

Other settings

'Absolute Alpha' defines how transparent paint is handled. When enabled, texture alpha will never go higher than the defined 'Paint Alpha'. Without it however, texture alpha is increased every frame, eventually leading to completely solid paint surface.

'Wetness' defines how wet the paint is. Basically how it's shown on the wetmap. Wetness is multiplied by paint alpha, so you can use textured painting but only get wetness on actually painted areas.

'Erase Paint' setting inverts the way paint object behaves. Making it to remove paint instead of adding it. You can use paint alpha to define erase strength. High alpha leads to more paint being erased.

You can also use textures on eraser. Just remember that alpha is what matters, not color.

Here is a comparison between textured and non-textured eraser: First a plain one.

Get the Flash Player to see this video.

And now with a noise texture affecting material alpha. Please note that you need lots of substeps to get a smooth track.

'Affect Displace' defines whether this object affects displace texture.

From the 'Paint Source' list you can select how paint mesh intersection is handled or whether to use particles instead.

Mesh Volume

This is the default behavior. It makes Dynamic Paint to use mesh volume as paint source. Basically every pixel inside the paint object mesh will be painted. Object mesh has to be closed and have proper normals.


Mesh volume painting. Only pixels inside the paint mesh will be painted.

Mesh Proximity

Mesh Proximity is used to paint with a distance to the mesh surface. You can define distance to paint with using the 'Paint Distance' settings. This is the maximum distance to mesh surface to affect paint.


Proximity painting. Only pixels withing the defined distance to the paint mesh surface are painted. Notice how some areas inside the mesh are unaffected by the paint.

From the 'Falloff' drop-box you can change proximity falloff type.

  • 'Sharp' paints solid paint within the defined distance.
  • 'Smooth' makes paint to linearly fade out until becoming completely invisible when it reaches the maximum distance.
  • 'Color Ramp' allows you to manually make a custom falloff behavior.

When using a color ramp falloff, the left side is color at right next to the paint object while right side is the maximum distance.

'Only Use Alpha' makes Dynamic Paint to only read color ramp alpha values. Then paint color remains unchanged.

This is an example of proximity painting. A following falloff color ramp is enabled to better illustrate the effect.

'Face Aligned' sets proximity painting to be processed only in the direction of canvas surface. This way only objects directly in front of the surface will be painted.

Here is an example of face aligned proximity painting using the same color ramp:

Get the Flash Player to see this video.

Mesh Volume + Proximity

This option enables both volume and proximity checking. Everything inside the mesh volume is painted but also objects within defined distance to the mesh surface.

This option can be useful for example when using Fluid simulation domain as a paint object. Fluid barely intersects the obstacles or domain walls so using low distance proximity painting is a good idea.

Get the Flash Player to see this video.

Particle System

This option lets you use a particle system as paint source.

From the sliders you can adjust particle influence radius in global units. 'Solid Radius' defines the distance, inside which paint is solid color. 'Smooth Radius' is an additional radius outside Solid Radius to add a smooth falloff.

If you set 'Smooth Radius' to zero, particle will be painted as a solid sphere. If you set 'Solid Radius' to zero, it gets painted as a smooth halo.

General notes

  • Like usually in Blender 2.5x, everything is animatable. This means you can freely animate Dynamic Paint settings. Every setting that accepts key frames can be freely animated to fit your purposes.
  • Canvas object and mesh can be freely animated - as long as the vertex count and uv data remains the same.
  • Paint object and mesh can be freely animated by all means. There are no limitations what-so-ever.

Downloadable samples

Here are some downloadable .blend file samples you can use to get started using Dynamic Paint. Please note that baking Dynamic Paint of these sample files may take a while on slower systems.

Paint and wetmaps rendering

This sample shows how to setup materials to render a nice looking paint material using both paint map and wetmap.

Download the .BLEND file.

Displacement painting

This sample shows how to use Dynamic Paint to produce interactive displacement maps.

Download the .BLEND file.

Fluid simulation wetmaps

This sample shows how to use fluid simulation as a paint object to produce fluid wetmaps.

Download the .BLEND file.

Painting with smoke

This sample shows how to use smoke simulator domain as a volumetric paint object to paint with the smoke.

Download the .BLEND file.


(Comments, questions or discussion about this article.)

Blender
Thank you for work and now the guide.
I'll down load a build and give it a try. :)
Oh WOW, thanks a lot for the nice guide. I'll try it out right now!
I dont know what else would you add , keep going! great job! THANKS!!!
Great work Miikah!! But I have a few suggestions for improvements.
1. Is it possible to make the effects as modifiers so that you can combine different effects to a final effect?
2. Wouldn't it be more logical to have dynamic paint at the same place as where you bake AO and such?
3. Allow more Anti-aliasing than 5x.
@Tobias
1. You can already stack effects. Just enable 'Do Effect' on multiple ones.
2. I have to look into that. I have never baked render stuff before. :p
3. I don't think that's worth the effort. After all it's just a texture. You barely notice whether AA is on or not. xP
Thank you so much for the tutorial.
I got a request for myself and others.
Would it be possible to get a video tutorial of the above? That way we can watch it on TV/Xbox/Playstation and follow along? Many of us (myself included) have to see it to actually 'get it.'
Exelent work, hope that this project reach the blender trunk!
this is fantastic work and great documentation! on a side note do you think the fantastic dynamic paint algorithm could be used as a way mightier dilate/erode node in the compositor? that would rock so much
cheers
Hey Miikah,
thanks alot!! This is really an awsome feature! I am looking forward and hope this will get integrated soon in the main branch!
It would be great if every feature in blender will be so well documented!! Thanks again!
Keep it up! I am looking foward to your future work!
nice stuff,
how about this case: Drying liquid which is leaving traces with more
color on the beginning and to the end. Second, the wind thats moving
pixels where it can reach them and move less in the areas with for example are some cracks.
each thing simulating for few minutes in the loop. This should be really
interesting.
oh, and of cause for the liquid Spreading-Dripping-Shrinking simultaneously =D
sorry for spamming ;)
Very nice effects, and a straightforward tutorial. Thanks!
Thank you so much Miika!
It is the best way to show off a technology, concept!
@blurdude
Either uncheck Color influence or click that 'RGB To Intensity' box. Then color brightness will be used as texture affect strength.
@MiikaH
Thanks a lot for the help :D I really appreciate it.
Maybe you can improve ur tutorials by adding 'DOs and DON'Ts'. Overall its an awesome tutorial. :D
Niiiiiiice! The shrinking looks like a lot of fun :D
@gimble
You mind posting a blend file where this happens? So I can check out what's going on there.
@gimble
Ok, I'll check that out.
About that 'trench slightly leading the sphere' issue: It was a bug in SVN version -> wrong default 'start frame' for image sequences. It has been fixed in recent SVN.
How to fix that, just set sequence 'Start' value to 1 instead of 0. :)
@gimble
It was a quite special bug. If canvas had more than 32.767 vertices those 'holes' started to emerge.
But now it's fixed: http://www.miikah.org/blender/snowball.jpg
Thanks alot for reporting it! I will post an updated patch and builds tomorrow.
Thanks MiikaH for the help and all your hard work.
Your latest demo looks really nice.
I can't get the Mirror or alpha to work under influence ,with the wet maps. I clicked RGB to intensity ,changed settings all day.
Remember to enable 'Transparency' and 'Mirror' from material settings. (You can just set material 'Alpha' and 'Reflectivity' to zero.)
Thanks, I just now got the mirror to work. I think this is the best tool I've seen in a time. I can think of so many uses.
Can a person use the spread with a texture without stepping? (I think that is the correct word) Re create the pattern evenly.?
Thanks again
Oh I got that to . put alpha over a texture and remove it with spread paint.
I love this work.
It can be used for so many cool things! More things than it was even intended to be used for because it has so many options...!
Simply Brilliant.
Hello Mikah, Awesome work, that's really great.
Can you please upload the blendfile of the Mesh Volume + Proximity example. The one with the fluid on the stone. I'd like to study it, thanks
umm, when i use openexr for a displacement map, it comes out darker then the if i use png, and it doesnt work with openexr format properly. works fine with png but.
@blazraidr:
What version and OS you're using?
I fixed that kind of bug months ago. Just tested with latest SVN on Windows 32/64-bit and it works fine.
So either you are using a very old version of Dynamic Paint or it's something OS related. :p
oh yes, my rev is 32013, an old version i guess. I'll try the latest rev, though its probably my fault for using an old build.
Thanks very much for all 'Dynamic Paint' features and also for the Guide. I appreciate it must have been quite a bit of work. Hope to see this in Blender and the Wiki soon. :)
This is amazing, you are very talented and generous. Thank you so much for sharing this with us.
hi, how come I can't see everything that's in the advanced settings?
I use blender 2.6 build from your site and windows 7 64bit.
nevermind, I was looking at the wrong menu
PS: Wohoo! first post of 2011
would it be possible for you to post the .blend for the rain simulation.
think your work is fantastic by the way keep it up.
thanks
Miikah.
Hi Miikah,
I just stumbled across your youtube channel and found your really great emitting light example of dynamic paint...could you give a small explanation how you did that? Or even post the blend? Btw.: I really think that your documentation is very good - should be more often that developers point out, how there piece of code is intended to work! I realy appreciate your effort!
Thank you so much! Thomas
They really need to implement this in the official blender.
wow this is so amazing. wish i had known about this a long time ago. they should include this with the next release of blender.
@Pep
Oh, that's a bug on latest version. Thanks for letting me know, I'll fix it right away!
With release 39115 it works again!
Thanks for your impressive work :)
Hi miikaH..dynamic painting is amazing. I'm more into vfx. its very useful for that purpose. I tried to replicate one of your demo videos; that is selecting material object option for the paint mesh. Then i applied blender logo image as texture to it. when i baked it and rendered blender logo image texture didn't show up. only defalut material colour rendered. could be generous to tell me what went wrong?
Hey miikaH,
Great stuff.
I could not get the wetmap to work. When I bake the wetmap to a PNG all the images are black.
I'm running 2.60.4 ver 41975.
Thanks!
Hello,
you explained the options very good and have nice examples, but i miss a general step-by-step tutorial on how to set up everything. It's not easy for a beginner like me to get it working.
[please pardon my english] Great site and tutorial...synthetic and completed both! You're so crazy!
I'm trying smoke painting but i have not understand what do you say for 'To paint with smoke, you just have to use the smoke domain as a paint object. Just remember that domain has to have a renderable volumetric material.'
Could you explain, please?
CIAO
Stefano
Hi,
why did you close the sample blend files? I actual like to see them. Is there a way?
greatings, Stephan.
just getting around to checking out dynamic paint and it is AWESOME!
Hi,
Since Bmesh merge(44245) DP generates a black canvas, no matter what color material is set. Is that a known bug ?
quick question I'm wanting to make like a snow effect. As the particles fall they build upon the canvas basically the opposite of what displacement works. Is there a way to raise instead of lower. By the way awesome guide thanks i'm excited to start using this more in a short film
I checked 'use object material' in brush menu and i have sphere with red material (set both in diffuse and in clouds map texture color) but after baking canvas i get blue color shape in rendered image sequence (same color as set in 'paint color' box before checking 'use object material'). Canvas and sphere UV mapped, blender internal render set, textures added to canvas and sphere so what i need to do to get red paint (object material) on canvas baked images?
This is best article about dynamic paint in web. So bad that the samples are not downloadable anymore. I have one question: how can I render wetmap in black&white output as in your sample above? I would like to use it in cycles to make some parts of the paint overlayed with another renderings. so i need to extract the transparency from the white parts. Thank you for the help!
Hi! How do I use object material as brush when rendering using cycles? Seems as if that option is not actually available for cycles.
2013
Nice Documentation.
Blender 2.67 I had difficulty animating
Displacement Depth
You obviously know what you're doing, but some of us don't. You should have titled this a demo, not a guide, because you don't really show us the complete process. Thanks anyway for the effort.
I am a newbie and using Blender 2.69. When I went to your tutorial on Dynamic Paint Basics as you suggested and selected bake from the dynamic paint cache, it wasn't selectable. Is there something else I am missing?
Sincerely,
nice. thanks for your tutorial. this guide very useful for me.