Weight Paint Improvement

If you’ve weight painted much in Blender you know that its very common to get ugly sharp edges instead of a smooth falloff. It happens when you paint to the edge of a curved surface and some of the faces under your brush face away from your current point of view. The result is that vertices just one one side of that artificial line are painted with full strength and verts just on the other side get nothing. You can move the camera around to try to fix those areas, but they don’t go away easily and you end up making new problem areas in other places.


I suggest a change to the brush algorithm. Instead of testing the verts and faces under the brush for visibility, you could find just the visible vertex closest to the center of the brush. Then you could add all the neighbors of that vertex to a list. For each vertex in that list, check to see if it falls inside the brush (but not whether it’s visible). If it is inside the brush, add all it’s neighbors to the list to be checked. If the vertex falls outside the bounds of the brush, discard it. This would give a smooth coverage that would wrap around curved edges in predictable ways.

To measure the strength of the brush, you could find the distance from the center vertex to the test vertex. The measurement would need to be the shortest distance “along the surface” to give best results. But even a simple approximation for the distance from the center of the brush would be an improvement.

Thoughts?

Sounds like it could work, note that recent builds have the option to paint with Limit to visible disabled, can be used in combination with selection or view border clipping.

That’s good to know. I will check out that feature.

So you could disable “Limit to Visible” so that there would be no missed verts. That would introduce the new problem that you would paint a lot of verts you didn’t want. But you could then pre-select all the verts that you want to paint as a mask. That sounds tedious and convoluted, but it would get the job done better than nothing. It would be very model dependent, I suppose. On certain models this would be an improvement in workflow.

You could select the vertex in edit mode, then hit shift k to apply the weight, go back and select more untill you get the right gradient. Not as fast as direct paint, but complete control.

Also with a temp shape key, you could stretch it out and flatten as you like and paint their. When finished remove or reset the shape key.

Sorry to drag up an old thread, but I just got a Blender development environment set up. I was wondering if anyone could point me to the code where this sampling happens. There is an “editors” directory that looks promising, but I’m so new that I got lost in the code pretty quickly.

http://developer.blender.org/diffusion/B/browse/master/source/blender/editors/sculpt_paint/paint_vertex.c$871