You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-05 12:10:55 +00:00
Handle corner cases for curve baking
When control point and point have equal position, the derivative is 0 vector, which cause error message in Basis::look_at(). This commit handles this case.
This commit is contained in:
@@ -274,13 +274,10 @@ void Path3DGizmo::redraw() {
|
||||
|
||||
// Fish Bone.
|
||||
v3p.push_back(p1);
|
||||
v3p.push_back(p1 + (side - forward) * 0.06);
|
||||
v3p.push_back(p1 + (side - forward + up * 0.3) * 0.06);
|
||||
|
||||
v3p.push_back(p1);
|
||||
v3p.push_back(p1 + (-side - forward) * 0.06);
|
||||
|
||||
v3p.push_back(p1);
|
||||
v3p.push_back(p1 + up * 0.03);
|
||||
v3p.push_back(p1 + (-side - forward + up * 0.3) * 0.06);
|
||||
}
|
||||
|
||||
add_lines(v3p, path_material);
|
||||
|
||||
Reference in New Issue
Block a user