Page MenuHome

Bevel unexpected result with certain geometry
Closed, ResolvedPublic


System Information
Windows 8.1 x64
Renderer: GeForce GTX 650/PCIe/SSE2
Vendor: NVIDIA Corporation
Version: 4.4.0

Blender Version
Broken: 2.69.8 ca2a144

Short description of error
Unexpected curvature continuity break with certain geometry.

Exact steps for others to reproduce the error
Blend file:



Event Timeline

Mikhail Rachinskiy (alm) set Type to Bug.
Mikhail Rachinskiy (alm) created this task.
Mikhail Rachinskiy (alm) raised the priority of this task from to Needs Triage by Developer.

About these bevel bugs... It's just a feeling but I've not checked, but I think the modifier is using some kind of linear interpolation when filling the corners. Perhaps a polar coordinate system gives better result for the curves...

There are cases where linear interpolation is used (when certain planes line up), but this is not one of them. (There are some other outstanding bevel bugs where that is indeed the problem, and I'm working on that now.)

In the case where there are only three edges into the corner (on the right), there is special code to project the mesh onto a sphere octant, so it all works out smoothly. In the left diagram, there are more than three edges into the corner, so the special code case doesn't apply (though I agree it probably could, in this case).

The general code for rounding corners on bevel uses a subdivision algorithm. It appears that that general algorithm is not ensuring proper normal continuity. This will not be easy to fix.

@Howard Trickey (howardt), thanks, I imagine how hard is to solve this. What I mentioned was to handle the end of the edge at the corner as an arc around a central point. For example, you can calculate the central point, the radius and the angles for each edges and you can interpolate these values instead of linear coordinates. Interpolating in a polar coordinate system results arcs and spheres instead of lines and planes. For example, if the centres are matching and the radius is the same (cube corner) you can get a perfect spherical corner.

But I don't know how this bevel works exactly, so maybe I'm totally wrong.

totoro, I think you are talking about what I call the LatLng method, under "Multiple Segment Corners", on .
For reasons mentioned there, I don't think that is the best method to use.
(I have to update the material on that page under "Calculating Vertex Positions for Adj Vertex Mesh Pattern"; I use a better algorithm now, though, as this bug points out, still not good enough.)

@Howard Trickey (howardt), Thanks, that's because I know nothing about these algorithms :) But still, if there is linear interpolation somewhere in this code (for example you interpolate between two vectors), I think you could try to replace it with a polar coordinates interpolation.

Finally, I think it's already a great job and I wish you a success in solving these corner problems.

Just wanted to report the same bug and noticed it's the last known one for bevel, congrats @Howard Trickey (howardt) for making it so robust :)

Unfortunately, it is not the last known one for bevel. I'm currently working on T53459, which is taking a lot of effort to fix (end is in sight, though).
For this bug, as mentioned earlier, the problem is that I don't understand the theory of subdivision with constraints on boundary normals well enough to make the general case ensure curvature continuity.

Also as mentioned earlier, I could fix this particular case by treating corners that look like cube corners except for extra in-plane edges use the special case corner algorithm. I probably will do that.

Another answer is to add a custom normal-editing option to bevel to fix up such continuity errors by changing the loop normals. I like that idea a lot and have proposed it as an idea for the next GSoC, as I am lacking enough time to work on this right now.

@Howard Trickey (howardt) ok, I looked at and saw it was the last one. So it's soon the last one :) It's still great to see this polishing going on.

Hi @mathieu menuet (bliblubli) I've attempted to resolve this discontinuity in my branch with all possible limit methods. Hope you can test it out.

Here is the link:

Howard Trickey (howardt) closed this task as Resolved.Mar 21 2019, 12:11 PM

Rohan's GSoC fix did indeed fix this particular case and is now in master, so closing this bug.